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

# Create Graphic

Add a new graphic to your library

# OpenAPI definition

```json
{
  "openapi": "3.0.1",
  "info": {
    "title": "Playout Scheduler",
    "description": "",
    "version": "1.0"
  },
  "servers": [
    {
      "url": "https://api.zype.com/"
    }
  ],
  "security": [
    {
      "api_key": []
    }
  ],
  "paths": {
    "/scheduler/v2/assets/graphics": {
      "post": {
        "summary": "Create Graphic",
        "description": "Add a new graphic to your library",
        "operationId": "createGraphic",
        "tags": [
          "Assets"
        ],
        "x-codegen-request-body-name": "graphic",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "title": "GraphicRequest",
                "type": "object",
                "required": [
                  "graphic"
                ],
                "properties": {
                  "graphic": {
                    "type": "object",
                    "title": "GraphicProperties",
                    "required": [
                      "title"
                    ],
                    "properties": {
                      "title": {
                        "type": "string"
                      },
                      "duration": {
                        "type": "number",
                        "default": 60,
                        "description": "Duration of the graphic in seconds (including fade in and fade out)"
                      },
                      "fadeIn": {
                        "type": "number",
                        "default": 0,
                        "description": "Duration of the fade in effect, in seconds"
                      },
                      "fadeOn": {
                        "type": "number",
                        "default": 0,
                        "description": "Duration of the fade out effect, in seconds"
                      },
                      "opacity": {
                        "type": "number",
                        "default": 100,
                        "description": "Opacity of image where 0 is transparent and 100 is fully opaque. Default is 100."
                      },
                      "staticOverlay": {
                        "type": "object",
                        "description": "Image overlay placement settings",
                        "required": [
                          "uploadId"
                        ],
                        "properties": {
                          "uploadId": {
                            "description": "Upload id so use as the image overlay",
                            "type": "string"
                          },
                          "yPosition": {
                            "description": "Y-axis position of the upload in the stream. 0 is the min value, in px",
                            "type": "number",
                            "default": 5
                          },
                          "xPosition": {
                            "description": "X-axis position of the upload in the stream. 0 is the min value, in px",
                            "type": "number",
                            "default": 5
                          },
                          "scale": {
                            "description": "Allows to scale down the image. Between 0 and 100",
                            "default": 100,
                            "type": "number"
                          }
                        }
                      },
                      "textOverlay": {
                        "type": "object",
                        "description": "Text overlay placement settings",
                        "required": [
                          "text"
                        ],
                        "properties": {
                          "text": {
                            "description": "Text to display. To include dynamic params, wrap the param name in {{}} and add it to the dynamicParams list",
                            "type": "string"
                          },
                          "fontSize": {
                            "description": "Font size of the text",
                            "type": "number",
                            "default": 12
                          },
                          "color": {
                            "description": "3-(RGB), 4-(ARGB), 6-(RRGGBB) or 8-digit (AARRGGBB) hexadecimal values. The \"A\" in a 4- or 8-digit hex value represents the color's alpha transparency.",
                            "type": "number",
                            "default": 5
                          },
                          "font": {
                            "description": "Text font",
                            "default": "Arial Narrow",
                            "type": "string"
                          },
                          "yPosition": {
                            "description": "Y-axis position of the text in the stream. 0 is the min value, in px",
                            "type": "number",
                            "default": 0
                          },
                          "xPosition": {
                            "description": "X-axis position of the text in the stream. 0 is the min value, in px",
                            "type": "number",
                            "default": 0
                          },
                          "width": {
                            "description": "Width of the text area",
                            "type": "number"
                          },
                          "leading": {
                            "description": "Controls the leading (or line spacing) in the text",
                            "type": "number"
                          },
                          "tracking": {
                            "description": "Controls the tracking (or letter spacing) in the text",
                            "type": "number"
                          },
                          "dynamicParams": {
                            "description": "A list of the dynamic replacements included in the text",
                            "type": "array",
                            "items": {
                              "type": "object",
                              "required": [
                                "name",
                                "sources",
                                "field"
                              ],
                              "properties": {
                                "name": {
                                  "description": "Name of the param within {{}} in the text",
                                  "type": "string"
                                },
                                "order": {
                                  "description": "Item order to use as data source (previous, current, next)",
                                  "type": "string",
                                  "enum": [
                                    "previous",
                                    "current",
                                    "next"
                                  ]
                                },
                                "sources": {
                                  "description": "A list of possible data sources, where the data will be picked in the following order: channel > block > playlist > video",
                                  "type": "array",
                                  "enum": [
                                    "channel",
                                    "block",
                                    "playlist",
                                    "video"
                                  ]
                                },
                                "field": {
                                  "description": "The field name of the source. Could be a predefined custom attribute, title or description"
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "title": "GraphicResponse",
                  "type": "object",
                  "properties": {
                    "destinationType": {
                      "title": "GraphicAsset",
                      "type": "object",
                      "required": [
                        "graphic"
                      ],
                      "properties": {
                        "asset": {
                          "type": "object",
                          "title": "GraphicProperties",
                          "properties": {
                            "id": {
                              "type": "string"
                            },
                            "title": {
                              "type": "string"
                            },
                            "duration": {
                              "type": "number",
                              "description": "Duration of the graphic in seconds (including fade in and fade out)"
                            },
                            "fadeIn": {
                              "type": "number",
                              "description": "Duration of the fade in effect, in seconds"
                            },
                            "fadeOn": {
                              "type": "number",
                              "description": "Duration of the fade out effect, in seconds"
                            },
                            "opacity": {
                              "type": "number",
                              "description": "Opacity of image where 0 is transparent and 100 is fully opaque. Default is 100."
                            },
                            "staticOverlay": {
                              "$ref": "#/paths/~1scheduler~1v2~1assets~1graphics/post/requestBody/content/application~1json/schema/properties/graphic/properties/staticOverlay"
                            },
                            "textOverlay": {
                              "$ref": "#/paths/~1scheduler~1v2~1assets~1graphics/post/requestBody/content/application~1json/schema/properties/graphic/properties/textOverlay"
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "422": {
            "description": "Unprocessable entity",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/paths/~1scheduler~1v1~1types/get/responses/422/content/application~1json/schema"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "api_key": {
        "type": "apiKey",
        "name": "X-API-Key",
        "in": "header"
      }
    }
  }
}
```