Launch coding session
Changed on<Info>This API is in beta. Endpoints, fields, and behavior may still change, so avoid depending on it in production.</Info>
Start a coding task in an isolated branch or on an existing working branch of an imported repository. Authenticate with a platform Bearer token whose user has write access to the app and repository. The request returns before the coding task runs and consumes credits through the regular Builder path. Poll the returned session ID for progress and its pull request. Reuse the Idempotency-Key and runtime inputs on retries. You may omit the previously associated client_reference; changing a supplied reference or any runtime input with the same key returns idempotency_conflict. Launch and cancellation share a limit of 6 requests per minute per user. Every response has X-Request-Id and rate-limit headers; 429 responses include Retry-After. Sessions that need an approval or clarification report needs_input; use session_url to continue in Base Code. This endpoint doesn't merge pull requests.
Request
- Base URL: https://app.base44.com
- URL: https://app.base44.com/api/apps/{app_id}/imported/sessions
- Auth: HTTP bearer
Path parameters
Headers
A unique key for this task. Reuse it with the same runtime inputs on retries; you may omit the previously associated client_reference.
Request body
Example request
{
"prompt": "Remove the retired example-feature flag, preserving its enabled behavior.",
"title": "Remove example-feature",
"existing_branch": "feature/review-fixes",
"source_ref": "main",
"pull_request_body": "Requested by the release workflow.",
"commit_message": "fix: remove the retired flag",
"client_reference": "release-task-123",
"expected_repository_full_name": "acme/project"
}Response
Successful Response
Example response
{
"launch_key": "flag-cleanup-123",
"client_reference": "release-task-123",
"id": "6820f3a4e7b91d003c45a1f2",
"state": "running",
"message_id": "ca00e880-1111-4444-aaaa-ccddeeff0011",
"input_request_id": "ca00e880-1111-4444-aaaa-ccddeeff0011",
"repository_full_name": "acme/project",
"branch_id": "6820f3a4e7b91d003c45a1f3",
"branch_name": "base-code/fix-login-redirect-45a1f2",
"session_url": "https://app.base44.com/apps/6820f3a4e7b91d003c45a1f2/editor/preview",
"pull_request": {
"number": 123,
"url": "https://github.com/acme/project/pull/123"
},
"error_code": "execution_failed",
"outcome": "pull_request",
"summary": "Removed the retired flag and kept the enabled behavior."
}Changes
- info
added the new optional request property
- info
- info
the
request property's maxLength was increased from99611to99618 - info
added the optional property
to the response with the status
- info