创建我的第一个广告活动
文档菜单
POST/api/v1/assets

File library

Upload images, logos and fonts to the workspace library, list them and remove them.

The library holds the images, logos and fonts your concepts use. Through the API you use it, for example, to upload the images of a reference composition before creating the banner.

Upload a file

POST /api/v1/assets is multipart/form-data and requires the assets permission. It accepts PNG, JPG, WebP, SVG and WOFF2, up to 5 MB. It responds 201 with the file.

FieldRequirementDescription
file
Required
The file.
licenseAck
Required
The app's rights checkbox: true. Without it, it responds 400.
kindstring
Optional
image, logo or font.
tagsstring
Optional
Comma-separated tags.
namestring
Optional
Name; if omitted, the file's.

List, read and remove

  • GET /api/v1/assets lists the library, with kind, tag, q and cursor pagination.
  • GET /api/v1/assets/:id returns a file: id, kind, name, mime, bytes, width, height, tags.
  • DELETE /api/v1/assets/:id removes it (requires assets) and responds 204. It is a soft delete: the file is kept for 30 days.
这一页对你有帮助吗?