Conversation Service

Our Conversation Service API comprehensively manages the entire lifecycle of conversations—enabling creation, updates (audio persistence, display name, language, sharing, skill, state, and metadata), retrieval, redaction or deletion of messages, tagging, event logging, batch operations, and final closure—providing robust end-to-end conversation management.

Languages
Servers
https://{api-domain}.cresta.com/

ConversationService

Operations

ListConversationMessages.

Request

ListConversationMessages lists ConversationMessages under a Conversation.

Path
parentstringrequired

Resource name of the parent.

Format: customers/{customer_id}/profiles/{profile_id}/conversations/{conversation_id}

Query
pageSizeinteger(int32)

The maximum number of ConversationMessages to return. If unspecified, at most 100 ConversationMessages will be returned.

pageTokenstring

A page token, received from a previous ListConversationMessages call. Provide this to retrieve the subsequent page.

curl -i -X GET \
  'https://{api-domain}.cresta.com/v1/{parent=customers/*/profiles/*/conversations/*}/conversationMessages'

Responses

A successful response.

Bodyapplication/json
conversationMessagesArray of objects(A message in a Conversation. Next ID: 22)read-only

The returned conversationMessages.

nextPageTokenstring

Token is used to retrieve the next page.

Response
application/json
{ "conversationMessages": [ {} ], "nextPageToken": "string" }

BatchCreateConversationEvents

Request

BatchCreateConversationEvents creates multiple ConversationEvents

Path
parentstringrequired

Resource name of the parent.

Format: customers/{customer_id}/profiles/{profile_id}/conversations/{conversation_id}

Bodyapplication/jsonrequired
eventsArray of objects(Events. (-- api-linter: core::0233::request-unknown-fields=disabled aip.dev/not-precedent: customized api. --))
skipAnnotationsboolean(If set to true, this API call won't trigger orchestrator to generate moment/action annotations. If not set to true, if the conversation has skip_annotations=true in StartConversationRequest.feature_override, it won't trigger as well. (-- api-linter: core::0233::request-unknown-fields=disabled aip.dev/not-precedent: customized api. --))
curl -i -X POST \
  'https://{api-domain}.cresta.com/v1/{parent=customers/*/profiles/*/conversations/*}/events:batchCreate' \
  -H 'Content-Type: application/json' \
  -d '{
    "events": [
      {
        "name": "string",
        "associatedMessage": "string",
        "associatedActionAnnotation": "string",
        "type": "EVENT_TYPE_UNSPECIFIED",
        "callReason": {
          "selectedMoment": "string"
        },
        "entityFeedback": {
          "isDelete": true,
          "entity": {
            "start": 0,
            "end": 0,
            "entityName": "string",
            "strValue": "string",
            "surfaceMode": "SURFACE_MODE_UNSPECIFIED",
            "postRedactionStart": 0,
            "postRedactionEnd": 0
          }
        },
        "summarizationFeedback": {
          "summary": {
            "summaryItems": [
              {
                "startTurn": 0,
                "endTurn": 0,
                "summaryText": "string",
                "type": "string",
                "summarizationItemValue": {},
                "metadata": {},
                "topicPrefix": "string",
                "skippedModelInference": true
              }
            ]
          }
        },
        "usedSuggestion": {
          "resultId": "string"
        },
        "usedHintSuggestion": {},
        "interactiveVoiceResponse": {
          "stringValue": "string"
        },
        "conversationMetadata": {
          "metadataValues": {
            "property1": {
              "values": [
                {}
              ]
            },
            "property2": {
              "values": [
                {}
              ]
            }
          },
          "source": "SOURCE_UNSPECIFIED"
        },
        "usedHintDocumentChip": {
          "document": "string"
        },
        "usedSearchSuggestion": {
          "resultId": "string",
          "documentName": "string",
          "title": "string",
          "text": "string",
          "confidence": 0.1
        },
        "usedKbSearch": {
          "sessionMetadata": {
            "sessionId": "string",
            "eventSequenceId": 0
          },
          "query": "string",
          "queryType": "QUERY_TYPE_UNSPECIFIED",
          "searchResultCount": 0
        },
        "usedKbDocument": {
          "sessionMetadata": {
            "sessionId": "string",
            "eventSequenceId": 0
          },
          "docType": "KB_DOCUMENT_TYPE_UNSPECIFIED",
          "document": "string",
          "guidedWorkflowData": {
            "name": "string",
            "toStepId": 0,
            "fromName": "string",
            "fromStepId": 0
          },
          "knowledgeSessionId": "string"
        },
        "conversationLanguageChange": {
          "newLanguageCode": "string",
          "oldLanguageCode": "string"
        },
        "usedSummarization": {
          "copyAllNotes": {
            "count": 0
          },
          "editSummarizationNote": {},
          "copySummarizationNote": {}
        },
        "usedNoteTaking": {
          "copyEntity": {
            "entityName": "string"
          },
          "updateEntity": {
            "key": "string",
            "value": "string"
          }
        },
        "conversationTextPasted": {
          "text": "string",
          "agent": {
            "agentName": "string",
            "fullName": "string"
          }
        },
        "kaGenAiReplyFeedback": {
          "type": "FEEDBACK_TYPE_UNSPECIFIED",
          "reason": "string",
          "knowledgeSessionId": "string"
        },
        "kaGenAiReplyCopied": {
          "text": "string",
          "knowledgeSessionId": "string"
        },
        "kaGenAiReplyInserted": {
          "text": "string",
          "knowledgeSessionId": "string"
        },
        "usedSmartCompose": {
          "textLength": 0,
          "usedTextLength": 0
        },
        "kaGenAiExtractedQuestionFeedback": {
          "type": "FEEDBACK_TYPE_UNSPECIFIED",
          "knowledgeSessionId": "string"
        },
        "topicSubmission": {
          "topics": {
            "summaryItems": [
              {
                "startTurn": 0,
                "endTurn": 0,
                "summaryText": "string",
                "type": "string",
                "summarizationItemValue": {},
                "metadata": {},
                "topicPrefix": "string",
                "skippedModelInference": true
              }
            ]
          }
        },
        "createTime": "2019-08-24T14:15:22Z"
      }
    ],
    "skipAnnotations": true
  }'

Responses

A successful response.

Bodyapplication/json
eventsArray of objects(Event is a non-message information in a Conversation. NEXT ID: 26)

Events created.

Response
application/json
{ "events": [ {} ] }

BatchGetConversationMessages

Request

BatchGetConversationMessages gets ConversationMessages based on specified resource names. The requested ConversationMessages may span multiple Conversations.

Path
parentstringrequired

Resource name of the parent Conversation that the requested ConversationMessages belong to. To get messages from multiple conversations, set conversation_id to "-" Format: customers/{customer_id}/profiles/{profile_id}/conversations/{conversation_id}

Query
namesArray of stringsrequired

Resource names of ConversationMessages.

curl -i -X GET \
  'https://{api-domain}.cresta.com/v1/{parent=customers/*/profiles/*/conversations/*}/messages:batchGet?names=string'

Responses

A successful response.

Bodyapplication/json
conversationMessagesArray of objects(A message in a Conversation. Next ID: 22)read-only

Returned ConversationMessages.

Response
application/json
{ "conversationMessages": [ {} ] }