curl --request PUT \
--url https://app.loops.so/api/v1/contacts/update \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"email": "<string>",
"userId": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"source": "<string>",
"subscribed": true,
"userGroup": "<string>",
"mailingLists": {}
}
'{
"success": true,
"id": "id_of_contact"
}
Update or create a contact.
curl --request PUT \
--url https://app.loops.so/api/v1/contacts/update \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"email": "<string>",
"userId": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"source": "<string>",
"subscribed": true,
"userGroup": "<string>",
"mailingLists": {}
}
'{
"success": true,
"id": "id_of_contact"
}
userId value. You can then make a request containing the userId field
along with an updated email address.email or userId to identify the contact you want to update.email or userId value. If a contact is found for one of the
values (e.g. email), the other value (e.g. userId) will be updated. If a
contact is not found, a new contact will be created using both email and
userId values.userId is not provided.email is not provided.subscribed: true in your update calls, contacts who have
previously unsubscribed will be re-subscribed. We recommend leaving this
field out of your requests unless you specifically want to unsubscribe or
re-subscribe a contact.boolean denoting if the contact should be added (true) or removed (false) from the list. Read
more"mailingLists": {
"cm06f5v0e45nf0ml5754o9cix": true,
"cm16k73gq014h0mmj5b6jdi9r": false
}
string, number, boolean or date (see allowed date formats).
{
"email": "hello@gmail.com",
"plan": "pro" /* Custom property */,
"favoriteColor": "Blue" /* Custom property */
}
null value.400 Bad Request.
{
"success": true,
"id": "id_of_contact"
}
Was this page helpful?