> For the complete documentation index, see [llms.txt](https://help.citrusad.com/retail-media-interface/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.citrusad.com/retail-media-interface/partner/cs/campaign-management-api/creativeassets/uploadfile-2.md).

# Nahrát soubor kampaně - v4

{% hint style="info" %}
Pokyny pro nahrávání souborů

* **Limit velikosti souboru**: Maximální podporovaná velikost souboru je 4 GB.
* **Podporované typy souborů bannerů**: Rozhraní API v současnosti přijímá následující formáty souborů: PNG, JPEG a JPG.
* **Podporované typy souborů bannerů X**: Rozhraní API v současnosti přijímá následující formáty souborů: PNG, JPEG, JPG, SVG a GIF.
* **Podporované typy souborů standardního zobrazovaného loga obsahu**: Rozhraní API v současnosti přijímá následující formáty souborů: JPEG, JPG a PNG.
* **Rozměry obrázku**: Rozměry obrázku jsou v současnosti ověřovány vůči obsahovému standardu prodejce.
* **Zpracování více souborů**: Pokud je v jediném požadavku odosláno více souborů, zpracuje se pouze první soubor a zbývající soubory budou ignorovány.
* BannerX\*\*: Pro `Campaign_File_Type_Banner_X_Image`je povinné zadat slot ID, content standard ID, slotType a imageType.
* Banner\*\*: Pro `Campaign_File_Type_Banner_Image`je povinné zadat slot ID, content standard ID a team ID.
* Značková stránka\*\*: Pro `Campaign_File_Type_Brand_Page_Image`je povinné poskytnout obrázek značkové stránky. Podporované formáty zahrnují PNG, JPEG, JPG, SVG a GIF.
  {% endhint %}

{% hint style="info" %}
URL pro nahrání souboru

Při nahrávání souboru svého reklamního materiálu se ujistěte, že uvádíte úplnou absolutní cestu k souboru. Pokud kopírujete ukázkový testovací kód z dokumentace pro použití ve svém prostředí, nezapomeňte před spuštěním příkazu aktualizovat umístění souboru. Například:

curl --request POST --url 'https\://\<your-url>.test.com/v4/campaign-file-upload?contentStandardId=test1\&imageType=IMAGE\_TYPE\_UNSPECIFIED\&campaignFileType=CAMPAIGN\_FILE\_TYPE\_BANNER\_IMAGE' --header 'accept: application/json' --header 'Authorization: Bearer \<your-token>' --header 'content-type: multipart/form-data' --form "file=**@/Users/test/downloads/apple.png**"
{% endhint %}

## Upload a campaign file - v4

> This endpoint allows uploading different types of campaign files including banners, banner X, and brand pages. It includes support for hero image display modes and background positioning controls. Accepted formats include JPEG, JPG, PNG, GIF, PDF, and SVG for banners, banner X, and brand page campaigns, along with standard PDF files for content. Display logos must be in JPEG, JPG, or PNG format.

```json
{"openapi":"3.0.0","info":{"title":"File Upload API","version":"a21"},"servers":[{"description":"Campaign server","url":"https://campaign.<env>.citrusad.com/v4"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"scheme":"bearer","type":"http"}},"schemas":{"campaignfileupload_body":{"properties":{"file":{"description":"The campaign file to upload, which can include an image, content standard display logo, or content standard PDF for banners and banner X. \n  - Supported image formats are jpeg, jpg, png, gif, PDF, and SVG. \n  - Display logos must be in jpeg, jpg, or png format.","format":"binary","type":"string"}},"required":["file"],"type":"object"},"v3UploadFileResponse":{"properties":{"fileId":{"description":"The unique identifier of the uploaded file.","type":"string"},"fileUrl":{"description":"The URL to access the file uploaded.","type":"string"}},"type":"object"},"rpcStatus":{"properties":{"code":{"type":"integer"},"details":{"items":{"type":"object"},"type":"array"},"message":{"type":"string"}},"type":"object"}}},"paths":{"/campaign-file-upload":{"post":{"description":"This endpoint allows uploading different types of campaign files including banners, banner X, and brand pages. It includes support for hero image display modes and background positioning controls. Accepted formats include JPEG, JPG, PNG, GIF, PDF, and SVG for banners, banner X, and brand page campaigns, along with standard PDF files for content. Display logos must be in JPEG, JPG, or PNG format.","operationId":"uploadFile","parameters":[{"description":"The template ID that determines the type of file that can be uploaded and where it will appear in the campaign. This configuration defines accepted file formats, size limits, and display requirements.","in":"query","name":"contentStandardId","schema":{"type":"string"}},{"description":"The specific location where the image will appear in the campaign template. Ensures the image adheres to predefined slot requirements and validations. Examples include left_ribbon, top_banner, or side_panel.","in":"query","name":"slotId","schema":{"type":"string"}},{"description":"Placement options for the image within the campaign include main background, secondary background, hero image, and more.","in":"query","name":"slotType","required":false,"schema":{"enum":["SLOT_TYPE_BANNER","IMAGE_TYPE_DOUBLE_TILE","IMAGE_TYPE_SINGLE_TILE"],"type":"string"}},{"description":"The unique identifier of the campaign team.","in":"query","name":"teamId","required":false,"schema":{"type":"string"}},{"description":"Manager team ID for the campaign. Applicable only to fixed tenancy campaigns.","in":"query","name":"managerTeamId","required":false,"schema":{"type":"string"}},{"description":"Placement options for the image within the campaign include main background, secondary background, hero image, and more.","in":"query","name":"imageType","required":false,"schema":{"enum":["IMAGE_TYPE_PRIMARY_BACKGROUND","IMAGE_TYPE_SECONDARY_BACKGROUND","IMAGE_TYPE_PRIMARY_HERO","IMAGE_TYPE_SECONDARY_HERO"],"type":"string"}},{"description":"Specifies the campaign file type: Supported types include: -\n  - CAMPAIGN_FILE_TYPE_BANNER_IMAGE: Image for your banner campaign. -\n  - CAMPAIGN_FILE_TYPE_BANNER_X_IMAGE: Image for your banner X campaign. -\n  - CAMPAIGN_FILE_TYPE_BANNER_X_CONTENT_STANDARD_DISPLAY_LOGO: Display logo for your banner X content standard file. \n  - CAMPAIGN_FILE_TYPE_BANNER_CONTENT_STANDARD_DISPLAY_LOGO: Display logo for\nyour banner content standard file. -\n  - CAMPAIGN_FILE_TYPE_BANNER_X_CONTENT_STANDARD_PDF: Content standard PDF for\nyour banner X campaign. \n  - CAMPAIGN_FILE_TYPE_BANNER_CONTENT_STANDARD_PDF:\nContent standard PDF for your banner campaign. \n  - CAMPAIGN_FILE_TYPE_BRAND_PAGE_IMAGE: Image for your BRAND PAGE campaign.","in":"query","name":"campaignFileType","required":true,"schema":{"enum":["CAMPAIGN_FILE_TYPE_BANNER_IMAGE","CAMPAIGN_FILE_TYPE_BANNER_X_IMAGE","CAMPAIGN_FILE_TYPE_BANNER_X_CONTENT_STANDARD_DISPLAY_LOGO","CAMPAIGN_FILE_TYPE_BANNER_X_CONTENT_STANDARD_PDF_FILE","CAMPAIGN_FILE_TYPE_BANNER_CONTENT_STANDARD_DISPLAY_LOGO","CAMPAIGN_FILE_TYPE_BANNER_CONTENT_STANDARD_PDF_FILE","CAMPAIGN_FILE_TYPE_BRAND_PAGE_IMAGE"],"type":"string"}}],"requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/campaignfileupload_body"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/v3UploadFileResponse"}}},"description":"File uploaded successfully"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/rpcStatus"}}},"description":"There was a problem with input."},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/rpcStatus"}}},"description":"Login failed or token not valid."},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/rpcStatus"}}},"description":"Access denied due to insufficient permissions."},"default":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/rpcStatus"}}},"description":"An unexpected error response."}},"summary":"Upload a campaign file - v4"}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://help.citrusad.com/retail-media-interface/partner/cs/campaign-management-api/creativeassets/uploadfile-2.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
