Skip to main content
GET
/
media
/
:id
Get Media
curl --request GET \
  --url https://api.example.com/media/:id

Endpoint

GET /media/:id

ID format

Supported IDs:
  • post-{postId}
  • author-{authorId}
Examples:
  • post-post_01HZX2...
  • author-author_01HZ...

Query parameters

ParameterTypeDescription
_fieldsstringComma-separated attribute field filter

Example request

curl "https://api.skayle.ai/v1/ORG_ID/media/post-post_01HZX2..."

Example response

{
  "data": {
    "id": "post-post_01HZX2...",
    "type": "media",
    "attributes": {
      "source": "post",
      "source_id": "post_01HZX2...",
      "url": "https://cdn.example.com/images/hero-1.jpg",
      "type": "image",
      "title": "B2B SaaS Content Strategy for 2026",
      "description": "Editorial hero composition",
      "aspect_ratio": "16:9",
      "created_at": "2026-02-01T09:20:11.000Z"
    },
    "links": {
      "self": "/v1/ORG_ID/media/post-post_01HZX2..."
    }
  }
}

Error responses

Invalid media ID format

{
  "errors": [
    {
      "status": "400",
      "title": "Bad Request",
      "detail": "Invalid media ID format"
    }
  ]
}

Media not found

{
  "errors": [
    {
      "status": "404",
      "title": "Not Found",
      "detail": "Media with id \"post-missing\" not found"
    }
  ]
}

Response field descriptions

FieldTypeDescription
data.idstringMedia ID
data.typestringResource type (media)
data.attributes.sourcestringpost or author
data.attributes.source_idstringRelated post/author ID
data.attributes.urlstringMedia URL
data.attributes.typestringMedia type (image)
data.attributes.titlestring | nullTitle
data.attributes.descriptionstring | nullDescription
data.attributes.aspect_ratiostring | nullAspect ratio
data.attributes.paletteobject | nullPalette metadata
data.attributes.created_atstringISO datetime

Notes

  • Media IDs are not slug-based.
  • Single media fetch expects exact media ID format.