
andreasjansson/svg-to-png
Public
4
runs
Run andreasjansson/svg-to-png with an API
Use one of our client libraries to get started quickly. Clicking on a library will take you to the Playground tab where you can tweak different inputs, see the results, and copy the corresponding code to use in your own project.
Input schema
The fields you can use to run this model with an API. If you don't give a value for a field its default value will be used.
Field | Type | Default value | Description |
---|---|---|---|
svg_file |
string
|
SVG file to convert to PNG
|
|
width |
integer
|
1024
Min: 1 Max: 8192 |
Output width in pixels
|
height |
integer
|
Min: 1 Max: 8192 |
Output height in pixels (maintains aspect ratio if not specified)
|
background_color |
string
|
transparent
|
Background color (e.g., 'white', 'transparent', '#FF0000')
|
{
"type": "object",
"title": "Input",
"required": [
"svg_file"
],
"properties": {
"width": {
"type": "integer",
"title": "Width",
"default": 1024,
"maximum": 8192,
"minimum": 1,
"x-order": 1,
"description": "Output width in pixels"
},
"height": {
"type": "integer",
"title": "Height",
"maximum": 8192,
"minimum": 1,
"x-order": 2,
"nullable": true,
"description": "Output height in pixels (maintains aspect ratio if not specified)"
},
"svg_file": {
"type": "string",
"title": "Svg File",
"format": "uri",
"x-order": 0,
"description": "SVG file to convert to PNG"
},
"background_color": {
"type": "string",
"title": "Background Color",
"default": "transparent",
"x-order": 3,
"description": "Background color (e.g., 'white', 'transparent', '#FF0000')"
}
}
}
Output schema
The shape of the response you’ll get when you run this model with an API.
Schema
{
"type": "string",
"title": "Output",
"format": "uri"
}