{
 "openapi": "3.0.1",
 "info": {
  "title": "Wydruki API",
  "version": "2026-10-08",
  "description": "Generowanie wydruków i dokumentów z szablonów (PDF, HTML).\n\nAdres bazowy: `https://{instancja}-renderer-api.enterprise.sellrocket.pl` — `{instancja}` to nazwa Twojej instancji Sellrocket, którą otrzymasz przy jej uruchomieniu.\n\nWszystkie żądania wymagają nagłówka `Authorization: Bearer <token>` — zobacz [Uwierzytelnianie](../../start/uwierzytelnianie/).\n\n**Specyfikacja OpenAPI:** [wydruki.json](../../specs/wydruki.json) — do importu w Postmanie/Insomnii lub generowania klienta."
 },
 "servers": [
  {
   "url": "https://{instancja}-renderer-api.enterprise.sellrocket.pl",
   "variables": {
    "instancja": {
     "default": "twoja-instancja",
     "description": "Nazwa Twojej instancji Sellrocket"
    }
   }
  }
 ],
 "tags": [
  {
   "name": "Szablony"
  },
  {
   "name": "Zadania asynchroniczne"
  },
  {
   "name": "Renderowanie"
  },
  {
   "name": "Modyfikatory"
  },
  {
   "name": "Szablony produktowe"
  }
 ],
 "paths": {
  "/api/v1/Jobs/{id}/cancel": {
   "post": {
    "tags": [
     "Zadania asynchroniczne"
    ],
    "parameters": [
     {
      "name": "id",
      "in": "path",
      "required": true,
      "style": "simple",
      "schema": {
       "type": "integer",
       "format": "int64"
      }
     }
    ],
    "responses": {
     "200": {
      "description": "Success"
     }
    },
    "operationId": "post-jobs-id-cancel",
    "summary": "Anuluj zadanie generowania dokumentu",
    "description": "Przerywa trwające zadanie generowania dokumentu."
   }
  },
  "/api/v1/Jobs/get/{id}": {
   "get": {
    "tags": [
     "Zadania asynchroniczne"
    ],
    "parameters": [
     {
      "name": "id",
      "in": "path",
      "required": true,
      "style": "simple",
      "schema": {
       "type": "integer",
       "format": "int64"
      }
     }
    ],
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/JobDto"
        }
       }
      }
     }
    },
    "operationId": "get-jobs-get-id",
    "summary": "Pobierz stan zadania generowania dokumentu",
    "description": "Zwraca status i wynik zadania utworzonego przez RenderPdf, RenderCsv, RenderHtml lub RenderXml."
   }
  },
  "/api/v1/Jobs/getPrintouts": {
   "get": {
    "tags": [
     "Zadania asynchroniczne"
    ],
    "parameters": [
     {
      "name": "daysOld",
      "in": "query",
      "style": "form",
      "schema": {
       "type": "integer",
       "format": "int32"
      }
     }
    ],
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "type": "array",
         "items": {
          "$ref": "#/components/schemas/PrintoutJobDto"
         }
        }
       }
      }
     }
    },
    "operationId": "get-jobs-getprintouts",
    "summary": "Pobierz ostatnie zadania wydruków",
    "description": "Zwraca zadania generowania wydruków z ostatnich dni (parametr daysOld)."
   }
  },
  "/api/v2/Modifiers": {
   "post": {
    "tags": [
     "Modyfikatory"
    ],
    "summary": "Utwórz modyfikator tagu",
    "description": "Tworzy regułę zmieniającą wartość tagu w szablonie (np. podmianę wartości przy spełnionym warunku), bez edycji samego szablonu.\n\nExample\n```\n{\n    \"parentId\": 1,\n    \"tag\": \"[tag]\",\n    \"operator\": \"replace_if\",\n    \"condition\": \"val1\",\n    \"newValue\": \"val2\",\n}\n```",
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "required": [
         "tag",
         "operator",
         "condition",
         "newValue"
        ],
        "allOf": [
         {
          "$ref": "#/components/schemas/CreateModifierRequest"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "type": "integer",
         "format": "int64"
        }
       }
      }
     }
    },
    "operationId": "post-modifiers"
   }
  },
  "/api/v2/Modifiers/{modifierId}": {
   "get": {
    "tags": [
     "Modyfikatory"
    ],
    "parameters": [
     {
      "name": "modifierId",
      "in": "path",
      "required": true,
      "style": "simple",
      "schema": {
       "type": "integer",
       "format": "int32"
      }
     }
    ],
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/ModifierResponse"
        }
       }
      }
     },
     "400": {
      "description": "Bad Request",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/BadRequestResponse"
        }
       }
      }
     },
     "500": {
      "description": "Server Error"
     }
    },
    "operationId": "get-modifiers-modifierid",
    "summary": "Pobierz modyfikator tagu"
   },
   "put": {
    "tags": [
     "Modyfikatory"
    ],
    "parameters": [
     {
      "name": "modifierId",
      "in": "path",
      "required": true,
      "style": "simple",
      "schema": {
       "type": "integer",
       "format": "int64"
      }
     }
    ],
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/UpdateModifierRequest"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/ModifierResponse"
        }
       }
      }
     }
    },
    "operationId": "put-modifiers-modifierid",
    "summary": "Zaktualizuj modyfikator tagu"
   },
   "delete": {
    "tags": [
     "Modyfikatory"
    ],
    "parameters": [
     {
      "name": "modifierId",
      "in": "path",
      "required": true,
      "style": "simple",
      "schema": {
       "type": "integer",
       "format": "int64"
      }
     }
    ],
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "type": "boolean"
        }
       }
      }
     }
    },
    "operationId": "delete-modifiers-modifierid",
    "summary": "Usuń modyfikator tagu"
   }
  },
  "/api/v2/Modifiers/List": {
   "get": {
    "tags": [
     "Modyfikatory"
    ],
    "parameters": [
     {
      "name": "offset",
      "in": "query",
      "style": "form",
      "schema": {
       "type": "integer",
       "format": "int32",
       "default": 0
      }
     },
     {
      "name": "limit",
      "in": "query",
      "style": "form",
      "schema": {
       "type": "integer",
       "format": "int32",
       "default": 100
      }
     }
    ],
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/ModifierResponsePage"
        }
       }
      }
     },
     "400": {
      "description": "Bad Request",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/BadRequestResponse"
        }
       }
      }
     },
     "500": {
      "description": "Server Error"
     }
    },
    "operationId": "get-modifiers-list",
    "summary": "Pobierz listę modyfikatorów tagów"
   }
  },
  "/api/v1/PimTemplates": {
   "post": {
    "tags": [
     "Szablony produktowe"
    ],
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/CreatePimTemplateRequest"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "type": "integer",
         "format": "int64"
        }
       }
      }
     }
    },
    "operationId": "post-pimtemplates",
    "summary": "Utwórz szablon produktowy",
    "description": "Tworzy szablon dla danych produktowych z katalogu PIM, np. do eksportu produktów do CSV."
   }
  },
  "/api/v1/PimTemplates/{templateId}": {
   "get": {
    "tags": [
     "Szablony produktowe"
    ],
    "parameters": [
     {
      "name": "templateId",
      "in": "path",
      "required": true,
      "style": "simple",
      "schema": {
       "type": "integer",
       "format": "int32"
      }
     }
    ],
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/PimTemplateResponse"
        }
       }
      }
     },
     "400": {
      "description": "Bad Request",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/BadRequestResponse"
        }
       }
      }
     },
     "500": {
      "description": "Server Error"
     }
    },
    "operationId": "get-pimtemplates-templateid",
    "summary": "Pobierz szablon produktowy"
   },
   "put": {
    "tags": [
     "Szablony produktowe"
    ],
    "parameters": [
     {
      "name": "templateId",
      "in": "path",
      "required": true,
      "style": "simple",
      "schema": {
       "type": "integer",
       "format": "int64"
      }
     }
    ],
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/UpdatePimTemplateRequest"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/PimTemplateResponse"
        }
       }
      }
     }
    },
    "operationId": "put-pimtemplates-templateid",
    "summary": "Zaktualizuj szablon produktowy"
   }
  },
  "/api/v1/PimTemplates/List": {
   "get": {
    "tags": [
     "Szablony produktowe"
    ],
    "parameters": [
     {
      "name": "offset",
      "in": "query",
      "style": "form",
      "schema": {
       "type": "integer",
       "format": "int32",
       "default": 0
      }
     },
     {
      "name": "limit",
      "in": "query",
      "style": "form",
      "schema": {
       "type": "integer",
       "format": "int32",
       "default": 100
      }
     },
     {
      "name": "isSystem",
      "in": "query",
      "style": "form",
      "schema": {
       "type": "boolean",
       "default": false
      }
     }
    ],
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/PimTemplateResponsePage"
        }
       }
      }
     },
     "400": {
      "description": "Bad Request",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/BadRequestResponse"
        }
       }
      }
     },
     "500": {
      "description": "Server Error"
     }
    },
    "operationId": "get-pimtemplates-list",
    "summary": "Pobierz listę szablonów produktowych",
    "description": "Parametr isSystem pozwala filtrować szablony systemowe."
   }
  },
  "/api/v3/Renderer/Combine": {
   "post": {
    "tags": [
     "Renderowanie"
    ],
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/CombinePdfRequest"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "type": "string",
         "format": "binary"
        }
       }
      }
     },
     "500": {
      "description": "Server Error"
     }
    },
    "operationId": "post-renderer-combine",
    "summary": "Połącz pliki PDF w jeden",
    "description": "Scala kilka dokumentów PDF w jeden plik, np. do zbiorczego wydruku."
   }
  },
  "/api/v3/Renderer/ExportFileTypes": {
   "get": {
    "tags": [
     "Renderowanie"
    ],
    "summary": "Pobierz obsługiwane formaty eksportu",
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "type": "array",
         "items": {
          "type": "string"
         }
        }
       }
      }
     },
     "500": {
      "description": "Server Error"
     }
    },
    "operationId": "get-renderer-exportfiletypes",
    "description": "Zwraca listę typów plików, do których można generować dokumenty z szablonów."
   }
  },
  "/api/v3/Renderer/Render": {
   "post": {
    "tags": [
     "Renderowanie"
    ],
    "summary": "Wygeneruj PDF z szablonu",
    "description": "Tworzy synchronicznie dokument PDF dla wskazanych obiektów (np. zamówień) na podstawie szablonu i zwraca plik. Odpowiednik wydruków z szablonów w BaseLinkerze.\n\nExample\n```\n{\n   \"templateId\": 1000000000,\n   \"objects\": {\n        \"type\": \"Order\",\n        \"ids\": [\"129575\", \"654321\"]\n    },\n    \"fileName\": \"nazwaPliku\"\n}\n```",
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/ExportPdfRequest"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success"
     }
    },
    "operationId": "post-renderer-render"
   }
  },
  "/api/v4/Renderer/RenderCsv": {
   "post": {
    "tags": [
     "Renderowanie"
    ],
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/ExportCsvRequestV4"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/JobDto"
        }
       }
      }
     }
    },
    "operationId": "post-renderer-rendercsv",
    "summary": "Zleć generowanie CSV z szablonu",
    "description": "Asynchronicznie generuje plik CSV z szablonu; wynik pobierzesz przez /api/Jobs/get/{id}."
   }
  },
  "/api/v2/Renderer/RenderEmail": {
   "post": {
    "tags": [
     "Renderowanie"
    ],
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/RenderEmailRequest"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success"
     }
    },
    "operationId": "post-renderer-renderemail",
    "summary": "Wygeneruj treść e-maila z szablonu",
    "description": "Renderuje wiadomość e-mail z szablonu dla wskazanego obiektu, np. do podglądu przed wysyłką."
   }
  },
  "/api/v4/Renderer/RenderHtml": {
   "post": {
    "tags": [
     "Renderowanie"
    ],
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/ExportHtmlRequestV4"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/JobDto"
        }
       }
      }
     }
    },
    "operationId": "post-renderer-renderhtml",
    "summary": "Zleć generowanie HTML z szablonu",
    "description": "Asynchronicznie generuje dokument HTML z szablonu; wynik pobierzesz przez /api/Jobs/get/{id}."
   }
  },
  "/api/v3/Renderer/RenderLineItemsAdditionalFields": {
   "post": {
    "tags": [
     "Renderowanie"
    ],
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/ExportLineItemsAdditionalFieldsAsPdfRequest"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success"
     }
    },
    "operationId": "post-renderer-renderlineitemsadditionalfields",
    "summary": "Wygeneruj PDF z dodatkowych pól pozycji",
    "description": "Tworzy PDF z zawartości dodatkowych pól pozycji zamówień."
   }
  },
  "/api/v4/Renderer/RenderPdf": {
   "post": {
    "tags": [
     "Renderowanie"
    ],
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/ExportPdfRequestV4"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/JobDto"
        }
       }
      }
     }
    },
    "operationId": "post-renderer-renderpdf",
    "summary": "Zleć generowanie PDF z szablonu",
    "description": "Asynchroniczna wersja generowania PDF – zwraca zadanie, którego wynik pobierzesz przez /api/Jobs/get/{id}. Zalecana przy wielu obiektach."
   }
  },
  "/api/v3/Renderer/RenderPdfToBlob": {
   "post": {
    "tags": [
     "Renderowanie"
    ],
    "summary": "Wygeneruj PDF i zapisz jako plik",
    "description": "Tworzy PDF z szablonu, zapisuje go w magazynie plików i zwraca adres pliku zamiast jego treści – np. do późniejszego wydruku.\n\nExample\n```\n{\n   \"templateId\": 1000000000,\n   \"objects\": {\n        \"type\": \"Order\",\n        \"ids\": [\"129575\", \"654321\"]\n    },\n    \"fileName\": \"nazwaPliku\"\n}\n```",
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/ExportPdfRequest"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success"
     }
    },
    "operationId": "post-renderer-renderpdftoblob"
   }
  },
  "/api/v3/Renderer/RenderText": {
   "post": {
    "tags": [
     "Renderowanie"
    ],
    "summary": "Wygeneruj tekst z szablonu",
    "description": "Renderuje szablon tekstowy dla wskazanych obiektów.\n\nExample\n```\n{\n   \"templateId\": 1000000000,\n   \"objects\": {\n        \"type\": \"Order\",\n        \"ids\": [\"129575\", \"654321\"]\n    }\n}\n```",
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/RenderTextRequest"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success"
     }
    },
    "operationId": "post-renderer-rendertext"
   }
  },
  "/api/v3/Renderer/RenderTextFromTemplate": {
   "post": {
    "tags": [
     "Renderowanie"
    ],
    "summary": "Wygeneruj tekst z szablonu podanego w żądaniu",
    "description": "Renderuje tekst z treści szablonu przekazanej bezpośrednio w żądaniu, bez zapisywania go – przydatne do podglądu i testowania szablonów.\n\nExample:\n```json\n{\n  \"template\": {\n    \"sections\": {\n      \"order\": {\n        \"body\": \"string\",\n        \"enabled\": true,\n        \"orderBy\": \"string\"\n      },\n      ... (other sections)\n    },\n    \"body\": \"string\"\n  },\n  \"objects\": {\n    \"type\": \"Order\",\n    \"streamSubType\": \"Order\",\n    \"ids\": [\n      \"string\"\n    ]\n  }\n}\n```",
    "requestBody": {
     "description": "The rendering request with inline template content.",
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/RenderFromRawTemplateRequest"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success"
     }
    },
    "operationId": "post-renderer-rendertextfromtemplate"
   }
  },
  "/api/v4/Renderer/RenderXml": {
   "post": {
    "tags": [
     "Renderowanie"
    ],
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/ExportXmlRequestV4"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/JobDto"
        }
       }
      }
     }
    },
    "operationId": "post-renderer-renderxml",
    "summary": "Zleć generowanie XML z szablonu",
    "description": "Asynchronicznie generuje plik XML z szablonu; wynik pobierzesz przez /api/Jobs/get/{id}."
   }
  },
  "/api/v3/Renderer/StreamCsv": {
   "post": {
    "tags": [
     "Renderowanie"
    ],
    "summary": "Pobierz CSV produktów z szablonu",
    "description": "Generuje i strumieniuje plik CSV z produktami katalogu PIM na podstawie szablonu produktowego, np. do eksportu produktów do zewnętrznych systemów.\n\n Example\n ```\n {\n  \"templateId\": 0,\n  \"objects\": {\n    \"type\": \"PimCatalog\",\n    \"streamSubType\": \"PimProductsPage\",\n    \"ids\": [\"999999999\"]\n    },\n  \"staticObjects\": [],\n  \"fileName\": \"export.csv\"\n}\n ```",
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/StreamPimProductsCSVRequest"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success"
     }
    },
    "operationId": "post-renderer-streamcsv"
   }
  },
  "/api/v3/Renderer/SupportedTags": {
   "get": {
    "tags": [
     "Renderowanie"
    ],
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/SupportedTags"
        }
       }
      }
     },
     "500": {
      "description": "Server Error"
     }
    },
    "operationId": "get-renderer-supportedtags",
    "summary": "Pobierz tagi dostępne w szablonach dokumentów",
    "description": "Zwraca tagi (zmienne), których można używać w szablonach dokumentów – odpowiednik listy znaczników w szablonach BaseLinkera."
   }
  },
  "/api/v3/Renderer/SupportedTags/Email": {
   "get": {
    "tags": [
     "Renderowanie"
    ],
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "type": "array",
         "items": {
          "type": "string"
         }
        }
       }
      }
     },
     "500": {
      "description": "Server Error"
     }
    },
    "operationId": "get-renderer-supportedtags-email",
    "summary": "Pobierz tagi dostępne w szablonach e-mail"
   }
  },
  "/api/v3/Renderer/SupportedTags/pim": {
   "get": {
    "tags": [
     "Renderowanie"
    ],
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/SupportedPimTags"
        }
       }
      }
     },
     "500": {
      "description": "Server Error"
     }
    },
    "operationId": "get-renderer-supportedtags-pim",
    "summary": "Pobierz tagi dostępne w szablonach produktowych"
   }
  },
  "/api/v2/Templates": {
   "post": {
    "tags": [
     "Szablony"
    ],
    "summary": "Utwórz szablon dokumentu",
    "description": "Tworzy szablon wydruku lub dokumentu (np. faktury proforma, potwierdzenia zamówienia), używany przez endpointy Renderer.\n\nExample\n```\n{\n    \"name\": \"test_template\",\n    \"body\": \"123\"\n}\n```",
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/CreateTemplateRequestV2"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "type": "integer",
         "format": "int64"
        }
       }
      }
     }
    },
    "operationId": "post-templates"
   }
  },
  "/api/v2/Templates/{templateId}": {
   "get": {
    "tags": [
     "Szablony"
    ],
    "parameters": [
     {
      "name": "templateId",
      "in": "path",
      "required": true,
      "style": "simple",
      "schema": {
       "type": "integer",
       "format": "int32"
      }
     }
    ],
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/TemplateResponse"
        }
       }
      }
     },
     "400": {
      "description": "Bad Request",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/BadRequestResponse"
        }
       }
      }
     },
     "500": {
      "description": "Server Error"
     }
    },
    "operationId": "get-templates-templateid",
    "summary": "Pobierz szablon dokumentu"
   },
   "put": {
    "tags": [
     "Szablony"
    ],
    "parameters": [
     {
      "name": "templateId",
      "in": "path",
      "required": true,
      "style": "simple",
      "schema": {
       "type": "integer",
       "format": "int64"
      }
     }
    ],
    "requestBody": {
     "content": {
      "application/json": {
       "schema": {
        "allOf": [
         {
          "$ref": "#/components/schemas/UpdateTemplateRequestV2"
         }
        ]
       }
      }
     }
    },
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/TemplateResponse"
        }
       }
      }
     }
    },
    "operationId": "put-templates-templateid",
    "summary": "Zaktualizuj szablon dokumentu"
   },
   "delete": {
    "tags": [
     "Szablony"
    ],
    "parameters": [
     {
      "name": "templateId",
      "in": "path",
      "required": true,
      "style": "simple",
      "schema": {
       "type": "integer",
       "format": "int64"
      }
     }
    ],
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "type": "boolean"
        }
       }
      }
     }
    },
    "operationId": "delete-templates-templateid",
    "summary": "Usuń szablon dokumentu"
   }
  },
  "/api/v2/Templates/List": {
   "get": {
    "tags": [
     "Szablony"
    ],
    "parameters": [
     {
      "name": "offset",
      "in": "query",
      "style": "form",
      "schema": {
       "type": "integer",
       "format": "int32",
       "default": 0
      }
     },
     {
      "name": "limit",
      "in": "query",
      "style": "form",
      "schema": {
       "type": "integer",
       "format": "int32",
       "default": 100
      }
     },
     {
      "name": "isSystem",
      "in": "query",
      "style": "form",
      "schema": {
       "type": "boolean",
       "default": false
      }
     }
    ],
    "responses": {
     "200": {
      "description": "Success",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/TemplateResponsePage"
        }
       }
      }
     },
     "400": {
      "description": "Bad Request",
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/BadRequestResponse"
        }
       }
      }
     },
     "500": {
      "description": "Server Error"
     }
    },
    "operationId": "get-templates-list",
    "summary": "Pobierz listę szablonów dokumentów",
    "description": "Parametr isSystem pozwala filtrować szablony systemowe."
   }
  }
 },
 "components": {
  "schemas": {
   "BadRequestResponse": {
    "type": "object",
    "properties": {
     "error": {
      "type": "string",
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "CombinePdfRequest": {
    "type": "object",
    "properties": {
     "data": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/DataItem"
      },
      "nullable": true
     },
     "exportType": {
      "type": "string",
      "nullable": true
     },
     "exportFileName": {
      "type": "string",
      "nullable": true
     },
     "pageLayout": {
      "type": "string",
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "CreateModifierRequest": {
    "required": [
     "condition",
     "newValue",
     "operator",
     "tag"
    ],
    "type": "object",
    "properties": {
     "tag": {
      "type": "string",
      "example": "[waluta]"
     },
     "operator": {
      "enum": [
       "replace_if",
       "replace_if_diff",
       "no_operator"
      ],
      "type": "string",
      "example": "replace_if"
     },
     "condition": {
      "type": "string",
      "example": "USD"
     },
     "newValue": {
      "type": "string",
      "example": "PLN"
     },
     "position": {
      "type": "integer",
      "format": "int64",
      "nullable": true
     },
     "parentId": {
      "type": "integer",
      "format": "int64",
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "CreateModifierRequestData": {
    "required": [
     "condition",
     "newValue",
     "operator",
     "tag"
    ],
    "type": "object",
    "properties": {
     "tag": {
      "type": "string",
      "example": "[waluta]"
     },
     "operator": {
      "enum": [
       "replace_if",
       "replace_if_diff",
       "no_operator"
      ],
      "type": "string",
      "example": "replace_if"
     },
     "condition": {
      "type": "string",
      "example": "USD"
     },
     "newValue": {
      "type": "string",
      "example": "PLN"
     },
     "position": {
      "type": "integer",
      "format": "int64",
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "CreatePimSectionsTemplateRequest": {
    "type": "object",
    "properties": {
     "product": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "parameter": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "relation": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "source": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "variant": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "bundle": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "manufacturer": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "supplier": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "category": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "stats": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "CreatePimTemplateRequest": {
    "type": "object",
    "properties": {
     "id": {
      "type": "integer",
      "format": "int64",
      "nullable": true
     },
     "name": {
      "type": "string",
      "nullable": true
     },
     "body": {
      "type": "string",
      "nullable": true
     },
     "lang": {
      "type": "string",
      "nullable": true
     },
     "isSystem": {
      "type": "boolean",
      "nullable": true
     },
     "tableTemplateType": {
      "type": "string",
      "nullable": true
     },
     "settings": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateTemplateSettingsRequestV2"
       }
      ],
      "nullable": true
     },
     "sections": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreatePimSectionsTemplateRequest"
       }
      ],
      "nullable": true
     },
     "ownedTags": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/CreateTemplateOwnedTagRequestV2"
      },
      "nullable": true
     },
     "modifiers": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/CreateModifierRequestData"
      },
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "CreateSectionRequestV2": {
    "type": "object",
    "properties": {
     "body": {
      "type": "string",
      "nullable": true
     },
     "enabled": {
      "type": "boolean"
     },
     "orderBy": {
      "type": "string",
      "nullable": true
     },
     "groupBy": {
      "type": "string",
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "CreateSectionsForTemplateRequestV2": {
    "type": "object",
    "properties": {
     "order": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "orderHistory": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "lineItems": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "lineItemsList": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "lineItemsSummary": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "shipment": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "invoice": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "invoiceItems": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "invoiceVat": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "receipt": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "receiptItems": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "return": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "returnItems": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "message": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "payment": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "pickpack": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "stats": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "orderStats": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionRequestV2"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "CreateTemplateOwnedTagRequestV2": {
    "type": "object",
    "properties": {
     "name": {
      "type": "string",
      "nullable": true
     },
     "value": {
      "type": "string",
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "CreateTemplateSettingsRequestV2": {
    "type": "object",
    "properties": {
     "pdfHeight": {
      "type": "string",
      "nullable": true
     },
     "pdfWidth": {
      "type": "string",
      "nullable": true
     },
     "pdfMarginTop": {
      "type": "string",
      "nullable": true
     },
     "pdfMarginBottom": {
      "type": "string",
      "nullable": true
     },
     "pdfMarginLeftRight": {
      "type": "string",
      "nullable": true
     },
     "type": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateTypeEnum"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "DataItem": {
    "type": "object",
    "properties": {
     "uri": {
      "type": "string",
      "nullable": true
     },
     "contentType": {
      "type": "string",
      "nullable": true
     },
     "method": {
      "type": "string",
      "nullable": true
     },
     "payload": {
      "type": "string",
      "nullable": true
     },
     "payloadContentType": {
      "type": "string",
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "ExportLineItemsAdditionalFieldsAsPdfRequest": {
    "type": "object",
    "properties": {
     "orderId": {
      "type": "integer",
      "format": "int64"
     },
     "fieldNames": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "lineItemIds": {
      "type": "array",
      "items": {
       "type": "integer",
       "format": "int64"
      },
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "ExportPdfRequest": {
    "required": [
     "fileName",
     "templateId"
    ],
    "type": "object",
    "properties": {
     "templateId": {
      "type": "integer",
      "format": "int64",
      "example": 1000000000
     },
     "objects": {
      "allOf": [
       {
        "$ref": "#/components/schemas/ObjectsDataRequest"
       }
      ],
      "nullable": true
     },
     "fileName": {
      "minLength": 1,
      "type": "string",
      "default": "export.pdf"
     }
    },
    "additionalProperties": false
   },
   "JobDto": {
    "type": "object",
    "properties": {
     "id": {
      "type": "integer",
      "format": "int64"
     },
     "status": {
      "allOf": [
       {
        "$ref": "#/components/schemas/JobStatusEnum"
       }
      ]
     },
     "payload": {
      "nullable": true
     },
     "result": {
      "nullable": true
     },
     "command": {
      "type": "string",
      "nullable": true
     },
     "createdAt": {
      "type": "string",
      "format": "date-time"
     },
     "startedAt": {
      "type": "string",
      "format": "date-time",
      "nullable": true
     },
     "finishedAt": {
      "type": "string",
      "format": "date-time",
      "nullable": true
     },
     "progress": {
      "type": "number",
      "format": "double"
     },
     "isCancellationRequested": {
      "type": "boolean"
     }
    },
    "additionalProperties": false
   },
   "JobStatusEnum": {
    "enum": [
     "New",
     "Pending",
     "InProgress",
     "Error",
     "Completed",
     "Cancelled"
    ],
    "type": "string"
   },
   "ModifierResponse": {
    "type": "object",
    "properties": {
     "id": {
      "type": "integer",
      "format": "int64"
     },
     "parentId": {
      "type": "integer",
      "format": "int64"
     },
     "tag": {
      "type": "string",
      "nullable": true
     },
     "operator": {
      "type": "string",
      "nullable": true
     },
     "condition": {
      "type": "string",
      "nullable": true
     },
     "newValue": {
      "type": "string",
      "nullable": true
     },
     "position": {
      "type": "integer",
      "format": "int64"
     },
     "createdAt": {
      "type": "string",
      "format": "date-time"
     },
     "updatedAt": {
      "type": "string",
      "format": "date-time",
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "ModifierResponsePage": {
    "type": "object",
    "properties": {
     "list": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/ModifierResponse"
      },
      "nullable": true
     },
     "pageNumber": {
      "type": "integer",
      "format": "int32"
     },
     "total": {
      "type": "integer",
      "format": "int32"
     }
    },
    "additionalProperties": false
   },
   "ObjectTypeEnum": {
    "enum": [
     "Order",
     "Connection",
     "Status",
     "LineItem",
     "LineItems",
     "EmailTemplate",
     "User",
     "OrderStats",
     "PimProduct",
     "PimProductsPage",
     "PimCatalog",
     "UserEvents",
     "StatusHistory",
     "ImageGalleryGetMany",
     "PimPriceGroup",
     "OrderShipmentConnections",
     "PimManufacturer",
     "PimManufacturers",
     "PimBundle",
     "PimBundles",
     "PimCategory",
     "PimCategories",
     "PimProductImage",
     "Connections",
     "ConnectionDefinitions",
     "ConnectionsAllGrouped",
     "PimComplexFields",
     "PimAllLanguages",
     "OrderHistory",
     "PimPriceGroups",
     "PimWarehouses"
    ],
    "type": "string"
   },
   "ObjectsDataRequest": {
    "type": "object",
    "properties": {
     "type": {
      "allOf": [
       {
        "$ref": "#/components/schemas/ObjectTypeEnum"
       }
      ]
     },
     "streamSubType": {
      "allOf": [
       {
        "$ref": "#/components/schemas/ObjectTypeEnum"
       }
      ]
     },
     "ids": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "filter": {
      "type": "string",
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "PimTemplateResponse": {
    "type": "object",
    "properties": {
     "id": {
      "type": "integer",
      "format": "int64"
     },
     "name": {
      "type": "string",
      "nullable": true
     },
     "body": {
      "type": "string",
      "nullable": true
     },
     "lang": {
      "type": "string",
      "nullable": true
     },
     "tableTemplateType": {
      "type": "string",
      "nullable": true
     },
     "createdAt": {
      "type": "string",
      "format": "date-time"
     },
     "updatedAt": {
      "type": "string",
      "format": "date-time",
      "nullable": true
     },
     "scope": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateScopeEnum"
       }
      ]
     },
     "settings": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSettingsResponse"
       }
      ],
      "nullable": true
     },
     "sections": {
      "allOf": [
       {
        "$ref": "#/components/schemas/PimTemplateSectionsResponse"
       }
      ],
      "nullable": true
     },
     "ownedTags": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/TemplateOwnedTagResponse"
      },
      "nullable": true
     },
     "modifiers": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/ModifierResponse"
      },
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "PimTemplateResponsePage": {
    "type": "object",
    "properties": {
     "list": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/PimTemplateResponse"
      },
      "nullable": true
     },
     "pageNumber": {
      "type": "integer",
      "format": "int32"
     },
     "total": {
      "type": "integer",
      "format": "int32"
     }
    },
    "additionalProperties": false
   },
   "PimTemplateSectionsResponse": {
    "type": "object",
    "properties": {
     "product": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "parameter": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "relation": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "source": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "variant": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "bundle": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "manufacturer": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "supplier": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "category": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "stats": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "PrintoutJobDto": {
    "type": "object",
    "properties": {
     "id": {
      "type": "integer",
      "format": "int64"
     },
     "templateName": {
      "type": "string",
      "nullable": true
     },
     "status": {
      "allOf": [
       {
        "$ref": "#/components/schemas/JobStatusEnum"
       }
      ]
     },
     "downloadLink": {
      "type": "string",
      "nullable": true
     },
     "error": {
      "type": "string",
      "nullable": true
     },
     "progress": {
      "type": "number",
      "format": "double"
     },
     "createdAt": {
      "type": "string",
      "format": "date-time"
     },
     "startedAt": {
      "type": "string",
      "format": "date-time",
      "nullable": true
     },
     "finishedAt": {
      "type": "string",
      "format": "date-time",
      "nullable": true
     },
     "isCancellationRequested": {
      "type": "boolean"
     }
    },
    "additionalProperties": false
   },
   "RawTemplateRequest": {
    "type": "object",
    "properties": {
     "sections": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionsForTemplateRequestV2"
       }
      ],
      "nullable": true
     },
     "body": {
      "type": "string",
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "RenderEmailRequest": {
    "required": [
     "templateId"
    ],
    "type": "object",
    "properties": {
     "templateId": {
      "type": "integer",
      "format": "int64"
     },
     "objects": {
      "allOf": [
       {
        "$ref": "#/components/schemas/ObjectsDataRequest"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "RenderFromRawTemplateRequest": {
    "type": "object",
    "properties": {
     "template": {
      "allOf": [
       {
        "$ref": "#/components/schemas/RawTemplateRequest"
       }
      ],
      "nullable": true
     },
     "objects": {
      "allOf": [
       {
        "$ref": "#/components/schemas/ObjectsDataRequest"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "RenderTextRequest": {
    "required": [
     "templateId"
    ],
    "type": "object",
    "properties": {
     "templateId": {
      "type": "integer",
      "format": "int64",
      "example": 1000000000
     },
     "objects": {
      "allOf": [
       {
        "$ref": "#/components/schemas/ObjectsDataRequest"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "ShipmentLabelType": {
    "enum": [
     "All",
     "Outbound",
     "Return"
    ],
    "type": "string"
   },
   "StaticObjectRequest": {
    "type": "object",
    "properties": {
     "type": {
      "allOf": [
       {
        "$ref": "#/components/schemas/ObjectTypeEnum"
       }
      ]
     },
     "uri": {
      "type": "string",
      "nullable": true
     },
     "data": {
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "StreamPimProductsCSVRequest": {
    "required": [
     "fileName",
     "templateId"
    ],
    "type": "object",
    "properties": {
     "templateId": {
      "type": "integer",
      "format": "int64"
     },
     "objects": {
      "allOf": [
       {
        "$ref": "#/components/schemas/ObjectsDataRequest"
       }
      ],
      "nullable": true
     },
     "staticObjects": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/StaticObjectRequest"
      },
      "nullable": true
     },
     "fileName": {
      "minLength": 1,
      "type": "string"
     },
     "options": {
      "allOf": [
       {
        "$ref": "#/components/schemas/StreamPimProductsOptions"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "StreamPimProductsOptions": {
    "type": "object",
    "properties": {
     "includeImages": {
      "type": "boolean"
     },
     "includeDescriptions": {
      "type": "boolean"
     }
    },
    "additionalProperties": false
   },
   "SupportedPimTags": {
    "type": "object",
    "properties": {
     "rootScopeTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "productScopeTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "parameterScopeTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "relationScopeTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "variantScopeTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "bundleScopeTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "manufacturerScopeTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "categoryScopeTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "SupportedTags": {
    "type": "object",
    "properties": {
     "rootScopeTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "orderScopeTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "orderShipmentScopeTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "lineItemScopeTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "paymentsHistoryTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "statusHistoryTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "invoiceTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "lineItemsListScopeTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "lineItemsSummaryScopeTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     },
     "statisticsScopeTags": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "TemplateOwnedTagResponse": {
    "type": "object",
    "properties": {
     "id": {
      "type": "integer",
      "format": "int64"
     },
     "name": {
      "type": "string",
      "nullable": true
     },
     "value": {
      "type": "string",
      "nullable": true
     },
     "createdAt": {
      "type": "string",
      "format": "date-time"
     },
     "updatedAt": {
      "type": "string",
      "format": "date-time",
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "TemplateResponse": {
    "type": "object",
    "properties": {
     "id": {
      "type": "integer",
      "format": "int64"
     },
     "name": {
      "type": "string",
      "nullable": true
     },
     "body": {
      "type": "string",
      "nullable": true
     },
     "lang": {
      "type": "string",
      "nullable": true
     },
     "tableTemplateType": {
      "type": "string",
      "nullable": true
     },
     "createdAt": {
      "type": "string",
      "format": "date-time"
     },
     "updatedAt": {
      "type": "string",
      "format": "date-time",
      "nullable": true
     },
     "scope": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateScopeEnum"
       }
      ]
     },
     "settings": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSettingsResponse"
       }
      ],
      "nullable": true
     },
     "sections": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionsResponse"
       }
      ],
      "nullable": true
     },
     "ownedTags": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/TemplateOwnedTagResponse"
      },
      "nullable": true
     },
     "modifiers": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/ModifierResponse"
      },
      "nullable": true
     },
     "shipmentLabelsSettings": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateShipmentLabelsSetttingsResponse"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "TemplateResponsePage": {
    "type": "object",
    "properties": {
     "list": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/TemplateResponse"
      },
      "nullable": true
     },
     "pageNumber": {
      "type": "integer",
      "format": "int32"
     },
     "total": {
      "type": "integer",
      "format": "int32"
     }
    },
    "additionalProperties": false
   },
   "TemplateScopeEnum": {
    "enum": [
     "Orders",
     "PIM"
    ],
    "type": "string"
   },
   "TemplateSectionResponse": {
    "type": "object",
    "properties": {
     "name": {
      "type": "string",
      "nullable": true
     },
     "body": {
      "type": "string",
      "nullable": true
     },
     "enabled": {
      "type": "boolean"
     },
     "orderBy": {
      "type": "string",
      "nullable": true
     },
     "groupBy": {
      "type": "string",
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "TemplateSectionsResponse": {
    "type": "object",
    "properties": {
     "order": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "orderHistory": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "lineItems": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "lineItemsList": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "lineItemsSummary": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "shipment": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "invoice": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "invoiceItems": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "invoiceVat": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "receipt": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "receiptItems": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "return": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "returnItems": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "message": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "payment": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "pickpack": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "stats": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     },
     "orderStats": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateSectionResponse"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "TemplateSettingsResponse": {
    "type": "object",
    "properties": {
     "id": {
      "type": "integer",
      "format": "int64"
     },
     "pdfHeight": {
      "type": "string",
      "nullable": true
     },
     "pdfWidth": {
      "type": "string",
      "nullable": true
     },
     "pdfMarginTop": {
      "type": "string",
      "nullable": true
     },
     "pdfMarginBottom": {
      "type": "string",
      "nullable": true
     },
     "pdfMarginLeftRight": {
      "type": "string",
      "nullable": true
     },
     "type": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateTypeEnum"
       }
      ],
      "nullable": true
     },
     "createdAt": {
      "type": "string",
      "format": "date-time"
     },
     "updatedAt": {
      "type": "string",
      "format": "date-time",
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "TemplateShipmentLabelsSetttingsResponse": {
    "type": "object",
    "properties": {
     "labelType": {
      "allOf": [
       {
        "$ref": "#/components/schemas/ShipmentLabelType"
       }
      ]
     },
     "marginTopMm": {
      "type": "integer",
      "format": "int64"
     },
     "marginLeftMm": {
      "type": "integer",
      "format": "int64"
     }
    },
    "additionalProperties": false
   },
   "TemplateTypeEnum": {
    "enum": [
     "CSV",
     "TEXT",
     "PDF",
     "XML"
    ],
    "type": "string"
   },
   "UpdateModifierRequest": {
    "type": "object",
    "properties": {
     "tag": {
      "type": "string",
      "nullable": true,
      "example": "[waluta]"
     },
     "operator": {
      "enum": [
       "replace_if",
       "replace_if_diff",
       "no_operator"
      ],
      "type": "string",
      "nullable": true,
      "example": "replace_if"
     },
     "condition": {
      "type": "string",
      "nullable": true,
      "example": "USD"
     },
     "newValue": {
      "type": "string",
      "nullable": true,
      "example": "PLN"
     }
    },
    "additionalProperties": false
   },
   "UpdatePimSectionsForTemplateRequest": {
    "type": "object",
    "properties": {
     "product": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "parameter": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "relation": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "source": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "variant": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "bundle": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "manufacturer": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "supplier": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "category": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "stats": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "UpdatePimTemplateRequest": {
    "type": "object",
    "properties": {
     "name": {
      "type": "string",
      "nullable": true
     },
     "body": {
      "type": "string",
      "nullable": true
     },
     "lang": {
      "type": "string",
      "nullable": true
     },
     "tableTemplateType": {
      "type": "string",
      "nullable": true
     },
     "settings": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateTemplateSettingsRequestV2"
       }
      ],
      "nullable": true
     },
     "sections": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdatePimSectionsForTemplateRequest"
       }
      ],
      "nullable": true
     },
     "ownedTags": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/UpdateTemplateOwnedTagRequestV2"
      },
      "nullable": true
     },
     "modifiers": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/CreateModifierRequestData"
      },
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "UpdateSectionRequestV2": {
    "type": "object",
    "properties": {
     "body": {
      "type": "string",
      "nullable": true
     },
     "enabled": {
      "type": "boolean"
     },
     "orderBy": {
      "type": "string",
      "nullable": true
     },
     "groupBy": {
      "type": "string",
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "UpdateTemplateOwnedTagRequestV2": {
    "type": "object",
    "properties": {
     "id": {
      "type": "integer",
      "format": "int64",
      "nullable": true
     },
     "name": {
      "type": "string",
      "nullable": true
     },
     "value": {
      "type": "string",
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "UpdateTemplateSettingsRequestV2": {
    "type": "object",
    "properties": {
     "pdfHeight": {
      "type": "string",
      "nullable": true
     },
     "pdfWidth": {
      "type": "string",
      "nullable": true
     },
     "pdfMarginTop": {
      "type": "string",
      "nullable": true
     },
     "pdfMarginBottom": {
      "type": "string",
      "nullable": true
     },
     "pdfMarginLeftRight": {
      "type": "string",
      "nullable": true
     },
     "type": {
      "allOf": [
       {
        "$ref": "#/components/schemas/TemplateTypeEnum"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "CreateTemplateRequestV2": {
    "type": "object",
    "properties": {
     "id": {
      "type": "integer",
      "format": "int64",
      "nullable": true
     },
     "name": {
      "type": "string",
      "nullable": true
     },
     "body": {
      "type": "string",
      "nullable": true
     },
     "lang": {
      "type": "string",
      "nullable": true
     },
     "isSystem": {
      "type": "boolean",
      "nullable": true
     },
     "tableTemplateType": {
      "type": "string",
      "nullable": true
     },
     "settings": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateTemplateSettingsRequestV2"
       }
      ],
      "nullable": true
     },
     "sections": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateSectionsForTemplateRequestV2"
       }
      ],
      "nullable": true
     },
     "ownedTags": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/CreateTemplateOwnedTagRequestV2"
      },
      "nullable": true
     },
     "modifiers": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/CreateModifierRequestData"
      },
      "nullable": true
     },
     "shipmentLabelsSettings": {
      "allOf": [
       {
        "$ref": "#/components/schemas/CreateTemplateShipmentLabelsRequestV2"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "CreateTemplateShipmentLabelsRequestV2": {
    "type": "object",
    "properties": {
     "labelType": {
      "allOf": [
       {
        "$ref": "#/components/schemas/ShipmentLabelType"
       }
      ]
     },
     "marginTopMm": {
      "type": "integer",
      "format": "int64"
     },
     "marginLeftMm": {
      "type": "integer",
      "format": "int64"
     }
    },
    "additionalProperties": false
   },
   "UpdateSectionsForTemplateRequestV2": {
    "type": "object",
    "properties": {
     "order": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "orderHistory": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "lineItems": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "lineItemsList": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "lineItemsSummary": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "shipment": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "invoice": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "invoiceItems": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "invoiceVat": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "receipt": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "receiptItems": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "return": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "returnItems": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "message": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "payment": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "pickpack": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "stats": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     },
     "orderStats": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionRequestV2"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "UpdateTemplateRequestV2": {
    "type": "object",
    "properties": {
     "name": {
      "type": "string",
      "nullable": true
     },
     "body": {
      "type": "string",
      "nullable": true
     },
     "lang": {
      "type": "string",
      "nullable": true
     },
     "tableTemplateType": {
      "type": "string",
      "nullable": true
     },
     "settings": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateTemplateSettingsRequestV2"
       }
      ],
      "nullable": true
     },
     "sections": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateSectionsForTemplateRequestV2"
       }
      ],
      "nullable": true
     },
     "ownedTags": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/UpdateTemplateOwnedTagRequestV2"
      },
      "nullable": true
     },
     "modifiers": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/CreateModifierRequestData"
      },
      "nullable": true
     },
     "shipmentLabelsSettings": {
      "allOf": [
       {
        "$ref": "#/components/schemas/UpdateTemplateShipmentLabelsRequestV2"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "UpdateTemplateShipmentLabelsRequestV2": {
    "type": "object",
    "properties": {
     "labelType": {
      "allOf": [
       {
        "$ref": "#/components/schemas/ShipmentLabelType"
       }
      ]
     },
     "marginTopMm": {
      "type": "integer",
      "format": "int64"
     },
     "marginLeftMm": {
      "type": "integer",
      "format": "int64"
     }
    },
    "additionalProperties": false
   },
   "ExportCsvRequestV4": {
    "required": [
     "fileName",
     "templateId"
    ],
    "type": "object",
    "properties": {
     "templateId": {
      "type": "integer",
      "format": "int64"
     },
     "objects": {
      "allOf": [
       {
        "$ref": "#/components/schemas/ObjectsDataRequest"
       }
      ],
      "nullable": true
     },
     "fileName": {
      "minLength": 1,
      "type": "string"
     }
    },
    "additionalProperties": false
   },
   "ExportHtmlRequestV4": {
    "required": [
     "templateId"
    ],
    "type": "object",
    "properties": {
     "templateId": {
      "type": "integer",
      "format": "int64"
     },
     "objects": {
      "allOf": [
       {
        "$ref": "#/components/schemas/ObjectsDataRequest"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "ExportPdfRequestV4": {
    "required": [
     "templateId"
    ],
    "type": "object",
    "properties": {
     "templateId": {
      "type": "integer",
      "format": "int64"
     },
     "objects": {
      "allOf": [
       {
        "$ref": "#/components/schemas/ObjectsDataRequest"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   },
   "ExportXmlRequestV4": {
    "required": [
     "templateId"
    ],
    "type": "object",
    "properties": {
     "templateId": {
      "type": "integer",
      "format": "int64"
     },
     "objects": {
      "allOf": [
       {
        "$ref": "#/components/schemas/ObjectsDataRequest"
       }
      ],
      "nullable": true
     }
    },
    "additionalProperties": false
   }
  },
  "securitySchemes": {
   "Bearer": {
    "type": "http",
    "scheme": "bearer",
    "bearerFormat": "JWT",
    "description": "Token API wygenerowany w panelu Sellrocket."
   }
  }
 },
 "security": [
  {
   "Bearer": []
  }
 ]
}