Migrate Distinct Id
Re-keys a contact from one distinct ID to another, carrying their properties and history across. The usual case is promoting a soft identity to a real one: someone first seen by email gets a soft_-prefixed ID, and when they later sign in you migrate that to your own user ID so the two do not persist as separate contacts. Rewriting the analytics history is expensive, so this is not a bulk operation.
Authorization
Authorization In: header
Path Parameters
ID of the project that owns the contact.
Request Body
application/json
The distinct ID to move the contact to, typically your own user ID.
The contact's current distinct ID, often a generated soft_ one.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://www.saasco.com/api/v2/projects/string/crm/contacts/migrate-distinct-id" \ -H "Content-Type: application/json" \ -d '{ "newDistinctId": "string", "oldDistinctId": "string" }'{
"id": "string",
"createdAt": "string",
"updatedAt": "string",
"projectId": "string",
"distinctId": "string",
"email": "string",
"toDelete": true
}{
"code": "BAD_REQUEST",
"message": "Invalid input data",
"issues": []
}{
"code": "UNAUTHORIZED",
"message": "Authorization not provided",
"issues": []
}{
"code": "FORBIDDEN",
"message": "Insufficient access",
"issues": []
}{
"code": "INTERNAL_SERVER_ERROR",
"message": "Internal server error",
"issues": []
}Count Subscribed
Counts how many contacts match an audience *and* are still subscribed: the number that would actually receive a campaign, which is lower than a plain contact count once unsubscribes are excluded. Use it to size an audience before sending. Returns only the count, so it is much cheaper than paging List Contacts.
List Attributes
Lists the contact attributes defined in this project: the property names available to filter and segment on, with their inferred types. Custom attributes appear once a contact has been written with that property; set `includeSystemAttributes` to also get Saasco's built-in `$`-prefixed ones.