> ## Documentation Index
> Fetch the complete documentation index at: https://dev.puppetvendors.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Upload Product Media

> Upload media to Shopify staging for later use in product creation

<Note>
  **V2 Preview** — This endpoint is part of the V2 API preview. Breaking changes may occur.
</Note>

## Overview

Upload media to Shopify staging for later use in product creation. Returns a staged upload URL, HTTP parameters to POST the binary to, and a `resourceUrl` that can be passed into subsequent `productSet` calls.

## Request Body

See `ProductMediaUploadRequest` in the OpenAPI spec. Typical fields:

<ParamField body="filename" type="string" required />

<ParamField body="mimeType" type="string" required>
  E.g. `image/png`, `image/jpeg`, `video/mp4`.
</ParamField>

<ParamField body="resource" type="string" required>
  Shopify resource type — usually `IMAGE` or `VIDEO`.
</ParamField>

<ParamField body="fileSize" type="string">
  Size in bytes (some MIME types require this).
</ParamField>

## Response

```json 200 theme={null}
{
  "success": true,
  "data": {
    "url": "https://shopify-staged-uploads.storage.googleapis.com/...",
    "resourceUrl": "gid://shopify/StagedUploadTarget/...",
    "parameters": {
      "Content-Type": "image/png",
      "acl": "private"
    }
  }
}
```

## Example

```bash theme={null}
curl -X POST "https://staging-api.puppetvendors.com/products/media" \
  -H "x-access-token: YOUR_VENDOR_JWT" \
  -H "Content-Type: application/json" \
  -d '{
    "filename": "hero.png",
    "mimeType": "image/png",
    "resource": "IMAGE"
  }'
```
