Create a Contact List with an Unique Identifier Column assigned

Greetings,

Trying to mass create contact lists for a project. One of the columns is to be an Unique Identifier or "custom-id" for added records.

I know that when adding records you signal the UID with the data.custom-id property, as per https://developer.mypurecloud.com/forum/t/able-to-set-id-using-api-to-add-contacts-to-list/2452/2

However I can't find any details on how to preemptively signal a column as the recipient for UIDs.-

Is this solely managed by setting the custom ID when creating records? Isn't there a property or something that can be used in the ContactList structure?

For example, something like:

{
    "name": file[i].contactListName,
    "version": 0,
    "columnNames": [
      "tel_cel1",
      "tel2",
      "id_unico_interaccion",
      "id_proxima_interaccion",
      "zone",
      "aux1",
      "aux2",
      "aux3"
    ],
    "data": {
        "columnName": "id_unico_interaccion",
        "type": "custom-id"
    },
    "phoneColumns": [
      {
        "columnName": "tel_cel1",
        "type": "Cell",
        "callableTimeColumn": "zone"
      },
      {
        "columnName": "tel2",
        "type": "Home",
        "callableTimeColumn": "zone"
      }
    ],
    "automaticTimeZoneMapping": false
 };

Regards,

I don't believe you can specify a custom ID when you create the contact list. You can only specify that column when creating via the UI, adding via the API as described in the post you linked, or when uploading contact lists. You can request new features and share your use case at https://genesyscloud.ideas.aha.io/.

Hi Tim,

We are basically doing this:

Quoting:
https://developer.mypurecloud.com/api/rest/v2/outbound/uploadcontactlists.html

Overview

After creating a contact list using the POST /api/v2/outbound/contactlists/{contactListId}/contacts API, records can be uploaded to the list by importing CSV files.

We are at the step of creating the Contact List, so basically I'm understanding that you create the List without designing the ID column, and when you start uploading (be it record by record or whole files) you assign the ContactID.

Correct?

Furthermore, going by your first answer I've been trying to add records to Contact Lists, through POST - /api/v2/outbound/contactlists/{contactListId}/contacts

Using lists both created through API first, without signaling any "custom-id" and also in Contact Lists that were created through the GUI using a column as ContactId.

In neither cases was I able to add a record adding the data.custom-id structure:
I was able to update an existing record, though.

Does any of these formats seem valid?

{
  "id": "0102030305060708090a0b0c0d0e0f",
  "contactListId": "9422b3f7-02c5-4076-80f7-0917e3251642",
  "data": {
    "telefono_cel1": "01564917288",
    "telefono_cel2": "01654324321",
    "telefono_cel3": ""
    "id_unico_interaccion": "0102030305060708090a0b0c0d0e0f",
    "id_proxima_interaccion": "0000030305060708090a0b0c000000",
    "zone": "America/Argentina/Buenos_Aires",
    "aux1": "39",
    "aux2": "aux2-001",
    "aux3": "aux3-012"
  },
  "callable": true
}

or

{
  "id": "0102030305060708090a0b0c0d0e0f",
  "contactListId": "9422b3f7-02c5-4076-80f7-0917e3251642",
  "data": {
    "custom-id": "0102030305060708090a0b0c0d0e0f",
    "telefono_cel1": "01564917288",
    "telefono_cel2": "01654324321",
    "telefono_cel3": ""
    "id_proxima_interaccion": "0000030305060708090a0b0c000000",
    "zone": "America/Argentina/Buenos_Aires",
    "aux1": "39",
    "aux2": "aux2-001",
    "aux3": "aux3-012"
  },
  "callable": true
}

(Note the missing "id_unico_interaccion")

or

{
  "id": "0102030305060708090a0b0c0d0e0f",
  "contactListId": "9422b3f7-02c5-4076-80f7-0917e3251642",
  "data": {
    "custom-id": "0102030305060708090a0b0c0d0e0f",
    "name": "id_unico_interaccion",
    "telefono_cel1": "01564917288",
    "telefono_cel2": "01654324321",
    "telefono_cel3": ""
    "id_proxima_interaccion": "0000030305060708090a0b0c000000",
    "zone": "America/Argentina/Buenos_Aires",
    "aux1": "39",
    "aux2": "aux2-001",
    "aux3": "aux3-012"
  },
  "callable": true
}

(this variant includes the "name", mentioned in https://developer.mypurecloud.com/forum/t/able-to-set-id-using-api-to-add-contacts-to-list/2452)
or

{
  "id": "0102030305060708090a0b0c0d0e0f",
  "contactListId": "9422b3f7-02c5-4076-80f7-0917e3251642",
  "data": {
    "custom-id": "0102030305060708090a0b0c0d0e0f",
    "telefono_cel1": "01564917288",
    "telefono_cel2": "01654324321",
    "telefono_cel3": ""
    "id_unico_interaccion": "0102030305060708090a0b0c0d0e0f",
    "id_proxima_interaccion": "0000030305060708090a0b0c000000",
    "zone": "America/Argentina/Buenos_Aires",
    "aux1": "39",
    "aux2": "aux2-001",
    "aux3": "aux3-012"
  },
  "callable": true
}

This variant includes the id, the custom-id, and the "id_unico_interaccion".

None of this options worked.

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.