# Add tag ID to new contact

**URL:** https://integration.keap.com/t/add-tag-id-to-new-contact/73271
**Category:** API Q&A
**Created:** [December 4, 2019, 6:00pm UTC](https://integration.keap.com/t/add-tag-id-to-new-contact/73271 "2019-12-04T18:00:45Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Sam\_Baitz](https://sea1.discourse-cdn.com/flex019/user_avatar/integration.keap.com/sam_baitz/32/1919_2.png) [@Sam\_Baitz](https://integration.keap.com/u/Sam_Baitz)
#### Post date: [December 4, 2019, 6:00pm UTC](https://integration.keap.com/t/add-tag-id-to-new-contact/73271/1 "2019-12-04T18:00:45Z")

</div>

I’ve got a wordpress form that sends a new lead to the contact list. This is all working perfectly:

Get the keys \> build the data array \> send the data \> post thank you message

What I want to do is add a tag to the new contact but there doesn’t seem to be a simple way to do this. One thread says I need a separate API call and the documentation will be updated to reflect this but it doesn’t appear to have happened.

In any case, adding a new contact doesn’t return the contact ID. I’m using:

$infusionsoft-\>contacts(‘xml’)-\>add($fields);

Where $fields is the data array.

Any clues as to how to fix this?

---

<div class="post-metadata">

### Author: ![bradb](https://sea1.discourse-cdn.com/flex019/user_avatar/integration.keap.com/bradb/32/13_2.png) [@bradb](https://integration.keap.com/u/bradb)
#### Post date: [December 13, 2019, 6:31am UTC](https://integration.keap.com/t/add-tag-id-to-new-contact/73271/2 "2019-12-13T06:31:23Z")

</div>

The API definitely returns the contact id on add, but maybe the SDK is not exposing this. I am not a PHP guy, but if you can get the raw XML response you should be able to get it.
