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

> ## Agent Instructions
> The base URL is https://api.sudomock.com.
> Authenticate every request with the x-api-key header. Keys begin with sm_.
> A render returns the finished image at data.print_files[0].export_path. A request sent with is_async true returns a job_id to poll at GET /api/v1/jobs/{job_id}.
> Prefer the official SDKs over hand-written HTTP calls: npm install sudomock for Node, pip install sudomock for Python.

# Preparing a PSD

> Author a Photoshop template that renders as designed.

A template you prepare once is rendered thousands of times, so the half hour
you spend in Photoshop is the cheapest half hour you will spend on it.
Everything here happens before the first upload.

> [!NOTE]
>
> Photoshop is needed only to author the template. Every render after the
> upload runs without it.

## File requirements

| Requirement | Value |
| - | - |
| Format | `.psd` or `.psb` |
| Photoshop version | CC 2015 or newer |
| Contents | At least one visible smart object or one text layer |
| Colour mode | RGB. Other modes are converted on upload. |
| Bit depth | 8-bit or 16-bit |
| Size | Up to Adobe's own PSD file size limit over the API, and 300 MB through the dashboard |

Keep the file under 100 MB when you can. Flattening the layers you never
address makes the upload faster and changes nothing about the render.

## What carries through from Photoshop

Transforms on a smart object are preserved, so build the geometry into the file
rather than into your request body.

| Transform | Use it for |
| - | - |
| Distort | Angled surfaces such as boxes and signage |
| Warp | Curved surfaces such as mugs and fabric folds |
| Rotate | Angled placement inside the scene |
| Scale | The size of the area relative to the canvas |

Perspective Warp stays live and renders to match Photoshop, so leave it in
place instead of baking it into pixels. Blend modes, opacity, masks, Drop
Shadow, Stroke, Glow, Bevel and Blend If render as authored. Rasterize 3D
layers and video layers before upload.
[Smart filters](https://sudomock.com/docs/concepts/smart-filters.md) covers what stays live, and
[PSD compatibility](https://sudomock.com/docs/psd-mockups/psd-compatibility.md) has the row-by-row table.

## Build the template

**1. Convert each design area to a smart object.**

Select the layers that will carry the design, right-click, and choose
**Convert to Smart Object**. Its contents set the size of the design area.

**2. Author the smart object contents at 3000 px or larger.**

Scaling down keeps quality and scaling up does not, so author larger than
you expect to need. Print work needs the pixels.

**3. Name every smart object and text layer for a human.**

Layer names come back in the upload response and are the only readable
handle your integration has. `Front Design` still means something six
months later. `Layer 1` and `Copy of Layer` parse fine and tell you
nothing.

**4. Make the layers you intend to address visible.**

A hidden smart object is not exposed as a slot. A hidden text layer stays a
fillable slot instead, which is how one template carries optional lines.
Both rules are in [PSD compatibility](https://sudomock.com/docs/psd-mockups/psd-compatibility.md).

**5. Stack adjustments and overlays above the design areas.**

Background at the bottom, then the product layers, then the design areas,
then overlays such as texture and shadow, and adjustments on top. In that
order a texture or a colour grade reads across the artwork the way it does
on the finished product.

**6. Flatten the layers you never address.**

**7. Embed any linked smart object.**

Linked content renders from its placement geometry, so this is optional.
**Layer > Smart Objects > Embed Linked** ends the file's dependence on
external content.

**8. Save the file as .psd or .psb in RGB.**

**9. Publish the file at a URL that answers without a session.**

The file is fetched server-side. A signed URL works. A link that redirects
to a sign-in page does not, whatever your browser shows while you are
logged in.

> [!TIP]
>
> Open the URL in a private window before you upload. A file that starts
> downloading is reachable. A sign-in page or a `403` is not.

**10. Upload the file and read back the slots you can address.**

The response lists every smart object, text layer and group layer it
detected, under the names you gave them. A layer missing from that list is
one your integration cannot address. Group outlines inside a smart object
render as designed and are not addressable on their own. The call is
[Create a mockup from a PSD](https://sudomock.com/docs/api-reference/psd-mockups/create-a-mockup-from-a-psd.md);
[Upload a PSD](https://sudomock.com/docs/psd-mockups/upload-a-psd.md) explains every field. Render once
at full size before the template goes into production.

## Learn more

> [card] [PSD compatibility](https://sudomock.com/docs/psd-mockups/psd-compatibility.md)
>
> Check a Photoshop feature before you build a template on it.

> [card] [Smart objects](https://sudomock.com/docs/psd-mockups/smart-objects.md)
>
> See how a design area is described and addressed.

## Next steps

> [card] [Upload a PSD](https://sudomock.com/docs/psd-mockups/upload-a-psd.md)
>
> Register the template once and read back every slot in it.

> [card] [Render a PSD](https://sudomock.com/docs/psd-mockups/render-a-psd-without-photoshop.md)
>
> Turn those slots into a finished image.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.