ressource.socialbetadocumentation
API referenceMedia

Attach files to one of the caller's sources

Multipart: `files` (repeat the field, up to 10). Each file succeeds or fails on its own: `attachments` lists the ones attached, `errors` the others with why. 201 when at least one was attached, 200 when none were. Someone else's source is 404. Accepted types: image/jpeg, image/jpg, image/png, image/gif, image/webp, image/svg+xml, image/avif, image/bmp, image/tiff, image/heic, image/heif, image/x-icon, image/vnd.microsoft.icon, application/pdf, application/msword, application/vnd.openxmlformats-officedocument.wordprocessingml.document, text/plain, text/markdown, application/zip, application/x-zip-compressed. At most 50 MB.

POST
/api/v1/sources/{id}/attachments

Sends a real request with your token. Prefer a read-only token; it is kept in this browser's storage.

Multipart: files (repeat the field, up to 10). Each file succeeds or fails on its own: attachments lists the ones attached, errors the others with why. 201 when at least one was attached, 200 when none were. Someone else's source is 404. Accepted types: image/jpeg, image/jpg, image/png, image/gif, image/webp, image/svg+xml, image/avif, image/bmp, image/tiff, image/heic, image/heif, image/x-icon, image/vnd.microsoft.icon, application/pdf, application/msword, application/vnd.openxmlformats-officedocument.wordprocessingml.document, text/plain, text/markdown, application/zip, application/x-zip-compressed. At most 50 MB.

Authorization

headerAuthorizationBearer <token>

A personal access token (rsk_…) or a Supabase access token.

Path Parameters

id*string
Length1 <= length

Request Body

multipart/form-data
  1. body
files*array<>
Items1 <= items

Response Body

Nothing attached — see errors

curl -X POST 'https://www.ressource.social/api/v1/sources/string/attachments' \  -F 'files=[  "string"]'
Empty