--- title: Customer Service API slug: '3321' canonical_url: https://docs.coveo.com/en/3321/ collection: apis source_format: adoc --- # Customer Service API ## What's the Coveo Customer Service API? The Customer Service API exposes endpoints which allow you to retrieve document and classification suggestions while a support case is being created. **Example** A client is creating a support case with the title `GC110 malfunction` and the description `My GC110 electrical panel is cutting off intermittently`. You have previously created a document suggestions configuration to request suggestions for the type of issues that your end users create. You make the following request to the Customer Service API: ```http POST https://platform.cloud.coveo.com/rest/organizations/myorganizationid9sd8df7s/caseassists/myc45ea55-isti-d9d5-8f1d-81be8e739b70/documents/suggest HTTP/1.1 Authorization: Bearer ********-****-****-************ ``` **Payload:** ```json { "clientId": "04850f2-ee0d-47a9-aff5-39ee47f294f9", "fields": { "subject": { "value": "GC110 malfunction" }, "description": { "value": "My GC110 electrical panel is cutting off intermittently" } }, "analytics": { "capture": true } } ``` The API returns the following payload: ```json { "documents": [ { "title": "GC110 Series Electrical Panel Troubleshooting", "uniqueId": "84.72597$https://na174.salesforce.com/5017g000000vLFgBCM:2", "hasHtmlVersion": true, "clickUri": "https://na174.salesforce.com/5017g000000vLFgBCM", "excerpt": "The GC110 series electrical panel needs to be reset using the following process if it begins to turn on and off without warnin...", "fields": { "syssfcreatedbyid": "0056g001172vCuBMAU", "sfsystemmodstamp": 1578952955001, ... } } ], "responseId": "2394cnd8-8dnc-3nc9-k432-9dn2nd8f93nd", "totalCount": 1 } ``` You then suggest that solution item to the client before they even finish creating their case, resulting in case deflection! ## When Should I Use the Coveo Customer Service API? The [Coveo for ServiceNow Case Deflection panel](https://docs.coveo.com/en/2111/) and [Coveo for Salesforce Case Deflection component](https://docs.coveo.com/en/1163/) provide features that overlap with the Service API. These built-in case deflection widgets are difficult to customize, so you should use the Service API whenever they don't meet your needs out of the box and would require customization. You should [manage your document and classification suggestion configurations though the Coveo Administration Console](https://docs.coveo.com/en/3328/), and use the API directly only to retrieve document and case classification suggestions. If you're working in the Salesforce environment, use the dedicated [Coveo Quantic Case Assist components](https://docs.coveo.com/en/quantic/latest/reference/case-assist-components), as they will handle most of the complexity for you. Outside of the Salesforce environment, use the dedicated [Coveo Headless Case Assist controllers](https://docs.coveo.com/en/headless/latest/reference/modules/Case_Assist.html), which wrap Customer Service API calls and also handle logging usage analytics events for you. ## Where Should I Start? To learn how to configure case classifications and document suggestions, see [Manage Case Assist Configurations](https://docs.coveo.com/en/3328/). To learn how to retrieve case classifications and document suggestions, see the [Usage page](https://docs.coveo.com/en/3326/). You may also want to check out the interactive reference documentation available through [Swagger UI](https://platform.cloud.coveo.com/docs?urls.primaryName=Customer%20Service). ## Related Documentation - [Manage Case Assist Configurations Using the Coveo Administration Console](https://docs.coveo.com/en/3328/) - [Coveo Quantic Case Assist components](https://docs.coveo.com/en/quantic/latest/reference/case-assist-components/)