Create Relation.Documentation Link - https://doc.clickup.com/8631005/d/h/87cpx-293776/cd0f4122abc04d3

http
POST https://services.leadconnectorhq.com/associations/relations

Authorization

NameTypeRequiredExampleDescription
AuthorizationstringYesBearer token generated from the Leadway portal. See Authentication.
VersionstringYes2021-07-28API version.

Body

NameTypeRequiredExampleDescription
locationIdstringYesclF1LD04GTUKN3b3XuOjYour Sub Account's ID
associationIdstringYesve9EPM428h8vShlRW1KTAssociation's Id
firstRecordIdstringYesve9EPM428h8vShlRW1KTFirst Record's Id. For instance, if you have an association between a contact and a custom object, and you specify the contact as the first object while creating the association, then your firstRecordId would be the contactId
secondRecordIdstringYesve9EPM428h8vShlRW1KTSecond Record's Id.For instance, if you have an association between a contact and a custom object, and you specify the custom object as the second entity while creating the association, then your secondRecordId would be the customObject record Id

Responses

201 - Successful response
  • locationId (string, required): Example: string

  • id (string, required): Example: ve9EPM428h8vShlRW1KT

  • key (string, required): First Objects Association Label (custom_objects.children) Example: student

  • firstObjectLabel (object, required): First Objects Association Label (custom_objects.children) Example: student

  • firstObjectKey (object, required): First Objects Key Example: custom_objects.children

  • secondObjectLabel (object, required): Second Object Association Label (contact) Example: Teacher

  • secondObjectKey (object, required): Second Objects Key Example: contact

  • associationType (object, required): Association Type can be USER_DEFINED or SYSTEM_DEFINED Example: USER_DEFINED

json
{
  "locationId": "string",
  "id": "ve9EPM428h8vShlRW1KT",
  "key": "student",
  "firstObjectLabel": "student",
  "firstObjectKey": "custom_objects.children",
  "secondObjectLabel": "Teacher",
  "secondObjectKey": "contact",
  "associationType": "USER_DEFINED"
}
400 - Bad Request
json
{}
401 - Unauthorized
json
{}
422 - Unprocessable Entity
json
{}

Example

curl -X POST 'https://services.leadconnectorhq.com/associations/relations' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Version: 2021-07-28' \
  -H 'Content-Type: application/json' \
  -d '{
  "locationId": "clF1LD04GTUKN3b3XuOj",
  "associationId": "ve9EPM428h8vShlRW1KT",
  "firstRecordId": "ve9EPM428h8vShlRW1KT",
  "secondRecordId": "ve9EPM428h8vShlRW1KT"
}'

Last updated October 26, 2026

Was this page helpful?