Bobsled AI API
Learn how the Bobsled AI REST API is organized and authorized, and complete common tasks such as paging, retries, Project grants, and connection tests.
This page is an overview of the Bobsled AI REST API for developers who build integrations. It explains how the API is organized, how it authorizes and rejects requests, and how to complete tasks that need more than a schema. For the parameters, request body, and response schema of every operation, see the API reference.
Before you begin
- Get a credential. For the supported credential types, see API authentication.
- Find your Bobsled AI URL, such as
https://customer.dogsled.it. The API is served from the same origin.
The curl examples on this page read the following shell variables:
$BOBSLED_ORIGIN: your Bobsled AI URL.$BOBSLED_API_KEY: a personal API key.$BOBSLED_ACCOUNT_ID: the ID of your Account.$BOBSLED_PROJECT_ID: the ID of the Project.
How the API is organized
Every Bobsled AI product operation is under /api/v1. Routes are grouped by the resource boundary that they authorize, not by UI screen. The route roots are the following:
/api/v1/accounts/**: Account access, Projects, members, service principals, Account connections and secrets, chats, chat history, Skills, Project attachments, Blueprints, pipelines, and Agents./api/v1/me/personal-api-keys: the only personal actor root, for user-owned keys./api/v1/projects/:projectId/**: connections, secrets, Skills, ad hoc queries, agent resources and operations, and external pipeline routes.
Blueprint authoring uses /api/v1/accounts/:accountId/projects/:projectId/blueprints/**, with no Account-less or legacy aliases. No API route stores a selected Account or Project. The browser reads that context from the current URL.
The routes outside /api/v1 are authentication, health checks, and MCP transport. They aren't alternate product APIs. For an external integration, use documented /api/v1 operations or /api/mcp.
Use the contract of your Bobsled AI URL
The API reference shows the current release. Your Bobsled AI URL can run a different version. The reference lists methods, paths, operation IDs, parameters, request and response schemas, and accepted credentials. Follow these rules:
- Generate a client from that OpenAPI document or from a pinned generated artifact, or call the HTTP API directly. Don't copy a request body from another Bobsled AI URL or an old screenshot.
- Regenerate the client when you move to a Bobsled AI URL with a different contract. Test compatibility before you promote a client change.
Use the stable Account, Project, Draft, version, pipeline, run, and resource IDs from Bobsled AI responses. Don't parse display names into identifiers. A service principal is a machine principal, so don't assume that every principal has a user ID.
How requests are authorized
Each operation declares the credential types that it accepts. Bobsled AI applies the following checks:
- A request selects exactly one credential family. A request with mixed credentials fails with
400andambiguous_credentials. - A session-authenticated mutation enforces the same-origin policy that its route declares. A request without a matching
Originheader fails with403andforbidden_origin. - For a personal API key or a service principal, Bobsled AI checks the Project and the exact read or write permission that the route requires.
Account and Project list responses include can, the permissions that the caller holds on each item. Use that list to decide which controls to show. For how to send each credential, see API authentication.
Permissions
Each product area has its own pair of permissions, <area>:read and <area>:write. A write permission doesn't include the read permission. The following table lists each pair and what it covers:
Chat permissions don't bypass ownership checks. The following table lists the permissions that each role holds. For the same roles by product area, see Roles and permissions.
The following rules also apply:
- Account Admins also hold
historicalChat:read. It lets them query the Account's Historical chats through Balto, MCP, and the SQL explorer. No/api/v1route requires it. - A Project Maintainer grant doesn't include Account membership or service-principal management.
- Bobsled AI limits a Partner to eligible delivery Projects. A request that sets the
partnerrole fails unless the Account has a Project with a locked landing link. For the workflow, see Partner delivery. - A personal API key keeps its owner's live Account permissions. Its
api:writescope can permit chat controls without Project write access. - Balto and MCP enforce the current member's permissions.
- Service principals use their own scope and grant model. For more information, see Developer access.
Account role values
Account membership responses return admin, maintainer, project_maintainer, reader, none, or partner. Member create and update requests accept the same values.
The app shows an existing project_maintainer membership as Maintainer · Projects in Edit access. The main role picker doesn't offer it for a new selection. To assign it, use the Account members API.
Older memberships kept their permissions when the role values changed: user became maintainer, and chat_only became reader. API clients must use the current values. Sign-in identity roles and chat message roles didn't change.
Responses and errors
Protected responses default to Cache-Control: no-store. Bobsled AI maps known failures to a safe error envelope, similar to the following:
{
"error": {
"code": "insufficient_scope",
"message": "The credential does not grant this operation",
"kind": "expected",
"retryable": false
}
}The envelope has the following fields:
code: a stable error code. The API reference lists the codes that each operation can return.message: a safe, human-readable summary.kind:expected,operational,defect, orinterruption.retryable: whether the same request can succeed later without a change.detailsanddiagnosticMessage: optional context, such asdetails.reasonfor a connection test.referenceId: an identifier that appears on some errors, such as internal defects. Include it when you report a problem.
Status codes have their conventional meanings:
Don't treat every non-2xx response as retryable. A lifecycle conflict or a validation error needs new state or input, not a retry loop.
Page through results
Cursor-paginated operations, such as pipeline run lists, return data.items and an opaque data.nextCursor. When nextCursor isn't null, send it unchanged as the next request's cursor. Don't parse it or derive your own.
The following command requests the next page of pipeline runs:
curl --fail-with-body --silent --show-error \
--get \
--header "X-Dogsled-API-Key: $BOBSLED_API_KEY" \
--data-urlencode "cursor=$BOBSLED_NEXT_CURSOR" \
--data-urlencode "limit=20" \
"$BOBSLED_ORIGIN/api/v1/projects/$BOBSLED_PROJECT_ID/pipeline-runs"Set $BOBSLED_NEXT_CURSOR to the nextCursor value from the previous response. The response is similar to the following:
{
"data": {
"items": [],
"nextCursor": "<opaque-cursor>"
}
}Retry requests safely
Retry a read operation only for a transient failure, and use bounded backoff. Before you retry a mutation after a network interruption, check whether the operation supports idempotent replay, and inspect the resulting state.
For a documented pipeline dispatch, reuse one idempotency key for every retry of the same logical request. A dispatch also needs the planFingerprint of a preview of the same selection. The following command previews a run of the daily_orders pipeline:
curl --fail-with-body --silent --show-error \
--request POST \
--header "Content-Type: application/json" \
--header "X-Dogsled-API-Key: $BOBSLED_API_KEY" \
--data '{}' \
"$BOBSLED_ORIGIN/api/v1/accounts/$BOBSLED_ACCOUNT_ID/projects/$BOBSLED_PROJECT_ID/pipelines/daily_orders/preview"The following command starts the previewed run:
curl --fail-with-body --silent --show-error \
--request POST \
--header "Content-Type: application/json" \
--header "X-Dogsled-API-Key: $BOBSLED_API_KEY" \
--data "{\"idempotencyKey\":\"daily-orders:2026-08-11\",\"planFingerprint\":\"$BOBSLED_PLAN_FINGERPRINT\"}" \
"$BOBSLED_ORIGIN/api/v1/projects/$BOBSLED_PROJECT_ID/pipelines/daily_orders/runs"Set $BOBSLED_PLAN_FINGERPRINT to the data.planFingerprint value from the preview response. Don't reuse that key for a different pipeline, selection, or intended run. Bobsled AI accepts a pipeline cancellation before the cancellation settles. Wait for a terminal state instead of sending duplicate completion or run requests.
Grant a person access to a Project
The Account role none appears as Project member in the app. It permits Account discovery but grants no Project access by itself. An Account Admin can give an existing Account member a role on one Project with a Project grant:
- A grant holds that role's Project permissions on that Project only. It never adds
account:writeorusage:read. - A grant adds to inherited Account permissions. Removing a grant doesn't remove access inherited from the Account role.
- Removing Account membership removes the person's Project grants.
The following table lists the grant routes:
The grant routes accept a session or a personal API key. A key also needs the operation's read or write scope. The routes don't accept service-principal credentials. They refuse Partner Accounts, self-grants, and grants to non-members.
The following command makes a person a reader on one Project:
curl --fail-with-body --silent --show-error \
--request PUT \
--header "Content-Type: application/json" \
--header "X-Dogsled-API-Key: $BOBSLED_API_KEY" \
--data '{"role":"reader"}' \
"$BOBSLED_ORIGIN/api/v1/accounts/$BOBSLED_ACCOUNT_ID/grants/project/$BOBSLED_PROJECT_ID/users/USER_ID"Replace USER_ID with the user ID of the Account member. To grant edit access, send {"role":"maintainer"}. A new PUT replaces the person's role.
Limit a person to Blueprint folders
A third grant, folder_reader, limits a person to folders of the published Blueprint. Send a body like the following:
{ "role": "folder_reader", "folders": ["models/finance"] }Each folder is a path without a trailing slash. A folder reader has the following access and limits:
- The person holds
chat:read,chat:write, andmodel:readon that Project, and no other Project permission. - The model list, model metadata, and queries cover only the published models under those folders.
- A query that reads another table fails with
unmapped_tableand names the table. - A query can call only built-in functions that compute from their own arguments. Each source type has its own list. For the lists, see Folder reader functions.
- Any other function, or a
SHOW,DESCRIBE, orUSEstatement, fails withfunction_not_allowed.details.tablesnames each refused function. - Write
a NOT LIKE borNOT (a LIKE b). The formNOT a LIKE bfails. - A query runs on one connection. Joins across connections, file sources, and live API models aren't available to this role.
- A new
PUTreplaces the role and the folders. The list response returnsfoldersfor this role. - Balto can also send this
PUTfor an Account Admin in a chat on the Project, after the Admin approves it.
For the app workflow, see Share a Project with a person.
Attach a connection or secret to a Project
Connections and secrets belong to the Account. A Project uses one only after it's attached to that Project. The routes work as follows:
/api/v1/accounts/:accountId/connections/**and/api/v1/accounts/:accountId/secrets/**list, create, edit, and delete rows for the whole Account. A user sees only the rows of Projects that they can open. A service principal limited to selected Projects can't call these routes and uses the Project routes instead.- A
PUTto/api/v1/projects/:projectId/connections/:connectionId/attachmentattaches a connection to that Project. ADELETEto the same path detaches it. Thesecrets/:secretId/attachmentpath does the same for secrets. - Attach needs
project:writein that Project and Accountconnection:writeorsecret:write. Detach needsproject:writein that Project. - When other Projects use a row, its item in a Project list has
otherProjects. It names the other Projects that the caller can open and counts the rest.
A caller without Account write permission can edit, rotate, or delete a row only when no other Project uses it. Otherwise, the API returns attached_to_other_projects. The other refusals are name_used_in_account, stays_in_one_project, connection_in_use, secret_in_use, and test_needs_project.
Test a connection
To test a saved connection, send a POST request with no body to the following endpoint:
POST /api/v1/projects/{projectId}/connections/{connectionId}/testThis endpoint is a read-connectivity test. For a read/write storage connection, its success doesn't verify writing and doesn't replace the saved storage-test health. Write-only connections reject it. Balto and MCP connection tests are also read-only. For the matching UI workflow, see Troubleshoot a failed test.
Connection test errors
Each failure returns its own error code, with details.reason and retryable in the error envelope. The following table lists the codes:
These codes replace the generic connection_test_failed response. Correct the credentials, grants, or settings before you repeat a non-retryable test. Use bounded backoff for a retryable failure. An unavailable destination can mean a timeout, a network failure, a rate limit, or a provider outage.
Test storage access
To test reading and writing on a saved S3 or Google Cloud Storage connection, use the following endpoint:
POST /api/v1/projects/{projectId}/connections/{connectionId}/test-storage-accessSend { "config": ... } with the connection's saved configuration. The endpoint requires connection:write. A session-authenticated request also needs the matching Origin header. If the saved configuration changed, the endpoint returns 409 conflict. Reload the configuration before you repeat the test.
The response reports list, read, write, and cleanup operations, plus probeObject, configurationFingerprint, message, and success. Each operation has a status of passed, failed, unverified, or not_requested, plus a nullable reason. Interpret the response as follows:
- An HTTP
200response can still containsuccess: false. Inspect each operation's status. - A read-only test can leave reading unverified when the prefix contains no objects.
- A write-enabled test creates and cleans up a disposable object within the saved prefix.
- A non-null
probeObjectnames an object whose cleanup needs review before another test.
For setup and interpretation in the app, see Storage access and testing.
Check an SFTP host key
To read an SFTP server's host key before you save a connection, send the host and port to the following endpoint:
POST /api/v1/projects/{projectId}/connections/sftp/host-key{ "host": "sftp.partner.example", "port": 22 }To check a key type that a connection already trusts, add "algorithms": ["ssh-rsa"]. The server then presents one of those key types when it has one. The endpoint requires connection:write. A session-authenticated request also needs the matching Origin header. Bobsled AI connects to the server without signing in and saves nothing.
The response includes the following fields:
algorithm: the host key type, such asssh-ed25519.fingerprint: the SHA256 fingerprint in padded form.fingerprintSha256: the same fingerprint without padding, as OpenSSH shows it.fingerprintMd5: the MD5 fingerprint, such asMD5:cd:05:80:b4:fe:f2:f8:ac:71:3f:b9:32:8a:7b:5e:c0.serverSoftware: the SSH software that the server reports, ornull.
Before you save a key, compare fingerprint or fingerprintMd5 with a fingerprint from the server's owner. To pin the key, save { "algorithm": ..., "fingerprint": ... } in the connection's required hostKeys list. The list holds one to four unique keys, in order of preference. Bobsled AI asks the server for one pinned key type at a time, in list order. It accepts a key only when its type and fingerprint match. To rotate a key, pin the second key ahead of the planned rotation, and remove the old key after the switch.
Failures use the connection test error codes. The diagnosticMessage field names the cause, such as a refused port or a private network address. For the complete setup, see Connect to an SFTP server.
Manage Project memories
Project memories store short facts, preferences, corrections, and terms for one Project. The following table lists the memory operations:
All four operations accept a session, a personal API key, or a service principal. Session-authenticated create, update, and delete requests need the matching Origin header. Successful operations return HTTP 200.
The following command creates a memory:
curl --fail-with-body --silent --show-error \
--request POST \
--header "Content-Type: application/json" \
--header "X-Dogsled-API-Key: $BOBSLED_API_KEY" \
--data '{"content":"Revenue reports use the fiscal year ending in June."}' \
"$BOBSLED_ORIGIN/api/v1/accounts/$BOBSLED_ACCOUNT_ID/projects/$BOBSLED_PROJECT_ID/memories"Update accepts the same content body. To update or delete one memory, use the id from the list result. The operations behave as follows:
contentmust contain 1 to 2,000 characters after trimming. A Project can contain up to 50 active memories and 20,000 characters in total.- Creating a memory with identical active content returns the existing memory. Updating a memory with unchanged content keeps its timestamp.
- The list returns active memories only. Delete is a soft delete, and a deleted memory no longer appears in Project context.
Don't put credentials or secret values in memory content. For how Balto uses memories, see Project memories.
Export a full query result
The export API creates a durable, Project-scoped CSV export, reports its status, and redirects to a short-lived download URL. For the operations, permissions, and a complete example, see Large CSV exports.
Read Account chat history
Account chat history is available to Account Admins and approved audit integrations. Use one of the following credentials:
- An Account Admin session.
- A personal API key with read permission, owned by an Account Admin.
- A service-principal token with read permission and access to the Account.
The following table lists the read operations:
The list operation supports createdAfter, createdBefore, cursor, deleted, feedback, limit, order, ownerServicePrincipalId, ownerUserId, projectId, search, sort, and state. It behaves as follows:
searchmatches titles, thread IDs, Project names, starter names and email addresses, and message text.- An omitted
deletedvalue meansinclude. To review only deleted conversations, usedeleted=only. To hide them, usedeleted=exclude. - The message operation includes deleted messages and labels them.
- The list and message operations return their documented objects directly, without a
datawrapper.
The following command lists the first page of a retained Account history:
curl --fail-with-body --silent --show-error \
--get \
--header "X-Dogsled-API-Key: $BOBSLED_API_KEY" \
--data-urlencode "limit=50" \
--data-urlencode "deleted=include" \
"$BOBSLED_ORIGIN/api/v1/accounts/$BOBSLED_ACCOUNT_ID/chat-history"When nextCursor is present, copy it unchanged into the next request's cursor. To fetch a conversation's metadata and message pages, use the chatId from an item.
The message projection can contain user and Balto text, reasoning summaries, tool state and bounded details, approvals, result metadata, usage, errors, feedback, and attachment references. It doesn't contain hidden model reasoning, raw provider payloads, credentials, secret values, internal session tokens, or runtime turn identifiers. Build exports from this projection instead of reading database tables. For the app workflow, see Chat history.
Operate Agents
Agent operations live under /api/v1/accounts/:accountId/background-agents/**. Decisions live under /api/v1/accounts/:accountId/background-agent-approvals/** and /api/v1/accounts/:accountId/background-agent-proposals/**. For the product workflow, see Agents.
The Agent API reads Agents and controls runs, approvals, and schedule pause state. It doesn't create, edit, delete, or publish Agent definitions. To change a definition, edit its Blueprint file, then check, commit, and publish the selected Draft. Agent files declare type: agent and usually live at agents/<slug>.yaml.
These Account routes accept any Account member. Bobsled AI then checks the Project that the Agent lives in:
- Reads need
backgroundAgent:read. An Agent in a Project that you can't read returns404. - Lists return only Agents from Projects that you can read. The template list needs
backgroundAgent:readon the Account or on at least one Project. - Runs, cancel, schedule, nudges, provisioning, and appearance need
backgroundAgent:write. - Approve and decline need
backgroundAgent:writeplus the write permission of the Action. A Blueprint change needsblueprint:write. A pipeline run needspipeline:write. A tool Action needs the permission that the tool requires. - Applying a proposal needs
blueprint:writeandbackgroundAgent:write. Abandoning one needsbackgroundAgent:write.
For these routes, the role badges in the API reference show only the Account check.
Inspect a finished Agent run's tool calls
To read a run's retained tool inputs and outputs, call the following route:
GET /api/v1/accounts/:accountId/background-agents/:agentId/runs/:runId/tool-callsThe route accepts a session, a personal API key, or a service-principal token. It needs backgroundAgent:read on the Agent's Project. The run must be succeeded, failed, or cancelled. An unfinished run returns 409 conflict. The route has no pagination or query parameters.
The response has runId, status, items, and truncated. Each item has a name, a status of completed, failed, or pending, and input and output with credentials redacted. The response has the following limits:
- It includes only calls from that run's saved turns.
- It holds at most 200 calls.
- A field larger than 16,384 JSON bytes becomes
null, and itsinputTruncatedoroutputTruncatedflag is set. truncatedalso marks missing session evidence.
Treat a truncated response as incomplete evidence, not as proof that an action never happened.
Submit response feedback
To submit feedback on a Balto response, call the following route:
PUT /api/v1/accounts/:accountId/chats/:chatId/messages/:messageId/feedbackUse a session or a personal API key with api:write. The route doesn't accept service-principal credentials. Session requests need the matching Origin header. Bobsled AI records the feedback as the session user or the key's owner. That person must be able to view the chat, and the message must be a completed or failed Balto response.
The following request body reports an incorrect SQL filter:
{
"type": "negative",
"categories": ["incorrect_sql"],
"comment": "The filter uses the wrong week."
}The body has the following rules:
typeispositiveornegative.categoriesholds one to six unique categories that match that type. For the category vocabulary, see the API reference.- The
othercategory requires a comment. - Bobsled AI trims comments and limits them to 2,000 characters.
Success returns 200 with a receipt that contains id, messageId, type, and created. Repeating the same submission returns the existing receipt with created: false. Different feedback from the same person on the same message returns 409 conflict.
This route doesn't grant access to the Admin feedback review workflow.
Request question cards
A service principal can request Balto question cards with the x-dogsled-question-cards: on header. Send the header on chat requests that start or continue a turn, and when you stream the turn's events. The header also works when the service principal acts as an Account member. The header doesn't turn on cards for personal API keys or for Slack delivery. For the chat workflow, see Answer Balto's questions.
Retired pipeline view discovery
Bobsled AI removed the following operation:
GET /api/v1/accounts/:accountId/projects/:projectId/pipeline-run-viewsStop using it as a precheck for pipeline runs, and call the run and task APIs directly. The app shows Steps and Results for recognized entity-resolution pipelines without a rollout lookup. For that workflow, see Review entity-resolution results.
What's next
- Authenticate with a service principal for unattended automation.
- Export a full query result as CSV when a result is too large for a chat.
- Connect an MCP client to let a coding agent author and operate a Project.