PSD Upload API
Uploads a PSD file and optionally creates a mockup template.
The request must accept JSON responses.
API key required for authentication.
YOUR_API_KEY_HERE
The URL to the PSD file.
https://drive.google.com/uc?export=download&id=11Low2n7A8_GeMWQkRXmmGXTOJOewRW4Q
An optional name for the PSD file.
My custom name
An optional category ID for the PSD file.
3
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": [],
"success": true,
"message": "PSD uploaded 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": []
},
"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.
You can create collections in our web application and use the Get Collections API to 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.
Please note that if you want to add the mockup to the collections automatically after the PSD Upload, you must set mockup_template.create_after_upload
to true
Last updated
Was this helpful?