Add highlight
Highlight a passage of a transcript, or remove an existing highlight.
POST https://cotlet.dev/api/v1/otter/conversations/{conversation_id}/highlights
Finds the passage in the transcript and highlights it. If the text is not found or appears more than once, the call fails and lists the matches, so nothing is highlighted by guess. Set remove to true to remove the highlight again. People the conversation is shared with, and anyone with a public link, can see highlights, so keep notes for yourself out of them. add_highlight runs without asking first: it sends nothing to anyone and is undone with one call.
Parameters
| Name | Type | Description |
|---|---|---|
| conversation_id string required | string | Conversation ID from list_conversations or search_transcripts. |
| text string required | string | The passage exactly as it appears in the transcript. |
| remove boolean | boolean | true removes the highlight. Default: false. |
Request
curl -X POST https://cotlet.dev/api/v1/otter/conversations/cv_7f3a91/highlights \
-H "Authorization: Bearer $COTLET_API_KEY" \
-H "Content-Type: application/json" \
-d '{"text":"We decided to go with the flat-rate option for the pilot."}' result = client.call("otter", "add_highlight", {"conversation_id":"cv_7f3a91","text":"We decided to go with the flat-rate option for the pilot."}) const result = await cotlet.call('otter', 'add_highlight', {"conversation_id":"cv_7f3a91","text":"We decided to go with the flat-rate option for the pilot."}); cotlet call otter add_highlight --data '{"conversation_id":"cv_7f3a91","text":"We decided to go with the flat-rate option for the pilot."}' Example response
{
"conversation_id": "cv_7f3a91",
"highlight_id": "hl_31",
"timestamp": "12:41",
"text": "We decided to go with the flat-rate option for the pilot.",
"removed": false
}