Skip to main content
GET
Get coding session by launch key on an imported app

Authorizations

Authorization
string
header
required

Personal access token, sent as Authorization: Bearer <token>. Each operation lists the permission it needs: read_only or full_access. A full-access token can call every operation. A read-only token can call only the operations that list read_only; anything else returns 403 read_only_credential_route_not_allowed.

Scopes

full_access
PersonalAccessTokenAuth
full_access
WorkspaceApiKeyAuth
full_access
WorkspaceApiKeyBearerAuth

Path Parameters

launch_key
string
required

The Idempotency-Key supplied to the launch request.

Required string length: 1 - 200
Pattern: ^[A-Za-z0-9_.:-]+$
Example:

"flag-cleanup-123"

app_id
string
required

Response

Successful Response

id
string
required

The session's opaque identifier.

Example:

"6820f3a4e7b91d003c45a1f2"

created_by_user_id
string
required

The ID of the user who launched the session. A session launched with a workspace API key reports the key's owner.

Example:

"6820f3a4e7b91d003c45a1f4"

state
enum<string>
required

The session's state: queued, running, opening_pull_request, needs_input, completed, failed, cancelling, or cancelled.

Available options:
queued,
running,
opening_pull_request,
needs_input,
completed,
failed,
cancelling,
cancelled
Example:

"running"

message_id
string | null
required

The UUID of the session's user message, or null before dispatch. Queued processing updates it to the UUID used for the turn.

Example:

"ca00e880-1111-4444-aaaa-ccddeeff0011"

repository_full_name
string
required

The connected repository the session runs in.

Example:

"acme/project"

branch_id
string | null
required

The session's Base Code branch identifier, or null before provisioning.

Example:

"6820f3a4e7b91d003c45a1f3"

branch_name
string | null
required

The session's working Git branch, or null before provisioning.

Example:

"base-code/fix-login-redirect-45a1f2"

session_url
string | null
required

The Base Code editor URL for inspecting the session or answering pending questions, or null until its branch is provisioned.

Example:

"https://app.base44.com/apps/6820f3a4e7b91d003c45a1f2/editor/preview"

pull_request
SessionPullRequest · object | null
required

The pull request of the branch the session launched on, in the connected repository, or null until one is opened. pull_requests lists every pull request of the session.

Example:
error_code
string | null
required

The stable failure cause, or null if there is no failure.

Example:

"execution_failed"

launch_key
string | null

The original Idempotency-Key, or null for sessions created before key recovery was recorded. Use the same principal and key to retry a queued launch.

Example:

"flag-cleanup-123"

client_reference
string | null

Your application reconciliation reference, or null.

Example:

"release-task-123"

input_request_id
string | null

Opaque identifier of the current question or approval pause, or null when the session is not waiting for input or the pause predates identifier tracking. Use it to deduplicate notifications for repeated input requests. To answer, use the input_request_id from Get a coding session's open question.

Example:

"ca00e880-1111-4444-aaaa-ccddeeff0011"

pull_requests
SessionPullRequestListItem · object[]

Every pull request of the session, for each branch in branches and each repository: the connected repository and the repositories added to a multi-repository project. Ordered by branch as in branches; within a branch, the connected repository first, then the added repositories. Empty until a pull request is opened.

Example:
branches
SessionBranch · object[]

The session's branches: the branch it launched on first, then the branches opened in the same Base Code session (for example after continuing it in the editor), in the order they were added. Merged and deleted branches stay listed. Empty before provisioning.

Example:
error_reason
string | null

A short, human-readable explanation of error_code and what to do next, or null if there is no failure or cut-short turn.

Example:

"The branch's sandbox ran out of disk space. Crash dumps were removed; send the message again."

outcome
enum<string> | null

How a completed session ended: pull_request when it opened or updated a pull request, answer when it ended without one and replied instead; has_unpublished_changes says whether that branch still changes files. null until the session completes. Pull requests opened later on the session's other branches don't change it; read pull_requests for those.

Available options:
pull_request,
answer
Example:

"pull_request"

summary
string | null

The session's final reply in Markdown, up to 10,000 characters: the answer for an answer outcome, the change summary for a pull_request outcome. null until the session publishes.

Example:

"Removed the retired flag and kept the enabled behavior."

live_turns
SessionLiveTurn · object[]

Turns running on the session's branches (every branch in branches) after it finished: a PR Watch turn fixing review findings, or a turn someone started in the editor. Empty when nothing is running. state keeps its finished value, so poll this field to tell a finished, idle session from one still working.

Example:
latest_watch_summary
string | null

The final reply of the most recent PR Watch turn on the session's branch, in Markdown up to 10,000 characters, or null when no Watch turn has replied. A Watch turn that changed nothing leaves summary as it was, so its conclusion appears only here.

Example:

"Re-ran the flaky check: infrastructure timeout, no code change needed."

has_unpublished_changes
boolean
default:false

true when an answer session's branch changes files that no pull request carries yet: send a message asking for one to have the agent open it. false otherwise.

Example:

false

push_failed
boolean
default:false

true when a pull_request session's last changes did not reach the pull request's branch on GitHub because the push failed; summary then starts with a warning that says where the work is. false otherwise.

Example:

false