Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.pixy.art/llms.txt

Use this file to discover all available pages before exploring further.

Supported Modifications

The generate endpoint applies object-level modifications before rendering.
ModificationText elementsImage elementsSVG / shape elements
text✅ Yes❌ No❌ No
fill✅ Yes❌ No✅ Yes
stroke✅ Yes✅ Yes✅ Yes
src❌ No✅ Yes❌ No

Examples

Replace Text

{
  "modifications": [
    {
      "id": "YOUR_ELEMENT_ID",
      "text": "Spring launch sale"
    }
  ]
}
Text changes keep the original text element’s styling and position. The text box can resize based on the new content, unless that text element is using “autofit” behavior.
Text resize placeholder

Replace An Image Source

{
  "modifications": [
    {
      "id": "YOUR_ELEMENT_ID",
      "src": "https://images.example.com/product-shot.jpg"
    }
  ]
}
Replacement images are always scaled to fill the original image element’s size. If the new image has a different aspect ratio, Pixy keeps the center of the new image in view and crops the outer edges as needed so the layout stays aligned.

Change A Fill Color

{
  "modifications": [
    {
      "id": "YOUR_ELEMENT_ID",
      "fill": "#ff4d6d"
    }
  ]
}

Change A Stroke

{
  "modifications": [
    {
      "id": "YOUR_ELEMENT_ID",
      "stroke": "#1c7ed6"
    }
  ]
}
Stroke changes update the selected element’s outline color. The stroke will only be visible if that element already has a stroke width greater than 0.

Combine Multiple Changes On The Same Element

{
  "modifications": [
    {
      "id": "YOUR_ELEMENT_ID",
      "text": "New season drop",
      "fill": "#111827",
      "stroke": "#ffffff"
    }
  ]
}
You can send multiple supported fields for one element in the same modification object when they apply to that element type.

Combine Multiple Changes On Different Elements

{
  "modifications": [
    {
      "id": "YOUR_ELEMENT_ID",
      "text": "New season drop"
    },
    {
      "id": "YOUR_ELEMENT_ID_2",
      "src": "https://images.example.com/lookbook-cover.jpg"
    },
    {
      "id": "YOUR_ELEMENT_ID_3",
      "fill": "#111827"
    }
  ]
}
One request can update multiple elements at once by sending multiple modification objects, each with its own element id.