Skip to main content
PATCH
/
v1
/
posts
/
{id}
/
upload-carousel
Upload a carousel (PDF) to a post
curl --request PATCH \
  --url https://api.yalg.ai/v1/posts/{id}/upload-carousel \
  --header 'Content-Type: multipart/form-data' \
  --header 'x-api-key: <api-key>' \
  --form carousel='@example-file' \
  --form 'title=Founder lessons carousel'
{
  "id": "123e4567-e89b-12d3-a456-426614174000",
  "content": "Post content...",
  "imageUrl": null,
  "videoUrl": null,
  "carouselUrl": "/uploads/carousels/1640123456789-example.pdf",
  "carouselTitle": "My Carousel Title",
  "authorId": "987fcdeb-51a2-43d7-8f9e-123456789abc",
  "createdAt": "2024-01-15T10:30:00Z",
  "updatedAt": "2024-01-15T10:35:00Z"
}

Authorizations

x-api-key
string
header
default:yalg_live_your_api_key
required

YALG Developer API key. Send it in the x-api-key header from a server-side environment only.

Path Parameters

id
string
required

UUID of the post

Example:

"123e4567-e89b-12d3-a456-426614174000"

Body

multipart/form-data

PDF file for carousel

title
string
required

Title for the carousel document (required by LinkedIn)

Response

Carousel uploaded successfully