# Mautic always create anonymous contact when create contact by API

**URL:** <https://forum.mautic.org/t/mautic-always-create-anonymous-contact-when-create-contact-by-api/21351>\
**Category:** Product Support\
**Tags:** mautic-3, mautic-4\
**Created:** [October 21, 2021, 4:29pm UTC](https://forum.mautic.org/t/mautic-always-create-anonymous-contact-when-create-contact-by-api/21351 "2021-10-21T16:29:12Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![dungnt23](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/dungnt23/32/6072_2.png) [@dungnt23](https://forum.mautic.org/u/dungnt23)\
**Post date:** [October 21, 2021, 4:29pm UTC](https://forum.mautic.org/t/mautic-always-create-anonymous-contact-when-create-contact-by-api/21351/1 "2021-10-21T16:29:12Z")

</div>

**Your software**  
My Mautic version is: 3.3.3 / 4.0.1  
My PHP version is: 7.4.24  
My Database type and version is: mysql

**Your problem**  
My problem is: Create contact by api - mautic always create Anonymous contact

These errors are showing in the log: no error code, code 200  
10.32.59.58 - user123 [30/Sep/2021:09:58:20 +0700] “POST /api/contacts/new HTTP/1.1” 200 7069 “-” “-” “-”

Steps I have tried to fix the problem:  
Step1: from only 1 VM : example : 10.10.x.x  
Send API to Mautic server with api : mautic.test.com.vn/api/contacts/new

```auto
{"birthday": "01/01/1995", "title": "Mrs", "firstname": "HA", "lastname": "", "email": "baoanh@hotmail.com", "mobile": "094123123123", "phone": "", "fax": "", "website": "", "address1": "hcm", "address2": "hcm", "city": "", "country": "Vietnam"}

```

Step2 : check Mautic UI \>\> tab Contact : only anonymous contact has been created .

 ![Clipboard - October 14, 2021 1_45 PM](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/d/db3b87867144e33318be4072f7b4f1423b903ed0.png)

More detail :

- Mautic server enable API & enable basic authen
- keep default all config
- tried clean cache and the same issue
- tried restart mautic and the same issue
- happen when deploy from source.zip ( v3.3.3 + v4.0.1 ) / docker already the same issue ( image: mautic/mautic:v4)

Please let me know anything if config is incorrect

---

<div class="post-metadata">

**Author:** ![joeyk](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/joeyk/32/11164_2.png) [@joeyk](https://forum.mautic.org/u/joeyk)\
**Post date:** [October 21, 2021, 5:29pm UTC](https://forum.mautic.org/t/mautic-always-create-anonymous-contact-when-create-contact-by-api/21351/2 "2021-10-21T17:29:25Z")

</div>

Hi!  
Could you plz show the event history of a contact like this?

---

<div class="post-metadata">

**Author:** ![dungnt23](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/dungnt23/32/6072_2.png) [@dungnt23](https://forum.mautic.org/u/dungnt23)\
**Post date:** [October 27, 2021, 7:53am UTC](https://forum.mautic.org/t/mautic-always-create-anonymous-contact-when-create-contact-by-api/21351/3 "2021-10-27T07:53:39Z")

</div>

actually, i do not have screenshot here, but the event history of that anonymous contact is so clear, just a name of user create that contact via API.

as You know , when create a real contact by api, we can see some event history like :

- created by user-create
- id
- …

---

<div class="post-metadata">

**Author:** ![jaymac](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/jaymac/32/6126_2.png) [@jaymac](https://forum.mautic.org/u/jaymac)\
**Post date:** [October 29, 2021, 2:15am UTC](https://forum.mautic.org/t/mautic-always-create-anonymous-contact-when-create-contact-by-api/21351/4 "2021-10-29T02:15:06Z")

</div>

Have you tried clearing the cache? I had this problem as well.
