Request content types

Use application/json for URL-based inputs across all Creative APIs. Use multipart/form-data only when an endpoint supports binary file uploads. Images can also be sent as base64 data URIs in image_url.

Picsart Creative APIs support a consistent set of request content types so you can integrate in the way that best matches your stack and asset flow.

  • application/json is supported across Creative APIs and is the recommended choice for URL-based inputs.
  • multipart/form-data is supported only for endpoints that accept binary file uploads (typically image uploads).
  • For image inputs, image_url can be either a normal https:// URL or a base64 data URI.

If you are unsure whether a specific endpoint supports file upload or which fields it accepts, follow the endpoint schema in the API reference.

Supported Content-Types

application/json

Use application/json when you pass media as URLs (for example, image_url, video_url) and when you want simpler request construction.

What to expect:

  • Parameters are sent as a JSON body.
  • Media inputs must be provided via *_url fields.
  • Binary file uploads are not supported in JSON requests.

Applies to:

  • Programmable Image APIs
  • Programmable Video APIs
  • GenAI APIs
  • Other Creative API families that accept URL-based inputs

multipart/form-data

Use multipart/form-data only when an endpoint supports uploading a binary image (for example, a local file coming directly from a user upload flow).

What to expect:

  • The media file is sent as a form file field (commonly named image, but the exact field name depends on the endpoint).
  • Other parameters are sent as additional form fields.
  • If an endpoint does not document a file field, do not use multipart for it.

Important:

  • Multipart is not required when you pass image_url. In that case, JSON is usually simpler.

Media inputs

URL inputs

Many endpoints accept media via URL fields such as:

  • image_url (images)
  • video_url (videos)

Requirements:

  • The URL must be accessible for the Picsart service to fetch.
  • Use a stable URL that remains available for the duration of the request.

Binary uploads

Binary uploads are available only for endpoints that explicitly support it (typically image endpoints that define an image file field).

If you need to send a local file:

  • Use multipart/form-data
  • Provide the file in the documented file field
  • Provide any other parameters as form fields

Base64 image support using data URIs in image_url

For image-based endpoints that accept image_url, you can provide an image inlined as a data URI.

This is useful when:

  • You want to use application/json
  • You do not want to host the image at a public URL
  • You still want a single request body format across your integration

Format

data:<mime_type>;base64,<base64_bytes>

Example

{
  "image_url": "data:image/jpeg;base64,/9j/4QAiRXhpZgAASUkqAAgAAAABABIBA..."
}

Notes:

  • Use the correct MIME type (for example image/jpeg, image/png).
  • Data URIs increase payload size. Make sure your own infrastructure supports the resulting request sizes.

Which content type should you use?

Use application/json when:

  • You provide inputs as URLs (image_url, video_url, and similar)
  • You want simpler debugging and easier client implementation
  • Your platform already stores assets in object storage or a CDN

Use multipart/form-data when:

  • You need to upload a local image file directly
  • The endpoint explicitly supports a binary file field (check the API reference)

Use base64 data URIs in image_url when:

  • You want JSON requests
  • You cannot reliably host the image at a URL
  • You accept larger request bodies as the tradeoff

Video API note

Programmable Video APIs accept application/json and use video_url as the input method. Binary video uploads are not supported.