---
title: "Render and save a meme"
method: POST
path: "/memes/render"
tags: ["Media"]
---

# Render and save a meme

`POST /memes/render`

## Request

- Base URL: `https://app.openpo.st/api/v1`
- URL: `https://app.openpo.st/api/v1/memes/render`
- Auth: one of:
  - HTTP bearer
  - API key in cookie `openpost_session`

## Request body

- RenderMemeInputBody
  - `$schema` string, uri: A URL to the JSON Schema for this object.
  - `alt_text` string: Alternative text saved with the media
  - `captions` string[], nullable, required: Caption values in template order
  - `filename` string: Output filename; its extension must match the rendered format (.jpg for jpg or jpeg). Defaults to the template-based filename.
  - `format` 'png' | 'jpg' | 'jpeg' | 'gif' | 'webp': Rendered image format
  - `overlay_media_ids` string[], nullable: Workspace media IDs for replaceable image slots
  - `parent_media_id` string: Prior generated media when this is an edited version
  - `retention_class` 'library' | 'temporary': Keep in the library or manage as temporary post media
  - `template_id` string, required: OpenPost meme template ID
  - `workspace_id` string, required: Workspace ID

## Response `200`

OK

- RenderMemeOutputBody
  - `$schema` string, uri: A URL to the JSON Schema for this object.
  - `media` MediaUploadResult, required
    - `$schema` string, uri: A URL to the JSON Schema for this object.
    - `alt_text` string, required: Persisted alt text
    - `analysis_error` string: Media analysis error
    - `analysis_status` string, required: Media analysis status
    - `asset_kind` string, required: Media library role
    - `deduped` boolean, required: Whether an existing media attachment was reused
    - `design_document_id` string: Producing OpenPost Image Editor design ID
    - `design_page_id` string: Producing OpenPost Image Editor page ID
    - `id` string, required: Media ID
    - `mime_type` string, required: MIME type
    - `original_filename` string, required: Persisted original filename
    - `parent_media_id` string: Source media ID
    - `poster_thumbnail_url` string: Poster thumbnail URL
    - `processing_progress` integer, required: Server processing progress from 0 to 100
    - `processing_status` string, required: Media processing status
    - `retention_class` 'library' | 'temporary', required: Media lifecycle class
    - `size` integer, required: File size in bytes
    - `source` string, required: Media provenance
    - `url` string, required: URL to access the media
  - `recipe` MemeRecipeResponse, required
    - `$schema` string, uri: A URL to the JSON Schema for this object.
    - `catalog_revision` string
    - `created_at` string, required
    - `created_by_id` string, required
    - `kind` string, required
    - `media_id` string, required
    - `recipe` MemeRecipeDocument, required
      - `alt_text` string
      - `captions` string[], nullable, required
      - `catalog_revision` string, required
      - `format` string, required
      - `overlay_media_ids` string[], nullable
      - `parent_media_id` string
      - `rendered_mime_type` string, required
      - `renderer_key` string, required
      - `schema_version` integer, required
      - `template` MemeRecipeTemplateSnapshot, required
        - `id` string, required
        - `lines` integer, required
        - `name` string, required
        - `overlays` integer, required
        - `source_url` string
    - `renderer_key` string, required
    - `template_id` string, required
    - `template_name` string, required
    - `template_source_url` string
    - `workspace_id` string, required

## Other responses

- `400`: Bad Request
- `403`: Forbidden
- `404`: Not Found
- `413`: Request Entity Too Large
- `422`: Unprocessable Entity
- `429`: Too Many Requests
- `500`: Internal Server Error
- `502`: Bad Gateway
- `503`: Service Unavailable

---

[API](https://skmtc.dev/openpo/apis/openpost-api.md) · [All operations](https://skmtc.dev/openpo/apis/openpost-api/llms.txt) · [OpenAPI document](https://skmtc.dev/openpo/apis/openpost-api/revisions/67d3964458a7?raw)
