Skip to content
GitmoapAPIBeta
Agentsai-org
GET/ai-sessions/{session_id}/transcript

A page of a session's transcript: what the agent wrote, what each tool call returned, the live

get_ai_session_transcript
  • ai_org:read
    A token needs the ai_org:read scope: Read an AI organization, its agents, sessions and usageGranted by read_api, write_api.Every operation this scope unlocks
  • Audited · sensitive read

    x-gitmoap-audit: {"kind":"audited","arg":"sensitive_read"}

Pages run by turn, oldest first, up to 8 turns each; poll from the last turn to follow a running session. Shown only to someone who can read every repository and group the session read from. Refused where transcripts are not configured.

Parameters

Path
  • session_idAiSessionId (string · uuid)The session
Query
  • from_turninteger · int32optionalThe first turn of the page (default 1)
  • limitinteger · int32optionalMaximum number of turns, 1-8 (default 4)

Responses

200A page of the transcriptapplication/json
  • inputsarray of AiSessionInputEvery input the session has received, in order.
    • The AiSessionInput schema
    • created_atstring · date-timeWhen it arrived.
    • kindAiSessionInputKindinstructionassignmentmentioncommentreviewpipeline_failureWhat it is.
    • seqinteger · int641, 2, … within the session.
    • textstringWhat it says.
    • aboutstring or nulloptionalThe address it is about.
    • fromstring or nulloptionalWho sent it, as @username, when a person did.
  • turnsarray of AiTranscriptTurnThe turns this page covers, oldest first.
    • The AiTranscriptTurn schema
    • callsarray of AiTranscriptCallThe tool calls it made, in order.
      • The AiTranscriptCall schema
      • call_nointeger · int32Its place in the turn, from 1.
      • inputobjectWhat the agent asked the tool for.
      • toolstringThe tool it called.
      • truncatedbooleanWhether result was cut short.
      • live_outputstring or nulloptionalThe latest output of a workspace command still running.
      • resultstring or nulloptionalWhat the tool returned, at most 32 KiB. Absent while the call runs.
    • textarray of stringWhat the agent wrote, in order.
    • turn_nointeger · int32The turn's number, from 1.
    • inputs_throughinteger · int64 or nulloptionalThe highest input the turn's request carried: inputs above the previous turn's and up to this one reached the agent before this turn.
  • next_turninteger · int32 or nulloptionalThe first turn of the next page; absent at the newest.
200 exampleSynthesized example
{
"inputs": [
{
"created_at": "2026-10-14T10:50:31Z",
"kind": "instruction",
"seq": 37,
"text": "text-34c0"
},
{
"created_at": "2026-10-12T23:53:39Z",
"kind": "instruction",
"seq": 50,
"text": "text-0182"
}
],
"turns": [
{
"calls": [],
"text": [],
"turn_no": 15
}
],
"next_turn": 70
}
400Bad request — a path parameter is not a well-formed value of its typeapplication/json
Error codes
  • BAD_REQUESTThe request is malformed: a parameter or a body field is not a well-formed value of its type
  • errorErrorBody
    • The ErrorBody schema
    • codestringThe coarse category, tied to the status: NOT_FOUND, CONFLICT, INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all.
    • messagestringWhat went wrong, for a person. Written to be read, not parsed: match on reason or code.
    • fieldstring or nulloptionalOn a 400 that refused one field's value, the field, as its JSON path: email, items[0].name. Put the message under that input. Absent on every other error.
    • reasonstring or nulloptionalThe specific code, when the error has one: LAST_ORGANIZATION_OWNER, BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and on code otherwise.
    • required_scopestring or nulloptionalThe scope the access token was missing, on INSUFFICIENT_SCOPE.
    • violationsanyoptionalPresent on the structured-validation errors (PROVIDER_VALIDATION_FAILED per-node, PIPELINE_VALIDATION_FAILED DAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
400 exampleSynthesized example
{
"error": {
"code": "code-f9d7",
"message": "Pin a page's payload to the build that rendered it"
}
}
401Unauthenticated — no credential, or an invalid oneapplication/json
Error codes
  • UNAUTHORIZEDNo credential was sent, or the one sent is invalid, expired or revoked
  • errorErrorBody
    • The ErrorBody schema
    • codestringThe coarse category, tied to the status: NOT_FOUND, CONFLICT, INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all.
    • messagestringWhat went wrong, for a person. Written to be read, not parsed: match on reason or code.
    • fieldstring or nulloptionalOn a 400 that refused one field's value, the field, as its JSON path: email, items[0].name. Put the message under that input. Absent on every other error.
    • reasonstring or nulloptionalThe specific code, when the error has one: LAST_ORGANIZATION_OWNER, BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and on code otherwise.
    • required_scopestring or nulloptionalThe scope the access token was missing, on INSUFFICIENT_SCOPE.
    • violationsanyoptionalPresent on the structured-validation errors (PROVIDER_VALIDATION_FAILED per-node, PIPELINE_VALIDATION_FAILED DAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
401 exampleSynthesized example
{
"error": {
"code": "code-18de",
"message": "Inline scalar newtypes but keep their brand"
}
}
403Forbidden — the caller's access level or token scope is insufficientapplication/json
Error codes
  • FORBIDDENYou are signed in but may not do this here; reason names the permission or the rule that refused it
  • INSUFFICIENT_SCOPEThe access token lacks the scope this operation needs; required_scope names it
  • PERMISSION_REQUIREDYou need a permission you do not hold here; the message names it
  • errorErrorBody
    • The ErrorBody schema
    • codestringThe coarse category, tied to the status: NOT_FOUND, CONFLICT, INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all.
    • messagestringWhat went wrong, for a person. Written to be read, not parsed: match on reason or code.
    • fieldstring or nulloptionalOn a 400 that refused one field's value, the field, as its JSON path: email, items[0].name. Put the message under that input. Absent on every other error.
    • reasonstring or nulloptionalThe specific code, when the error has one: LAST_ORGANIZATION_OWNER, BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and on code otherwise.
    • required_scopestring or nulloptionalThe scope the access token was missing, on INSUFFICIENT_SCOPE.
    • violationsanyoptionalPresent on the structured-validation errors (PROVIDER_VALIDATION_FAILED per-node, PIPELINE_VALIDATION_FAILED DAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
403 exampleSynthesized example
{
"error": {
"code": "code-e2d8",
"message": "Inline scalar newtypes but keep their brand"
}
}
404Not found — or found and private, which is masked as absentapplication/json
Error codes
  • NOT_FOUNDThe resource does not exist — or exists and you cannot see it: a private resource you have no access to answers exactly as an absent one does
  • errorErrorBody
    • The ErrorBody schema
    • codestringThe coarse category, tied to the status: NOT_FOUND, CONFLICT, INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all.
    • messagestringWhat went wrong, for a person. Written to be read, not parsed: match on reason or code.
    • fieldstring or nulloptionalOn a 400 that refused one field's value, the field, as its JSON path: email, items[0].name. Put the message under that input. Absent on every other error.
    • reasonstring or nulloptionalThe specific code, when the error has one: LAST_ORGANIZATION_OWNER, BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and on code otherwise.
    • required_scopestring or nulloptionalThe scope the access token was missing, on INSUFFICIENT_SCOPE.
    • violationsanyoptionalPresent on the structured-validation errors (PROVIDER_VALIDATION_FAILED per-node, PIPELINE_VALIDATION_FAILED DAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
404 exampleSynthesized example
{
"error": {
"code": "code-3525",
"message": "Stream pipeline status into the run header"
}
}

CLI

gitmoap ai-org get-ai-session-transcript

  • --session-ididThe session
  • --from-turnnumberoptionalThe first turn of the page (default 1)
  • --limitnumberoptionalMaximum number of turns, 1-8 (default 4)