openapi: 3.0.1
info:
title: Coveo Activity Activities Case Assist API
description: API for Coveo Platform
termsOfService: https://www.coveo.com/en/support/terms-agreements
contact:
name: Coveo
url: https://connect.coveo.com/s/discussions
version: 1.0.0
servers:
- url: https://platform.cloud.coveo.com
description: Coveo public API endpoint
security:
- oauth2:
- full
tags:
- name: Case Assist
x-displayName: Case Assist
paths:
/rest/organizations/{organizationId}/caseassists/{caseAssistId}:
get:
tags:
- Case Assist
summary: Show Case Assist Configuration
description: Shows a case assist configuration in a [Coveo Cloud organization](https://docs.coveo.com/en/185/).
Required privilege: Customer Service - Case assist configuration - View
operationId: getCaseAssistConfiguration
parameters:
- name: organizationId
in: path
description: The unique identifier of the target [organization](https://docs.coveo.com/en/185/).
Example: `mycoveocloudv2organizationg8tp8wu3`
required: true
schema:
type: string
- name: caseAssistId
in: path
description: The unique identifier of the target case assist configuration.
Example: `812efd5e-a7e3-49d5-8f1d-81be8e739b70`
required: true
schema:
type: string
responses:
'200':
description: OK
content:
'*/*':
schema:
$ref: '#/components/schemas/RestCaseAssistConfigurationResponse'
deprecated: false
security:
- oauth2:
- full
put:
tags:
- Case Assist
summary: Update Case Assist Configuration
description: Updates a case assist configuration in a [Coveo Cloud organization](https://docs.coveo.com/en/185/).
Required privilege: Customer Service - Case assist configuration - Edit
operationId: updateCaseAssistConfiguration
parameters:
- name: organizationId
in: path
description: The unique identifier of the target [organization](https://docs.coveo.com/en/185/).
Example: `mycoveocloudv2organizationg8tp8wu3`
required: true
schema:
type: string
- name: caseAssistId
in: path
description: The unique identifier of the target case assist configuration.
Example: `812efd5e-a7e3-49d5-8f1d-81be8e739b70`
required: true
schema:
type: string
requestBody:
content:
'*/*':
schema:
$ref: '#/components/schemas/RestCaseAssistConfigurationRequest'
required: true
responses:
'204':
description: No Content
content: {}
deprecated: false
security:
- oauth2:
- full
x-codegen-request-body-name: body
delete:
tags:
- Case Assist
summary: Delete Case Assist Configuration
description: Deletes a case assist configuration in a [Coveo Cloud organization](https://docs.coveo.com/en/185/).
Required privilege: Customer Service - Case assist configuration - Edit
operationId: deleteCaseAssistConfiguration
parameters:
- name: organizationId
in: path
description: The unique identifier of the target [organization](https://docs.coveo.com/en/185/).
Example: `mycoveocloudv2organizationg8tp8wu3`
required: true
schema:
type: string
- name: caseAssistId
in: path
description: The unique identifier of the target case assist configuration.
Example: `812efd5e-a7e3-49d5-8f1d-81be8e739b70`
required: true
schema:
type: string
responses:
'204':
description: No Content
content: {}
deprecated: false
security:
- oauth2:
- full
/rest/organizations/{organizationId}/caseassists/{caseAssistId}/classify:
post:
tags:
- Case Assist
summary: Request Classifications
description: Requests field value suggestions for a case.
Required privilege: Customer Service - Use case assist - Allowed
operationId: postClassify
parameters:
- name: organizationId
in: path
description: The unique identifier of the target [organization](https://docs.coveo.com/en/185/).
Example: `mycoveocloudv2organizationg8tp8wu3`
required: true
schema:
type: string
- name: caseAssistId
in: path
description: The unique identifier of the target case assist configuration.
Example: `812efd5e-a7e3-49d5-8f1d-81be8e739b70`
required: true
schema:
type: string
- name: debug
in: query
description: Whether to include an execution report for debugging purposes.
schema:
type: boolean
default: false
requestBody:
content:
'*/*':
schema:
$ref: '#/components/schemas/RestCaseAssistContext'
required: true
responses:
'200':
description: OK
content:
'*/*':
schema:
$ref: '#/components/schemas/RestClassification'
deprecated: false
security:
- oauth2:
- full
x-codegen-request-body-name: body
/rest/organizations/{organizationId}/caseassists/preview/classify:
post:
tags:
- Case Assist
summary: Request Classifications Preview
description: Requests field value suggestions preview for a case and configuration.
Required privilege:
)-formatted GUID. You will need to send this ID as `analytics.clientId` in every event that is sent to Coveo UA and the Search API.
Coveo Machine Learning models may use this information to provide contextually relevant output.
**Note** The `clientId` replaces the deprecated `visitorId`. For compatibility, the cookie and local storage values are still named `coveo_visitorId`.'
documentLocation:
type: string
description: 'The URL of the current page or component.
If not present, the referrer is obtained from the [Referer](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Referer) header.
**Note**: This information can be obtained from `coveo.analytics.js`.'
documentReferrer:
type: string
description: 'Typically the URL of the page that linked to the search interface from which the request originates (e.g., in JavaScript, this would correspond to the `document.referrer` value).
Coveo Machine Learning models may use this information to provide contextually relevant output.
**Note**: This information can be obtained from `coveo.analytics.js`.'
pageId:
description: 'A GUID representing the page ID.
**Note**: This information can be obtained from `coveo.analytics.js`.'
anyOf:
- type: string
nullable: true
- type: integer
userIp:
type: string
description: 'The user IP. If not present, the IP is obtained from the [X-Forwarded-For](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-For) and [Forwarded](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Forwarded) headers.
**Note**: This information is required when endpoints are behind a proxy.
**Example**: `127.0. 0.1`'
clientRequestId:
type: string
description: 'A GUID generated by the client representing the current request.
This information is used to identify operations across different apis related to the same request.'
clientTimestamp:
type: string
description: Client ISO 8601 timestamp with milliseconds.
userAgent:
type: string
description: 'The user agent of the request. If not present, the user agent is obtained from the [User-Agent](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/User-Agent) header.
**Note**: This information is required when endpoints are behind a proxy.'
actionCause:
type: string
description: 'The type of operation that triggered this event.
See [Standard actions and Usage Analytics reference](docs.coveo.com/en/1389)).'
example: facetSelect
originContext:
type: string
example: CommunitySearch
description: The origin of the event. Used to specify the deployment from which the user performs the action. Suggested values are Search, InternalSearch, CommunitySearch, or the originLevel1 value
customData:
type: object
description: 'The user defined dimensions and their values. Keys can only contain alphanumeric or underscore characters.
Whitespaces in keys are converted to underscores. Uppercase characters in keys are converted to lowercase characters.
The value could be any valid JSON, but it is handled as string over Coveo usage analytics. It is highly recommended that you
create your custom dimension before adding customData'
configId:
type: string
description: 'An optional external reference to a use-case specific search configuration.
These configurations are maintained by LOBs and the search api has no knowledge of them.
This field can be used by LOBs to break down search statistics in LOB specific reporting.
This field is not present on non-captured search calls.'
source:
description: Defines one or more client side libraries that generated the analytics event. The format should be the library's name followed by '@', and then the version. For example, '[custom.library.js@2.0.0]'.
type: array
items:
type: string
x-coveo-internal: true
RestCaseAssistContext:
type: object
properties:
analytics:
$ref: '#/components/schemas/Analytics'
visitorId:
$ref: '#/components/schemas/visitorId'
clientId:
$ref: '#/components/schemas/clientId'
locale:
$ref: '#/components/schemas/locale'
fields:
$ref: '#/components/schemas/Fields'
context:
$ref: '#/components/schemas/ContextAttributes'
RestDocumentSuggestions:
required:
- documents
- responseId
- totalCount
type: object
properties:
documents:
type: array
description: The document suggestions.
items:
required:
- clickUri
- excerpt
- fields
- hasHtmlVersion
- title
- uniqueId
type: object
properties:
title:
type: string
description: The document title.
example: GC3000 Series Propane Generator Ignition
clickUri:
type: string
description: The document clickable URI.
example: http://www.salesforce.com/org:organization/object:Solution/record:5013h000000tPmnAAE
excerpt:
type: string
description: An excerpt from the document.
example: The GC3000 series propane generators need to be started up using the following process if the ignition fails at the first try
uniqueId:
type: string
description: The unique ID of the document.
example: 84.72597$http://www.salesforce.com/org:organization/object:Solution/record:5013h000000tPmnAAE:2
hasHtmlVersion:
type: boolean
description: Whether the index contains an HTML version of this item.
example: true
fields:
type: object
properties:
title:
type: string
example: GC3000 Series Propane Generator Ignition
urihash:
type: string
example: EFQOedWwU1M5af37
'...':
type: object
example: '...'
description: The `raw` fields of the item.
totalCount:
type: integer
description: The total number of suggestions.
format: int32
example: 1
responseId:
type: string
description: The unique identifier of the response.
example: 123e4567-e89b-12d3-a456-426614174000
RestCaseAssistConfigurationRequest:
required:
- name
type: object
properties:
name:
type: string
description: The name of the case assist configuration.
example: myCaseAssistConfiguration
documentSuggestionConfiguration:
$ref: '#/components/schemas/RestDocumentSuggestionConfiguration'
classificationConfigurations:
type: array
items:
$ref: '#/components/schemas/RestClassificationConfiguration'
description: A case assist configuration.
ContextAttributes:
type: object
additionalProperties:
type: string
description: The value of the attribute.
example: GC3000 Series
description: A dictionary where each key is the name of a context attribute that pertains to the target case, and each value is a string that describes the content of that context attribute.
example:
product: Propane Generator
subproduct: GC3000 Series
RestCaseAssistConfigurationResponse:
required:
- classificationConfigurations
- id
- name
type: object
properties:
id:
type: string
description: The unique identifier of the case assist configuration.
example: d9ff783c-574f-4d22-838c-df2c18a0c2b3
name:
type: string
description: The name of the case assist configuration.
example: myCaseAssistConfiguration
documentSuggestionConfiguration:
$ref: '#/components/schemas/RestDocumentSuggestionConfiguration'
classificationConfigurations:
type: array
items:
$ref: '#/components/schemas/RestClassificationConfiguration'
description: A case assist configuration.
RestListOfCaseAssistConfigurations:
required:
- configurations
type: object
properties:
configurations:
type: array
items:
$ref: '#/components/schemas/RestCaseAssistConfigurationResponse'
totalEntries:
type: integer
description: The total number of configurations.
format: int32
example: 1
totalPages:
type: integer
description: The total number of pages.
format: int32
example: 1
Fields:
type: object
additionalProperties:
type: object
properties:
value:
type: string
description: The value of the field.
example: My GC3000 series propane generator won't start
description: 'A dictionary where each key is the name of a field that pertains to the target case, and each value is an object that describes the content of that field.
Example: `{"subject": {"value": "GC3000 won''t start"}, "description": {"value": "My GC3000 series propane generator won''t start"}`}'
example:
subject:
value: GC3000 won't start
description:
value: My GC3000 series propane generator won't start
visitorId:
type: string
description: A GUID which represents the current user, who can either be authenticated or anonymous.
visitorId is deprecated and has been replaced by clientId in newer versions of the Coveo UI libraries. For compatibility, the new first-party cookie and local storage values are still named coveo_visitorId.
For older versions of the JavaScript Search Framework, the visitor ID is generated by the Coveo Usage Analytics service and stored in a non-expiring third-party cookie. Note: Third-party cookies have also been deprecated. This is unrelated to the deprecation of visitorId.
example: 5cb98953-9c13-42ff-8176-e6fcba6a50bf
PreviewClassificationRequest:
required:
- configuration
- fields
type: object
properties:
allOf:
- $ref: '#/components/schemas/RestCaseAssistContext'
configuration:
$ref: '#/components/schemas/CaseClassificationConfiguration'
clientId:
type: string
description: The clientId identifies a user on a browser of a Coveo-powered search page and provides insight into the events they performed
example: 5cb98953-9c13-42ff-8176-e6fcba6a50bf
locale:
type: string
description: The locale of the current user. Must comply with IETF's BCP 47 definition.
Coveo Machine Learning models use this information to provide contextually relevant output. Moreover, this information can be referred to in query expressions and QPL statements by using the $locale object.
Note: When logging a Search Usage Analytics event, the language field of that event should match the language part of the locale value of the query (e.g., en-US in locale becomes en in language).
example: en-US
RestCaseAssistConfigurationWithProjectResponse:
allOf:
- $ref: '#/components/schemas/RestCaseAssistConfigurationResponse'
- type: object
properties:
classificationConfigurations:
type: array
items:
$ref: '#/components/schemas/RestCaseAssistConfigurationWithProject'
RestListOfCaseAssistConfigurationsWithProjects:
required:
- configurations
type: object
properties:
configurations:
type: array
items:
$ref: '#/components/schemas/RestCaseAssistConfigurationWithProjectResponse'
totalEntries:
type: integer
format: int32
description: The total number of configurations
example: 1
totalPages:
type: integer
format: int32
description: The total number of pages
example: 1
securitySchemes:
oauth2:
type: oauth2
flows:
authorizationCode:
authorizationUrl: https://platform.cloud.coveo.com/oauth/authorize
tokenUrl: https://platform.cloud.coveo.com/oauth/token
scopes:
full: required