docs/Conversations

Conversations

These endpoints let you retrieve, inspect, and delete conversation data for completed calls.

All requests require an Authorization: Bearer YOUR_GUAVA_API_KEY header. See the API Overview for details.

Get conversation details

GET /v1/conversations/{call_id}

Retrieve metadata about a single conversation.

Parameters

NameTypeRequiredDescription
call_idstringYesID of the call

Response

A JSON object with the following fields:

FieldTypeDescription
call_idstringID of the call
tsstringDate of the call in ISO 8601 format
directionstring"inbound" or "outbound" (from the perspective of your agent)
from_numberstringPhone number that initiated the call
to_numberstringPhone number that received the call
duration_secintegerHow long the call lasted in seconds
campaign_idstring (nullable)Outbound campaign that initiated this call, if applicable

Errors

StatusDescription
401Invalid authentication
404The call with this ID does not exist

Example

curl -H 'Authorization: Bearer YOUR_GUAVA_API_KEY' \
  https://api.goguava.ai/v1/conversations/6064ab9663dc4eb0

Get conversation transcript

GET /v1/conversations/{call_id}/transcript

Download the transcript for a conversation as a list of turns.

Parameters

NameTypeRequiredDescription
call_idstringYesID of the call

Response

A JSON array of turn objects. Each turn has:

FieldTypeDescription
speakerstring"HUMAN" or "AGENT"
textstringWhat was said by the speaker
offset_msintegerMilliseconds into the call when this turn began

Errors

StatusDescription
401Invalid authentication
404The call with this ID does not exist

Example

curl -H 'Authorization: Bearer YOUR_GUAVA_API_KEY' \
  https://api.goguava.ai/v1/conversations/6064ab9663dc4eb0/transcript

Get conversation recording

GET /v1/conversations/{call_id}/recording

Download the audio recording for a conversation in WAV format.

Parameters

NameTypeRequiredDescription
call_idstringYesID of the call

Response

WAV audio file.

Errors

StatusDescription
401Invalid authentication
404The call with this ID does not exist

Example

curl -H 'Authorization: Bearer YOUR_GUAVA_API_KEY' \
  -o recording.wav \
  https://api.goguava.ai/v1/conversations/6064ab9663dc4eb0/recording

Delete a conversation

DELETE /v1/conversations/{call_id}

Permanently delete a conversation and its associated data.

Parameters

NameTypeRequiredDescription
call_idstringYesID of the call

Response

None (empty body).

Errors

StatusDescription
401Invalid authentication
404The call with this ID does not exist

Example

curl -X DELETE -H 'Authorization: Bearer YOUR_GUAVA_API_KEY' \
  https://api.goguava.ai/v1/conversations/6064ab9663dc4eb0

Questions? hi@goguava.ai