conversations
Creates, updates, deletes, gets or lists a conversations
resource.
Overview
Name | conversations |
Type | Resource |
Id | google.discoveryengine.conversations |
Fields
Name | Datatype | Description |
---|---|---|
name | string | Immutable. Fully qualified name projects/{project}/locations/global/collections/{collection}/dataStore/*/conversations/* or projects/{project}/locations/global/collections/{collection}/engines/*/conversations/* . |
endTime | string | Output only. The time the conversation finished. |
messages | array | Conversation messages. |
startTime | string | Output only. The time the conversation started. |
state | string | The state of the Conversation. |
userPseudoId | string | A unique identifier for tracking users. |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
projects_locations_collections_data_stores_conversations_get | SELECT | collectionsId, conversationsId, dataStoresId, locationsId, projectsId | Gets a Conversation. |
projects_locations_collections_data_stores_conversations_list | SELECT | collectionsId, dataStoresId, locationsId, projectsId | Lists all Conversations by their parent DataStore. |
projects_locations_collections_engines_conversations_get | SELECT | collectionsId, conversationsId, enginesId, locationsId, projectsId | Gets a Conversation. |
projects_locations_collections_engines_conversations_list | SELECT | collectionsId, enginesId, locationsId, projectsId | Lists all Conversations by their parent DataStore. |
projects_locations_data_stores_conversations_get | SELECT | conversationsId, dataStoresId, locationsId, projectsId | Gets a Conversation. |
projects_locations_data_stores_conversations_list | SELECT | dataStoresId, locationsId, projectsId | Lists all Conversations by their parent DataStore. |
projects_locations_collections_data_stores_conversations_create | INSERT | collectionsId, dataStoresId, locationsId, projectsId | Creates a Conversation. If the Conversation to create already exists, an ALREADY_EXISTS error is returned. |
projects_locations_collections_engines_conversations_create | INSERT | collectionsId, enginesId, locationsId, projectsId | Creates a Conversation. If the Conversation to create already exists, an ALREADY_EXISTS error is returned. |
projects_locations_data_stores_conversations_create | INSERT | dataStoresId, locationsId, projectsId | Creates a Conversation. If the Conversation to create already exists, an ALREADY_EXISTS error is returned. |
projects_locations_collections_data_stores_conversations_delete | DELETE | collectionsId, conversationsId, dataStoresId, locationsId, projectsId | Deletes a Conversation. If the Conversation to delete does not exist, a NOT_FOUND error is returned. |
projects_locations_collections_engines_conversations_delete | DELETE | collectionsId, conversationsId, enginesId, locationsId, projectsId | Deletes a Conversation. If the Conversation to delete does not exist, a NOT_FOUND error is returned. |
projects_locations_data_stores_conversations_delete | DELETE | conversationsId, dataStoresId, locationsId, projectsId | Deletes a Conversation. If the Conversation to delete does not exist, a NOT_FOUND error is returned. |
projects_locations_collections_data_stores_conversations_patch | UPDATE | collectionsId, conversationsId, dataStoresId, locationsId, projectsId | Updates a Conversation. Conversation action type cannot be changed. If the Conversation to update does not exist, a NOT_FOUND error is returned. |
projects_locations_collections_engines_conversations_patch | UPDATE | collectionsId, conversationsId, enginesId, locationsId, projectsId | Updates a Conversation. Conversation action type cannot be changed. If the Conversation to update does not exist, a NOT_FOUND error is returned. |
projects_locations_data_stores_conversations_patch | UPDATE | conversationsId, dataStoresId, locationsId, projectsId | Updates a Conversation. Conversation action type cannot be changed. If the Conversation to update does not exist, a NOT_FOUND error is returned. |
projects_locations_collections_data_stores_conversations_converse | EXEC | collectionsId, conversationsId, dataStoresId, locationsId, projectsId | Converses a conversation. |
projects_locations_collections_engines_conversations_converse | EXEC | collectionsId, conversationsId, enginesId, locationsId, projectsId | Converses a conversation. |
projects_locations_data_stores_conversations_converse | EXEC | conversationsId, dataStoresId, locationsId, projectsId | Converses a conversation. |
SELECT
examples
Lists all Conversations by their parent DataStore.
SELECT
name,
endTime,
messages,
startTime,
state,
userPseudoId
FROM google.discoveryengine.conversations
WHERE dataStoresId = '{{ dataStoresId }}'
AND locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';
INSERT
example
Use the following StackQL query and manifest file to create a new conversations
resource.
- All Properties
- Manifest
/*+ create */
INSERT INTO google.discoveryengine.conversations (
dataStoresId,
locationsId,
projectsId,
name,
state,
userPseudoId,
messages
)
SELECT
'{{ dataStoresId }}',
'{{ locationsId }}',
'{{ projectsId }}',
'{{ name }}',
'{{ state }}',
'{{ userPseudoId }}',
'{{ messages }}'
;
- name: your_resource_model_name
props:
- name: name
value: string
- name: state
value: string
- name: userPseudoId
value: string
- name: messages
value:
- - name: userInput
value:
- name: input
value: string
- name: context
value:
- name: contextDocuments
value:
- string
- name: activeDocument
value: string
- name: reply
value:
- name: summary
value:
- name: summaryText
value: string
- name: summarySkippedReasons
value:
- string
- name: safetyAttributes
value:
- name: categories
value:
- string
- name: scores
value:
- number
- name: summaryWithMetadata
value:
- name: summary
value: string
- name: citationMetadata
value:
- name: citations
value:
- - name: startIndex
value: string
- name: endIndex
value: string
- name: sources
value:
- - name: referenceIndex
value: string
- name: references
value:
- - name: title
value: string
- name: document
value: string
- name: uri
value: string
- name: chunkContents
value:
- - name: content
value: string
- name: pageIdentifier
value: string
- name: createTime
value: string
- name: startTime
value: string
- name: endTime
value: string
UPDATE
example
Updates a conversations
resource.
/*+ update */
UPDATE google.discoveryengine.conversations
SET
name = '{{ name }}',
state = '{{ state }}',
userPseudoId = '{{ userPseudoId }}',
messages = '{{ messages }}'
WHERE
conversationsId = '{{ conversationsId }}'
AND dataStoresId = '{{ dataStoresId }}'
AND locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';
DELETE
example
Deletes the specified conversations
resource.
/*+ delete */
DELETE FROM google.discoveryengine.conversations
WHERE conversationsId = '{{ conversationsId }}'
AND dataStoresId = '{{ dataStoresId }}'
AND locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';