GET
/
api
/
v1
/
agents
/
{agentId}
/
conversations
/
{conversationId}
/
transcript
curl --request GET \
  --url https://api.play.ai/api/v1/agents/{agentId}/conversations/{conversationId}/transcript \
  --header 'Authorization: Bearer <token>' \
  --header 'X-USER-ID: <api-key>'
[
  {
    "id": "tIKQo8GMvOZyGx0Wm2RT",
    "role": "assistant",
    "content": "Hey, How are you doing today ?",
    "timestamp": "2024-06-04T15:13:53.682Z"
  }
]

Response Headers for Pagination

Header NameTypeDescription
X-Page-SizeintegerThe number of items per page.
X-Start-AfterstringThe ID of the last item on the previous page.
X-Next-Start-AfterstringThe ID of the last item on the current page.
X-Total-CountintegerThe total number of items.

These headers are included in the response to help manage pagination when retrieving conversation transcript for a specific agent conversation.

Authorizations

Authorization
string
header
required

Your secret API key from PlayAI, formatted as Bearer YOUR_SECRET_API_KEY.

X-USER-ID
string
header
required

Your unique user ID from PlayAI.

Headers

accept
enum<string>
Available options:
application/json

Path Parameters

agentId
string
required

The agent's ID.

Example:

"f0gZrOKBKL7veJ6o1M"

conversationId
string
required

The conversation's ID.

Query Parameters

pageSize
integer
default:50

The number of items to return per page.

startAfter
string

The conversation ID to start after.

Response

200 - application/json
Conversation transcript retrieved.
id
string
Example:

"tIKQo8GMvOZyGx0Wm2RT"

role
string
Example:

"assistant"

content
string
Example:

"Hey, How are you doing today ?"

timestamp
string
Example:

"2024-06-04T15:13:53.682Z"