Conga Product Documentation

Welcome to the new doc site. Some of your old bookmarks will no longer work. Please use the search bar to find your desired topic.

Manage Object Records using External ID

An External ID is a unique identifier used to maintain relationships between records in the Conga Advantage Platform and external systems. It serves as a consistent reference across systems, enabling seamless data synchronization and integration without depending on Conga's internal ID values.

To support managing object records using External ID field, a few APIs are enhanced and newly introduced. For more information, see the following sections.

Enhanced APIs

The following Data APIs are enhanced to support External ID field.

Note:

Prerequisite: The IsExternalIdValidationEnabled configuration flag is true.

  • To check the configuration flag value, use the GET {baseURL}/api/config-management/v1/configurations/{category}/{name} endpoint and pass the category as Platform and name as IsExternalIdValidationEnabled.

  • To update the configuration flag value, use the PUT {baseURL}/api/config-management/v1/configurations endpoint and pass the category, name,and value as the Platform, IsExternalIdValidationEnabled, and true respectively.

  1. POST {baseURL}/api/data/v1/custom-objects/{objectName}/{id} and POST {baseURL}/api/data/v1/custom-objects/{objectName}/bulk - Create new record(s) using the ID and/or external ID field values, passed in the payload, to create new record(s).

    Refer to the following table to understand the behavior when you pass ID and/or external ID:

    ID in payload?External ID in payload?BehaviorValidation
    YesYesCreate a record using the ID field value as provided in the payload, and ensure the externalId is unique.ExternalId unique validation
    YesNoCreate a record using the ID field value as provided in the payload and set the externalId to null.NA
    NoYesGenerate a new GUID and create a record using the ID field value with the new GUID value.ExternalId unique validation
    NoNoGenerate a new GUID and create a record using the ID field value with the new GUID value and set the externalId to null.NA
  2. PUT {baseURL}/api/data/v1/custom-objects/{objectName}/{id} - Update the record using the ID parameter, and ensure the externalId is unique whenever the value is changed.

  3. DELETE {baseURL}/api/data/v1/custom-objects/{objectName}/bulk - Delete a record using ID or an external ID filed. For this, a new parameter, DeleteByField, with Id and ExternalId options is added.

  4. PUT {baseURL}/api/data/v1/custom-objects/{objectName}/bulk - Update records using ID or external ID field. For this, a new parameter, UpdateByField, with Id and ExternalId options is added. Refer to the following tables for each option's behavior.

    Refer to the following table to understand the behavior when you want to update records by ID field.

    ID in payload?External ID in payload?BehaviorValidation
    YesYesUpdate the record using the ID if it exists, and ensure the externalId is unique.ExternalId unique validation
    YesNoUpdate the record using the ID if it exists, and externalId will remain tha same.NA
    NoYesInvalid scenario. Throw a validation error.Throw a validation error if the ID is not found, indicating that the ID must exist.
    NoNoInvalid scenario. Throw a validation error.NA

    Refer to the following table to understand the behavior when you want to update records by externalId field.

    ID in payload?External ID in payload?BehaviorValidation
    YesYesUpdate the record using the externalId if it exists.The record's ID must match the ID provided in the payload. If not, give an error. Do not allow the ID to be updated in any case.
    YesNoInvalid scenario. Throw a validation error.Throw a validation error indicating that the externalId must exist.
    NoYesUpdate the record using the externalId if it exists.ExternalId unique validation
    NoNoInvalid scenario. Throw a validation error.Throw a validation error indicating that the externalId must exist.
  5. PATCH {baseURL}/api/data/v1/custom-objects/{objectName}/bulk - Upsert records using ID or external ID field. For this, a new parameter, UpdateByField, with Id and ExternalId options is added. Refer to the following tables for each option's behavior.

    Refer to the following table to understand the behavior when you want to upsert records by ID field.

    ID in payload?External ID in payload?BehaviorValidation
    YesYesUpdate the record using the ID if it exists, and ensure the externalId is unique.ExternalId unique validation
    YesNoUpdate the record using the ID if it exists, and externalId will remain tha same.NA
    NoYesGenerate a new GUID to use as the ID, create a new record with ID, and ensure the externalId is unique.ExternalId unique validation
    NoNoGenerate a new GUID to use as the ID, create a new record with ID, and ensure the externalId remains null.NA

    Refer to the following table to understand the behavior when you want to upsert records by externalId field.

    ID in payload?External ID in payload?BehaviorValidation
    YesYesUpdate the record using the externalId if it exists.The record's ID must match the ID provided in the payload. If not, give an error. Do not allow the ID to be updated in any case.
    YesNoUpdate the record using the ID if it exists, keeping externalId unchanged. If the ID does not exist, create a new record with that ID, and set the externalId to null.NA
    NoYesUpdate the record using the externalId if it exists.ExternalId unique validation
    NoNoGenerate a new GUID to use as the ID, create a new record with ID, and ensure the externalId remains null.NA

New APIs

The following Data APIs are newly introduced to support the external ID field.

Note:

There is no dependency on the IsExternalIdValidationEnabled configuration flag.

  1. PUT {baseURL}/api/data/v1/custom-objects/{objectName}/by-externalId/{externalId} - Update a record using an external ID.

    Refer to the following table to understand the behavior when you pass ID along with the external ID in the payload.

    ID in payload?BehaviorValidation
    YesUpdate a record by externalIdThe record's ID must match the ID provided in the payload. If not, give an error. Do not allow the ID to be updated in any case.
    NoUpdate a record by externalIdNA
  2. GET {baseURL}/api/data/v1/custom-objects/{objectName}/by-externalId/{externalId} - Fetch a record using an external ID.

  3. DELETE {baseURL}/api/data/v1/custom-objects/{objectName}/by-externalId/{externalId} - Delete a record using an external ID.