POST: Brand Asset Image
Learn how to upload brand assets to your workspace
Overview
This endpoint allows you to upload new brand assets (images) to your workspace. You can upload images from a URL or as a base64-encoded string.
https://api.orshot.com/v1/brand-assets/images/addRequest
await fetch("https://api.orshot.com/v1/brand-assets/images/add", {
method: "POST",
headers: {
"Content-Type": "application/json",
Authorization: "Bearer <ORSHOT_API_KEY>",
},
body: JSON.stringify({
file: "https://example.com/path/to/image.png",
fileName: "company-logo.png", // optional
fileType: "image/png", // optional
}),
});await fetch("https://api.orshot.com/v1/brand-assets/images/add", {
method: "POST",
headers: {
"Content-Type": "application/json",
Authorization: "Bearer <ORSHOT_API_KEY>",
},
body: JSON.stringify({
file: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAA...",
fileName: "product-image.png", // optional
meta: { // optional
description: "Product image for website",
category: "products"
}
}),
});{
"data": {
"asset": {
"id": "01234567-89ab-cdef-0123-456789abcdef",
"created_at": "2025-09-11T10:15:30.123Z",
"direct_url": "https://storage.orshot.com/brand-assets/workspace_id/company-logo.png",
"file_name": "company-logo.png",
"file_size": 24680,
"workspace_id": "98765432-10fe-dcba-9876-543210fedcba",
"user_id": "abcdef01-2345-6789-abcd-ef0123456789"
},
"url": "https://storage.orshot.com/brand-assets/workspace_id/company-logo.png"
}
}Request Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
file | String | Yes | URL or base64-encoded string of the image |
fileName | String | No | Custom filename for the asset (default: auto-generated based on timestamp) |
fileType | String | No | MIME type of the file (e.g., "image/png"). If not provided, it will be detected from the file |
Supported Image Formats
- PNG (
image/png) - JPEG (
image/jpeg) - WebP (
image/webp) - SVG (
image/svg+xml) - GIF (
image/gif)
Notes
- Images are automatically optimized and resized if needed (maximum dimensions: 2000x2000 pixels)
- Maximum file size: 3MB
- SVG files are not optimized to preserve their vector format
Rate Limits
- 30 requests per minute per endpoint