{
  "openapi": "3.1.1",
  "info": {
    "title": "Cassetto Assicurativo - API",
    "description": "Backend del Cassetto Assicurativo. Tutte le rotte applicano l'autorizzazione lato server: il client non e' mai fonte di autorizzazione.",
    "version": "v1"
  },
  "servers": [
    {
      "url": "https://areariservataback-uat.valiabroker.com/"
    }
  ],
  "paths": {
    "/auth/login": {
      "post": {
        "tags": [
          "Auth"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LoginRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/LoginRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/LoginRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/LoginResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoginResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoginResponse"
                }
              }
            }
          }
        }
      }
    },
    "/auth/refresh": {
      "post": {
        "tags": [
          "Auth"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RefreshTokenRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/RefreshTokenRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/RefreshTokenRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/TokenResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TokenResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/TokenResponse"
                }
              }
            }
          }
        }
      }
    },
    "/auth/logout": {
      "post": {
        "tags": [
          "Auth"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/RefreshTokenRequest"
                  }
                ]
              }
            },
            "text/json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/RefreshTokenRequest"
                  }
                ]
              }
            },
            "application/*+json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/RefreshTokenRequest"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/auth/register": {
      "post": {
        "tags": [
          "Auth"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RegisterRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/RegisterRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/RegisterRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/auth/forgot-password": {
      "post": {
        "tags": [
          "Auth"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ForgotPasswordRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/ForgotPasswordRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/ForgotPasswordRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/auth/reset-password": {
      "post": {
        "tags": [
          "Auth"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ResetPasswordRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/ResetPasswordRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/ResetPasswordRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/auth/me": {
      "get": {
        "tags": [
          "Auth"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/MeResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MeResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/MeResponse"
                }
              }
            }
          }
        }
      }
    },
    "/auth/captcha-config": {
      "get": {
        "tags": [
          "Auth"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/CaptchaConfigResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CaptchaConfigResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/CaptchaConfigResponse"
                }
              }
            }
          }
        }
      }
    },
    "/auth/mfa/totp/enroll": {
      "post": {
        "tags": [
          "Auth"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/TotpEnrollResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TotpEnrollResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/TotpEnrollResponse"
                }
              }
            }
          }
        }
      }
    },
    "/auth/mfa/totp/verify": {
      "post": {
        "tags": [
          "Auth"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/VerifyCodeRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/VerifyCodeRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/VerifyCodeRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/TokenResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TokenResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/TokenResponse"
                }
              }
            }
          }
        }
      }
    },
    "/auth/mfa/totp/challenge": {
      "post": {
        "tags": [
          "Auth"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/VerifyCodeRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/VerifyCodeRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/VerifyCodeRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/TokenResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TokenResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/TokenResponse"
                }
              }
            }
          }
        }
      }
    },
    "/auth/mfa/totp": {
      "delete": {
        "tags": [
          "Auth"
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/auth/mfa/recovery-codes": {
      "post": {
        "tags": [
          "Auth"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/RecoveryCodesResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/RecoveryCodesResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/RecoveryCodesResponse"
                }
              }
            }
          }
        }
      }
    },
    "/auth/mfa/recovery-codes/verify": {
      "post": {
        "tags": [
          "Auth"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/VerifyCodeRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/VerifyCodeRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/VerifyCodeRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/TokenResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TokenResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/TokenResponse"
                }
              }
            }
          }
        }
      }
    },
    "/auth/mfa/sms/send": {
      "post": {
        "tags": [
          "Auth"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SendSmsOtpRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/SendSmsOtpRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/SendSmsOtpRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/auth/mfa/sms/verify": {
      "post": {
        "tags": [
          "Auth"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/VerifyCodeRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/VerifyCodeRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/VerifyCodeRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/TokenResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TokenResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/TokenResponse"
                }
              }
            }
          }
        }
      }
    },
    "/auth/mfa/sms": {
      "delete": {
        "tags": [
          "Auth"
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api-tokens": {
      "get": {
        "tags": [
          "ApiTokens"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ApiTokenDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ApiTokenDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ApiTokenDto"
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "ApiTokens"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ApiTokenUpsertDto"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/ApiTokenUpsertDto"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/ApiTokenUpsertDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTokenCreatedDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTokenCreatedDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTokenCreatedDto"
                }
              }
            }
          }
        }
      }
    },
    "/api-tokens/{id}": {
      "put": {
        "tags": [
          "ApiTokens"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ApiTokenUpsertDto"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/ApiTokenUpsertDto"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/ApiTokenUpsertDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTokenDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTokenDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTokenDto"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "ApiTokens"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/backoffice/distributors": {
      "get": {
        "tags": [
          "Backoffice"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/BackofficeDistributorDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/BackofficeDistributorDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/BackofficeDistributorDto"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/backoffice/quotes": {
      "get": {
        "tags": [
          "Backoffice"
        ],
        "parameters": [
          {
            "name": "distributor_id",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "updated_since",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "page_size",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 50
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfBackofficeQuoteDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfBackofficeQuoteDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfBackofficeQuoteDto"
                }
              }
            }
          }
        }
      }
    },
    "/backoffice/quotes/{id}": {
      "get": {
        "tags": [
          "Backoffice"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/BackofficeQuoteDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BackofficeQuoteDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/BackofficeQuoteDetailDto"
                }
              }
            }
          }
        }
      }
    },
    "/backoffice/policies": {
      "get": {
        "tags": [
          "Backoffice"
        ],
        "parameters": [
          {
            "name": "distributor_id",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "updated_since",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "page_size",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 50
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfBackofficePolicyDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfBackofficePolicyDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfBackofficePolicyDto"
                }
              }
            }
          }
        }
      }
    },
    "/backoffice/policies/{id}": {
      "get": {
        "tags": [
          "Backoffice"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/BackofficePolicyDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BackofficePolicyDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/BackofficePolicyDetailDto"
                }
              }
            }
          }
        }
      }
    },
    "/backoffice/documents": {
      "get": {
        "tags": [
          "Backoffice"
        ],
        "parameters": [
          {
            "name": "quote_id",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "policy_id",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "distributor_id",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "page_size",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 50
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfBackofficeDocumentDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfBackofficeDocumentDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfBackofficeDocumentDto"
                }
              }
            }
          }
        }
      }
    },
    "/backoffice/documents/{id}/download": {
      "get": {
        "tags": [
          "Backoffice"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/backoffice/messages": {
      "get": {
        "tags": [
          "Backoffice"
        ],
        "parameters": [
          {
            "name": "quote_id",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "since",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "page_size",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 50
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfBackofficeMessageDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfBackofficeMessageDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfBackofficeMessageDto"
                }
              }
            }
          }
        }
      }
    },
    "/maintenance/purge-files": {
      "post": {
        "tags": [
          "Maintenance"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/PurgeFilesRequest"
                  }
                ]
              }
            },
            "text/json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/PurgeFilesRequest"
                  }
                ]
              }
            },
            "application/*+json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/PurgeFilesRequest"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PurgeResultDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PurgeResultDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PurgeResultDto"
                }
              }
            }
          }
        }
      }
    },
    "/distributors": {
      "get": {
        "tags": [
          "Distributors"
        ],
        "parameters": [
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "isActive",
            "in": "query",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 100
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfDistributorDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfDistributorDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfDistributorDto"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Distributors"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDistributorRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDistributorRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDistributorRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/DistributorDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DistributorDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/DistributorDto"
                }
              }
            }
          }
        }
      }
    },
    "/distributors/{id}": {
      "put": {
        "tags": [
          "Distributors"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDistributorRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDistributorRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDistributorRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/DistributorDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DistributorDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/DistributorDto"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Distributors"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/distributors/{id}/default-documents": {
      "get": {
        "tags": [
          "Distributors"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/DefaultDocumentDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/DefaultDocumentDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/DefaultDocumentDto"
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Distributors"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "type": "object",
                "allOf": [
                  {
                    "type": "object",
                    "properties": {
                      "ContentType": {
                        "type": "string"
                      },
                      "ContentDisposition": {
                        "type": "string"
                      },
                      "Headers": {
                        "type": "object",
                        "additionalProperties": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        }
                      },
                      "Length": {
                        "pattern": "^-?(?:0|[1-9]\\d*)$",
                        "type": [
                          "integer",
                          "string"
                        ],
                        "format": "int64"
                      },
                      "Name": {
                        "type": "string"
                      },
                      "FileName": {
                        "type": "string"
                      }
                    }
                  },
                  {
                    "type": "object",
                    "properties": {
                      "documentTypeId": {
                        "type": "string",
                        "format": "uuid"
                      }
                    }
                  },
                  {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      }
                    }
                  }
                ]
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/DefaultDocumentDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DefaultDocumentDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/DefaultDocumentDto"
                }
              }
            }
          }
        }
      }
    },
    "/distributors/default-documents/{documentId}": {
      "delete": {
        "tags": [
          "Distributors"
        ],
        "parameters": [
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/branches": {
      "get": {
        "tags": [
          "Branches"
        ],
        "parameters": [
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "distributorId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "isActive",
            "in": "query",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 100
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfBranchDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfBranchDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfBranchDto"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Branches"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertBranchRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertBranchRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertBranchRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/BranchDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BranchDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/BranchDto"
                }
              }
            }
          }
        }
      }
    },
    "/branches/{id}": {
      "put": {
        "tags": [
          "Branches"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertBranchRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertBranchRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertBranchRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/BranchDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BranchDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/BranchDto"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Branches"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/products": {
      "get": {
        "tags": [
          "Products"
        ],
        "parameters": [
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "distributorId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "isActive",
            "in": "query",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 100
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfProductDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfProductDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfProductDto"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Products"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertProductRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertProductRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertProductRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/ProductDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ProductDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/ProductDto"
                }
              }
            }
          }
        }
      }
    },
    "/products/{id}": {
      "put": {
        "tags": [
          "Products"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertProductRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertProductRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertProductRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/ProductDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ProductDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/ProductDto"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Products"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/products/{id}/documents": {
      "get": {
        "tags": [
          "Products"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ProductDocumentDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ProductDocumentDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ProductDocumentDto"
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Products"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "type": "object",
                "allOf": [
                  {
                    "type": "object",
                    "properties": {
                      "ContentType": {
                        "type": "string"
                      },
                      "ContentDisposition": {
                        "type": "string"
                      },
                      "Headers": {
                        "type": "object",
                        "additionalProperties": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        }
                      },
                      "Length": {
                        "pattern": "^-?(?:0|[1-9]\\d*)$",
                        "type": [
                          "integer",
                          "string"
                        ],
                        "format": "int64"
                      },
                      "Name": {
                        "type": "string"
                      },
                      "FileName": {
                        "type": "string"
                      }
                    }
                  },
                  {
                    "type": "object",
                    "properties": {
                      "documentTypeId": {
                        "type": "string",
                        "format": "uuid"
                      }
                    }
                  },
                  {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      }
                    }
                  }
                ]
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/ProductDocumentDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ProductDocumentDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/ProductDocumentDto"
                }
              }
            }
          }
        }
      }
    },
    "/products/documents/{documentId}": {
      "delete": {
        "tags": [
          "Products"
        ],
        "parameters": [
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/guarantees": {
      "get": {
        "tags": [
          "Guarantees"
        ],
        "parameters": [
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "productId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "distributorId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "isActive",
            "in": "query",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 100
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfGuaranteeDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfGuaranteeDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfGuaranteeDto"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Guarantees"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertGuaranteeRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertGuaranteeRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertGuaranteeRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/GuaranteeDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GuaranteeDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/GuaranteeDto"
                }
              }
            }
          }
        }
      }
    },
    "/guarantees/{id}": {
      "put": {
        "tags": [
          "Guarantees"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertGuaranteeRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertGuaranteeRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertGuaranteeRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/GuaranteeDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GuaranteeDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/GuaranteeDto"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Guarantees"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/document-types": {
      "get": {
        "tags": [
          "DocumentTypes"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/DocumentTypeDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/DocumentTypeDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/DocumentTypeDto"
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "DocumentTypes"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDocumentTypeRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDocumentTypeRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDocumentTypeRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentTypeDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentTypeDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentTypeDto"
                }
              }
            }
          }
        }
      }
    },
    "/document-types/{id}": {
      "put": {
        "tags": [
          "DocumentTypes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDocumentTypeRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDocumentTypeRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDocumentTypeRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentTypeDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentTypeDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentTypeDto"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "DocumentTypes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/quote-statuses": {
      "get": {
        "tags": [
          "QuoteStatuses"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteStatusDetailDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteStatusDetailDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteStatusDetailDto"
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "QuoteStatuses"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertQuoteStatusRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertQuoteStatusRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertQuoteStatusRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteStatusDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteStatusDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteStatusDetailDto"
                }
              }
            }
          }
        }
      }
    },
    "/quote-statuses/{id}": {
      "put": {
        "tags": [
          "QuoteStatuses"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertQuoteStatusRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertQuoteStatusRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertQuoteStatusRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteStatusDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteStatusDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteStatusDetailDto"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "QuoteStatuses"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/settings": {
      "get": {
        "tags": [
          "Settings"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AppSettingDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AppSettingDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AppSettingDto"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/settings/{key}": {
      "put": {
        "tags": [
          "Settings"
        ],
        "parameters": [
          {
            "name": "key",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertAppSettingRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertAppSettingRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertAppSettingRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/AppSettingDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AppSettingDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/AppSettingDto"
                }
              }
            }
          }
        }
      }
    },
    "/{entity}/import": {
      "post": {
        "tags": [
          "ConfigurationImport"
        ],
        "parameters": [
          {
            "name": "entity",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "type": "object",
                "properties": {
                  "ContentType": {
                    "type": "string"
                  },
                  "ContentDisposition": {
                    "type": "string"
                  },
                  "Headers": {
                    "type": "object",
                    "additionalProperties": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    }
                  },
                  "Length": {
                    "pattern": "^-?(?:0|[1-9]\\d*)$",
                    "type": [
                      "integer",
                      "string"
                    ],
                    "format": "int64"
                  },
                  "Name": {
                    "type": "string"
                  },
                  "FileName": {
                    "type": "string"
                  }
                }
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/ImportResultDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ImportResultDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/ImportResultDto"
                }
              }
            }
          }
        }
      }
    },
    "/notifications": {
      "get": {
        "tags": [
          "Notifications"
        ],
        "parameters": [
          {
            "name": "unreadOnly",
            "in": "query",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 25
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfNotificationDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfNotificationDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfNotificationDto"
                }
              }
            }
          }
        }
      }
    },
    "/notifications/unread-count": {
      "get": {
        "tags": [
          "Notifications"
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/notifications/{id}/read": {
      "post": {
        "tags": [
          "Notifications"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/notifications/read-all": {
      "post": {
        "tags": [
          "Notifications"
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/email-logs": {
      "get": {
        "tags": [
          "Logs"
        ],
        "parameters": [
          {
            "name": "from",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date"
            }
          },
          {
            "name": "to",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date"
            }
          },
          {
            "name": "recipient",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "status",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "quoteId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 25
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfEmailLogDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfEmailLogDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfEmailLogDto"
                }
              }
            }
          }
        }
      }
    },
    "/api-logs": {
      "get": {
        "tags": [
          "Logs"
        ],
        "parameters": [
          {
            "name": "from",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date"
            }
          },
          {
            "name": "to",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date"
            }
          },
          {
            "name": "source",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "onlyErrors",
            "in": "query",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 25
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfApiLogDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfApiLogDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfApiLogDto"
                }
              }
            }
          }
        }
      }
    },
    "/auth-attempts": {
      "get": {
        "tags": [
          "Logs"
        ],
        "parameters": [
          {
            "name": "email",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 50
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfAuthAttemptDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfAuthAttemptDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfAuthAttemptDto"
                }
              }
            }
          }
        }
      }
    },
    "/ndg/lookup": {
      "post": {
        "tags": [
          "Integrations"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/NdgLookupRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/NdgLookupRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/NdgLookupRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/NdgLookupResult"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/NdgLookupResult"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/NdgLookupResult"
                }
              }
            }
          }
        }
      }
    },
    "/integrations/console": {
      "post": {
        "tags": [
          "Integrations"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ApiConsoleRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/ApiConsoleRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/ApiConsoleRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api-console": {
      "post": {
        "tags": [
          "Integrations"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ApiConsoleRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/ApiConsoleRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/ApiConsoleRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/email/test": {
      "post": {
        "tags": [
          "Integrations"
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/policies": {
      "get": {
        "tags": [
          "Policies"
        ],
        "parameters": [
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "distributorId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "productId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "customerId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "status",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 25
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfPolicyListItemDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfPolicyListItemDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfPolicyListItemDto"
                }
              }
            }
          }
        }
      }
    },
    "/policies/{id}": {
      "get": {
        "tags": [
          "Policies"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PolicyDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PolicyDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PolicyDetailDto"
                }
              }
            }
          }
        }
      }
    },
    "/policies/{id}/guarantees": {
      "get": {
        "tags": [
          "Policies"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteGuaranteeDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteGuaranteeDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteGuaranteeDto"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/policies/{id}/documents": {
      "get": {
        "tags": [
          "Policies"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/PolicyDocumentDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/PolicyDocumentDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/PolicyDocumentDto"
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Policies"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "type": "object",
                "allOf": [
                  {
                    "type": "object",
                    "properties": {
                      "ContentType": {
                        "type": "string"
                      },
                      "ContentDisposition": {
                        "type": "string"
                      },
                      "Headers": {
                        "type": "object",
                        "additionalProperties": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        }
                      },
                      "Length": {
                        "pattern": "^-?(?:0|[1-9]\\d*)$",
                        "type": [
                          "integer",
                          "string"
                        ],
                        "format": "int64"
                      },
                      "Name": {
                        "type": "string"
                      },
                      "FileName": {
                        "type": "string"
                      }
                    }
                  },
                  {
                    "type": "object",
                    "properties": {
                      "documentTypeId": {
                        "type": "string",
                        "format": "uuid"
                      }
                    }
                  },
                  {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      }
                    }
                  }
                ]
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PolicyDocumentDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PolicyDocumentDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PolicyDocumentDto"
                }
              }
            }
          }
        }
      }
    },
    "/policies/documents/{documentId}/download": {
      "get": {
        "tags": [
          "Policies"
        ],
        "parameters": [
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentDownloadDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentDownloadDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentDownloadDto"
                }
              }
            }
          }
        }
      }
    },
    "/quotes": {
      "get": {
        "tags": [
          "Quotes"
        ],
        "parameters": [
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "statusId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "distributorId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "productId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "customerId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "sportellistaId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "createdFrom",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date"
            }
          },
          {
            "name": "createdTo",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date"
            }
          },
          {
            "name": "sortBy",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "sortDescending",
            "in": "query",
            "schema": {
              "type": "boolean",
              "default": true
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 25
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfQuoteListItemDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfQuoteListItemDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfQuoteListItemDto"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Quotes"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateQuoteRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateQuoteRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/CreateQuoteRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDetailDto"
                }
              }
            }
          }
        }
      }
    },
    "/quotes/{id}": {
      "get": {
        "tags": [
          "Quotes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDetailDto"
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Quotes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateQuoteRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateQuoteRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateQuoteRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDetailDto"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Quotes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/quotes/{id}/status": {
      "put": {
        "tags": [
          "Quotes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ChangeQuoteStatusRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/ChangeQuoteStatusRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/ChangeQuoteStatusRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDetailDto"
                }
              }
            }
          }
        }
      }
    },
    "/quotes/{id}/customer": {
      "put": {
        "tags": [
          "Quotes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AssignCustomerRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/AssignCustomerRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/AssignCustomerRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDetailDto"
                }
              }
            }
          }
        }
      }
    },
    "/quotes/{id}/guarantees": {
      "get": {
        "tags": [
          "Quotes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteGuaranteeDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteGuaranteeDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteGuaranteeDto"
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Quotes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetQuoteGuaranteesRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/SetQuoteGuaranteesRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/SetQuoteGuaranteesRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteGuaranteeDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteGuaranteeDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteGuaranteeDto"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/quotes/{id}/convert-to-policy": {
      "post": {
        "tags": [
          "Quotes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ConvertToPolicyRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/ConvertToPolicyRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/ConvertToPolicyRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PolicyDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PolicyDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PolicyDetailDto"
                }
              }
            }
          }
        }
      }
    },
    "/quotes/{id}/documents": {
      "get": {
        "tags": [
          "Quotes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteDocumentDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteDocumentDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteDocumentDto"
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Quotes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "type": "object",
                "allOf": [
                  {
                    "type": "object",
                    "properties": {
                      "ContentType": {
                        "type": "string"
                      },
                      "ContentDisposition": {
                        "type": "string"
                      },
                      "Headers": {
                        "type": "object",
                        "additionalProperties": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        }
                      },
                      "Length": {
                        "pattern": "^-?(?:0|[1-9]\\d*)$",
                        "type": [
                          "integer",
                          "string"
                        ],
                        "format": "int64"
                      },
                      "Name": {
                        "type": "string"
                      },
                      "FileName": {
                        "type": "string"
                      }
                    }
                  },
                  {
                    "type": "object",
                    "properties": {
                      "documentTypeId": {
                        "type": "string",
                        "format": "uuid"
                      }
                    }
                  },
                  {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      }
                    }
                  },
                  {
                    "type": "object",
                    "properties": {
                      "audience": {
                        "type": "string"
                      }
                    }
                  },
                  {
                    "type": "object",
                    "properties": {
                      "notify": {
                        "type": "boolean"
                      }
                    }
                  }
                ]
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDocumentDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDocumentDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDocumentDto"
                }
              }
            }
          }
        }
      }
    },
    "/quotes/{id}/messages": {
      "get": {
        "tags": [
          "Quotes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/MessageDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/MessageDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/MessageDto"
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Quotes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PostMessageRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/PostMessageRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/PostMessageRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/MessageDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MessageDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/MessageDto"
                }
              }
            }
          }
        }
      }
    },
    "/quotes/{id}/messages/read": {
      "post": {
        "tags": [
          "Quotes"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/documents/{id}/download": {
      "get": {
        "tags": [
          "Documents"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentDownloadDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentDownloadDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentDownloadDto"
                }
              }
            }
          }
        }
      }
    },
    "/documents/{id}/audience": {
      "put": {
        "tags": [
          "Documents"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ChangeAudienceRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/ChangeAudienceRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/ChangeAudienceRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDocumentDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDocumentDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDocumentDto"
                }
              }
            }
          }
        }
      }
    },
    "/documents/{id}": {
      "delete": {
        "tags": [
          "Documents"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/messages/unread": {
      "get": {
        "tags": [
          "Messages"
        ],
        "parameters": [
          {
            "name": "distributorId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/UnreadSummaryDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UnreadSummaryDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/UnreadSummaryDto"
                }
              }
            }
          }
        }
      }
    },
    "/signature-templates": {
      "get": {
        "tags": [
          "SignatureTemplates"
        ],
        "parameters": [
          {
            "name": "distributorId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/SignatureTemplateDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/SignatureTemplateDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/SignatureTemplateDto"
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "SignatureTemplates"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SignatureTemplateUpsertDto"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/SignatureTemplateUpsertDto"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/SignatureTemplateUpsertDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureTemplateDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureTemplateDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureTemplateDto"
                }
              }
            }
          }
        }
      }
    },
    "/signature-templates/{id}": {
      "get": {
        "tags": [
          "SignatureTemplates"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureTemplateDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureTemplateDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureTemplateDto"
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "SignatureTemplates"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SignatureTemplateUpsertDto"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/SignatureTemplateUpsertDto"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/SignatureTemplateUpsertDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureTemplateDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureTemplateDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureTemplateDto"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "SignatureTemplates"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/signatures": {
      "get": {
        "tags": [
          "Signatures"
        ],
        "parameters": [
          {
            "name": "quoteId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "status",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 25
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfSignatureRequestDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfSignatureRequestDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfSignatureRequestDto"
                }
              }
            }
          }
        }
      }
    },
    "/signatures/start": {
      "post": {
        "tags": [
          "Signatures"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SignatureStartDto"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/SignatureStartDto"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/SignatureStartDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureRequestDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureRequestDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureRequestDto"
                }
              }
            }
          }
        }
      }
    },
    "/signatures/{id}/link": {
      "post": {
        "tags": [
          "Signatures"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureRequestDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureRequestDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureRequestDto"
                }
              }
            }
          }
        }
      }
    },
    "/signatures/{id}/refresh": {
      "post": {
        "tags": [
          "Signatures"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureRequestDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureRequestDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/SignatureRequestDto"
                }
              }
            }
          }
        }
      }
    },
    "/webhooks/namirial": {
      "get": {
        "tags": [
          "NamirialWebhook"
        ],
        "parameters": [
          {
            "name": "envelope",
            "in": "query",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/NamirialWebhookBody"
                  }
                ]
              }
            },
            "text/json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/NamirialWebhookBody"
                  }
                ]
              }
            },
            "application/*+json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/NamirialWebhookBody"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      },
      "post": {
        "tags": [
          "NamirialWebhook"
        ],
        "parameters": [
          {
            "name": "envelope",
            "in": "query",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/NamirialWebhookBody"
                  }
                ]
              }
            },
            "text/json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/NamirialWebhookBody"
                  }
                ]
              }
            },
            "application/*+json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/NamirialWebhookBody"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/document-templates": {
      "get": {
        "tags": [
          "DocumentTemplates"
        ],
        "parameters": [
          {
            "name": "distributorId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "productId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/DocumentTemplateDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/DocumentTemplateDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/DocumentTemplateDto"
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "DocumentTemplates"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDocumentTemplateRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDocumentTemplateRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDocumentTemplateRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentTemplateDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentTemplateDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentTemplateDto"
                }
              }
            }
          }
        }
      }
    },
    "/document-templates/{id}": {
      "get": {
        "tags": [
          "DocumentTemplates"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentTemplateDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentTemplateDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentTemplateDto"
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "DocumentTemplates"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDocumentTemplateRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDocumentTemplateRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpsertDocumentTemplateRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentTemplateDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentTemplateDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/DocumentTemplateDto"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "DocumentTemplates"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/document-templates/{id}/pdf": {
      "post": {
        "tags": [
          "DocumentTemplates"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "type": "object",
                "properties": {
                  "ContentType": {
                    "type": "string"
                  },
                  "ContentDisposition": {
                    "type": "string"
                  },
                  "Headers": {
                    "type": "object",
                    "additionalProperties": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    }
                  },
                  "Length": {
                    "pattern": "^-?(?:0|[1-9]\\d*)$",
                    "type": [
                      "integer",
                      "string"
                    ],
                    "format": "int64"
                  },
                  "Name": {
                    "type": "string"
                  },
                  "FileName": {
                    "type": "string"
                  }
                }
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/DetectedPdfFieldDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/DetectedPdfFieldDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/DetectedPdfFieldDto"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/document-templates/{id}/pdf-fields": {
      "get": {
        "tags": [
          "DocumentTemplates"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/DetectedPdfFieldDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/DetectedPdfFieldDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/DetectedPdfFieldDto"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/document-templates/{id}/fields": {
      "get": {
        "tags": [
          "DocumentTemplates"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/TemplateFieldDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/TemplateFieldDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/TemplateFieldDto"
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "DocumentTemplates"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetTemplateFieldsRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/SetTemplateFieldsRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/SetTemplateFieldsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/TemplateFieldDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/TemplateFieldDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/TemplateFieldDto"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/document-templates/{id}/preview": {
      "post": {
        "tags": [
          "DocumentTemplates"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PreviewDocumentRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/PreviewDocumentRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/PreviewDocumentRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/document-templates/generate": {
      "post": {
        "tags": [
          "DocumentTemplates"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GenerateOrPreviewRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/GenerateOrPreviewRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/GenerateOrPreviewRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/quote-data-fields": {
      "get": {
        "tags": [
          "QuoteDataFields"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteDataFieldDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteDataFieldDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/QuoteDataFieldDto"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/quotes/{quoteId}/generate-document": {
      "post": {
        "tags": [
          "QuoteDocumentGeneration"
        ],
        "parameters": [
          {
            "name": "quoteId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GenerateDocumentRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/GenerateDocumentRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/GenerateDocumentRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDocumentDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDocumentDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/QuoteDocumentDto"
                }
              }
            }
          }
        }
      }
    },
    "/users": {
      "get": {
        "tags": [
          "Users"
        ],
        "parameters": [
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "role",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "distributorId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "branchId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "isApproved",
            "in": "query",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 25
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfUserListItemDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfUserListItemDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfUserListItemDto"
                }
              }
            }
          }
        }
      }
    },
    "/users/{id}": {
      "get": {
        "tags": [
          "Users"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Users"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateUserRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateUserRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateUserRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Users"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/users/invite": {
      "post": {
        "tags": [
          "Users"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/InviteUserRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/InviteUserRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/InviteUserRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              }
            }
          }
        }
      }
    },
    "/users/{id}/reset-link": {
      "post": {
        "tags": [
          "Users"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/ResetLinkResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResetLinkResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResetLinkResponse"
                }
              }
            }
          }
        }
      }
    },
    "/users/{id}/approve": {
      "post": {
        "tags": [
          "Users"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              }
            }
          }
        }
      }
    },
    "/users/{id}/revoke-approval": {
      "post": {
        "tags": [
          "Users"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              }
            }
          }
        }
      }
    },
    "/users/{id}/roles": {
      "put": {
        "tags": [
          "Users"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetRolesRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/SetRolesRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/SetRolesRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              }
            }
          }
        }
      }
    },
    "/users/{id}/distributors": {
      "put": {
        "tags": [
          "Users"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetDistributorsRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/SetDistributorsRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/SetDistributorsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              }
            }
          }
        }
      }
    },
    "/users/{id}/branches": {
      "put": {
        "tags": [
          "Users"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetBranchesRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/SetBranchesRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/SetBranchesRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              }
            }
          }
        }
      }
    },
    "/users/{id}/delete": {
      "post": {
        "tags": [
          "Users"
        ],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/DeleteUserRequest"
                  }
                ]
              }
            },
            "text/json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/DeleteUserRequest"
                  }
                ]
              }
            },
            "application/*+json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/DeleteUserRequest"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/users/export": {
      "get": {
        "tags": [
          "Users"
        ],
        "parameters": [
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "role",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "distributorId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "branchId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "isApproved",
            "in": "query",
            "schema": {
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/users/import": {
      "post": {
        "tags": [
          "Users"
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "type": "object",
                "properties": {
                  "ContentType": {
                    "type": "string"
                  },
                  "ContentDisposition": {
                    "type": "string"
                  },
                  "Headers": {
                    "type": "object",
                    "additionalProperties": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    }
                  },
                  "Length": {
                    "pattern": "^-?(?:0|[1-9]\\d*)$",
                    "type": [
                      "integer",
                      "string"
                    ],
                    "format": "int64"
                  },
                  "Name": {
                    "type": "string"
                  },
                  "FileName": {
                    "type": "string"
                  }
                }
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/ImportResultDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ImportResultDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/ImportResultDto"
                }
              }
            }
          }
        }
      }
    },
    "/users/sportellisti": {
      "get": {
        "tags": [
          "Users"
        ],
        "parameters": [
          {
            "name": "distributorId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/RefDto"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/RefDto"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/RefDto"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/customers": {
      "get": {
        "tags": [
          "Customers"
        ],
        "parameters": [
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "distributorId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "pattern": "^-?(?:0|[1-9]\\d*)$",
              "type": [
                "integer",
                "string"
              ],
              "format": "int32",
              "default": 25
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfUserListItemDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfUserListItemDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedResultOfUserListItemDto"
                }
              }
            }
          }
        }
      }
    },
    "/profile": {
      "get": {
        "tags": [
          "Profile"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Profile"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateOwnProfileRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateOwnProfileRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateOwnProfileRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserDetailDto"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "ApiConsoleRequest": {
        "required": [
          "method",
          "path"
        ],
        "type": "object",
        "properties": {
          "method": {
            "type": "string"
          },
          "path": {
            "type": "string"
          },
          "body": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "ApiLogDto": {
        "required": [
          "id",
          "createdAt",
          "source",
          "method",
          "url"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "source": {
            "type": "string"
          },
          "method": {
            "type": "string"
          },
          "url": {
            "type": "string"
          },
          "responseStatus": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "null",
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "durationMs": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "null",
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "ok": {
            "type": [
              "null",
              "boolean"
            ]
          },
          "error": {
            "type": [
              "null",
              "string"
            ]
          },
          "userEmail": {
            "type": [
              "null",
              "string"
            ]
          },
          "requestHeaders": {
            "type": [
              "null",
              "string"
            ]
          },
          "requestBody": {
            "type": [
              "null",
              "string"
            ]
          },
          "responseBody": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "ApiTokenCreatedDto": {
        "required": [
          "token",
          "plainToken"
        ],
        "type": "object",
        "properties": {
          "token": {
            "$ref": "#/components/schemas/ApiTokenDto"
          },
          "plainToken": {
            "type": "string"
          }
        }
      },
      "ApiTokenDto": {
        "required": [
          "id",
          "name",
          "tokenPrefix",
          "distributorIds",
          "isActive",
          "createdAt"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "tokenPrefix": {
            "type": "string"
          },
          "distributorIds": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "uuid"
            }
          },
          "distributorNames": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "isActive": {
            "type": "boolean"
          },
          "expiresAt": {
            "type": [
              "null",
              "string"
            ],
            "format": "date-time"
          },
          "lastUsedAt": {
            "type": [
              "null",
              "string"
            ],
            "format": "date-time"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "ApiTokenUpsertDto": {
        "required": [
          "name"
        ],
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "distributorIds": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "uuid"
            }
          },
          "isActive": {
            "type": "boolean"
          },
          "expiresAt": {
            "type": [
              "null",
              "string"
            ],
            "format": "date-time"
          }
        }
      },
      "AppSettingDto": {
        "required": [
          "key",
          "value",
          "updatedAt"
        ],
        "type": "object",
        "properties": {
          "key": {
            "type": "string"
          },
          "value": {
            "type": "string"
          },
          "description": {
            "type": [
              "null",
              "string"
            ]
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "AssignCustomerRequest": {
        "required": [
          "customerId"
        ],
        "type": "object",
        "properties": {
          "customerId": {
            "type": "string",
            "format": "uuid"
          }
        }
      },
      "AuthAttemptDto": {
        "required": [
          "id",
          "createdAt",
          "email",
          "ipAddress",
          "success"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "email": {
            "type": [
              "null",
              "string"
            ]
          },
          "ipAddress": {
            "type": [
              "null",
              "string"
            ]
          },
          "success": {
            "type": "boolean"
          }
        }
      },
      "BackofficeDistributorDto": {
        "required": [
          "id",
          "code",
          "name",
          "isActive"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "code": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "isActive": {
            "type": "boolean"
          }
        }
      },
      "BackofficeDocumentDto": {
        "required": [
          "id",
          "name",
          "scanStatus",
          "createdAt"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "quoteId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "policyId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "documentType": {
            "type": [
              "null",
              "string"
            ]
          },
          "fileSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "null",
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "mimeType": {
            "type": [
              "null",
              "string"
            ]
          },
          "scanStatus": {
            "type": "string"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "BackofficeMessageDto": {
        "required": [
          "id",
          "quoteId",
          "content",
          "audience",
          "createdAt"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "quoteId": {
            "type": "string",
            "format": "uuid"
          },
          "content": {
            "type": "string"
          },
          "senderName": {
            "type": [
              "null",
              "string"
            ]
          },
          "audience": {
            "type": "string"
          },
          "attachmentName": {
            "type": [
              "null",
              "string"
            ]
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "BackofficePolicyDetailDto": {
        "required": [
          "policy",
          "documents"
        ],
        "type": "object",
        "properties": {
          "policy": {
            "$ref": "#/components/schemas/BackofficePolicyDto"
          },
          "documents": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BackofficeDocumentDto"
            }
          }
        }
      },
      "BackofficePolicyDto": {
        "required": [
          "id",
          "title",
          "insuredName",
          "createdAt",
          "updatedAt"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "externalId": {
            "type": [
              "null",
              "string"
            ]
          },
          "quoteId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "policyNumber": {
            "type": [
              "null",
              "string"
            ]
          },
          "adhesionNumber": {
            "type": [
              "null",
              "string"
            ]
          },
          "distributorId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "distributorCode": {
            "type": [
              "null",
              "string"
            ]
          },
          "title": {
            "type": "string"
          },
          "insuredName": {
            "type": "string"
          },
          "status": {
            "type": [
              "null",
              "string"
            ]
          },
          "totalPremiumGross": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "startDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "endDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "BackofficeQuoteDetailDto": {
        "required": [
          "quote",
          "documents",
          "messages"
        ],
        "type": "object",
        "properties": {
          "quote": {
            "$ref": "#/components/schemas/BackofficeQuoteDto"
          },
          "documents": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BackofficeDocumentDto"
            }
          },
          "messages": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BackofficeMessageDto"
            }
          }
        }
      },
      "BackofficeQuoteDto": {
        "required": [
          "id",
          "title",
          "insuredName",
          "createdAt",
          "updatedAt"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "externalId": {
            "type": [
              "null",
              "string"
            ]
          },
          "adhesionNumber": {
            "type": [
              "null",
              "string"
            ]
          },
          "distributorId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "distributorCode": {
            "type": [
              "null",
              "string"
            ]
          },
          "title": {
            "type": "string"
          },
          "insuredName": {
            "type": "string"
          },
          "status": {
            "type": [
              "null",
              "string"
            ]
          },
          "productName": {
            "type": [
              "null",
              "string"
            ]
          },
          "totalPremiumGross": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "startDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "endDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "BranchDto": {
        "required": [
          "id",
          "distributorId",
          "name",
          "branchCode",
          "isActive"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "distributorId": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "nameSecondary": {
            "type": [
              "null",
              "string"
            ]
          },
          "branchCode": {
            "type": "string"
          },
          "areaCode": {
            "type": [
              "null",
              "string"
            ]
          },
          "city": {
            "type": [
              "null",
              "string"
            ]
          },
          "isActive": {
            "type": "boolean"
          }
        }
      },
      "CaptchaConfigResponse": {
        "required": [
          "enabled"
        ],
        "type": "object",
        "properties": {
          "enabled": {
            "type": "boolean"
          },
          "siteKey": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "ChangeAudienceRequest": {
        "required": [
          "audience"
        ],
        "type": "object",
        "properties": {
          "audience": {
            "type": "string"
          }
        }
      },
      "ChangeQuoteStatusRequest": {
        "required": [
          "statusId"
        ],
        "type": "object",
        "properties": {
          "statusId": {
            "type": "string",
            "format": "uuid"
          },
          "notify": {
            "type": [
              "null",
              "boolean"
            ]
          }
        }
      },
      "ConvertToPolicyRequest": {
        "type": "object",
        "properties": {
          "policyNumber": {
            "type": [
              "null",
              "string"
            ]
          },
          "title": {
            "type": [
              "null",
              "string"
            ]
          },
          "insuredName": {
            "type": [
              "null",
              "string"
            ]
          },
          "startDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "endDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "audience": {
            "type": [
              "null",
              "string"
            ]
          },
          "notifyEmail": {
            "type": [
              "null",
              "boolean"
            ]
          },
          "documentIds": {
            "type": [
              "null",
              "array"
            ],
            "items": {
              "type": "string",
              "format": "uuid"
            }
          }
        }
      },
      "CreateQuoteRequest": {
        "required": [
          "title",
          "insuredName"
        ],
        "type": "object",
        "properties": {
          "title": {
            "type": "string"
          },
          "insuredName": {
            "type": "string"
          },
          "notes": {
            "type": [
              "null",
              "string"
            ]
          },
          "customerId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "sportellistaId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "productId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "distributorId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "statusId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "ndg": {
            "type": [
              "null",
              "string"
            ]
          },
          "prospectData": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/JsonNode"
              }
            ]
          },
          "totalPremiumNet": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "null",
              "number",
              "string"
            ],
            "format": "double"
          },
          "totalPremiumTax": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "null",
              "number",
              "string"
            ],
            "format": "double"
          },
          "totalPremiumGross": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "null",
              "number",
              "string"
            ],
            "format": "double"
          },
          "durationMonths": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "null",
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "startDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "endDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "periodicity": {
            "type": [
              "null",
              "string"
            ]
          },
          "notify": {
            "type": [
              "null",
              "boolean"
            ]
          }
        }
      },
      "DefaultDocumentDto": {
        "required": [
          "id",
          "distributorId",
          "name",
          "sourceType",
          "isActive"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "distributorId": {
            "type": "string",
            "format": "uuid"
          },
          "documentType": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "name": {
            "type": "string"
          },
          "fileUrl": {
            "type": [
              "null",
              "string"
            ]
          },
          "fileSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "null",
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "mimeType": {
            "type": [
              "null",
              "string"
            ]
          },
          "sourceType": {
            "type": "string"
          },
          "templateId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "isActive": {
            "type": "boolean"
          }
        }
      },
      "DeleteUserRequest": {
        "type": "object",
        "properties": {
          "action": {
            "type": "string"
          }
        }
      },
      "DetectedPdfFieldDto": {
        "required": [
          "name",
          "type",
          "isMapped"
        ],
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "type": {
            "type": "string"
          },
          "isMapped": {
            "type": "boolean"
          }
        }
      },
      "DistributorDto": {
        "required": [
          "id",
          "code",
          "name",
          "adhesionBase",
          "nextAdhesionNumber",
          "isActive",
          "createdAt"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "code": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "adhesionBase": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "nextAdhesionNumber": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "isActive": {
            "type": "boolean"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "branchCount": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "productCount": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "DocumentDownloadDto": {
        "required": [
          "url",
          "fileName",
          "expiresIn"
        ],
        "type": "object",
        "properties": {
          "url": {
            "type": "string"
          },
          "fileName": {
            "type": "string"
          },
          "expiresIn": {
            "pattern": "^-?(\\d+\\.)?\\d{2}:\\d{2}:\\d{2}(\\.\\d{1,7})?$",
            "type": "string"
          }
        }
      },
      "DocumentTemplateDto": {
        "required": [
          "id",
          "distributor",
          "name",
          "validFrom",
          "isActive",
          "createdAt",
          "isCurrentlyValid"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "distributor": {
            "$ref": "#/components/schemas/RefDto"
          },
          "product": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "documentType": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "name": {
            "type": "string"
          },
          "validFrom": {
            "type": "string",
            "format": "date"
          },
          "validTo": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "fileName": {
            "type": [
              "null",
              "string"
            ]
          },
          "fileSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "null",
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "isActive": {
            "type": "boolean"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "fieldCount": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "isCurrentlyValid": {
            "type": "boolean"
          }
        }
      },
      "DocumentTypeDto": {
        "required": [
          "id",
          "name",
          "isActive"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "null",
              "string"
            ]
          },
          "isActive": {
            "type": "boolean"
          }
        }
      },
      "EmailLogDto": {
        "required": [
          "id",
          "createdAt",
          "source",
          "status",
          "provider"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "source": {
            "type": "string"
          },
          "eventType": {
            "type": [
              "null",
              "string"
            ]
          },
          "recipientEmail": {
            "type": [
              "null",
              "string"
            ]
          },
          "subject": {
            "type": [
              "null",
              "string"
            ]
          },
          "bodyPreview": {
            "type": [
              "null",
              "string"
            ]
          },
          "status": {
            "type": "string"
          },
          "provider": {
            "type": "string"
          },
          "error": {
            "type": [
              "null",
              "string"
            ]
          },
          "quoteId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "policyId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "actorEmail": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "ForgotPasswordRequest": {
        "required": [
          "email"
        ],
        "type": "object",
        "properties": {
          "email": {
            "type": "string"
          },
          "captchaToken": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "GenerateDocumentRequest": {
        "type": "object",
        "properties": {
          "documentTypeId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "referenceDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "templateId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "name": {
            "type": [
              "null",
              "string"
            ]
          },
          "audience": {
            "type": [
              "null",
              "string"
            ]
          },
          "flatten": {
            "type": "boolean"
          }
        }
      },
      "GenerateOrPreviewRequest": {
        "type": "object",
        "properties": {
          "mode": {
            "type": "string"
          },
          "templateId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "quoteId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "documentTypeId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "overrides": {
            "type": [
              "null",
              "object"
            ],
            "additionalProperties": {
              "type": "string"
            }
          },
          "referenceDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "name": {
            "type": [
              "null",
              "string"
            ]
          },
          "audience": {
            "type": [
              "null",
              "string"
            ]
          },
          "flatten": {
            "type": "boolean"
          }
        }
      },
      "GuaranteeDto": {
        "required": [
          "id",
          "productId",
          "name",
          "internalCode",
          "taxRate",
          "isActive"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "productId": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "null",
              "string"
            ]
          },
          "internalCode": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int64"
          },
          "code": {
            "type": [
              "null",
              "string"
            ]
          },
          "companyCode": {
            "type": [
              "null",
              "string"
            ]
          },
          "taxRate": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "isActive": {
            "type": "boolean"
          }
        }
      },
      "ImportResultDto": {
        "required": [
          "totalRows",
          "imported",
          "updated",
          "skipped",
          "errors"
        ],
        "type": "object",
        "properties": {
          "totalRows": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "imported": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "updated": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "skipped": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "errors": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ImportRowErrorDto"
            }
          }
        }
      },
      "ImportRowErrorDto": {
        "required": [
          "rowNumber",
          "message"
        ],
        "type": "object",
        "properties": {
          "rowNumber": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "message": {
            "type": "string"
          }
        }
      },
      "InviteUserRequest": {
        "required": [
          "email"
        ],
        "type": "object",
        "properties": {
          "email": {
            "type": "string"
          },
          "firstName": {
            "type": [
              "null",
              "string"
            ]
          },
          "lastName": {
            "type": [
              "null",
              "string"
            ]
          },
          "phone": {
            "type": [
              "null",
              "string"
            ]
          },
          "roles": {
            "type": [
              "null",
              "array"
            ],
            "items": {
              "type": "string"
            }
          },
          "distributorId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "branchId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "approve": {
            "type": "boolean"
          }
        }
      },
      "JsonNode": { },
      "LoginRequest": {
        "required": [
          "email",
          "password"
        ],
        "type": "object",
        "properties": {
          "email": {
            "type": "string"
          },
          "password": {
            "type": "string"
          },
          "captchaToken": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "LoginResponse": {
        "required": [
          "status"
        ],
        "type": "object",
        "properties": {
          "status": {
            "type": "string"
          },
          "tokens": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/TokenResponse"
              }
            ]
          },
          "mfaChallenge": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/MfaChallengeDto"
              }
            ]
          }
        }
      },
      "MeResponse": {
        "required": [
          "userId",
          "profileId",
          "email",
          "roles",
          "roleLabels",
          "isApproved",
          "distributors",
          "mfa",
          "aal"
        ],
        "type": "object",
        "properties": {
          "userId": {
            "type": "string",
            "format": "uuid"
          },
          "profileId": {
            "type": "string",
            "format": "uuid"
          },
          "email": {
            "type": "string"
          },
          "firstName": {
            "type": [
              "null",
              "string"
            ]
          },
          "lastName": {
            "type": [
              "null",
              "string"
            ]
          },
          "phone": {
            "type": [
              "null",
              "string"
            ]
          },
          "roles": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "roleLabels": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "isApproved": {
            "type": "boolean"
          },
          "distributors": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RefDto"
            }
          },
          "primaryDistributor": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "branch": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "mfa": {
            "$ref": "#/components/schemas/MfaStatusDto"
          },
          "aal": {
            "type": "string"
          }
        }
      },
      "MessageDto": {
        "required": [
          "id",
          "quoteId",
          "content",
          "isRead",
          "createdAt",
          "isMine"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "quoteId": {
            "type": "string",
            "format": "uuid"
          },
          "sender": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "content": {
            "type": "string"
          },
          "attachmentName": {
            "type": [
              "null",
              "string"
            ]
          },
          "isRead": {
            "type": "boolean"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "audience": {
            "type": [
              "null",
              "string"
            ]
          },
          "isMine": {
            "type": "boolean"
          }
        }
      },
      "MfaChallengeDto": {
        "required": [
          "challengeToken",
          "expiresIn",
          "methods"
        ],
        "type": "object",
        "properties": {
          "challengeToken": {
            "type": "string"
          },
          "expiresIn": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "methods": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "phoneHint": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "MfaStatusDto": {
        "required": [
          "totpEnabled",
          "smsEnabled",
          "required"
        ],
        "type": "object",
        "properties": {
          "totpEnabled": {
            "type": "boolean"
          },
          "smsEnabled": {
            "type": "boolean"
          },
          "smsPhoneHint": {
            "type": [
              "null",
              "string"
            ]
          },
          "required": {
            "type": "boolean"
          }
        }
      },
      "NamirialWebhookBody": {
        "type": "object",
        "properties": {
          "envelopeId": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "NdgLookupRequest": {
        "required": [
          "ndg",
          "personType",
          "distributorCode"
        ],
        "type": "object",
        "properties": {
          "ndg": {
            "type": "string"
          },
          "personType": {
            "type": "string"
          },
          "distributorCode": {
            "type": "string"
          }
        }
      },
      "NdgLookupResult": {
        "required": [
          "ndg",
          "groups",
          "rawJson"
        ],
        "type": "object",
        "properties": {
          "ndg": {
            "type": "string"
          },
          "groups": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/NdgPersonGroup"
            }
          },
          "rawJson": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "NdgPersonGroup": {
        "required": [
          "groupType",
          "label",
          "fields"
        ],
        "type": "object",
        "properties": {
          "groupType": {
            "type": "string"
          },
          "label": {
            "type": "string"
          },
          "fields": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            }
          }
        }
      },
      "NotificationDto": {
        "required": [
          "id",
          "title",
          "message",
          "type",
          "isRead",
          "createdAt"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "title": {
            "type": "string"
          },
          "message": {
            "type": "string"
          },
          "type": {
            "type": "string"
          },
          "relatedType": {
            "type": [
              "null",
              "string"
            ]
          },
          "relatedId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "messageId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "isRead": {
            "type": "boolean"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "OrphanFileDto": {
        "required": [
          "key",
          "size",
          "lastModified"
        ],
        "type": "object",
        "properties": {
          "key": {
            "type": "string"
          },
          "size": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int64"
          },
          "lastModified": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "PagedResultOfApiLogDto": {
        "required": [
          "items",
          "total",
          "page",
          "pageSize"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ApiLogDto"
            }
          },
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "page": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "pageSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "totalPages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PagedResultOfAuthAttemptDto": {
        "required": [
          "items",
          "total",
          "page",
          "pageSize"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AuthAttemptDto"
            }
          },
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "page": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "pageSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "totalPages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PagedResultOfBackofficeDocumentDto": {
        "required": [
          "items",
          "total",
          "page",
          "pageSize"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BackofficeDocumentDto"
            }
          },
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "page": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "pageSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "totalPages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PagedResultOfBackofficeMessageDto": {
        "required": [
          "items",
          "total",
          "page",
          "pageSize"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BackofficeMessageDto"
            }
          },
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "page": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "pageSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "totalPages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PagedResultOfBackofficePolicyDto": {
        "required": [
          "items",
          "total",
          "page",
          "pageSize"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BackofficePolicyDto"
            }
          },
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "page": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "pageSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "totalPages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PagedResultOfBackofficeQuoteDto": {
        "required": [
          "items",
          "total",
          "page",
          "pageSize"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BackofficeQuoteDto"
            }
          },
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "page": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "pageSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "totalPages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PagedResultOfBranchDto": {
        "required": [
          "items",
          "total",
          "page",
          "pageSize"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BranchDto"
            }
          },
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "page": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "pageSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "totalPages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PagedResultOfDistributorDto": {
        "required": [
          "items",
          "total",
          "page",
          "pageSize"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/DistributorDto"
            }
          },
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "page": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "pageSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "totalPages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PagedResultOfEmailLogDto": {
        "required": [
          "items",
          "total",
          "page",
          "pageSize"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmailLogDto"
            }
          },
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "page": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "pageSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "totalPages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PagedResultOfGuaranteeDto": {
        "required": [
          "items",
          "total",
          "page",
          "pageSize"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/GuaranteeDto"
            }
          },
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "page": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "pageSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "totalPages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PagedResultOfNotificationDto": {
        "required": [
          "items",
          "total",
          "page",
          "pageSize"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/NotificationDto"
            }
          },
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "page": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "pageSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "totalPages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PagedResultOfPolicyListItemDto": {
        "required": [
          "items",
          "total",
          "page",
          "pageSize"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PolicyListItemDto"
            }
          },
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "page": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "pageSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "totalPages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PagedResultOfProductDto": {
        "required": [
          "items",
          "total",
          "page",
          "pageSize"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductDto"
            }
          },
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "page": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "pageSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "totalPages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PagedResultOfQuoteListItemDto": {
        "required": [
          "items",
          "total",
          "page",
          "pageSize"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/QuoteListItemDto"
            }
          },
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "page": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "pageSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "totalPages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PagedResultOfSignatureRequestDto": {
        "required": [
          "items",
          "total",
          "page",
          "pageSize"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SignatureRequestDto"
            }
          },
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "page": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "pageSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "totalPages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PagedResultOfUserListItemDto": {
        "required": [
          "items",
          "total",
          "page",
          "pageSize"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/UserListItemDto"
            }
          },
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "page": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "pageSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "totalPages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PolicyDetailDto": {
        "required": [
          "header"
        ],
        "type": "object",
        "properties": {
          "header": {
            "$ref": "#/components/schemas/PolicyListItemDto"
          },
          "guarantees": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/QuoteGuaranteeDto"
            }
          },
          "documents": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PolicyDocumentDto"
            }
          }
        }
      },
      "PolicyDocumentDto": {
        "required": [
          "id",
          "name",
          "createdAt"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "documentType": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "fileSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "null",
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "mimeType": {
            "type": [
              "null",
              "string"
            ]
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "PolicyListItemDto": {
        "required": [
          "id",
          "title",
          "insuredName",
          "createdAt"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "policyNumber": {
            "type": [
              "null",
              "string"
            ]
          },
          "title": {
            "type": "string"
          },
          "insuredName": {
            "type": "string"
          },
          "adhesionNumber": {
            "type": [
              "null",
              "string"
            ]
          },
          "customer": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "product": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "distributor": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "totalPremiumNet": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "totalPremiumTax": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "totalPremiumGross": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "startDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "endDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "status": {
            "type": [
              "null",
              "string"
            ]
          },
          "quoteId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "PostMessageRequest": {
        "required": [
          "content"
        ],
        "type": "object",
        "properties": {
          "content": {
            "type": "string"
          },
          "audience": {
            "type": [
              "null",
              "string"
            ]
          },
          "notifyEmail": {
            "type": [
              "null",
              "boolean"
            ]
          }
        }
      },
      "PreviewDocumentRequest": {
        "type": "object",
        "properties": {
          "quoteId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "values": {
            "type": [
              "null",
              "object"
            ],
            "additionalProperties": {
              "type": "string"
            }
          },
          "flatten": {
            "type": "boolean"
          }
        }
      },
      "ProductDocumentDto": {
        "required": [
          "id",
          "productId",
          "name",
          "createdAt"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "productId": {
            "type": "string",
            "format": "uuid"
          },
          "documentType": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "name": {
            "type": "string"
          },
          "fileSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "null",
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "mimeType": {
            "type": [
              "null",
              "string"
            ]
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "ProductDto": {
        "required": [
          "id",
          "name",
          "distributor",
          "isActive"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "code": {
            "type": [
              "null",
              "string"
            ]
          },
          "description": {
            "type": [
              "null",
              "string"
            ]
          },
          "distributor": {
            "$ref": "#/components/schemas/RefDto"
          },
          "communicationEmail": {
            "type": [
              "null",
              "string"
            ]
          },
          "isActive": {
            "type": "boolean"
          },
          "guaranteeCount": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "PurgeFilesRequest": {
        "type": "object",
        "properties": {
          "action": {
            "type": "string"
          }
        }
      },
      "PurgeResultDto": {
        "required": [
          "action",
          "scanned",
          "orphanCount",
          "orphanBytes",
          "deleted",
          "sample"
        ],
        "type": "object",
        "properties": {
          "action": {
            "type": "string"
          },
          "scanned": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "orphanCount": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "orphanBytes": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int64"
          },
          "deleted": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "sample": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OrphanFileDto"
            }
          },
          "failed": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        }
      },
      "QuoteDataFieldDto": {
        "required": [
          "key",
          "label",
          "group",
          "example"
        ],
        "type": "object",
        "properties": {
          "key": {
            "type": "string"
          },
          "label": {
            "type": "string"
          },
          "group": {
            "type": "string"
          },
          "example": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "QuoteDetailDto": {
        "required": [
          "id",
          "title",
          "insuredName",
          "createdAt",
          "updatedAt",
          "permissions"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "title": {
            "type": "string"
          },
          "insuredName": {
            "type": "string"
          },
          "notes": {
            "type": [
              "null",
              "string"
            ]
          },
          "adhesionNumber": {
            "type": [
              "null",
              "string"
            ]
          },
          "ndg": {
            "type": [
              "null",
              "string"
            ]
          },
          "prospectData": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/JsonNode"
              }
            ]
          },
          "customer": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "sportellista": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "product": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "distributor": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "status": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/QuoteStatusDto"
              }
            ]
          },
          "totalPremiumNet": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "totalPremiumTax": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "totalPremiumGross": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "durationMonths": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "null",
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "startDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "endDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "periodicity": {
            "type": [
              "null",
              "string"
            ]
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          },
          "guarantees": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/QuoteGuaranteeDto"
            }
          },
          "documents": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/QuoteDocumentDto"
            }
          },
          "permissions": {
            "$ref": "#/components/schemas/QuotePermissionsDto"
          }
        }
      },
      "QuoteDocumentDto": {
        "required": [
          "id",
          "name",
          "scanStatus",
          "createdAt"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "documentType": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "fileSize": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "null",
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "mimeType": {
            "type": [
              "null",
              "string"
            ]
          },
          "scanStatus": {
            "type": "string"
          },
          "audience": {
            "type": [
              "null",
              "string"
            ]
          },
          "uploadedBy": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "canDownload": {
            "type": "boolean"
          }
        }
      },
      "QuoteGuaranteeDto": {
        "required": [
          "guaranteeId",
          "name"
        ],
        "type": "object",
        "properties": {
          "guaranteeId": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "code": {
            "type": [
              "null",
              "string"
            ]
          },
          "taxRate": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "premiumNet": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "premiumTax": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "premiumGross": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          }
        }
      },
      "QuoteListItemDto": {
        "required": [
          "id",
          "title",
          "insuredName",
          "createdAt",
          "updatedAt"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "title": {
            "type": "string"
          },
          "insuredName": {
            "type": "string"
          },
          "adhesionNumber": {
            "type": [
              "null",
              "string"
            ]
          },
          "ndg": {
            "type": [
              "null",
              "string"
            ]
          },
          "customer": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "sportellista": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "product": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "distributor": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "status": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/QuoteStatusDto"
              }
            ]
          },
          "totalPremiumNet": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "totalPremiumTax": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "totalPremiumGross": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "startDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "endDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          },
          "unreadMessages": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "QuotePermissionsDto": {
        "type": "object",
        "properties": {
          "canEdit": {
            "type": "boolean"
          },
          "canChangeStatus": {
            "type": "boolean"
          },
          "canSetPremiums": {
            "type": "boolean"
          },
          "canUploadDocuments": {
            "type": "boolean"
          },
          "canChooseAudience": {
            "type": "boolean"
          },
          "canConvertToPolicy": {
            "type": "boolean"
          },
          "canDelete": {
            "type": "boolean"
          },
          "canSeeAudienceLabels": {
            "type": "boolean"
          }
        }
      },
      "QuoteStatusDetailDto": {
        "required": [
          "id",
          "name",
          "sortOrder",
          "isActive"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "null",
              "string"
            ]
          },
          "color": {
            "type": [
              "null",
              "string"
            ]
          },
          "sortOrder": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "isActive": {
            "type": "boolean"
          }
        }
      },
      "QuoteStatusDto": {
        "required": [
          "id",
          "name",
          "color",
          "sortOrder"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "color": {
            "type": [
              "null",
              "string"
            ]
          },
          "sortOrder": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "RecoveryCodesResponse": {
        "required": [
          "codes"
        ],
        "type": "object",
        "properties": {
          "codes": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        }
      },
      "RefDto": {
        "required": [
          "id",
          "name"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          }
        }
      },
      "RefreshTokenRequest": {
        "required": [
          "refreshToken"
        ],
        "type": "object",
        "properties": {
          "refreshToken": {
            "type": "string"
          }
        }
      },
      "RegisterRequest": {
        "required": [
          "email",
          "password"
        ],
        "type": "object",
        "properties": {
          "email": {
            "type": "string"
          },
          "password": {
            "type": "string"
          },
          "firstName": {
            "type": [
              "null",
              "string"
            ]
          },
          "lastName": {
            "type": [
              "null",
              "string"
            ]
          },
          "phone": {
            "type": [
              "null",
              "string"
            ]
          },
          "captchaToken": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "ResetLinkResponse": {
        "required": [
          "url",
          "generatedAt"
        ],
        "type": "object",
        "properties": {
          "url": {
            "type": "string"
          },
          "generatedAt": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "ResetPasswordRequest": {
        "required": [
          "email",
          "token",
          "newPassword"
        ],
        "type": "object",
        "properties": {
          "email": {
            "type": "string"
          },
          "token": {
            "type": "string"
          },
          "newPassword": {
            "type": "string"
          }
        }
      },
      "SendSmsOtpRequest": {
        "type": "object",
        "properties": {
          "phone": {
            "type": [
              "null",
              "string"
            ]
          },
          "challengeToken": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "SetBranchesRequest": {
        "required": [
          "branchIds"
        ],
        "type": "object",
        "properties": {
          "branchIds": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "uuid"
            }
          }
        }
      },
      "SetDistributorsRequest": {
        "required": [
          "distributorIds"
        ],
        "type": "object",
        "properties": {
          "distributorIds": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "uuid"
            }
          }
        }
      },
      "SetQuoteGuaranteeItem": {
        "required": [
          "guaranteeId"
        ],
        "type": "object",
        "properties": {
          "guaranteeId": {
            "type": "string",
            "format": "uuid"
          },
          "premiumNet": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "premiumTax": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          },
          "premiumGross": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "number",
              "string"
            ],
            "format": "double"
          }
        }
      },
      "SetQuoteGuaranteesRequest": {
        "required": [
          "guarantees"
        ],
        "type": "object",
        "properties": {
          "guarantees": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SetQuoteGuaranteeItem"
            }
          }
        }
      },
      "SetRolesRequest": {
        "required": [
          "roles"
        ],
        "type": "object",
        "properties": {
          "roles": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        }
      },
      "SetTemplateFieldItem": {
        "required": [
          "pdfFieldName"
        ],
        "type": "object",
        "properties": {
          "pdfFieldName": {
            "type": "string"
          },
          "pdfFieldType": {
            "type": [
              "null",
              "string"
            ]
          },
          "sourceKey": {
            "type": [
              "null",
              "string"
            ]
          },
          "staticValue": {
            "type": [
              "null",
              "string"
            ]
          },
          "sortOrder": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "SetTemplateFieldsRequest": {
        "required": [
          "fields"
        ],
        "type": "object",
        "properties": {
          "fields": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SetTemplateFieldItem"
            }
          }
        }
      },
      "SignatureRequestDto": {
        "required": [
          "id",
          "quoteId",
          "documentName",
          "signerFirstName",
          "signerLastName",
          "signerEmail",
          "signerPhone",
          "status",
          "createdAt",
          "updatedAt"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "quoteId": {
            "type": "string",
            "format": "uuid"
          },
          "quoteDocumentId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "documentName": {
            "type": "string"
          },
          "signerFirstName": {
            "type": "string"
          },
          "signerLastName": {
            "type": "string"
          },
          "signerEmail": {
            "type": "string"
          },
          "signerPhone": {
            "type": "string"
          },
          "status": {
            "type": "string"
          },
          "error": {
            "type": [
              "null",
              "string"
            ]
          },
          "signingUrl": {
            "type": [
              "null",
              "string"
            ]
          },
          "signedDocumentId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "completedAt": {
            "type": [
              "null",
              "string"
            ],
            "format": "date-time"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          },
          "adhesionNumber": {
            "type": [
              "null",
              "string"
            ]
          },
          "quoteTitle": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "SignatureStartDto": {
        "required": [
          "documentId",
          "firstName",
          "lastName",
          "email",
          "phone"
        ],
        "type": "object",
        "properties": {
          "documentId": {
            "type": "string",
            "format": "uuid"
          },
          "firstName": {
            "type": "string"
          },
          "lastName": {
            "type": "string"
          },
          "email": {
            "type": "string"
          },
          "phone": {
            "type": "string"
          }
        }
      },
      "SignatureTemplateDto": {
        "required": [
          "id",
          "distributorId",
          "name",
          "isActive",
          "createdAt",
          "updatedAt"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "distributorId": {
            "type": "string",
            "format": "uuid"
          },
          "distributorName": {
            "type": [
              "null",
              "string"
            ]
          },
          "name": {
            "type": "string"
          },
          "isActive": {
            "type": "boolean"
          },
          "envelopeJson": {
            "type": [
              "null",
              "string"
            ]
          },
          "placeholders": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "SignatureTemplateUpsertDto": {
        "required": [
          "distributorId",
          "name",
          "envelopeJson"
        ],
        "type": "object",
        "properties": {
          "distributorId": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "envelopeJson": {
            "type": "string"
          },
          "isActive": {
            "type": "boolean"
          }
        }
      },
      "TemplateFieldDto": {
        "required": [
          "id",
          "pdfFieldName",
          "sortOrder"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "pdfFieldName": {
            "type": "string"
          },
          "pdfFieldType": {
            "type": [
              "null",
              "string"
            ]
          },
          "sourceKey": {
            "type": [
              "null",
              "string"
            ]
          },
          "staticValue": {
            "type": [
              "null",
              "string"
            ]
          },
          "sortOrder": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "TokenResponse": {
        "required": [
          "accessToken",
          "refreshToken",
          "expiresIn",
          "aal"
        ],
        "type": "object",
        "properties": {
          "accessToken": {
            "type": "string"
          },
          "refreshToken": {
            "type": "string"
          },
          "tokenType": {
            "type": "string"
          },
          "expiresIn": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "aal": {
            "type": "string"
          }
        }
      },
      "TotpEnrollResponse": {
        "required": [
          "sharedKey",
          "authenticatorUri"
        ],
        "type": "object",
        "properties": {
          "sharedKey": {
            "type": "string"
          },
          "authenticatorUri": {
            "type": "string"
          }
        }
      },
      "UnreadByQuoteDto": {
        "required": [
          "quoteId",
          "quoteTitle",
          "unread"
        ],
        "type": "object",
        "properties": {
          "quoteId": {
            "type": "string",
            "format": "uuid"
          },
          "quoteTitle": {
            "type": "string"
          },
          "unread": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          }
        }
      },
      "UnreadSummaryDto": {
        "required": [
          "total",
          "byQuote"
        ],
        "type": "object",
        "properties": {
          "total": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "byQuote": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/UnreadByQuoteDto"
            }
          }
        }
      },
      "UpdateOwnProfileRequest": {
        "type": "object",
        "properties": {
          "firstName": {
            "type": [
              "null",
              "string"
            ]
          },
          "lastName": {
            "type": [
              "null",
              "string"
            ]
          },
          "phone": {
            "type": [
              "null",
              "string"
            ]
          },
          "fiscalCode": {
            "type": [
              "null",
              "string"
            ]
          },
          "address": {
            "type": [
              "null",
              "string"
            ]
          },
          "city": {
            "type": [
              "null",
              "string"
            ]
          },
          "postalCode": {
            "type": [
              "null",
              "string"
            ]
          },
          "companyName": {
            "type": [
              "null",
              "string"
            ]
          },
          "vatNumber": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "UpdateQuoteRequest": {
        "type": "object",
        "properties": {
          "title": {
            "type": [
              "null",
              "string"
            ]
          },
          "insuredName": {
            "type": [
              "null",
              "string"
            ]
          },
          "notes": {
            "type": [
              "null",
              "string"
            ]
          },
          "productId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "sportellistaId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "ndg": {
            "type": [
              "null",
              "string"
            ]
          },
          "prospectData": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/JsonNode"
              }
            ]
          },
          "totalPremiumNet": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "null",
              "number",
              "string"
            ],
            "format": "double"
          },
          "totalPremiumTax": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "null",
              "number",
              "string"
            ],
            "format": "double"
          },
          "totalPremiumGross": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "null",
              "number",
              "string"
            ],
            "format": "double"
          },
          "durationMonths": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "null",
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "startDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "endDate": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "periodicity": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "UpdateUserRequest": {
        "type": "object",
        "properties": {
          "firstName": {
            "type": [
              "null",
              "string"
            ]
          },
          "lastName": {
            "type": [
              "null",
              "string"
            ]
          },
          "phone": {
            "type": [
              "null",
              "string"
            ]
          },
          "fiscalCode": {
            "type": [
              "null",
              "string"
            ]
          },
          "address": {
            "type": [
              "null",
              "string"
            ]
          },
          "city": {
            "type": [
              "null",
              "string"
            ]
          },
          "postalCode": {
            "type": [
              "null",
              "string"
            ]
          },
          "personType": {
            "type": [
              "null",
              "string"
            ]
          },
          "companyName": {
            "type": [
              "null",
              "string"
            ]
          },
          "vatNumber": {
            "type": [
              "null",
              "string"
            ]
          },
          "employeeCode": {
            "type": [
              "null",
              "string"
            ]
          },
          "distributorId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "branchId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          }
        }
      },
      "UpsertAppSettingRequest": {
        "required": [
          "value"
        ],
        "type": "object",
        "properties": {
          "value": {
            "type": "string"
          },
          "description": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "UpsertBranchRequest": {
        "required": [
          "distributorId",
          "name",
          "branchCode"
        ],
        "type": "object",
        "properties": {
          "distributorId": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "nameSecondary": {
            "type": [
              "null",
              "string"
            ]
          },
          "branchCode": {
            "type": "string"
          },
          "areaCode": {
            "type": [
              "null",
              "string"
            ]
          },
          "city": {
            "type": [
              "null",
              "string"
            ]
          },
          "isActive": {
            "type": [
              "null",
              "boolean"
            ]
          }
        }
      },
      "UpsertDistributorRequest": {
        "required": [
          "code",
          "name"
        ],
        "type": "object",
        "properties": {
          "code": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "adhesionBase": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "null",
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "isActive": {
            "type": [
              "null",
              "boolean"
            ]
          }
        }
      },
      "UpsertDocumentTemplateRequest": {
        "required": [
          "distributorId",
          "name"
        ],
        "type": "object",
        "properties": {
          "distributorId": {
            "type": "string",
            "format": "uuid"
          },
          "productId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "documentTypeId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "validFrom": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "validTo": {
            "type": [
              "null",
              "string"
            ],
            "format": "date"
          },
          "isActive": {
            "type": [
              "null",
              "boolean"
            ]
          }
        }
      },
      "UpsertDocumentTypeRequest": {
        "required": [
          "name"
        ],
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "null",
              "string"
            ]
          },
          "isActive": {
            "type": [
              "null",
              "boolean"
            ]
          }
        }
      },
      "UpsertGuaranteeRequest": {
        "required": [
          "productId",
          "name"
        ],
        "type": "object",
        "properties": {
          "productId": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "null",
              "string"
            ]
          },
          "internalCode": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "null",
              "integer",
              "string"
            ],
            "format": "int64"
          },
          "code": {
            "type": [
              "null",
              "string"
            ]
          },
          "companyCode": {
            "type": [
              "null",
              "string"
            ]
          },
          "taxRate": {
            "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$",
            "type": [
              "null",
              "number",
              "string"
            ],
            "format": "double"
          },
          "isActive": {
            "type": [
              "null",
              "boolean"
            ]
          }
        }
      },
      "UpsertProductRequest": {
        "required": [
          "name",
          "distributorId"
        ],
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "code": {
            "type": [
              "null",
              "string"
            ]
          },
          "description": {
            "type": [
              "null",
              "string"
            ]
          },
          "distributorId": {
            "type": "string",
            "format": "uuid"
          },
          "communicationEmail": {
            "type": [
              "null",
              "string"
            ]
          },
          "isActive": {
            "type": [
              "null",
              "boolean"
            ]
          }
        }
      },
      "UpsertQuoteStatusRequest": {
        "required": [
          "name"
        ],
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "null",
              "string"
            ]
          },
          "color": {
            "type": [
              "null",
              "string"
            ]
          },
          "sortOrder": {
            "pattern": "^-?(?:0|[1-9]\\d*)$",
            "type": [
              "null",
              "integer",
              "string"
            ],
            "format": "int32"
          },
          "isActive": {
            "type": [
              "null",
              "boolean"
            ]
          }
        }
      },
      "UserDetailDto": {
        "required": [
          "header",
          "personType"
        ],
        "type": "object",
        "properties": {
          "header": {
            "$ref": "#/components/schemas/UserListItemDto"
          },
          "address": {
            "type": [
              "null",
              "string"
            ]
          },
          "city": {
            "type": [
              "null",
              "string"
            ]
          },
          "postalCode": {
            "type": [
              "null",
              "string"
            ]
          },
          "personType": {
            "type": "string"
          },
          "companyName": {
            "type": [
              "null",
              "string"
            ]
          },
          "vatNumber": {
            "type": [
              "null",
              "string"
            ]
          },
          "branches": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RefDto"
            }
          }
        }
      },
      "UserListItemDto": {
        "required": [
          "id",
          "userId",
          "email",
          "isApproved",
          "isDisabled",
          "roles",
          "roleLabels",
          "createdAt",
          "mfaEnabled"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "userId": {
            "type": "string",
            "format": "uuid"
          },
          "email": {
            "type": "string"
          },
          "firstName": {
            "type": [
              "null",
              "string"
            ]
          },
          "lastName": {
            "type": [
              "null",
              "string"
            ]
          },
          "phone": {
            "type": [
              "null",
              "string"
            ]
          },
          "fiscalCode": {
            "type": [
              "null",
              "string"
            ]
          },
          "isApproved": {
            "type": "boolean"
          },
          "isDisabled": {
            "type": "boolean"
          },
          "roles": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "roleLabels": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "primaryDistributor": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "branch": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/RefDto"
              }
            ]
          },
          "distributors": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RefDto"
            }
          },
          "employeeCode": {
            "type": [
              "null",
              "string"
            ]
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "lastLoginAt": {
            "type": [
              "null",
              "string"
            ],
            "format": "date-time"
          },
          "mfaEnabled": {
            "type": "boolean"
          }
        }
      },
      "VerifyCodeRequest": {
        "required": [
          "code"
        ],
        "type": "object",
        "properties": {
          "code": {
            "type": "string"
          },
          "challengeToken": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      }
    },
    "securitySchemes": {
      "Bearer": {
        "type": "http",
        "description": "Access token restituito da POST /auth/login. Incollare il solo valore di accessToken, senza il prefisso Bearer. Se l'utente ha la verifica in due passaggi attiva, il login non restituisce un access token ma una sfida: il token arriva dopo POST /auth/mfa/totp/challenge.",
        "scheme": "bearer",
        "bearerFormat": "JWT"
      }
    }
  },
  "security": [
    {
      "Bearer": [ ]
    }
  ],
  "tags": [
    {
      "name": "Auth"
    },
    {
      "name": "ApiTokens"
    },
    {
      "name": "Backoffice"
    },
    {
      "name": "Maintenance"
    },
    {
      "name": "Distributors"
    },
    {
      "name": "Branches"
    },
    {
      "name": "Products"
    },
    {
      "name": "Guarantees"
    },
    {
      "name": "DocumentTypes"
    },
    {
      "name": "QuoteStatuses"
    },
    {
      "name": "Settings"
    },
    {
      "name": "ConfigurationImport"
    },
    {
      "name": "Notifications"
    },
    {
      "name": "Logs"
    },
    {
      "name": "Integrations"
    },
    {
      "name": "Policies"
    },
    {
      "name": "Quotes"
    },
    {
      "name": "Documents"
    },
    {
      "name": "Messages"
    },
    {
      "name": "SignatureTemplates"
    },
    {
      "name": "Signatures"
    },
    {
      "name": "NamirialWebhook"
    },
    {
      "name": "DocumentTemplates"
    },
    {
      "name": "QuoteDataFields"
    },
    {
      "name": "QuoteDocumentGeneration"
    },
    {
      "name": "Users"
    },
    {
      "name": "Customers"
    },
    {
      "name": "Profile"
    }
  ]
}