Skip to main content
For most use cases, the slideless CLI is easier than calling this endpoint directly. The CLI command equivalent is slideless share <presentationId> --name "Acme".

When to use

Your presentation is already uploaded, and you want a new share link for a specific recipient, with:
  • its own view count (accessCount) — independent of the default token and any other tokens
  • its own URL — stable once issued
  • the ability to revoke just this recipient later without disrupting other recipients
Common trigger: sending the same deck to multiple prospects and wanting to know which of them actually opened it. If you’re emailing directly, use POST /sharePresentationViaEmail instead — it mints per-recipient tokens automatically.

Endpoint

POST https://europe-west1-slideless-ai.cloudfunctions.net/addPresentationToken

Auth

HeaderValue
AuthorizationBearer cko_… (or cka_…) — must belong to the presentation’s owner
Content-Typeapplication/json
Recommended scope: presentations:write.

Request body

FieldTypeRequiredDescription
presentationIdstringyesThe presentationId of the existing presentation
tokenNamestringyesHuman-readable label. Shown in getSharedPresentationInfo and the dashboard.
versionModeobjectnoEither {"type":"latest"} (default) or {"type":"pinned","version":N} where N ≤ current version. See Versioning.
Example — default (follows latest):
{ "presentationId": "0192f1c3-...", "tokenName": "Acme Corp" }
Example — pinned to v2:
{
  "presentationId": "0192f1c3-...",
  "tokenName": "Acme Corp",
  "versionMode": { "type": "pinned", "version": 2 }
}

Response (200)

{
  "success": true,
  "data": {
    "tokenId": "0192f1c3-abcd-...",
    "token": "r2h_cS3eqVg4...",
    "shareUrl": "https://app.slideless.ai/share/0192f1c3-...?token=r2h_cS3eqVg4..."
  }
}
FieldTypeDescription
tokenIdstringOpaque identifier. Pass it to unsharePresentation (with --token) to cut off just this recipient.
tokenstringThe raw secret embedded in the URL. Never shown again — store the shareUrl instead.
shareUrlstringThe link to hand to the recipient.

Examples

curl

curl -sS -X POST \
  -H "Authorization: Bearer $SLIDELESS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"presentationId":"0192f1c3-...","tokenName":"Acme Corp"}' \
  https://europe-west1-slideless-ai.cloudfunctions.net/addPresentationToken

Node.js

const res = await fetch(
  'https://europe-west1-slideless-ai.cloudfunctions.net/addPresentationToken',
  {
    method: 'POST',
    headers: {
      'Authorization': `Bearer ${process.env.SLIDELESS_API_KEY}`,
      'Content-Type': 'application/json'
    },
    body: JSON.stringify({ presentationId: '0192f1c3-...', tokenName: 'Acme Corp' })
  }
);
const { data } = await res.json();
console.log('Send this URL to the recipient:', data.shareUrl);

Errors

StatusCodeCauseFix
400invalid-argumentpresentationId or tokenName missing or wrong type / emptySend both as non-empty strings
401unauthenticatedMissing or invalid API keySet a valid Authorization header
403permission-deniedKey’s user is not the presentation’s ownerUse a key from the owner’s account
404not-foundNo presentation with that presentationIdVerify with listMyPresentations
405method-not-allowedUsed GET/PUT/etc.Use POST
500internalBackend errorRetry with exponential backoff

Next