PermuteDocs
Go to Permute

Apps · appsPublicationRequestsCreate

Request publication of a saved app revision

Requires Edit draft. Pins revisionId and expectedVersion; expires after seven days. Repeated requests for the same candidate and principal reuse the pending task. This does not grant Publish or change the live app.

POST/v1/apps/{applicationId}/publication-requests
betaapiKeyworkspace

When to use

Ask a publisher to review a saved app revision when you can edit drafts.

For agents

Read the revision and observed resource version first. The request expires after seven days and never grants Publish. The live app stays unchanged until a current publisher approves.

Example

typescript
import { PermuteClient } from '@permute/sdk';

const orgClient = new PermuteClient({
  apiKey: process.env.PERMUTE_API_KEY!,
});

const client = orgClient.withWorkspace(process.env.PERMUTE_WORKSPACE_ID!);

const result = await client.apps.requestPublication('appl_abcdefghijklmnopqrstuvwx', {
  "revisionId": "rvsn_abcdefghijklmnopqrstuvwx",
  "expectedVersion": "observed-version",
  "reason": "Ready for launch"
});

Request body

json
{
  "revisionId": "rvsn_abcdefghijklmnopqrstuvwx",
  "expectedVersion": "observed-version",
  "reason": "Ready for launch"
}

Response

json
{
  "data": {
    "id": "task_abcdefghijklmnopqrstuvwx",
    "revisionId": "rvsn_abcdefghijklmnopqrstuvwx",
    "expectedVersion": "observed-version",
    "principalType": "apiKey",
    "principalId": "apik_author",
    "reason": "Ready for launch",
    "status": "pending",
    "createdAt": "2026-10-29T12:00:00.000Z",
    "expiresAt": "2026-11-05T12:00:00.000Z",
    "canPublish": false,
    "canCancel": true,
    "applicationId": "appl_abcdefghijklmnopqrstuvwx"
  }
}