Genesys Cloud - Main

 View Only

Sign Up

  Thread closed by the administrator, not accepting new replies.
  • 1.  External contacts - import and export

    Posted 04-14-2023 08:22
    No replies, thread closed.

    Hi,

    I need to bulk import External contacts to our system. I have a csv mostly ready, simple thing.
    But it is required to include Contact ID value in import file. And if I use some ID that already exists, the contact will be overwritten. Risk is very small, but I'd like to avoid it at all.
    So, is there any way to export existing external contacts with that ID? I tried to use API, and results give me list with each contact that has some ID, but this is different thing, some system created, like: 59367d65-ba95-4740-abc2-6b6bf0f92036.  And that contact was created as import using id I thought out, some random words and digits.
    I don't have any old files with previous contacts (other people did those).
    Any suggestions?

    Regards,
    Paweł


    #PlatformAdministration

    ------------------------------
    Pawel Dragan
    Lyreco Management SAS
    ------------------------------


  • 2.  RE: External contacts - import and export

    Posted 04-23-2023 01:17
    No replies, thread closed.

    You can use the CLI with gc externalcontacts scan contacts list or the API /api/v2/externalcontacts/scan/contacts to get a list of all the contacts.  Then you could do a compare on the files after you convert JSON to CSV



    ------------------------------
    Robert Wakefield-Carl
    ttec Digital
    Sr. Director - Innovation Architects
    Robert.WC@ttecdigital.com
    https://www.ttecDigital.com
    https://RobertWC.Blogspot.com
    ------------------------------



  • 3.  RE: External contacts - import and export

    Posted 04-25-2023 14:53
    No replies, thread closed.

    Hello Pawan,

     

    The Contact ID is effectively the external ID of the contact. We use that to handle updates to the records uploaded via CSV; as long as the Contact ID matches what we have in our system, the CSV record will be used to overwrite the existing contact.

    To extract your contacts as Robert mentioned above, you can use the scan APIs.

    scan endpoint: https://developer.genesys.cloud/commdigital/externalcontacts/externalcontacts-apis#get-api-v2-externalcontacts-scan-contacts

    more in-depth explanation of the scan APIs and how to use them: https://developer.genesys.cloud/commdigital/externalcontacts/scan

    tutorial on how to scan: https://developer.genesys.cloud/commdigital/externalcontacts/scan-external-contacts-guide

     

    As you noted, the issue with scanning is that you won't be able to retrieve Contact ID.

    We have a feature on our roadmap that will resolve this limitation, however we are at least 2 quarters away from the GA availability of this feature.

     

    In the meantime, the workaround is to compare the 

     

    Option 1 : Scanning your external contacts and running a diff on cellPhone or workPhone or PersonalEmail between your export file ( after your convert JSON to CSV) and your import CSV.

    For those entries that there's a match in your CSV, you should be able to fetch them one at a time and check the Contact ID value via the following API call ( listed as External ID in the response) : 

    GET /api/v2/externalcontacts/contacts/{id}

    using the expand=externalDataSources query param.

     Where {id} = the system created id of the entry in your export file. ( e.g. : 59367d65-ba95-4740-abc2-6b6bf0f92036. )

    This way you can eliminate those contacts that could be overwritten from your import CSV file.



    ------------------------------
    Mojdeh Toyserkani
    -----------------------------------------
    Director, Product Management - Data Platform
    Genesys - Employees
    ------------------------------