{
  "openapi": "3.0.1",
  "info": {
    "title": "Кабінет B2B відправника Укрпошти (неофіційний)",
    "description": "Незалежний B2B-кабінет відправника для сервісів Укрпошти. Не є офіційним сайтом АТ «Укрпошта» і не афілійований з ним.",
    "version": "v1"
  },
  "servers": [
    {
      "url": "https://ukrposhta.main.fish/"
    }
  ],
  "paths": {
    "/api/v1/whoami": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/shipments": {
      "post": {
        "tags": [
          "ExternalApi"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateShipmentRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateShipmentRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/CreateShipmentRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      },
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "groupId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "offset",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/shipments/batch": {
      "post": {
        "tags": [
          "ExternalApi"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/CreateShipmentRequest"
                }
              }
            },
            "text/json": {
              "schema": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/CreateShipmentRequest"
                }
              }
            },
            "application/*+json": {
              "schema": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/CreateShipmentRequest"
                }
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/shipments/price": {
      "post": {
        "tags": [
          "ExternalApi"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DeliveryPriceQuery"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/DeliveryPriceQuery"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/DeliveryPriceQuery"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/shipments/{id}": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      },
      "put": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EditShipmentRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/EditShipmentRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/EditShipmentRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      },
      "delete": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/groups": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      },
      "post": {
        "tags": [
          "ExternalApi"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateGroupBody"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateGroupBody"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/CreateGroupBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/groups/{id}/close": {
      "post": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/shipments/{id}/postpay": {
      "post": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ChangePostPayRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/ChangePostPayRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/ChangePostPayRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/shipments/{id}/recipient": {
      "post": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RecipientInput"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/RecipientInput"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/RecipientInput"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/shipments/{id}/recipient/retry": {
      "post": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/shipments/{id}/recipient/pending": {
      "delete": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/shipments/{id}/return-order": {
      "post": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReturnOrderBody"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/ReturnOrderBody"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/ReturnOrderBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/courier/orders": {
      "post": {
        "tags": [
          "ExternalApi"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateCourierOrderInput"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateCourierOrderInput"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/CreateCourierOrderInput"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/cargo": {
      "post": {
        "tags": [
          "ExternalApi"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RegisterCargoBody"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/RegisterCargoBody"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/RegisterCargoBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/cargo/{id}": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/postpay-transfers": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "state",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "from",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "to",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "offset",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/postpay-transfers/summary": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "from",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "to",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/address/regions": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "description": "Читання нашої копії довідника Укрпошти (у саму Укрпошту цей запит не ходить). Пагінація offset/limit: за замовчуванням 100, СТЕЛЯ 500 — у відповіді повертаються ФАКТИЧНО застосовані offset/limit (попросив 5000 — побачиш limit: 500), а total рахується ДО пагінації. Кожна відповідь несе syncedAt (коли цей шар копії востаннє оновлювався ПОВНІСТЮ; 0001-01-01 = повного проходу ще не було, а НЕ «даних немає» — про наповненість каже total) і source = \"Ukrposhta address classifier\" — атрибуція джерела даних. І ЗВОРОТНЄ: поки syncedAt = 0001-01-01, ПОРОЖНЯ сторінка НЕ означає «збігів немає» — шар може бути ще не налитий (курсор не дійшов до цього н.п./області), тож таку відповідь не можна тримати як остаточну відповідь довідника. Відповідь несе ETag і Cache-Control; повторний запит із тим самим тегом у If-None-Match дає 304 БЕЗ ТІЛА (і теж витрачає одиницю ліміту адресних читань). Тег СЛАБКИЙ (форма W/\"...\"): приставка — частина значення, повертайте тег дослівно. Тег рахується від syncedAt шару та параметрів запиту, тож між повними прогонами синка він НЕ відображає курсорний долив (рядок може бути м'яко видалений) — id, що йде в адресу ТТН, звіряйте запитом із ПОВНІСТЮ вимкненим кешуванням на вашому боці (fetch cache:'no-store', requests-cache вимкнений для виклику, HttpClient без кеш-хендлера) і без If-None-Match. Просто прибрати If-None-Match НЕ ДОСИТЬ: наша відповідь несе max-age=300, тож кешуючий клієнт віддасть тіло зі свого кешу, не сходивши до нас узагалі, а Cache-Control: no-cache у запиті змусить його лише ревалідувати — ревалідація піде з вашим збереженим тегом і поверне той самий 304. Поки повного проходу шару не було, ETag не віддається взагалі, а Cache-Control дорівнює no-store: валідатора в цьому стані немає, тож відповідь не можна кешувати й за евристикою. УВАГА: усі id та індекси тут — із ПРОДАКШЕН-простору ідентифікаторів Укрпошти (копія знімається з бойової бази); у sandbox простір id ІНШИЙ, тож у ТТН sandbox-підключення підставляти їх не можна.",
        "parameters": [
          {
            "name": "q",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "offset",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          },
          "304": {
            "description": "Сторінка не змінилась із моменту, коли клієнт отримав надісланий ETag: тіла НЕМАЄ, у заголовках повторюється той самий ETag. Витрачає одиницю ліміту адресних читань нарівні з 200."
          }
        }
      }
    },
    "/api/v1/address/cities": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "description": "Читання нашої копії довідника Укрпошти (у саму Укрпошту цей запит не ходить). Пагінація offset/limit: за замовчуванням 100, СТЕЛЯ 500 — у відповіді повертаються ФАКТИЧНО застосовані offset/limit (попросив 5000 — побачиш limit: 500), а total рахується ДО пагінації. Кожна відповідь несе syncedAt (коли цей шар копії востаннє оновлювався ПОВНІСТЮ; 0001-01-01 = повного проходу ще не було, а НЕ «даних немає» — про наповненість каже total) і source = \"Ukrposhta address classifier\" — атрибуція джерела даних. І ЗВОРОТНЄ: поки syncedAt = 0001-01-01, ПОРОЖНЯ сторінка НЕ означає «збігів немає» — шар може бути ще не налитий (курсор не дійшов до цього н.п./області), тож таку відповідь не можна тримати як остаточну відповідь довідника. Відповідь несе ETag і Cache-Control; повторний запит із тим самим тегом у If-None-Match дає 304 БЕЗ ТІЛА (і теж витрачає одиницю ліміту адресних читань). Тег СЛАБКИЙ (форма W/\"...\"): приставка — частина значення, повертайте тег дослівно. Тег рахується від syncedAt шару та параметрів запиту, тож між повними прогонами синка він НЕ відображає курсорний долив (рядок може бути м'яко видалений) — id, що йде в адресу ТТН, звіряйте запитом із ПОВНІСТЮ вимкненим кешуванням на вашому боці (fetch cache:'no-store', requests-cache вимкнений для виклику, HttpClient без кеш-хендлера) і без If-None-Match. Просто прибрати If-None-Match НЕ ДОСИТЬ: наша відповідь несе max-age=300, тож кешуючий клієнт віддасть тіло зі свого кешу, не сходивши до нас узагалі, а Cache-Control: no-cache у запиті змусить його лише ревалідувати — ревалідація піде з вашим збереженим тегом і поверне той самий 304. Поки повного проходу шару не було, ETag не віддається взагалі, а Cache-Control дорівнює no-store: валідатора в цьому стані немає, тож відповідь не можна кешувати й за евристикою. УВАГА: усі id та індекси тут — із ПРОДАКШЕН-простору ідентифікаторів Укрпошти (копія знімається з бойової бази); у sandbox простір id ІНШИЙ, тож у ТТН sandbox-підключення підставляти їх не можна.",
        "parameters": [
          {
            "name": "regionId",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "districtId",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "q",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "offset",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          },
          "304": {
            "description": "Сторінка не змінилась із моменту, коли клієнт отримав надісланий ETag: тіла НЕМАЄ, у заголовках повторюється той самий ETag. Витрачає одиницю ліміту адресних читань нарівні з 200."
          }
        }
      }
    },
    "/api/v1/address/streets": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "description": "Читання нашої копії довідника Укрпошти (у саму Укрпошту цей запит не ходить). Пагінація offset/limit: за замовчуванням 100, СТЕЛЯ 500 — у відповіді повертаються ФАКТИЧНО застосовані offset/limit (попросив 5000 — побачиш limit: 500), а total рахується ДО пагінації. Кожна відповідь несе syncedAt (коли цей шар копії востаннє оновлювався ПОВНІСТЮ; 0001-01-01 = повного проходу ще не було, а НЕ «даних немає» — про наповненість каже total) і source = \"Ukrposhta address classifier\" — атрибуція джерела даних. І ЗВОРОТНЄ: поки syncedAt = 0001-01-01, ПОРОЖНЯ сторінка НЕ означає «збігів немає» — шар може бути ще не налитий (курсор не дійшов до цього н.п./області), тож таку відповідь не можна тримати як остаточну відповідь довідника. Відповідь несе ETag і Cache-Control; повторний запит із тим самим тегом у If-None-Match дає 304 БЕЗ ТІЛА (і теж витрачає одиницю ліміту адресних читань). Тег СЛАБКИЙ (форма W/\"...\"): приставка — частина значення, повертайте тег дослівно. Тег рахується від syncedAt шару та параметрів запиту, тож між повними прогонами синка він НЕ відображає курсорний долив (рядок може бути м'яко видалений) — id, що йде в адресу ТТН, звіряйте запитом із ПОВНІСТЮ вимкненим кешуванням на вашому боці (fetch cache:'no-store', requests-cache вимкнений для виклику, HttpClient без кеш-хендлера) і без If-None-Match. Просто прибрати If-None-Match НЕ ДОСИТЬ: наша відповідь несе max-age=300, тож кешуючий клієнт віддасть тіло зі свого кешу, не сходивши до нас узагалі, а Cache-Control: no-cache у запиті змусить його лише ревалідувати — ревалідація піде з вашим збереженим тегом і поверне той самий 304. Поки повного проходу шару не було, ETag не віддається взагалі, а Cache-Control дорівнює no-store: валідатора в цьому стані немає, тож відповідь не можна кешувати й за евристикою. УВАГА: усі id та індекси тут — із ПРОДАКШЕН-простору ідентифікаторів Укрпошти (копія знімається з бойової бази); у sandbox простір id ІНШИЙ, тож у ТТН sandbox-підключення підставляти їх не можна.",
        "parameters": [
          {
            "name": "cityId",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "q",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "offset",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          },
          "304": {
            "description": "Сторінка не змінилась із моменту, коли клієнт отримав надісланий ETag: тіла НЕМАЄ, у заголовках повторюється той самий ETag. Витрачає одиницю ліміту адресних читань нарівні з 200."
          }
        }
      }
    },
    "/api/v1/address/postoffices": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "description": "Читання нашої копії довідника Укрпошти (у саму Укрпошту цей запит не ходить). Пагінація offset/limit: за замовчуванням 100, СТЕЛЯ 500 — у відповіді повертаються ФАКТИЧНО застосовані offset/limit (попросив 5000 — побачиш limit: 500), а total рахується ДО пагінації. Кожна відповідь несе syncedAt (коли цей шар копії востаннє оновлювався ПОВНІСТЮ; 0001-01-01 = повного проходу ще не було, а НЕ «даних немає» — про наповненість каже total) і source = \"Ukrposhta address classifier\" — атрибуція джерела даних. І ЗВОРОТНЄ: поки syncedAt = 0001-01-01, ПОРОЖНЯ сторінка НЕ означає «збігів немає» — шар може бути ще не налитий (курсор не дійшов до цього н.п./області), тож таку відповідь не можна тримати як остаточну відповідь довідника. Відповідь несе ETag і Cache-Control; повторний запит із тим самим тегом у If-None-Match дає 304 БЕЗ ТІЛА (і теж витрачає одиницю ліміту адресних читань). Тег СЛАБКИЙ (форма W/\"...\"): приставка — частина значення, повертайте тег дослівно. Тег рахується від syncedAt шару та параметрів запиту, тож між повними прогонами синка він НЕ відображає курсорний долив (рядок може бути м'яко видалений) — id, що йде в адресу ТТН, звіряйте запитом із ПОВНІСТЮ вимкненим кешуванням на вашому боці (fetch cache:'no-store', requests-cache вимкнений для виклику, HttpClient без кеш-хендлера) і без If-None-Match. Просто прибрати If-None-Match НЕ ДОСИТЬ: наша відповідь несе max-age=300, тож кешуючий клієнт віддасть тіло зі свого кешу, не сходивши до нас узагалі, а Cache-Control: no-cache у запиті змусить його лише ревалідувати — ревалідація піде з вашим збереженим тегом і поверне той самий 304. Поки повного проходу шару не було, ETag не віддається взагалі, а Cache-Control дорівнює no-store: валідатора в цьому стані немає, тож відповідь не можна кешувати й за евристикою. УВАГА: усі id та індекси тут — із ПРОДАКШЕН-простору ідентифікаторів Укрпошти (копія знімається з бойової бази); у sandbox простір id ІНШИЙ, тож у ТТН sandbox-підключення підставляти їх не можна.",
        "parameters": [
          {
            "name": "cityId",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "index",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "offset",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          },
          "304": {
            "description": "Сторінка не змінилась із моменту, коли клієнт отримав надісланий ETag: тіла НЕМАЄ, у заголовках повторюється той самий ETag. Витрачає одиницю ліміту адресних читань нарівні з 200."
          }
        }
      }
    },
    "/api/v1/shipments/{id}/sticker": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "size",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "hideDeliveryPrice",
            "in": "query",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "hidePostPayDeliveryPrice",
            "in": "query",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "hideWeight",
            "in": "query",
            "schema": {
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/shipments/bulk": {
      "post": {
        "tags": [
          "ExternalApi"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BulkDownloadRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/BulkDownloadRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/BulkDownloadRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/groups/{id}/sticker": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "size",
            "in": "query",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/groups/{id}/registry": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "showSenderName",
            "in": "query",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "hideDeclaredPrice",
            "in": "query",
            "schema": {
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/shipments/{id}/form119": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/groups/{id}/form119": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/shipments/{id}/form107": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/groups/{id}/form107": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/shipments/{id}/form20": {
      "get": {
        "tags": [
          "ExternalApi"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "reason",
            "in": "query",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "AddressInput": {
        "required": [
          "postcode"
        ],
        "type": "object",
        "properties": {
          "postcode": {
            "type": "string"
          },
          "region": {
            "type": "string",
            "nullable": true
          },
          "district": {
            "type": "string",
            "nullable": true
          },
          "city": {
            "type": "string",
            "nullable": true
          },
          "street": {
            "type": "string",
            "nullable": true
          },
          "houseNumber": {
            "type": "string",
            "nullable": true
          },
          "apartmentNumber": {
            "type": "string",
            "nullable": true
          }
        },
        "nullable": true
      },
      "BulkDownloadRequest": {
        "type": "object",
        "properties": {
          "shipmentIds": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "uuid"
            }
          },
          "format": {
            "type": "string",
            "nullable": true
          },
          "hideDeliveryPrice": {
            "type": "boolean"
          },
          "hidePostPayDeliveryPrice": {
            "type": "boolean"
          },
          "hideWeight": {
            "type": "boolean"
          },
          "reason": {
            "type": "string",
            "nullable": true
          }
        }
      },
      "ChangePostPayRequest": {
        "required": [
          "postPay"
        ],
        "type": "object",
        "properties": {
          "postPay": {
            "type": "number",
            "format": "double"
          }
        }
      },
      "CreateCourierOrderInput": {
        "required": [
          "dropDate",
          "interval"
        ],
        "type": "object",
        "properties": {
          "connectionId": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          },
          "senderId": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          },
          "shipmentIds": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "uuid"
            },
            "nullable": true
          },
          "barcodes": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "nullable": true
          },
          "groupId": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          },
          "addressId": {
            "type": "integer",
            "format": "int64",
            "nullable": true
          },
          "phoneId": {
            "type": "integer",
            "format": "int64",
            "nullable": true
          },
          "dropDate": {
            "type": "string"
          },
          "interval": {
            "type": "string"
          }
        }
      },
      "CreateGroupBody": {
        "required": [
          "name",
          "type"
        ],
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "type": {
            "type": "string",
            "nullable": true
          },
          "senderId": {
            "type": "string",
            "format": "uuid",
            "default": null,
            "nullable": true
          }
        }
      },
      "CreateShipmentRequest": {
        "required": [
          "recipient",
          "parcels"
        ],
        "type": "object",
        "properties": {
          "groupId": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          },
          "senderId": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          },
          "deliveryType": {
            "type": "string",
            "nullable": true
          },
          "type": {
            "type": "string",
            "nullable": true
          },
          "recipient": {
            "$ref": "#/components/schemas/RecipientInput"
          },
          "parcels": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ParcelInput"
            }
          },
          "postPayUah": {
            "type": "number",
            "format": "double",
            "nullable": true
          },
          "paidByRecipient": {
            "type": "boolean",
            "nullable": true
          },
          "description": {
            "type": "string",
            "nullable": true
          },
          "externalId": {
            "type": "string",
            "nullable": true
          },
          "onFailReceiveType": {
            "type": "string",
            "nullable": true
          },
          "withDeliveryNotification": {
            "type": "boolean",
            "nullable": true
          },
          "withEmailDeliveryNotification": {
            "type": "boolean",
            "nullable": true
          },
          "transferPostPayToBankAccount": {
            "type": "boolean",
            "nullable": true
          },
          "postPayPaidByRecipient": {
            "type": "boolean",
            "nullable": true
          },
          "sms": {
            "type": "boolean",
            "nullable": true
          },
          "fragile": {
            "type": "boolean",
            "nullable": true
          },
          "bulky": {
            "type": "boolean",
            "nullable": true
          },
          "documentBack": {
            "type": "boolean",
            "nullable": true
          },
          "checkOnDelivery": {
            "type": "boolean",
            "nullable": true
          },
          "fittingAllowed": {
            "type": "boolean",
            "nullable": true
          },
          "ascentToTheFloor": {
            "type": "boolean",
            "nullable": true
          },
          "postPayRecipientUuid": {
            "type": "string",
            "nullable": true
          }
        }
      },
      "DeliveryPriceQuery": {
        "required": [
          "recipientPostcode"
        ],
        "type": "object",
        "properties": {
          "deliveryType": {
            "type": "string",
            "nullable": true
          },
          "type": {
            "type": "string",
            "nullable": true
          },
          "senderId": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          },
          "recipientPostcode": {
            "type": "string"
          },
          "senderPostcode": {
            "type": "string",
            "nullable": true
          },
          "weightGrams": {
            "type": "integer",
            "format": "int32"
          },
          "lengthCm": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "widthCm": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "heightCm": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "declaredPriceUah": {
            "type": "number",
            "format": "double",
            "nullable": true
          },
          "postPayUah": {
            "type": "number",
            "format": "double",
            "nullable": true
          }
        }
      },
      "EditShipmentRequest": {
        "required": [
          "parcels"
        ],
        "type": "object",
        "properties": {
          "deliveryType": {
            "type": "string",
            "nullable": true
          },
          "type": {
            "type": "string",
            "nullable": true
          },
          "parcels": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ParcelInput"
            }
          },
          "postPayUah": {
            "type": "number",
            "format": "double",
            "nullable": true
          },
          "paidByRecipient": {
            "type": "boolean",
            "nullable": true
          },
          "description": {
            "type": "string",
            "nullable": true
          }
        }
      },
      "EnclosedItemInput": {
        "required": [
          "name"
        ],
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "value": {
            "type": "number",
            "format": "double"
          },
          "quantity": {
            "type": "integer",
            "format": "int32"
          },
          "countryOfOrigin": {
            "type": "string",
            "nullable": true
          }
        }
      },
      "ParcelInput": {
        "type": "object",
        "properties": {
          "uuid": {
            "type": "string",
            "nullable": true
          },
          "weightGrams": {
            "type": "integer",
            "format": "int32"
          },
          "lengthCm": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "widthCm": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "heightCm": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "declaredPriceUah": {
            "type": "number",
            "format": "double",
            "nullable": true
          },
          "description": {
            "type": "string",
            "nullable": true
          },
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EnclosedItemInput"
            },
            "nullable": true
          }
        }
      },
      "RecipientInput": {
        "type": "object",
        "properties": {
          "clientUuid": {
            "maxLength": 64,
            "minLength": 0,
            "type": "string",
            "nullable": true
          },
          "type": {
            "type": "string"
          },
          "firstName": {
            "type": "string",
            "nullable": true
          },
          "lastName": {
            "type": "string",
            "nullable": true
          },
          "middleName": {
            "type": "string",
            "nullable": true
          },
          "companyName": {
            "type": "string",
            "nullable": true
          },
          "edrpou": {
            "type": "string",
            "nullable": true
          },
          "tin": {
            "type": "string",
            "nullable": true
          },
          "phone": {
            "type": "string",
            "nullable": true
          },
          "email": {
            "type": "string",
            "nullable": true
          },
          "address": {
            "$ref": "#/components/schemas/AddressInput"
          },
          "postcode": {
            "type": "string",
            "nullable": true
          }
        }
      },
      "RegisterCargoBody": {
        "required": [
          "returnUrl"
        ],
        "type": "object",
        "properties": {
          "returnUrl": {
            "type": "string",
            "nullable": true
          },
          "externalId": {
            "type": "string",
            "default": null,
            "nullable": true
          }
        }
      },
      "ReturnOrderBody": {
        "required": [
          "returnAddressId"
        ],
        "type": "object",
        "properties": {
          "returnAddressId": {
            "type": "string"
          }
        }
      }
    }
  },
  "tags": [
    {
      "name": "ExternalApi"
    }
  ]
}