returnAttachmentUpload
A signed URL to upload one attachment to
Arguments
| Argument | Type | Description |
|---|---|---|
filename | String! | |
contentType | String! |
Returns
ReturnAttachmentUploadResponse!
| Field | Type | Description |
|---|---|---|
upload | ReturnAttachmentUpload | |
returnErrors | [ReturnAttachmentUploadError!] | Such as a content type or size the server refuses |
Example
mutation ReturnAttachmentUpload($filename: String!, $contentType: String!) { returnAttachmentUpload(filename: $filename, contentType: $contentType) { upload { attachmentId uploadUrl expiresAt } returnErrors { __typename ... on ValidationError { message } ... on ReturnError { message code } } }}{ "filename": "Example", "contentType": "Example"}{ "data": { "returnAttachmentUpload": { "upload": { "attachmentId": "id-1", "uploadUrl": "https://example.com/", "expiresAt": "2026-10-01T09:30:00Z" }, "returnErrors": [ { "__typename": "ValidationError", "message": "Example" } ] } }}The query selects the return type's fields two levels deep; pick the ones you need. The response shows its shape with placeholder values.
Served by
| @evolve-framework/commercetools | Resolved |
Used by
The storefront packages that send it, in these GraphQL documents:
- @evolve-storefront/feature-return:
ReturnAttachmentUpload

