Connect Bluesky with an app password with POST /api/v1/integrations/bluesky/session. Requires a signed-in workspace owner, in the web app or the CLI; API keys are not accepted and MCP cannot call it.
Request
Exchanges a handle and app password for an encrypted AT Protocol session, connects the account, and returns a workspace URL. Pass accountId to reconnect that existing Bluesky account; a different DID is rejected.
| Parameter | In | Type | Required |
|---|---|---|---|
workspaceId |
query | UUID | Yes |
| Body field | Type | Required |
|---|---|---|
handle |
string | Yes |
appPassword |
string | Yes |
service |
string | No |
accountId |
UUID | No |
profileId |
UUID | No |
Response
- HTTP 200: an object with
attemptId,url,expiresAt.
The OpenAPI document has each field’s type.
Examples
The TypeScript SDK has no method for this operation yet; send it over HTTP as the cURL tab shows.
The Python SDK authenticates with a workspace API key, which this operation does not accept, so it has no method for it.
curl -X POST "https://pubnio.com/api/v1/integrations/bluesky/session?workspaceId=$WORKSPACE_ID" \
-H "Authorization: Bearer $PUBNIO_TOKEN" \
-H "Content-Type: application/json" \
-d '{"handle":"studio.bsky.social","appPassword":"abcd-efgh-ijkl-mnop"}'pnio integrations bluesky-session --handle studio.bsky.social --app-password "$BLUESKY_APP_PASSWORD"async () => {
const response = await codemode.request({
method: "POST",
path: "/api/v1/integrations/bluesky/session",
query: { workspaceId: codemode.workspaceId },
body: {
handle: "studio.bsky.social",
appPassword: "abcd-efgh-ijkl-mnop",
},
});
return response.data;
};Errors
It declares no problem of its own.
It declares the problems most operations declare.
Idempotency
No key, so a retried POST is not deduplicated. Read the current state before you retry.
Limits
- API keys and MCP cannot call it. A signed-in person runs it from the CLI after
pnio auth loginor in the web app.