Photoshop Files API

Upload a PSD file

post

Uploads a PSD file and optionally creates a mockup template.

Authorizations
x-api-keystringRequired

API key required for authentication.

Header parameters
Acceptstring · enumRequired

The request must accept JSON responses.

Possible values:
x-api-keystringRequired

API key required for authentication.

Example: YOUR_API_KEY_HERE
Body
psd_file_urlstringRequired

The URL to the PSD file.

Example: https://drive.google.com/uc?export=download&id=11Low2n7A8_GeMWQkRXmmGXTOJOewRW4Q
psd_namestringOptional

An optional name for the PSD file.

Example: My custom name
psd_category_idintegerOptional

An optional category ID for the PSD file.

Example: 3
Responses
200

Successful PSD upload operation.

application/json
post
/psd/upload
POST /api/v1/psd/upload HTTP/1.1
Host: app.dynamicmockups.com
x-api-key: text
Accept: application/json
Content-Type: application/json
Content-Length: 249

{
  "psd_file_url": "https://drive.google.com/uc?export=download&id=11Low2n7A8_GeMWQkRXmmGXTOJOewRW4Q",
  "psd_name": "My custom name",
  "psd_category_id": 3,
  "mockup_template": {
    "create_after_upload": true,
    "collections": [
      "c6585e16-16ff-4961-91ad-e10757c385b2"
    ]
  }
}
{
  "data": {
    "uuid": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "name": "My custom name"
  },
  "success": true,
  "message": "PSD uploaded successfully"
}

Delete a PSD file

post

Deletes a PSD file by UUID with optional deletion of related mockups.

Authorizations
x-api-keystringRequired

API key required for authentication.

Header parameters
Acceptstring · enumRequired

The request must accept JSON responses.

Possible values:
x-api-keystringRequired

API key required for authentication.

Example: YOUR_API_KEY_HERE
Body
psd_uuidstringRequired

The UUID of the PSD file to delete.

Example: a1b2c3d4-e5f6-7890-abcd-ef1234567890
delete_related_mockupsbooleanOptional

Whether to delete all mockups related to this PSD file.

Example: false
Responses
200

Successful PSD deletion operation.

application/json
post
/psd/delete
POST /api/v1/psd/delete HTTP/1.1
Host: app.dynamicmockups.com
x-api-key: text
Accept: application/json
Content-Type: application/json
Content-Length: 82

{
  "psd_uuid": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
  "delete_related_mockups": false
}
{
  "data": [],
  "success": true,
  "message": "PSD file deleted successfully."
}

Export OpenAPI specification for PSD Upload API

psd_category_id

If you do not provide this optional parameter, your uploaded PSD file will automatically be assigned to the default "Other" category.

This is the list of available PSD Category IDs at this moment:


        {
            "id": 1,
            "name": "T-shirts",
        },
        {
            "id": 2,
            "name": "Hoodies",    
        },
        {
            "id": 3,
            "name": "Wall Art",
        },
        {
            "id": 4,
            "name": "Mugs",
        },
        {
            "id": 5,
            "name": "Sweatshirts",
        },
        {
            "id": 6,
            "name": "Other", //default category if not provided as psd_category_id
        },
        {
            "id": 7,
            "name": "Pillows",
        },
        {
            "id": 8,
            "name": "Tote Bags",
        },
        {
            "id": 9,
            "name": "Phone Cases",
        },
        {
            "id": 10,
            "name": "Blankets",
        }

mockup_template.create_after_upload

If you are subscribed to our PRO plans and have uploaded your own Photoshop files using our web application, you know that after uploading PSD files you need to create a Mockup first from the uploaded PSD file and then use Mockup UUID and all other Mockup components via Render API.

Now you can fully automate this flow!

If you provide mockup_template.create_after_upload: true A mockup will be automatically created from the uploaded PSD file and our API will return in response a lot of useful data regarding the created mockup.

After mockup creation is successful, use the Mockup UUID and Smart Object UUIDs field to render images automatically using our Render API.

Response example

{
    "data": {
        "uuid": "65c10d09-6724-4026-89a4-2cbf00f8670f", //Mockup UUID
        "name": "My mockup automatically created after PSD upload",
        "thumbnail": "https://app-design-copilot-localhost.s3.eu-central-1.amazonaws.com/mockup/251/thumbnail.webp",
        "smart_objects": [
            {
                "uuid": "c39de536-7255-40d4-9458-6215355a5e30",
                "name": "T-shirt"
            },
            {
                "uuid": "2574e3aa-74a3-4fee-b10d-aa3721f2ee26",
                "name": "Background"
            }
        ],
        "collections": [],
        "psd": {
            "uuid": "38607fc2-fa2d-4113-ba70-8bded3f44c23",
            "name": "My custom name"
        }
    },
    "success": true,
    "message": ""
}

This created Mockup will regularly show as any other created mockup in the web application. You can even fetch it using the Get Mockups API when you need it.

mockup_template.collections

You probably noticed the collections field that has an empty array from the previous example.

In the Collections API, you can create and retrieve collections.

You may provide a collections optional field to the PSD Upload API to automatically put the created mockup in the collections array of strings, which will be returned in the PSD Upload API response as well, instead of an empty array.

Last updated

Was this helpful?