Documentation menu

Shares

Create and revoke shareable preview links for a post.

GET /posts/{id}/shares

Requires Authorization: Bearer <token>.

Path parameters

FieldTypeNotes
idrequiredstring

Query parameters

FieldTypeNotes
per_pageintegernullable1–100

Example request

curl 'https://app.shoutrrr.com/api/v1/posts/{id}/shares' \
  -H 'Authorization: Bearer <token>'
const res = await fetch('https://app.shoutrrr.com/api/v1/posts/{id}/shares', {
  method: 'GET',
  headers: {
    'Authorization': 'Bearer <token>',
  },
});
const data = await res.json();
import requests

res = requests.get(
    'https://app.shoutrrr.com/api/v1/posts/{id}/shares',
    headers={'Authorization': 'Bearer <token>'},
)
data = res.json()
<?php
$ch = curl_init('https://app.shoutrrr.com/api/v1/posts/{id}/shares');
curl_setopt_array($ch, [
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_CUSTOMREQUEST => 'GET',
    CURLOPT_HTTPHEADER => [
        'Authorization: Bearer <token>',
    ],
]);
$data = json_decode(curl_exec($ch), true);

Responses

200

FieldTypeNotes
datarequiredobject
paginationrequiredobject
per_pagerequiredinteger
next_cursorrequiredstringnullable
prev_cursorrequiredstringnullable
has_morerequiredboolean

401 Unauthenticated

FieldTypeNotes
messagerequiredError overview.string

422 Validation error

FieldTypeNotes
messagerequiredErrors overview.string
errorsrequiredA detailed description of each field that failed validation.object

POST /posts/{id}/shares

Requires Authorization: Bearer <token>.

Path parameters

FieldTypeNotes
idrequiredstring

Request body

FieldTypeNotes
expires_atstringnullableformat: date-time

Example request

curl -X POST 'https://app.shoutrrr.com/api/v1/posts/{id}/shares' \
  -H 'Authorization: Bearer <token>' \
  -H 'Content-Type: application/json' \
  -d '{
  "expires_at": "2026-01-01T09:00:00Z"
}'
const res = await fetch('https://app.shoutrrr.com/api/v1/posts/{id}/shares', {
  method: 'POST',
  headers: {
    'Authorization': 'Bearer <token>',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
  "expires_at": "2026-01-01T09:00:00Z"
}),
});
const data = await res.json();
import requests

res = requests.post(
    'https://app.shoutrrr.com/api/v1/posts/{id}/shares',
    headers={'Authorization': 'Bearer <token>'},
    json={
        'expires_at': '2026-01-01T09:00:00Z'
    },
)
data = res.json()
<?php
$ch = curl_init('https://app.shoutrrr.com/api/v1/posts/{id}/shares');
curl_setopt_array($ch, [
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_CUSTOMREQUEST => 'POST',
    CURLOPT_POSTFIELDS => '{
  "expires_at": "2026-01-01T09:00:00Z"
}',
    CURLOPT_HTTPHEADER => [
        'Authorization: Bearer <token>',
        'Content-Type: application/json',
    ],
]);
$data = json_decode(curl_exec($ch), true);

Responses

201

FieldTypeNotes
idrequiredstring
urlrequiredstring
expires_atrequiredstringnullable

401 Unauthenticated

FieldTypeNotes
messagerequiredError overview.string

422 Validation error

FieldTypeNotes
messagerequiredErrors overview.string
errorsrequiredA detailed description of each field that failed validation.object

DELETE /posts/{id}/shares/{shareId}

Requires Authorization: Bearer <token>.

Path parameters

FieldTypeNotes
idrequiredstring
shareIdrequiredstring

Example request

curl -X DELETE 'https://app.shoutrrr.com/api/v1/posts/{id}/shares/{shareId}' \
  -H 'Authorization: Bearer <token>'
const res = await fetch('https://app.shoutrrr.com/api/v1/posts/{id}/shares/{shareId}', {
  method: 'DELETE',
  headers: {
    'Authorization': 'Bearer <token>',
  },
});
const data = await res.json();
import requests

res = requests.delete(
    'https://app.shoutrrr.com/api/v1/posts/{id}/shares/{shareId}',
    headers={'Authorization': 'Bearer <token>'},
)
data = res.json()
<?php
$ch = curl_init('https://app.shoutrrr.com/api/v1/posts/{id}/shares/{shareId}');
curl_setopt_array($ch, [
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_CUSTOMREQUEST => 'DELETE',
    CURLOPT_HTTPHEADER => [
        'Authorization: Bearer <token>',
    ],
]);
$data = json_decode(curl_exec($ch), true);

Responses

200

FieldTypeNotes
revokedrequiredboolean

401 Unauthenticated

FieldTypeNotes
messagerequiredError overview.string

404 Not found

FieldTypeNotes
messagerequiredError overview.string