{
  "openapi": "3.0.4",
  "info": {
    "title": "Distribution Manager API",
    "description": "The Distribution Manager API provides programmatic access to create and manage fund\ndistributions, payout instructions, and reports.\n\n## Key Resources\n\n- **Distributions**: Endpoints for creating and managing distributions.\n- **Payout Instructions**: Endpoints for creating and managing payout instructions.\n- **Payout Methods**: Endpoints for viewing available payout methods, such as ACH, PayPal, and gift cards.\n- **Reports**: Endpoints for retrieving analytics and reporting data about distributions and payouts.\n- **Funds Holders**: Endpoints for creating and viewing funds holders.\n- **Templates**: Endpoints for creating and managing notification templates, including retrieving template-type schemas and sending preview notifications.\n- **Users**: Endpoints for viewing and managing members of your organization, including changing a member's role and removing members.\n- **Roles**: Endpoints for viewing the roles that can be assigned to members of your organization.\n- **Invitations**: Endpoints for sending and managing invitations for members to join your organization.\n- **Bank Accounts**: Endpoints for creating and managing bank accounts, including transactions, withdrawal accounts, and withdrawals.\n- **Brand Configuration**: Authenticated endpoints for managing the organisation's white-label brand configuration: slug, colours, logo, favicon, and company details.\n- **Credentials**: Endpoints for API credentials.\n\n## Authentication\n\nAll requests require OAuth 2.0 authentication using Auth0 with appropriate scopes.",
    "contact": {
      "name": "Talli API Support",
      "email": "api-support@talli.ai"
    },
    "license": {
      "name": "Proprietary and Confidential"
    },
    "version": "v3"
  },
  "paths": {
    "/v3/distribution-manager/bank-accounts": {
      "post": {
        "tags": [
          "bank-accounts"
        ],
        "summary": "Create Bank account",
        "description": "Creates a new bank account",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateBankAccountV3Request"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "bankAccounts:create"
            ]
          }
        ]
      },
      "get": {
        "tags": [
          "bank-accounts"
        ],
        "summary": "List Bank Accounts",
        "description": "Retrieves a paginated list of bank accounts for the organization. By default, bank accounts still being set up (Pending) are excluded; pass `includePending=true` to include them.",
        "parameters": [
          {
            "name": "pageNumber",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "maximum": 100,
              "minimum": 1,
              "type": "integer",
              "format": "int32",
              "default": 20
            }
          },
          {
            "name": "includePending",
            "in": "query",
            "schema": {
              "type": "boolean",
              "default": false
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedCollectionOfBankAccountResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "bankAccounts:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/bank-accounts/{id}": {
      "get": {
        "tags": [
          "bank-accounts"
        ],
        "summary": "Get Bank account",
        "description": "Retrieves a single bank account based on provided identifier",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BankAccountResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "bankAccounts:view"
            ]
          }
        ]
      },
      "patch": {
        "tags": [
          "bank-accounts"
        ],
        "summary": "Rename Bank account",
        "description": "Updates the display alias of a bank account.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RenameBankAccountRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "bankAccounts:create"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/bank-accounts/{id}/transactions": {
      "get": {
        "tags": [
          "bank-accounts"
        ],
        "summary": "Get Bank Account Transactions",
        "description": "Retrieves a paginated list of all transactions for the given bank account, regardless of distribution. Supports filtering by transaction type and optional aggregation of internal transfers by date and status.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "pageNumber",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "maximum": 100,
              "minimum": 1,
              "type": "integer",
              "format": "int32",
              "default": 20
            }
          },
          {
            "name": "filterByTransactionType",
            "in": "query",
            "schema": {
              "$ref": "#/components/schemas/BankAccountTransactionType"
            }
          },
          {
            "name": "aggregate",
            "in": "query",
            "schema": {
              "type": "boolean",
              "default": false
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DistributionsBankAccountTransactionsResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "bankAccounts:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/bank-accounts/transfers/{id}/tags": {
      "patch": {
        "tags": [
          "bank-accounts"
        ],
        "summary": "Set tags on a bank account transfer",
        "description": "Sets the tags on an existing bank account funding transfer.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TagAchTransferDistributionRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "transfers:tagCampaign"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/bank-accounts/{id}/withdrawal-accounts": {
      "get": {
        "tags": [
          "bank-accounts"
        ],
        "summary": "Get Withdrawal Accounts",
        "description": "Retrieves a paginated list of withdrawal accounts for a bank account",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "pageNumber",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "maximum": 100,
              "minimum": 1,
              "type": "integer",
              "format": "int32",
              "default": 20
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BankAccountWithdrawalAccountsResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "bankAccounts:view"
            ]
          }
        ]
      },
      "post": {
        "tags": [
          "bank-accounts"
        ],
        "summary": "Create withdrawal account for bank account",
        "description": "Creates a new withdrawal account associated with a bank account",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateWithdrawalAccountForFundsHolderRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CreateWithdrawalAccountResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized"
          },
          "403": {
            "description": "Forbidden"
          }
        },
        "security": [
          {
            "oauth2": [
              "linkedAccounts:create"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/bank-accounts/{id}/:withdraw": {
      "post": {
        "tags": [
          "bank-accounts"
        ],
        "summary": "Withdraw from bank account",
        "description": "Triggers a money movement from a bank account to a withdrawal account.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WithdrawFromBankAccountRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted",
            "content": {
              "application/json": {
                "schema": {
                  "type": "string",
                  "format": "uuid"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "bankAccounts:withdraw"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/brand": {
      "get": {
        "tags": [
          "brand-configuration"
        ],
        "summary": "Get Brand Config",
        "description": "Returns the organisation's brand configuration, or an empty one if not set up yet.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BrandConfigResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "organizationSettings:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/brand/slug": {
      "put": {
        "tags": [
          "brand-configuration"
        ],
        "summary": "Set Brand Slug",
        "description": "Sets the brand slug. Required for branding to take effect; immutable once set.",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetBrandSlugRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BrandConfigResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "organizationSettings:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/brand/colors": {
      "put": {
        "tags": [
          "brand-configuration"
        ],
        "summary": "Set Brand Colors",
        "description": "Sets or clears the brand's primary and secondary colors (paired).",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BrandColors"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BrandConfigResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "organizationSettings:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/brand/company-details": {
      "put": {
        "tags": [
          "brand-configuration"
        ],
        "summary": "Set Brand Company Details",
        "description": "Updates display name (UI label), company name (legal name), support email and address.",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetBrandCompanyDetailsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BrandConfigResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "organizationSettings:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/brand/logo": {
      "post": {
        "tags": [
          "brand-configuration"
        ],
        "summary": "Upload Brand Logo",
        "description": "Uploads the brand logo. Accepts SVG (≤ 200KB) or PNG (≤ 400×120px, ≤ 200KB).",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "required": [
                  "file"
                ],
                "type": "object",
                "properties": {
                  "file": {
                    "type": "string",
                    "format": "binary"
                  }
                }
              },
              "encoding": {
                "file": {
                  "style": "form"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BrandAssetUploadResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "organizationSettings:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/brand/favicon": {
      "post": {
        "tags": [
          "brand-configuration"
        ],
        "summary": "Upload Brand Favicon",
        "description": "Uploads the brand favicon. Accepts ICO (all images ≤ 32×32px, ≤ 20KB).",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "required": [
                  "file"
                ],
                "type": "object",
                "properties": {
                  "file": {
                    "type": "string",
                    "format": "binary"
                  }
                }
              },
              "encoding": {
                "file": {
                  "style": "form"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BrandAssetUploadResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "organizationSettings:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/credentials": {
      "get": {
        "tags": [
          "credentials"
        ],
        "summary": "List credentials",
        "description": "Lists the organization's API credentials, oldest first: for each, the client id, name, scopes preset\nand granted scopes, and when it was created, last updated and last had its secret rotated. The\nresponse holds no client secret.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/CredentialResponse"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "credentials:view"
            ]
          }
        ]
      },
      "post": {
        "tags": [
          "credentials"
        ],
        "summary": "Create a credential",
        "description": "Creates a credential, a client ID and secret for the caller's organization, with the scopes of the\nchosen scopesPreset: FullAccess or ReadOnly. The response holds the client secret, the token URL and\nthe audience. The secret is shown once: Talli does not store it. The name is 1 to 128 characters,\nnot only whitespace, with no control characters. It is stored as sent and must be unique in the\norganization, case included. Returns 409 with error code CREDENTIAL_LIMIT_REACHED when the\norganization already has 2 credentials, the maximum, and CREDENTIAL_NAME_TAKEN when another\ncredential has the name. A call with the token of a credential that no longer exists gets 403 with\nerror code CALLER_CREDENTIAL_NOT_FOUND. Returns 502 when the credential could not be created; retry\nthe call.",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateCredentialRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CreatedCredentialResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "502": {
            "description": "Bad Gateway",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "credentials:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/credentials/{clientId}": {
      "get": {
        "tags": [
          "credentials"
        ],
        "summary": "Get a credential",
        "description": "Retrieves one of the organization's API credentials by its client id, with the fields the list\nreturns. The response holds no client secret. Returns 404 when the organization has no credential\nwith that client id.",
        "parameters": [
          {
            "name": "clientId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CredentialResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "credentials:view"
            ]
          }
        ]
      },
      "patch": {
        "tags": [
          "credentials"
        ],
        "summary": "Rename a credential",
        "description": "Renames a credential. The name is the only field that changes: a credential's access is set when it\nis created. The name is 1 to 128 characters, not only whitespace, with no control characters. It is\nstored as sent and must be unique in the organization, case included: a name that another credential\nhas returns 409 with error code CREDENTIAL_NAME_TAKEN. A call with the token of a credential that no\nlonger exists gets 403 with error code CALLER_CREDENTIAL_NOT_FOUND. Returns 404 when the organization\nhas no credential with this client ID.",
        "parameters": [
          {
            "name": "clientId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateCredentialRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CredentialResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "credentials:manage"
            ]
          }
        ]
      },
      "delete": {
        "tags": [
          "credentials"
        ],
        "summary": "Delete a credential",
        "description": "Deletes a credential of the caller's organization. Its client ID and secret can no longer get access\ntokens. Access tokens already issued with it keep working until they expire, at most 24 hours later. A\ncredential cannot delete itself: a call with the token of the credential it deletes gets 409 with error\ncode CANNOT_DELETE_OWN_CREDENTIAL, so a credential token never deletes the organization's last\ncredential; a console user can. A call with the token of a credential that no longer exists gets 403\nwith error code CALLER_CREDENTIAL_NOT_FOUND. Returns 404 when the organization has no credential with\nthis client ID, and 502 when the deletion failed or could not be confirmed; retry the call.",
        "parameters": [
          {
            "name": "clientId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "204": {
            "description": "No Content"
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "502": {
            "description": "Bad Gateway",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "credentials:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/credentials/{clientId}/:rotate-secret": {
      "post": {
        "tags": [
          "credentials"
        ],
        "summary": "Rotate a credential's secret",
        "description": "Issues a new client secret for the credential and returns it with the credential, the token URL and\nthe audience. The secret is shown once: Talli does not store it. The previous secret stops working,\nand access tokens already issued keep working until they expire. A credential can rotate its own\nsecret. A call with the token of a credential that no longer exists gets 403 with error code\nCALLER_CREDENTIAL_NOT_FOUND. Returns 404 when the organization has no credential with this client\nID, and 502 when the rotation failed or could not be confirmed. After a 502 or any other 5xx, call\nagain: the previous secret may already have stopped working.",
        "parameters": [
          {
            "name": "clientId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CreatedCredentialResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "502": {
            "description": "Bad Gateway",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "credentials:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{id}/funding-requests": {
      "get": {
        "tags": [
          "distributions"
        ],
        "summary": "List funding requests",
        "description": "Lists funding requests for the distribution, newest first. Each entry includes the current\nstatus, the amount, the addressee, and a snapshot of the distribution's bank account taken\nwhen the request was sent.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "pageNumber",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 20
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedCollectionOfFundingRequestResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "fundingRequests:view"
            ]
          }
        ]
      },
      "post": {
        "tags": [
          "distributions"
        ],
        "summary": "Send a funding request",
        "description": "Sends a funding request to another console user asking them to fund the distribution's bank\naccount. The request is a notification with a receipt: it does not move money and nothing\ndownstream waits on it. The distribution's bank account snapshot (account name, numbers and\naddress) and reference are captured at send time and returned as-is on later reads.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateFundingRequestRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FundingRequestResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "fundingRequests:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{id}/funding-requests/{requestId}": {
      "get": {
        "tags": [
          "distributions"
        ],
        "summary": "Get a funding request",
        "description": "Retrieves a single funding request by identifier.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "requestId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FundingRequestResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "fundingRequests:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{id}/funding-requests/{requestId}/:confirm": {
      "post": {
        "tags": [
          "distributions"
        ],
        "summary": "Confirm a funding request",
        "description": "Confirms a Sent funding request. Only the user the request was sent to can confirm it, whatever\ntheir role; anyone else gets 403 with error code NOT_FUNDING_REQUEST_ADDRESSEE. The confirmation\nrecords who confirmed, their name, the time and the user agent. Returns 409 with error code\nFUNDING_REQUEST_NOT_PENDING when the request is no longer Sent, or\nFUNDING_REQUEST_CHANGED_CONCURRENTLY when it changed while the call was processed; retry then.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "requestId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FundingRequestResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "fundingRequests:respond"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{id}/funding-requests/{requestId}/:decline": {
      "post": {
        "tags": [
          "distributions"
        ],
        "summary": "Decline a funding request",
        "description": "Declines a Sent funding request with a reason of up to 1000 characters. Only the user the request\nwas sent to can decline it, whatever their role; anyone else gets 403 with error code\nNOT_FUNDING_REQUEST_ADDRESSEE. The decline records who declined, their name, the time and the user\nagent. Returns 409 with error code FUNDING_REQUEST_NOT_PENDING when the request is no longer Sent,\nor FUNDING_REQUEST_CHANGED_CONCURRENTLY when it changed while the call was processed; retry then.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "requestId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DeclineFundingRequestRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FundingRequestResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "fundingRequests:respond"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{id}/funding-requests/{requestId}/:cancel": {
      "post": {
        "tags": [
          "distributions"
        ],
        "summary": "Cancel a funding request",
        "description": "Withdraws a Sent funding request before its addressee answers. Returns 409 with error code\nFUNDING_REQUEST_NOT_PENDING when the request is no longer Sent, or\nFUNDING_REQUEST_CHANGED_CONCURRENTLY when it changed while the call was processed; retry then.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "requestId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FundingRequestResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "fundingRequests:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions": {
      "get": {
        "tags": [
          "distributions"
        ],
        "summary": "Get Distributions",
        "description": "Retrieves a paginated list of distributions, optionally filtered by a payout instruction ID, a bank account ID,\nan exact 'externalId', or a 'name' term matched case-insensitively against any part of the distribution name.\nFilters combine with AND. Rows are ordered by creation date, newest first, then by id as a tiebreak.\nTo include details about total funds received and statistics on the statuses of the payout instructions, use 'includeDetails' flag.",
        "parameters": [
          {
            "name": "pageNumber",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "maximum": 100,
              "minimum": 1,
              "type": "integer",
              "format": "int32",
              "default": 20
            }
          },
          {
            "name": "payoutInstructionId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "bankAccountId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "includeDetails",
            "in": "query",
            "schema": {
              "type": "boolean",
              "default": false
            }
          },
          {
            "name": "externalId",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "name",
            "in": "query",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedCollectionOfDistributionWithDetailsResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "distributions:view"
            ]
          }
        ]
      },
      "post": {
        "tags": [
          "distributions"
        ],
        "summary": "Create Distribution",
        "description": "Creates a new distribution with the specified data. Icon file accepts a PNG or JPEG image up to 2 MB.",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/CreateDistributionRequest"
              }
            },
            "application/x-www-form-urlencoded": {
              "schema": {
                "$ref": "#/components/schemas/CreateDistributionRequest"
              }
            }
          }
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "distributions:create"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{id}": {
      "patch": {
        "tags": [
          "distributions"
        ],
        "summary": "Patch Distribution",
        "description": "Patches an existing distribution with the provided data.\nNote: The icon needs to be patched separately.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "required": [
                    "op",
                    "path"
                  ],
                  "type": "object",
                  "properties": {
                    "op": {
                      "enum": [
                        "add",
                        "remove",
                        "replace"
                      ],
                      "type": "string",
                      "description": "The operation to perform."
                    },
                    "path": {
                      "enum": [
                        "/Name",
                        "/WelcomeHeadline",
                        "/DistributionDescription",
                        "/WelcomeText",
                        "/DistributionManager",
                        "/PayoutMethods",
                        "/ExpiryDate",
                        "/DisplayEndDate",
                        "/EmailTemplates",
                        "/AutomaticReminders",
                        "/FromEmail",
                        "/TaxCollection"
                      ],
                      "type": "string",
                      "description": "JSON Pointer to the field to change."
                    },
                    "value": {
                      "description": "The new value. Required for `add` and `replace`; its type matches the corresponding field on the Distribution."
                    }
                  },
                  "additionalProperties": false
                },
                "description": "JSON Patch document (RFC 6902) applied to the Distribution. Only the fields listed under `path` may be changed."
              },
              "example": [
                {
                  "op": "replace",
                  "path": "/Name",
                  "value": "new value"
                }
              ]
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "distributions:edit"
            ]
          }
        ]
      },
      "get": {
        "tags": [
          "distributions"
        ],
        "summary": "Get Distribution",
        "description": "Retrieves a single distribution based on provided identifier",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DistributionResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "distributions:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{id}/distribution-icon": {
      "patch": {
        "tags": [
          "distributions"
        ],
        "summary": "Patch Distribution icon",
        "description": "Patches an existing distribution with the provided icon file. Accepts a PNG or JPEG image up to 2 MB.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "required": [
                  "iconFile"
                ],
                "type": "object",
                "properties": {
                  "iconFile": {
                    "type": "string",
                    "format": "binary"
                  }
                }
              },
              "encoding": {
                "iconFile": {
                  "style": "form"
                }
              }
            }
          }
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "distributions:edit"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/payout-instructions/:get-sample-file": {
      "get": {
        "tags": [
          "distributions"
        ],
        "summary": "Download a sample beneficiaries file",
        "description": "Retrieves a sample beneficiaries file in the expected format. Add a column of your own to the file to import it as a tag on every row.",
        "parameters": [
          {
            "name": "size",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 20
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/csv": {
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:view",
              "distributions:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{distributionId}/:set-password": {
      "post": {
        "tags": [
          "distributions"
        ],
        "summary": "Set password for given distribution",
        "description": "Allows to set a password for the distribution.\nFrom that moment on, each beneficiary will be asked to enter the password when attempting to redeem funds.\nOnce set, the password cannot be removed, it can only be changed.",
        "parameters": [
          {
            "name": "distributionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetDistributionPasswordRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "distributions:setPassword"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{id}/:reassign-subclient": {
      "post": {
        "tags": [
          "distributions"
        ],
        "summary": "Reassign distribution sub-client",
        "description": "Reassigns the distribution to a different sub-client (or to the parent organization when no sub-client is provided).\nThe new sub-client cascades to every payout instruction of the distribution.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReassignDistributionSubClientRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "sub-clients:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{id}/account-details": {
      "get": {
        "tags": [
          "distributions"
        ],
        "summary": "Get Bank account",
        "description": "Retrieves a single bank account based on provided distribution identifier",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BankAccountResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "bankAccounts:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{id}/transactions": {
      "get": {
        "tags": [
          "distributions"
        ],
        "summary": "Get Transactions",
        "description": "Retrieves a list of transactions tagged with the specific distribution.\nWhen 'aggregate' is set to true, InternalTransfer transactions are aggregated by UTC date and status,\nwhile other transaction types are returned as individual transactions.\nThe 'filterByTransactionType' parameter can be used to filter the results to a specific transaction type.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "pageNumber",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "maximum": 100,
              "minimum": 1,
              "type": "integer",
              "format": "int32",
              "default": 20
            }
          },
          {
            "name": "filterByTransactionType",
            "in": "query",
            "schema": {
              "$ref": "#/components/schemas/BankAccountTransactionType"
            }
          },
          {
            "name": "aggregate",
            "in": "query",
            "schema": {
              "type": "boolean",
              "default": false
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DistributionsBankAccountTransactionsResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "bankAccounts:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{id}/payout-instructions/:upload": {
      "post": {
        "tags": [
          "distributions"
        ],
        "summary": "Upload a file with payout instructions",
        "description": "Uploads a file with payout instructions to the given distribution. The maximum size of the file is 262144000 bytes. The returned identifier tags the upload batch: poll the upload-status endpoint with it until processing completes, then list each row's outcome through the upload-status rows endpoint. Columns beyond the known ones are imported as tags: at most 20 of them, names up to 64 characters and values up to 128, names unique regardless of case and different from the known column names. Two tag columns whose names differ only by case are rejected here; on a payout instruction itself such a pair is two separate tags. Neither a name nor a value can contain < > { }, and a name cannot contain a comma, a double quote or an ampersand. An empty cell means the row carries no such tag. detectedTagColumns in the response lists the columns that were read as tags, so an unexpected entry there means a column name did not land where you meant it to. A file with tag columns replaces the tags of every row it re-uploads; a file without them leaves the stored tags alone.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "required": [
                  "file"
                ],
                "type": "object",
                "properties": {
                  "file": {
                    "type": "string",
                    "format": "binary"
                  }
                }
              },
              "encoding": {
                "file": {
                  "style": "form"
                }
              }
            }
          }
        },
        "responses": {
          "202": {
            "description": "Accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UploadPayoutInstructionsFileResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:create",
              "payoutInstructions:update"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{id}/payout-instructions/upload-status/{batchId}": {
      "get": {
        "tags": [
          "distributions"
        ],
        "summary": "Get the processing status of a payout instructions upload",
        "description": "Returns exact progress for one upload batch: total rows in the file, how many have been processed so far, and whether processing is complete. The Ready/Draft/Skipped/Failed counts reflect each row's outcome at import time; the upload-status rows endpoint lists the rows behind each count. Use this instead of polling the Ready count. Note: do not treat a complete snapshot as final. For a short time after processing completes, a row reported as Failed can change to Ready. A row that failed because processing was delayed can change to its real outcome later, and the Failed count then goes down. Re-uploading the file is safe in either case — rows are matched by their 'Id' value.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "batchId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PayoutInstructionUploadStatusResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{id}/payout-instructions/upload-status/{batchId}/rows": {
      "get": {
        "tags": [
          "distributions"
        ],
        "summary": "Get the per-row outcomes of a payout instructions upload",
        "description": "Lists the per-row outcomes of one upload batch, ordered by each row's line number in the uploaded file. Every row reports the file's 'Id' column value and, once imported, the payout instruction it created or updated; the optional 'outcome' parameter narrows the list to one outcome (e.g. outcome=Failed). Wait until the upload-status endpoint reports the upload batch complete before sweeping rows — outcomes settle while processing runs. For a short time after processing completes, a Failed row can still change to Ready. A row that failed because processing was delayed can change to its real outcome later. Skipped rows reference no payout instruction; resolve a skipped row to its live payout instruction by filtering the payout instructions list on its externalId.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "batchId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "outcome",
            "in": "query",
            "schema": {
              "$ref": "#/components/schemas/PayoutInstructionUploadRowOutcome"
            }
          },
          {
            "name": "pageNumber",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "maximum": 100,
              "minimum": 1,
              "type": "integer",
              "format": "int32",
              "default": 20
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedCollectionOfPayoutInstructionUploadRowResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{distributionId}/payout-instructions/:initiate": {
      "post": {
        "tags": [
          "distributions"
        ],
        "summary": "Bulk initiate payout instructions",
        "description": "Initiates payout instructions of the distribution in a single batch and sends the initial email notification to each beneficiary.\nOnly payout instructions in the Ready status are selected, oldest first; the response reports how many were actually accepted.\nThe selection can be scoped with 'uploadBatchId' (only instructions created or updated by that upload batch) and capped with 'count'.\nAlternatively, pass 'payoutInstructionIds' to initiate an explicit, hand-picked set — mutually exclusive with 'uploadBatchId' and 'count'. That selection is all-or-nothing: every id must belong to this distribution and be Ready, otherwise the request is rejected with 409 listing the unusable ids and nothing is initiated.\nThe upload batch must belong to this distribution and have finished processing: an unknown batch is rejected with 404, a still-processing one with 409 — poll the upload-status endpoint until it reports complete.\nWhen 'count' is omitted, all Ready instructions in scope are selected; if more than 25000 are Ready the request is rejected — provide a count, split the work into smaller uploads, or contact Talli support.\nThe whole batch is accepted or rejected atomically: the distribution's bank account must hold enough unallocated funds to cover the batch,\nand the batch must fit within the organization's daily email send limit (otherwise the request is rejected with the current limit and usage — contact Talli support to send more emails).\nAccepted emails are queued and sent gradually; the returned batch identifier tags every email produced by the batch.\nWith 'dryRun' set to true, all validations run and the would-be batch summary is returned with status 200, but nothing is initiated.",
        "parameters": [
          {
            "name": "distributionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BulkInitiatePayoutInstructionsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BulkInitiatePayoutInstructionsResponse"
                }
              }
            }
          },
          "202": {
            "description": "Accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BulkInitiatePayoutInstructionsResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:initiate"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{distributionId}/payout-instructions/:send-reminders": {
      "post": {
        "tags": [
          "distributions"
        ],
        "summary": "Bulk send payout instruction reminders",
        "description": "Sends reminders for up to 'count' eligible payout instructions of the distribution in a single batch.\nEligible instructions are those still awaiting beneficiary action that have not been notified within the reminder interval, oldest reminder first; the response reports how many were actually accepted.\nThe batch must fit within the organization's daily email send limit (otherwise the request is rejected with the current limit and usage — contact Talli support to send more emails).\nAccepted reminders are queued and sent gradually; the returned batch identifier tags every email produced by the batch.\nWith 'dryRun' set to true, all validations run and the would-be batch summary is returned with status 200, but nothing is sent.",
        "parameters": [
          {
            "name": "distributionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BulkSendRemindersRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BulkSendRemindersResponse"
                }
              }
            }
          },
          "202": {
            "description": "Accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BulkSendRemindersResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:sendReminder"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{distributionId}/payout-instructions/:direct-ach": {
      "post": {
        "tags": [
          "distributions"
        ],
        "summary": "Request Direct ACH Transfer",
        "description": "Requests a direct ACH payout to a beneficiary supplied entirely by the distribution manager, with no claim journey.\nThe beneficiary's identity and destination bank details are supplied in the request body rather than collected from them, so no claim notification is ever sent.\nReturns the identifier of the payout instruction the request will produce. The identifier is derived from the distribution and 'externalId'.\nA second request with the same 'externalId' is rejected with 400, unless the earlier request was rejected. To find the payout instruction of an earlier request, filter the payout instructions list on 'externalId'.",
        "parameters": [
          {
            "name": "distributionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DirectACHTransferRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted",
            "content": {
              "application/json": {
                "schema": {
                  "type": "string",
                  "format": "uuid"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:directPayout"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/distributions/{distributionId}/:refund": {
      "post": {
        "tags": [
          "distributions"
        ],
        "summary": "Refund distribution",
        "description": "Triggers a money movement from a distribution bank account to return external account. Deprecated: use POST /v3/distribution-manager/bank-accounts/{id}/:withdraw instead.",
        "parameters": [
          {
            "name": "distributionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RefundDistributionRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted",
            "content": {
              "application/json": {
                "schema": {
                  "type": "string",
                  "format": "uuid"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "bankAccounts:withdraw"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/funds-holders": {
      "get": {
        "tags": [
          "funds-holders"
        ],
        "summary": "List Funds Holders",
        "description": "Retrieves a paginated list of funds holders for the organization.\n                    Funds holders represent accounts that can be used to fund distributions,\n                    including the primary organization account and settlement funds.\n                    Optional pagination parameters: pageNumber (default: 1) and pageSize (default: 20, max: 100).\n                    The 'page' parameter is deprecated. Use 'pageNumber' instead.",
        "parameters": [
          {
            "name": "pageNumber",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "maximum": 100,
              "minimum": 1,
              "type": "integer",
              "format": "int32",
              "default": 20
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedCollectionOfFundsHolderResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "fundsHolders:view"
            ]
          }
        ]
      },
      "post": {
        "tags": [
          "funds-holders"
        ],
        "summary": "Create Settlement Fund",
        "description": "Creates a new settlement fund (FBO account) for the organization.\n                The settlement fund inherits business details from the organization's primary account\n                and requires a settlement fund name plus optional supporting documents.\n                Returns both the new FundsHolderId and the BankAccountId of a Pending bank account\n                that will be activated automatically once the FundsHolder becomes Active.",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/CreateSettlementFundRequest"
              }
            }
          }
        },
        "responses": {
          "202": {
            "description": "Accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CreateFundsHolderResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "fundsHolders:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/funds-holders/{id}": {
      "get": {
        "tags": [
          "funds-holders"
        ],
        "summary": "Get Funds Holders",
        "description": "Retrieves a specific funds holder by its unique identifier.\n                    Returns the funds holder details including banking information and current status.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FundsHolderResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "fundsHolders:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/invitations": {
      "get": {
        "tags": [
          "invitations"
        ],
        "summary": "Get invitations",
        "description": "Retrieves a paginated list of pending invitations for the organization.",
        "parameters": [
          {
            "name": "pageNumber",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "maximum": 100,
              "minimum": 1,
              "type": "integer",
              "format": "int32",
              "default": 50
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedCollectionOfInvitationResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "invitations:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/invitations/bulk": {
      "post": {
        "tags": [
          "invitations"
        ],
        "summary": "Create bulk invitations",
        "description": "Creates multiple invitations at once (maximum 5 invitations per request).",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateBulkInvitationsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/InvitationResponse"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "invitations:create"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/invitations/{id}": {
      "delete": {
        "tags": [
          "invitations"
        ],
        "summary": "Delete invitation",
        "description": "Cancels a pending invitation.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "204": {
            "description": "No Content"
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "invitations:delete"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/payout-instructions": {
      "get": {
        "tags": [
          "payout-instructions"
        ],
        "summary": "Get Payout Instructions",
        "description": "Retrieves a paginated list of payout instructions, optionally filtered by distribution id(s), status(es), external id, email, phone number, creation-date range, the upload batch that created them (batchId), or a tag.\n                A payout instruction represents an intention to pay a specific amount of money to a beneficiary and is associated with exactly one distribution.\n                Filters of different kinds combine with AND. Multiple statuses (statuses) or distributions (distributionIds) may be supplied either as repeated query parameters or as a single comma-separated value, and match any of the listed values; each status must be a defined status name (numeric or unknown values are rejected with 400) and each distribution id a valid guid. Supplying both a singular filter and its plural form (status + statuses, or distributionId + distributionIds) is rejected.\n                fromDate and toDate bound the payout instruction's creation date (UTC, inclusive on both ends); fromDate must not be after toDate.\n                The phone number filter matches the beneficiary's number exactly after normalization, so common US formats all match the same record (for example '+15551234567', '15551234567', or '(555) 123-4567'); a number written in full international form (a leading '+' followed by its country code) matches too, but its '+' must be percent-encoded as '%2B' -- an unencoded '+' decodes to a space and is only reliable for US-length numbers.\n                The email filter matches on the beginning of the address rather than the whole of it, so a partial address (for example 'john') matches every address starting with it, and a full address matches that beneficiary plus any address that extends it. Any characters in the term, including '%', '_' and '\\', are matched literally rather than as wildcards.\n                The tag filter matches exactly: tagKey together with tagValue returns the instructions that carry that exact key-value pair, while tagKey alone returns the instructions that carry the key with any value. tagValue without tagKey is rejected with 400. The tag filter combines with all the other filters.\n                Results are returned by creation date, newest first, with the instruction id breaking ties.",
        "operationId": "GetPayoutInstructionsV3",
        "parameters": [
          {
            "name": "distributionId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "status",
            "in": "query",
            "schema": {
              "enum": [
                "Draft",
                "Ready",
                "PushInitiated",
                "Initiated",
                "InitiationFailed",
                "PayoutMethodSelected",
                "Requested",
                "Restored",
                "Reinitiated",
                "ExpiryRequested",
                "Fulfilled",
                "Expired",
                "Cancelled"
              ],
              "type": "string"
            }
          },
          {
            "name": "externalId",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "email",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "pageNumber",
            "in": "query",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "required": true,
            "schema": {
              "maximum": 100,
              "minimum": 1,
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "batchId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "tagKey",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "tagValue",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "statuses",
            "in": "query",
            "schema": {
              "type": "array",
              "items": {
                "enum": [
                  "Draft",
                  "Ready",
                  "PushInitiated",
                  "Initiated",
                  "InitiationFailed",
                  "PayoutMethodSelected",
                  "Requested",
                  "Restored",
                  "Reinitiated",
                  "ExpiryRequested",
                  "Fulfilled",
                  "Expired",
                  "Cancelled"
                ],
                "type": "string"
              }
            }
          },
          {
            "name": "distributionIds",
            "in": "query",
            "schema": {
              "type": "array",
              "items": {
                "type": "string",
                "format": "uuid"
              }
            }
          },
          {
            "name": "phoneNumber",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "fromDate",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date"
            }
          },
          {
            "name": "toDate",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedCollectionOfV3PayoutInstructionResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:view"
            ]
          }
        ]
      },
      "post": {
        "tags": [
          "payout-instructions"
        ],
        "summary": "Create Payout Instruction",
        "description": "Creates a new payout instruction with the specified distribution and recipient details.\n                Note that creating a payout instruction does not automatically send it to the beneficiary or allocate funds; it only records the intention to pay.\n                The payout instruction must be explicitly initiated in a separate step to notify the beneficiary.",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreatePayoutInstructionV3Request"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:create"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/payout-instructions/{id}": {
      "get": {
        "tags": [
          "payout-instructions"
        ],
        "summary": "Get Payout Instruction",
        "description": "Retrieves a single payout instruction based on provided identifier.\n                Creating a payout instruction does not automatically distribute funds to the beneficiary; it requires subsequent initiation.",
        "operationId": "GetPayoutInstructionV3",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/V3PayoutInstructionResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:view"
            ]
          }
        ]
      },
      "patch": {
        "tags": [
          "payout-instructions"
        ],
        "summary": "Update Payout Instruction",
        "description": "Patches an existing payout instruction with the provided data.\nNote: Except for tags, this operation might be performed only for payout instructions that have not been redeemed or requested. Tags can be patched in any status, including after redemption.\nNote2: /amount and /email can be changed only in the Draft, Ready, Restored and Cancelled statuses. An email change does not restore a Cancelled payout instruction. To change the email of a payout that was already sent, cancel it, change the email, then reinitiate it.\nNote3: Tags are replaced as a whole set. Replace /Tags with an empty object to clear them; removing /Tags is not accepted.\nNote4: An /amount increase on a Restored payout adjusts the live allocation, so the distribution's bank account must hold enough unallocated funds to cover the difference; otherwise the request is rejected with 409.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "required": [
                    "op",
                    "path"
                  ],
                  "type": "object",
                  "properties": {
                    "op": {
                      "enum": [
                        "add",
                        "remove",
                        "replace"
                      ],
                      "type": "string",
                      "description": "The operation to perform."
                    },
                    "path": {
                      "enum": [
                        "/Amount",
                        "/FirstName",
                        "/LastName",
                        "/PhoneNumber",
                        "/AddressLine1",
                        "/AddressLine2",
                        "/City",
                        "/StateCode",
                        "/ZipCode",
                        "/Email",
                        "/Tags"
                      ],
                      "type": "string",
                      "description": "JSON Pointer to the field to change."
                    },
                    "value": {
                      "description": "The new value. Required for `add` and `replace`; its type matches the corresponding field on the payout instruction."
                    }
                  },
                  "additionalProperties": false
                },
                "description": "JSON Patch document (RFC 6902) applied to the payout instruction. Only the fields listed under `path` may be changed."
              },
              "example": [
                {
                  "op": "replace",
                  "path": "/Amount",
                  "value": "new value"
                }
              ]
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:update"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/payout-instructions/{id}/activity": {
      "get": {
        "tags": [
          "payout-instructions"
        ],
        "summary": "Get Payout Instruction Activity",
        "description": "Retrieves the complete activity history for a specific payout instruction, including status changes, notifications sent, and actions performed by both administrators and beneficiaries.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/PayoutInstructionActivityResponse"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/payout-instructions/{id}/payout": {
      "get": {
        "tags": [
          "payout-instructions"
        ],
        "summary": "Get Payout Instruction Payout",
        "description": "Retrieves the payout details for a specific payout instruction.\n                A payout is created when a beneficiary acts on a payout instruction and selects a specific payout method to receive their funds.\n                The payout contains additional details specific to the chosen method, such as gift card identifiers or transaction references.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PayoutInstructionPayoutResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/payout-instructions/{id}/:initiate": {
      "post": {
        "tags": [
          "payout-instructions"
        ],
        "summary": "Initiate Payout Instruction",
        "description": "Initiates the payout process for a specific payout instruction using the specified notification channel.\n                This action allocates funds from the associated distribution to this payout instruction and sends the initial notification to the beneficiary, allowing them to claim their funds.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/InitiatePayoutInstructionRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:initiate"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/payout-instructions/{id}/:reinitiate": {
      "post": {
        "tags": [
          "payout-instructions"
        ],
        "summary": "Reinitiate Payout Instruction",
        "description": "Reinitiates a payout instruction by publishing a command to send the payout notification again through the specified communication channel. The payout instruction must be in a state that allows reinitiation. When the payout is in the Cancelled status a new allocation is created for the current amount, so the distribution's bank account must hold enough unallocated funds to cover it; otherwise the request is rejected with 409.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReinitiatePayoutInstructionRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:reinitiate"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/payout-instructions/{id}/:cancel": {
      "post": {
        "tags": [
          "payout-instructions"
        ],
        "summary": "Cancel Payout Instruction",
        "description": "Cancels a specific payout instruction with the provided cancellation reason.\n                This halts the payout process and prevents the beneficiary from claiming the funds.\n                If funds were already allocated, they will be returned to the distribution budget.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CancelPayoutInstructionRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:cancel"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/payout-instructions/{id}/:try-restore": {
      "post": {
        "tags": [
          "payout-instructions"
        ],
        "summary": "Try Restore Payout Instruction",
        "description": "Attempts to restore a payout instruction when a payment was requested but not successfully processed (e.g., a PayPal transfer that the beneficiary hasn't accepted, or a check transfer that has not been sent to the vendor yet).\n                This action attempts to cancel the pending external payout and return the beneficiary to a state where they can select a different payout method and process their payout again.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:tryRestore"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/payout-instructions/{id}/:send-reminder": {
      "post": {
        "tags": [
          "payout-instructions"
        ],
        "summary": "Send Payout Instruction Reminder",
        "description": "Sends a reminder notification to the beneficiary about their pending payout instruction.\n                This can be used when a beneficiary has not claimed their funds after the initial notification was sent.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SendPayoutInstructionReminderRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:sendReminder"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/payout-instructions/{id}/:send-notification": {
      "post": {
        "tags": [
          "payout-instructions"
        ],
        "summary": "Send Payout Instruction Notification",
        "description": "Emails the beneficiary the payout instruction's initiate email with a claim link: the distribution's initiate email, the same one sent when a payout instruction is initiated by email. Earlier claim links, emailed or exported, stay valid.\n                The payout instruction must be in one of these statuses: Initiated, Reinitiated, Restored, PayoutMethodSelected, Requested, PushInitiated, Fulfilled or ExpiryRequested. A direct payout, or a beneficiary who has unsubscribed from emails, is rejected with 400.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:sendReminder"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/payout-instructions/{id}/:export-claim-link": {
      "post": {
        "tags": [
          "payout-instructions"
        ],
        "summary": "Export Payout Instruction Claim Link",
        "description": "Returns the claim link for a payout instruction, so that you can deliver the link to the beneficiary through your own channel.\n                The link logs the beneficiary in to the redeem portal. Treat it as a credential.\n                When the beneficiary opens the link, Talli sends a one-time code to the beneficiary's email address.\n                The payout instruction must be in one of these statuses: Initiated, Reinitiated, Restored, PayoutMethodSelected, Requested, PushInitiated, Fulfilled or ExpiryRequested. A direct payout has no claim link. To export the link of a Ready payout instruction, initiate it first with :initiate and channel none, then wait until its status is Initiated.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ExportClaimLinkResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:exportClaimLink"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/payout-methods": {
      "get": {
        "tags": [
          "payout-methods"
        ],
        "summary": "Get Payout Methods",
        "description": "Retrieves payout methods available to the caller for distributing funds to beneficiaries.\n                    Pass 'distributionId' to scope availability to an existing distribution's bank; omit it to scope to the\n                    default bank.",
        "parameters": [
          {
            "name": "distributionId",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/PayoutMethodResponse"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutMethods:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/payout-methods/{id}": {
      "get": {
        "tags": [
          "payout-methods"
        ],
        "summary": "Get Payout Method",
        "description": "Retrieves a specific payout method by its unique identifier.\n                    This endpoint provides detailed information about a single payout method,\n                    including its name, category, requirements, and transaction limits.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PayoutMethodResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutMethods:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/reports/distributions/{distributionId}/payout-methods": {
      "get": {
        "tags": [
          "reports"
        ],
        "summary": "Get Distribution Payout Methods Report",
        "description": "Retrieves a report detailing the distribution of payout methods selected by beneficiaries for a specific distribution.",
        "parameters": [
          {
            "name": "distributionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DistributionsPayoutMethodsReportResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "reports:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/reports/distributions/{distributionId}/conversion": {
      "get": {
        "tags": [
          "reports"
        ],
        "summary": "Get Distribution Conversion Report",
        "description": "Retrieves a report analyzing conversion metrics for a specific distribution, including notification delivery and payout claim rates.",
        "parameters": [
          {
            "name": "distributionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DistributionsConversionReportResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "reports:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/reports/distributions/{distributionId}/statistics": {
      "get": {
        "tags": [
          "reports"
        ],
        "summary": "Get Distribution Statistics Report",
        "description": "Retrieves comprehensive statistics for a specific distribution, including overall performance metrics, budget utilization, and timeline analysis.",
        "parameters": [
          {
            "name": "distributionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DistributionStatisticsReportResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "reports:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/reports/distributions/{distributionId}/payouts-history": {
      "get": {
        "tags": [
          "reports"
        ],
        "summary": "Get Distribution Payouts History Report",
        "description": "Retrieves a historical record of all payouts processed for a specific distribution, including timestamps, amounts, and status changes.",
        "parameters": [
          {
            "name": "distributionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DistributionsPayoutsHistoryReportResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "reports:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/reports/distributions/{distributionId}/basic": {
      "get": {
        "tags": [
          "reports"
        ],
        "summary": "Get Distribution Basic Report",
        "description": "Retrieves a basic CSV report for a specific distribution with sorting and pagination options. The report contains fundamental information about payout instructions and their current status. After the fixed columns the report carries one column per distinct tag key in the distribution, in alphabetical order; a cell is empty when the payout instruction does not carry that tag. Every page of one distribution carries the same tag columns. Rows are ordered by the requested sort column, or by creation date descending when none is given; the payout instruction id breaks ties either way.",
        "parameters": [
          {
            "name": "distributionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "pageNumber",
            "in": "query",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "sortBy",
            "in": "query",
            "schema": {
              "$ref": "#/components/schemas/BasicDistributionReportSortableColumn"
            }
          },
          {
            "name": "sortDirection",
            "in": "query",
            "schema": {
              "$ref": "#/components/schemas/SortDirection"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/csv": {
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "reports:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/reports/tax/export": {
      "post": {
        "tags": [
          "reports"
        ],
        "summary": "Export Tax Data",
        "description": "Exports certified W-9 tax data for the requested scope as a password-protected, AES-encrypted ZIP containing a CSV. The only endpoint that egresses TINs; every call is written to the durable tax data access log.",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TaxExportRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/zip": {
                "schema": {
                  "type": "string",
                  "format": "byte"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "tax:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/roles": {
      "get": {
        "tags": [
          "roles"
        ],
        "summary": "Get Roles",
        "description": "Retrieves a list of available roles with their associated permissions.\n                    Each role includes its name and a list of permissions that the role grants.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/RoleResponse"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "roles:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/subclients": {
      "get": {
        "tags": [
          "subclients"
        ],
        "summary": "Get sub-clients",
        "description": "Retrieves the sub-clients in the current organization, with member counts.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/SubClientSummaryResponse"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "sub-clients:manage"
            ]
          }
        ]
      },
      "post": {
        "tags": [
          "subclients"
        ],
        "summary": "Create sub-client",
        "description": "Creates a new sub-client in the current organization.",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateSubClientRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SubClientSummaryResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "sub-clients:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/subclients/{id}": {
      "patch": {
        "tags": [
          "subclients"
        ],
        "summary": "Update sub-client.",
        "description": "Renames an existing sub-client.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateSubClientRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SubClientSummaryResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "sub-clients:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/tag-keys": {
      "get": {
        "tags": [
          "tag-keys"
        ],
        "summary": "Get Tag Keys",
        "description": "Retrieves the distinct tag keys across all the payout instructions visible to the caller.\n                The keys are sorted alphabetically without regard to case. Returns an empty array when no visible payout instruction carries a tag.",
        "operationId": "GetTagKeysV3",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "payoutInstructions:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/templates/template-type-schemas": {
      "get": {
        "tags": [
          "templates"
        ],
        "summary": "Get template types",
        "description": "Retrieves a list of template types.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/TemplateTypeSchemaResponse"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "templates:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/templates/{id}": {
      "get": {
        "tags": [
          "templates"
        ],
        "summary": "Get template",
        "description": "Retrieves a single template based on provided identifier.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TemplateResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "templates:view"
            ]
          }
        ]
      },
      "put": {
        "tags": [
          "templates"
        ],
        "summary": "Update template",
        "description": "Updates an existing template with the provided template.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateTemplateRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "templates:edit"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/templates": {
      "get": {
        "tags": [
          "templates"
        ],
        "summary": "Get templates",
        "description": "Retrieves a paginated list of templates, optionally filtered by template type.",
        "parameters": [
          {
            "name": "pageNumber",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "maximum": 100,
              "minimum": 1,
              "type": "integer",
              "format": "int32",
              "default": 20
            }
          },
          {
            "name": "templateType",
            "in": "query",
            "schema": {
              "$ref": "#/components/schemas/TemplateType"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedCollectionOfTemplateResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "templates:view"
            ]
          }
        ]
      },
      "post": {
        "tags": [
          "templates"
        ],
        "summary": "Create template",
        "description": "Creates a new template with the specified details.",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateTemplateRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "templates:create"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/templates/:send-preview": {
      "post": {
        "tags": [
          "templates"
        ],
        "summary": "Send notification preview",
        "description": "Sends a notification preview to the specified recipient using the provided template model. Dynamic fields keyed `tag:Key` supply sample values for the `{{tag:Key}}` placeholders; a placeholder with no matching key renders as its own name.",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SendNotificationPreviewRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "description": "Accepted"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "templates:sendPreview"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/users": {
      "get": {
        "tags": [
          "users"
        ],
        "summary": "Get Users",
        "description": "Retrieves a paginated list of users in the current organization.\n                    Optional pagination parameters: pageNumber (default: 1) and pageSize (default: 50, max: 100).",
        "parameters": [
          {
            "name": "pageNumber",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "maximum": 100,
              "minimum": 1,
              "type": "integer",
              "format": "int32",
              "default": 50
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PagedCollectionOfUserResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "users:view"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/users/{id}": {
      "get": {
        "tags": [
          "users"
        ],
        "summary": "Get User",
        "description": "Retrieves a single user by ID with assigned role.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "users:view"
            ]
          }
        ]
      },
      "delete": {
        "tags": [
          "users"
        ],
        "summary": "Delete user",
        "description": "Deletes a user from the organization.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "204": {
            "description": "No Content"
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "users:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/users/{id}/role": {
      "put": {
        "tags": [
          "users"
        ],
        "summary": "Change user's role",
        "description": "Change user's role. A user may only be assigned to one role.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ChangeUserRoleRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "users:manage"
            ]
          }
        ]
      }
    },
    "/v3/distribution-manager/users/{id}/subclient": {
      "patch": {
        "tags": [
          "users"
        ],
        "summary": "Assign or detach a user's sub-client",
        "description": "Assigns the user to a sub-client (forcing the sub-client-viewer role), or detaches them when subClientId is omitted/null.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateUserSubClientRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/HttpValidationProblemDetails"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        },
        "security": [
          {
            "oauth2": [
              "sub-clients:manage"
            ]
          }
        ]
      }
    }
  },
  "components": {
    "schemas": {
      "AutomaticReminders": {
        "enum": [
          "None",
          "FixedIntervals"
        ],
        "type": "string"
      },
      "BankAccountAddressResponse": {
        "type": "object",
        "properties": {
          "address1": {
            "type": "string",
            "description": "Primary street address line"
          },
          "address2": {
            "type": "string",
            "description": "Secondary address information such as unit or apartment number",
            "nullable": true
          },
          "city": {
            "type": "string",
            "description": "City"
          },
          "state": {
            "type": "string",
            "description": "State code"
          },
          "postalCode": {
            "type": "string",
            "description": "Postal code"
          },
          "country": {
            "type": "string",
            "description": "Country code"
          }
        },
        "additionalProperties": false
      },
      "BankAccountOwnerType": {
        "enum": [
          "Individual",
          "Business"
        ],
        "type": "string"
      },
      "BankAccountOwnershipType": {
        "enum": [
          "Own",
          "ThirdParty"
        ],
        "type": "string"
      },
      "BankAccountResponse": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The unique identifier for the bank account.",
            "format": "uuid"
          },
          "fundsHolderId": {
            "type": "string",
            "description": "The unique identifier for the funds holder that owns the bank account.",
            "format": "uuid"
          },
          "balance": {
            "type": "number",
            "description": "Total balance in the bank account.",
            "format": "double"
          },
          "availableBalance": {
            "type": "number",
            "description": "Available balance in the bank account.",
            "format": "double"
          },
          "allocatedBalance": {
            "type": "number",
            "description": "Allocated balance in the bank account.",
            "format": "double",
            "nullable": true
          },
          "unallocatedBalance": {
            "type": "number",
            "description": "Unallocated balance in the bank account.",
            "format": "double",
            "nullable": true
          },
          "routingNumber": {
            "type": "string",
            "description": "The routing number for the bank account."
          },
          "accountNumber": {
            "type": "string",
            "description": "The account number for the bank account."
          },
          "accountName": {
            "type": "string",
            "description": "The display name of the bank account."
          },
          "address": {
            "$ref": "#/components/schemas/BankAccountAddressResponse"
          },
          "accountHolderName": {
            "type": "string",
            "description": "The legal name of the account holder. Use it as the beneficiary name when you send a wire."
          },
          "bankName": {
            "type": "string",
            "description": "The name of the bank that holds the account."
          },
          "bankAddress": {
            "$ref": "#/components/schemas/BankAccountAddressResponse"
          },
          "acceptsWires": {
            "type": "boolean",
            "description": "True when the bank accepts incoming domestic wires to this account. When false, fund the account by ACH only."
          },
          "creationDate": {
            "type": "string",
            "description": "The date when the bank account was created.",
            "format": "date"
          },
          "accountType": {
            "$ref": "#/components/schemas/BankAccountOwnershipType"
          },
          "status": {
            "$ref": "#/components/schemas/BankAccountStatus"
          },
          "acceptsNewDistributions": {
            "type": "boolean",
            "description": "True when this bank account is on the organization's default bank partner AND is Active. Consumers should use this flag when deciding whether an account is eligible for new distribution creation."
          }
        },
        "additionalProperties": false
      },
      "BankAccountStatus": {
        "enum": [
          "Pending",
          "Active"
        ],
        "type": "string"
      },
      "BankAccountTransactionStatus": {
        "enum": [
          "Pending",
          "Settled",
          "Declined",
          "Returned"
        ],
        "type": "string"
      },
      "BankAccountTransactionType": {
        "enum": [
          "ExternalTransfer",
          "InternalTransfer"
        ],
        "type": "string"
      },
      "BankAccountWithdrawalAccountResponse": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "businessName": {
            "type": "string"
          },
          "accountType": {
            "$ref": "#/components/schemas/CommonAccountType"
          },
          "routingNumber": {
            "type": "string"
          },
          "accountNumber": {
            "type": "string"
          },
          "addressLine1": {
            "type": "string"
          },
          "addressLine2": {
            "type": "string",
            "nullable": true
          },
          "city": {
            "type": "string"
          },
          "state": {
            "$ref": "#/components/schemas/StateCode"
          },
          "zipCode": {
            "type": "string"
          },
          "status": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "BankAccountWithdrawalAccountsResponse": {
        "type": "object",
        "properties": {
          "withdrawalAccounts": {
            "$ref": "#/components/schemas/PagedCollectionOfBankAccountWithdrawalAccountResponse"
          }
        },
        "additionalProperties": false
      },
      "BasicDistributionReportSortableColumn": {
        "enum": [
          "PayoutInstructionId",
          "PayoutInstructionStatus",
          "CreatedOn",
          "UpdatedOn",
          "BeneficiaryFirstName",
          "BeneficiaryLastName",
          "PayoutInstructionAmount",
          "BeneficiaryEmail",
          "BeneficiaryPhoneNumber",
          "SelectedPayoutMethod",
          "SelectedPayoutMethodCategory"
        ],
        "type": "string"
      },
      "BrandAssetUploadResponse": {
        "type": "object",
        "properties": {
          "url": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "BrandColors": {
        "type": "object",
        "properties": {
          "primaryColor": {
            "type": "string",
            "nullable": true
          },
          "secondaryColor": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "BrandConfigResponse": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "organizationId": {
            "type": "string"
          },
          "slug": {
            "type": "string",
            "nullable": true
          },
          "customBeneficiaryDomain": {
            "type": "string",
            "nullable": true
          },
          "customConsoleDomain": {
            "type": "string",
            "nullable": true
          },
          "branding": {
            "$ref": "#/components/schemas/BrandingResponse"
          },
          "companyDetails": {
            "$ref": "#/components/schemas/CompanyDetailsResponse"
          },
          "fromEmail": {
            "type": "string",
            "nullable": true
          },
          "fromEmailActive": {
            "type": "boolean"
          }
        },
        "additionalProperties": false
      },
      "BrandingResponse": {
        "type": "object",
        "properties": {
          "schemaVersion": {
            "type": "integer",
            "format": "int32"
          },
          "logoUrl": {
            "type": "string",
            "nullable": true
          },
          "faviconUrl": {
            "type": "string",
            "nullable": true
          },
          "primaryColor": {
            "type": "string",
            "nullable": true
          },
          "secondaryColor": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "BulkInitiatePayoutInstructionsRequest": {
        "type": "object",
        "properties": {
          "payoutInstructionIds": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "uuid"
            },
            "description": "Optional. When set, exactly these payout instructions are initiated — no more, no fewer. Every id must belong to this distribution and be in the Ready status; if any id is unknown, belongs to another distribution, or is not Ready, the whole request is rejected with 409 and none are initiated. Cannot be combined with uploadBatchId or count.",
            "nullable": true
          },
          "uploadBatchId": {
            "type": "string",
            "description": "Optional. When set, only payout instructions created or updated by this upload batch (the batchId returned by the upload endpoint) are selected. The batch must belong to this distribution and have finished processing: an unknown batch is rejected with 404, a still-processing batch with 409 (poll the upload-status endpoint until complete). When omitted, all Ready payout instructions of the distribution are eligible.",
            "format": "uuid",
            "nullable": true
          },
          "count": {
            "type": "integer",
            "description": "Optional cap on how many payout instructions to initiate, oldest first. When omitted, all Ready payout instructions in scope are selected, up to the batch maximum; if more are Ready than the maximum, the request is rejected. The response reports how many were actually accepted.",
            "format": "int32",
            "nullable": true
          },
          "dryRun": {
            "type": "boolean",
            "description": "When true, runs all validations (instruction selection, available funds, email send limit) and returns the would-be batch summary without initiating anything. Rejections are reported exactly as for a real run."
          }
        },
        "additionalProperties": false
      },
      "BulkInitiatePayoutInstructionsResponse": {
        "required": [
          "acceptedCount",
          "dryRun",
          "totalAmount"
        ],
        "type": "object",
        "properties": {
          "dryRun": {
            "type": "boolean",
            "description": "True when the request was a dry run: all validations were performed and the summary returned, but nothing was initiated."
          },
          "batchId": {
            "type": "string",
            "description": "The identifier of this initiation batch. All emails produced by the batch are tagged with it. Null for dry runs.",
            "format": "uuid",
            "nullable": true
          },
          "acceptedCount": {
            "type": "integer",
            "description": "The number of payout instructions accepted for initiation (or that would be accepted, for a dry run).",
            "format": "int32"
          },
          "totalAmount": {
            "type": "number",
            "description": "The total monetary amount of the accepted payout instructions.",
            "format": "double"
          }
        },
        "additionalProperties": false
      },
      "BulkSendRemindersRequest": {
        "required": [
          "count"
        ],
        "type": "object",
        "properties": {
          "count": {
            "type": "integer",
            "description": "The maximum number of reminders to send. The endpoint selects up to this many eligible payout instructions of the distribution (those awaiting action that have not been reminded recently), oldest reminder first. The response reports how many reminders were actually accepted.",
            "format": "int32"
          },
          "dryRun": {
            "type": "boolean",
            "description": "When true, runs all validations (recipient selection, email send limit) and returns the would-be batch summary without sending anything. Rejections are reported exactly as for a real run."
          }
        },
        "additionalProperties": false
      },
      "BulkSendRemindersResponse": {
        "required": [
          "acceptedCount",
          "dryRun"
        ],
        "type": "object",
        "properties": {
          "dryRun": {
            "type": "boolean",
            "description": "True when the request was a dry run: all validations were performed and the summary returned, but no reminders were sent."
          },
          "batchId": {
            "type": "string",
            "description": "The identifier of this reminder batch. All emails produced by the batch are tagged with it. Null for dry runs.",
            "format": "uuid",
            "nullable": true
          },
          "acceptedCount": {
            "type": "integer",
            "description": "The number of reminders accepted for sending (or that would be accepted, for a dry run).",
            "format": "int32"
          }
        },
        "additionalProperties": false
      },
      "CancelPayoutInstructionRequest": {
        "type": "object",
        "properties": {
          "cancellationReason": {
            "type": "string",
            "description": "Reason for Payout Instruction Cancelation, valid values are: `BeneficiaryRequest`, `DistributionManagerRequest`, 'EmailHardBounce', 'EmailSpamComplaint', 'UnsubscribedFromEmails', 'EmailScreeningFailed'"
          }
        },
        "additionalProperties": false
      },
      "CancellationReason": {
        "enum": [
          "Unknown",
          "BeneficiaryRequest",
          "CampaignManagerRequest",
          "DistributionManagerRequest",
          "EmailHardBounce",
          "EmailSpamComplaint",
          "UnsubscribedFromEmails",
          "EmailScreeningFailed",
          "CheckRequest",
          "DirectAchFailed",
          "DirectAchRequestRejected"
        ],
        "type": "string"
      },
      "ChangeUserRoleRequest": {
        "type": "object",
        "properties": {
          "roleId": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "CommonAccountType": {
        "enum": [
          "Checking",
          "Savings"
        ],
        "type": "string"
      },
      "CompanyAddress": {
        "type": "object",
        "properties": {
          "addressLine1": {
            "type": "string"
          },
          "addressLine2": {
            "type": "string",
            "nullable": true
          },
          "city": {
            "type": "string"
          },
          "state": {
            "$ref": "#/components/schemas/StateCode"
          },
          "zipCode": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "CompanyDetailsResponse": {
        "type": "object",
        "properties": {
          "displayName": {
            "type": "string",
            "nullable": true
          },
          "companyName": {
            "type": "string",
            "nullable": true
          },
          "companyAddress": {
            "$ref": "#/components/schemas/CompanyAddress"
          },
          "supportEmail": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "ContentFieldDefinitionResponse": {
        "type": "object",
        "properties": {
          "description": {
            "type": "string",
            "description": "Description of the content field."
          },
          "defaultValue": {
            "type": "string",
            "description": "Default value of the content field."
          }
        },
        "additionalProperties": false
      },
      "ConversionStageMetrics": {
        "type": "object",
        "properties": {
          "count": {
            "type": "integer",
            "description": "Number of payout instructions in this stage",
            "format": "int32"
          },
          "amount": {
            "type": "number",
            "description": "Total monetary amount of payout instructions in this stage",
            "format": "double"
          },
          "percentage": {
            "type": "number",
            "description": "Percentage of eligible payout instructions that are in this stage",
            "format": "double"
          },
          "statuses": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PayoutInstructionStatus"
            },
            "description": "List of payout instruction statuses that are included in this stage"
          }
        },
        "additionalProperties": false
      },
      "ConversionStages": {
        "type": "object",
        "properties": {
          "eligible": {
            "$ref": "#/components/schemas/ConversionStageMetrics"
          },
          "communicated": {
            "$ref": "#/components/schemas/ConversionStageMetrics"
          },
          "actioned": {
            "$ref": "#/components/schemas/ConversionStageMetrics"
          },
          "completed": {
            "$ref": "#/components/schemas/ConversionStageMetrics"
          },
          "excluded": {
            "$ref": "#/components/schemas/ConversionStageMetrics"
          }
        },
        "additionalProperties": false
      },
      "CreateBankAccountV3Request": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "CreateBulkInvitationsRequest": {
        "type": "object",
        "properties": {
          "invitations": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CreateInvitationRequest"
            }
          }
        },
        "additionalProperties": false
      },
      "CreateCredentialRequest": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "scopesPreset": {
            "$ref": "#/components/schemas/CredentialScopesPreset"
          }
        },
        "additionalProperties": false
      },
      "CreateDistributionRequest": {
        "required": [
          "externalId",
          "iconFile",
          "name",
          "welcomeHeadline",
          "welcomeText"
        ],
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "externalId": {
            "type": "string"
          },
          "welcomeHeadline": {
            "type": "string"
          },
          "distributionDescription": {
            "type": "string",
            "nullable": true
          },
          "distributionManager": {
            "type": "string",
            "nullable": true
          },
          "welcomeText": {
            "type": "string"
          },
          "iconFile": {
            "type": "string",
            "format": "binary"
          },
          "payoutMethodIds": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "uuid"
            }
          },
          "expiryDate": {
            "type": "string",
            "format": "date",
            "nullable": true
          },
          "displayEndDate": {
            "type": "string",
            "format": "date",
            "nullable": true
          },
          "emailTemplates": {
            "type": "object",
            "additionalProperties": {
              "type": "string",
              "format": "uuid"
            }
          },
          "bankAccountId": {
            "type": "string",
            "format": "uuid"
          },
          "automaticReminders": {
            "$ref": "#/components/schemas/AutomaticReminders"
          },
          "subClientId": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          },
          "taxCollectionMode": {
            "$ref": "#/components/schemas/TaxCollectionMode"
          }
        },
        "additionalProperties": false
      },
      "CreateFundingRequestRequest": {
        "type": "object",
        "properties": {
          "amount": {
            "type": "number",
            "format": "double"
          },
          "sentToUserId": {
            "type": "string",
            "format": "uuid"
          },
          "note": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "CreateFundsHolderResponse": {
        "required": [
          "bankAccountId",
          "fundsHolderId"
        ],
        "type": "object",
        "properties": {
          "fundsHolderId": {
            "type": "string",
            "format": "uuid"
          },
          "bankAccountId": {
            "type": "string",
            "format": "uuid"
          }
        },
        "additionalProperties": false
      },
      "CreateInvitationRequest": {
        "type": "object",
        "properties": {
          "inviteeEmail": {
            "type": "string"
          },
          "role": {
            "$ref": "#/components/schemas/UserRole"
          },
          "subClientId": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "CreatePayoutInstructionV3Request": {
        "required": [
          "externalId"
        ],
        "type": "object",
        "properties": {
          "distributionId": {
            "type": "string",
            "description": "The unique identifier of the distribution this payout instruction belongs to.",
            "format": "uuid"
          },
          "externalId": {
            "type": "string",
            "description": "An external identifier for this payout instruction, used for integration with client systems."
          },
          "firstName": {
            "type": "string",
            "description": "The first name of the beneficiary.",
            "nullable": true
          },
          "lastName": {
            "type": "string",
            "description": "The last name of the beneficiary.",
            "nullable": true
          },
          "amount": {
            "type": "number",
            "description": "The monetary amount of the payout instruction.",
            "format": "double",
            "nullable": true
          },
          "email": {
            "type": "string",
            "description": "The email address of the beneficiary. This is the primary contact method.",
            "nullable": true
          },
          "phoneNumber": {
            "type": "string",
            "description": "The phone number of the beneficiary. May be required for certain payout methods.",
            "nullable": true
          },
          "tags": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "Free-form key/value labels for this payout instruction, for example {\"TeamId\": \"Alpha\"}. At most 20 tags; keys are limited to 64 characters, values to 128. Keys cannot repeat, and two keys that differ only by case are two different tags. A key cannot contain a comma, a double quote, an ampersand, or any of < > { }, and cannot be one of the upload file columns (Id, Amount, FirstName, LastName, Email, PhoneNumber). Values cannot contain < > { }.",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "CreateSettlementFundRequest": {
        "type": "object",
        "properties": {
          "settlementFundName": {
            "type": "string"
          },
          "attachments": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "binary"
            }
          }
        },
        "additionalProperties": false
      },
      "CreateSubClientRequest": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "CreateTemplateRequest": {
        "type": "object",
        "properties": {
          "templateType": {
            "$ref": "#/components/schemas/TemplateType"
          },
          "name": {
            "type": "string",
            "description": "The name of the template."
          },
          "isActive": {
            "type": "boolean",
            "description": "Indicates whether a template is active or not. If this is disabled, this template will not be used.",
            "nullable": true
          },
          "contentFields": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "The dictionary is used to store context fields. The template consists of content fields.",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "CreateWithdrawalAccountForFundsHolderRequest": {
        "required": [
          "accountNumber",
          "accountType",
          "addressLine1",
          "businessName",
          "city",
          "routingNumber",
          "state",
          "zipCode"
        ],
        "type": "object",
        "properties": {
          "businessName": {
            "type": "string"
          },
          "routingNumber": {
            "type": "string"
          },
          "accountNumber": {
            "type": "string"
          },
          "accountType": {
            "$ref": "#/components/schemas/CommonAccountType"
          },
          "addressLine1": {
            "type": "string"
          },
          "addressLine2": {
            "type": "string",
            "nullable": true
          },
          "city": {
            "type": "string"
          },
          "state": {
            "$ref": "#/components/schemas/StateCode"
          },
          "zipCode": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "CreateWithdrawalAccountResponse": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          }
        },
        "additionalProperties": false
      },
      "CreatedCredentialResponse": {
        "type": "object",
        "properties": {
          "clientId": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "scopesPreset": {
            "$ref": "#/components/schemas/CredentialScopesPreset"
          },
          "scopes": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "createdOn": {
            "type": "string",
            "format": "date-time"
          },
          "updatedOn": {
            "type": "string",
            "format": "date-time"
          },
          "secretRotatedOn": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "clientSecret": {
            "type": "string"
          },
          "tokenUrl": {
            "type": "string"
          },
          "audience": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "CredentialResponse": {
        "type": "object",
        "properties": {
          "clientId": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "scopesPreset": {
            "$ref": "#/components/schemas/CredentialScopesPreset"
          },
          "scopes": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "createdOn": {
            "type": "string",
            "format": "date-time"
          },
          "updatedOn": {
            "type": "string",
            "format": "date-time"
          },
          "secretRotatedOn": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "CredentialScopesPreset": {
        "enum": [
          "FullAccess",
          "ReadOnly"
        ],
        "type": "string"
      },
      "DailyActivity": {
        "required": [
          "initiations",
          "redemptions"
        ],
        "type": "object",
        "properties": {
          "date": {
            "type": "string",
            "description": "Calendar date of the activity",
            "format": "date"
          },
          "initiations": {
            "$ref": "#/components/schemas/PayoutActivityMetrics"
          },
          "redemptions": {
            "$ref": "#/components/schemas/PayoutActivityMetrics"
          }
        },
        "additionalProperties": false
      },
      "DeclineFundingRequestRequest": {
        "type": "object",
        "properties": {
          "reason": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "DetailsResponse": {
        "type": "object",
        "properties": {
          "totalFundsReceived": {
            "type": "number",
            "description": "Total funds that landed in the account",
            "format": "double",
            "nullable": true
          },
          "stats": {
            "$ref": "#/components/schemas/ConversionStages"
          }
        },
        "additionalProperties": false
      },
      "DirectACHTransferRequest": {
        "required": [
          "accountNumber",
          "addressLine1",
          "city",
          "email",
          "externalId",
          "firstName",
          "lastName",
          "phoneNumber",
          "routingNumber",
          "zipCode"
        ],
        "type": "object",
        "properties": {
          "externalId": {
            "type": "string",
            "description": "An external identifier for this payout instruction, used for integration with client systems."
          },
          "amount": {
            "type": "number",
            "description": "The monetary amount of the payout. Required and must be positive with at most two decimal places.",
            "format": "double"
          },
          "firstName": {
            "type": "string",
            "description": "The beneficiary's first name."
          },
          "lastName": {
            "type": "string",
            "description": "The beneficiary's last name."
          },
          "email": {
            "type": "string",
            "description": "The beneficiary's email address (recorded only; no notification is sent for a direct payout)."
          },
          "phoneNumber": {
            "type": "string",
            "description": "The beneficiary's phone number in E.164 format."
          },
          "dateOfBirth": {
            "type": "string",
            "description": "The beneficiary's date of birth. Required for an individual bank account; ignored for a business account.",
            "format": "date",
            "nullable": true
          },
          "addressLine1": {
            "type": "string",
            "description": "The beneficiary's street address line 1."
          },
          "addressLine2": {
            "type": "string",
            "description": "The beneficiary's street address line 2.",
            "nullable": true
          },
          "city": {
            "type": "string",
            "description": "The beneficiary's city."
          },
          "stateCode": {
            "$ref": "#/components/schemas/StateCode"
          },
          "zipCode": {
            "type": "string",
            "description": "The beneficiary's ZIP code (12345 or 12345-6789)."
          },
          "routingNumber": {
            "type": "string",
            "description": "The destination bank routing number (9 digits)."
          },
          "accountNumber": {
            "type": "string",
            "description": "The destination bank account number (1-17 digits)."
          },
          "accountType": {
            "$ref": "#/components/schemas/CommonAccountType"
          },
          "accountOwnerType": {
            "$ref": "#/components/schemas/BankAccountOwnerType"
          },
          "businessName": {
            "type": "string",
            "description": "The business name. Required for a business account; must be omitted for an individual account.",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "DistributionMetrics": {
        "type": "object",
        "properties": {
          "totalFundsReceived": {
            "type": "number",
            "description": "Total funds that landed in the distribution FBO account",
            "format": "double"
          },
          "totalPayoutsSentAmount": {
            "type": "number",
            "description": "Total amount of payouts that are either redeemed or in progress (where money is allocated)",
            "format": "double"
          },
          "totalPayoutsSentCount": {
            "type": "integer",
            "description": "Total count of payouts that have been sent",
            "format": "int32"
          },
          "totalPayoutsSentPercentage": {
            "type": "integer",
            "description": "Percentage of total funds that have been sent as payouts",
            "format": "int32"
          },
          "unredeemedFundsAmount": {
            "type": "number",
            "description": "Total amount of payouts sent but not yet redeemed by beneficiaries",
            "format": "double"
          },
          "unredeemedFundsPercentage": {
            "type": "integer",
            "description": "Percentage of total funds that have been sent but not yet redeemed",
            "format": "int32"
          },
          "availableToDisburse": {
            "type": "number",
            "description": "Balance available to send more payouts (unallocated balance)",
            "format": "double"
          },
          "availableToDisbursePercentage": {
            "type": "integer",
            "description": "Percentage of total funds that are still available to disburse",
            "format": "int32"
          },
          "numberOfBeneficiaries": {
            "type": "integer",
            "description": "Total number of beneficiaries in the distribution",
            "format": "int32"
          }
        },
        "additionalProperties": false
      },
      "DistributionPayoutMethodResponse": {
        "type": "object",
        "properties": {
          "payoutMethodId": {
            "type": "string",
            "description": "The unique identifier of the payout method.",
            "format": "uuid"
          },
          "isDisabled": {
            "type": "boolean",
            "description": "Indicates whether this payout method is disabled for the distribution."
          },
          "disableReason": {
            "$ref": "#/components/schemas/PayoutMethodDisableReason"
          }
        },
        "additionalProperties": false
      },
      "DistributionResponse": {
        "required": [
          "emailTemplates",
          "externalId",
          "name",
          "payoutMethods"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The unique identifier for the distribution.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "The name of the distribution."
          },
          "externalId": {
            "type": "string",
            "description": "An external identifier to match Talli distributions with entities in your system"
          },
          "welcomeHeadline": {
            "type": "string",
            "description": "The welcome headline text that will be displayed in the application welcome screen.",
            "nullable": true
          },
          "distributionDescription": {
            "type": "string",
            "description": "The distribution description of the distribution.",
            "nullable": true
          },
          "distributionManager": {
            "type": "string",
            "description": "The name of the distribution manager.",
            "nullable": true
          },
          "welcomeText": {
            "type": "string",
            "description": "The welcome text that will be displayed in the application welcome screen.",
            "nullable": true
          },
          "iconUrl": {
            "type": "string",
            "description": "URL to the distribution's icon image that will be displayed in the application welcome screen.",
            "nullable": true
          },
          "payoutMethods": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/DistributionPayoutMethodResponse"
            },
            "description": "Available payout methods for this distribution."
          },
          "expiryDate": {
            "type": "string",
            "description": "The date when the distribution expires.",
            "format": "date",
            "nullable": true
          },
          "displayEndDate": {
            "type": "string",
            "description": "The date informing beneficiaries when is the end of the distribution.",
            "format": "date",
            "nullable": true
          },
          "creationDate": {
            "type": "string",
            "description": "The date when the distribution was created.",
            "format": "date"
          },
          "emailTemplates": {
            "type": "object",
            "properties": {
              "InitiateEmail": {
                "type": "string",
                "format": "uuid"
              },
              "ReminderEmail": {
                "type": "string",
                "format": "uuid"
              }
            },
            "additionalProperties": false,
            "description": "The dictionary containing the template ids for given template type.If template type is not provided, the default template will be used."
          },
          "automaticReminders": {
            "$ref": "#/components/schemas/AutomaticReminders"
          },
          "fromEmail": {
            "type": "string",
            "nullable": true
          },
          "bankAccountId": {
            "type": "string",
            "description": "The bank account associated with the distribution.",
            "format": "uuid"
          },
          "subClientId": {
            "type": "string",
            "description": "The sub-client that owns this distribution, if any.",
            "format": "uuid",
            "nullable": true
          },
          "taxCollection": {
            "$ref": "#/components/schemas/DistributionTaxCollectionResponse"
          }
        },
        "additionalProperties": false
      },
      "DistributionStatisticsReportResponse": {
        "required": [
          "distributionName",
          "metrics"
        ],
        "type": "object",
        "properties": {
          "distributionId": {
            "type": "string",
            "description": "Unique identifier of the distribution",
            "format": "uuid"
          },
          "distributionName": {
            "type": "string",
            "description": "Name of the distribution"
          },
          "metrics": {
            "$ref": "#/components/schemas/DistributionMetrics"
          },
          "generationDate": {
            "type": "string",
            "description": "Date and time when this report was generated",
            "format": "date-time"
          }
        },
        "additionalProperties": false
      },
      "DistributionTaxCollectionResponse": {
        "type": "object",
        "properties": {
          "mode": {
            "$ref": "#/components/schemas/TaxCollectionMode"
          },
          "enabledOn": {
            "type": "string",
            "description": "The timestamp when tax collection was enabled on this distribution; null if never enabled.",
            "format": "date-time",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "DistributionWithDetailsResponse": {
        "required": [
          "distribution"
        ],
        "type": "object",
        "properties": {
          "distribution": {
            "$ref": "#/components/schemas/DistributionResponse"
          },
          "details": {
            "$ref": "#/components/schemas/DetailsResponse"
          }
        },
        "additionalProperties": false
      },
      "DistributionsBankAccountTransactionResponse": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The unique identifier for the transaction.",
            "format": "uuid",
            "nullable": true
          },
          "status": {
            "$ref": "#/components/schemas/BankAccountTransactionStatus"
          },
          "amount": {
            "type": "number",
            "description": "The amount associated with the transaction.",
            "format": "double"
          },
          "description": {
            "type": "string",
            "description": "The description of the transaction.",
            "nullable": true
          },
          "createdOnTimestamp": {
            "type": "string",
            "description": "The date when the transaction was created.",
            "format": "date-time"
          },
          "updatedOnTimestamp": {
            "type": "string",
            "description": "The date of last transaction update.",
            "format": "date-time",
            "nullable": true
          },
          "type": {
            "$ref": "#/components/schemas/BankAccountTransactionType"
          },
          "isAggregated": {
            "type": "boolean",
            "description": "Indicates whether this transaction represents an aggregated group of transactions."
          },
          "distributionId": {
            "type": "string",
            "description": "The distributionId associated with the transaction.",
            "format": "uuid",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "DistributionsBankAccountTransactionsResponse": {
        "type": "object",
        "properties": {
          "transactions": {
            "$ref": "#/components/schemas/PagedCollectionOfDistributionsBankAccountTransactionResponse"
          }
        },
        "additionalProperties": false
      },
      "DistributionsConversionReportResponse": {
        "type": "object",
        "properties": {
          "distributionId": {
            "type": "string",
            "description": "Unique identifier of the distribution",
            "format": "uuid"
          },
          "distributionName": {
            "type": "string",
            "description": "Name of the distribution"
          },
          "conversionStages": {
            "$ref": "#/components/schemas/ConversionStages"
          },
          "generationDate": {
            "type": "string",
            "description": "Date and time when this report was generated",
            "format": "date-time"
          }
        },
        "additionalProperties": false
      },
      "DistributionsPayoutMethodsReportResponse": {
        "type": "object",
        "properties": {
          "distributionId": {
            "type": "string",
            "description": "Unique identifier of the distribution",
            "format": "uuid"
          },
          "distributionName": {
            "type": "string",
            "description": "Name of the distribution"
          },
          "payoutMethods": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PayoutMethodUsage"
            },
            "description": "List of payout methods with their usage metrics"
          },
          "generationDate": {
            "type": "string",
            "description": "Date and time when this report was generated",
            "format": "date-time"
          },
          "totalCount": {
            "type": "integer",
            "description": "Total count of payout instructions across all payout methods",
            "format": "int32"
          },
          "totalAmount": {
            "type": "number",
            "description": "Total monetary amount across all payout methods",
            "format": "double"
          }
        },
        "additionalProperties": false
      },
      "DistributionsPayoutsHistoryReportResponse": {
        "type": "object",
        "properties": {
          "distributionId": {
            "type": "string",
            "description": "Unique identifier of the distribution",
            "format": "uuid"
          },
          "distributionName": {
            "type": "string",
            "description": "Name of the distribution"
          },
          "reportPeriod": {
            "$ref": "#/components/schemas/PayoutsHistoryPeriod"
          },
          "dailyActivity": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/DailyActivity"
            },
            "description": "List of daily payout activities within the report period"
          },
          "summary": {
            "$ref": "#/components/schemas/PayoutsHistorySummary"
          },
          "generationDate": {
            "type": "string",
            "description": "Date and time when this report was generated",
            "format": "date-time"
          }
        },
        "additionalProperties": false
      },
      "DynamicFieldResponse": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "description": "Type of the template model element (e.g., string)."
          },
          "description": {
            "type": "string",
            "description": "Description of the template model element."
          }
        },
        "additionalProperties": false
      },
      "ExportClaimLinkResponse": {
        "required": [
          "claimLink"
        ],
        "type": "object",
        "properties": {
          "claimLink": {
            "type": "string",
            "description": "The full claim link. It is the same URL that the initiate email carries. Treat it as a credential."
          }
        },
        "additionalProperties": false
      },
      "FundingAccountResponse": {
        "type": "object",
        "properties": {
          "accountName": {
            "type": "string"
          },
          "accountNumber": {
            "type": "string"
          },
          "routingNumber": {
            "type": "string"
          },
          "address": {
            "$ref": "#/components/schemas/BankAccountAddressResponse"
          },
          "accountHolderName": {
            "type": "string",
            "nullable": true
          },
          "bankName": {
            "type": "string",
            "nullable": true
          },
          "bankAddress": {
            "$ref": "#/components/schemas/BankAccountAddressResponse"
          },
          "acceptsWires": {
            "type": "boolean",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "FundingRequestActorResponse": {
        "type": "object",
        "properties": {
          "userId": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          },
          "name": {
            "type": "string",
            "nullable": true
          },
          "clientId": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "FundingRequestAddresseeResponse": {
        "type": "object",
        "properties": {
          "userId": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "email": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "FundingRequestResponse": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "distributionId": {
            "type": "string",
            "format": "uuid"
          },
          "distributionName": {
            "type": "string"
          },
          "subClientId": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          },
          "status": {
            "$ref": "#/components/schemas/FundingRequestStatus"
          },
          "amount": {
            "type": "number",
            "format": "double"
          },
          "note": {
            "type": "string",
            "nullable": true
          },
          "availableBalanceAtRequest": {
            "type": "number",
            "format": "double"
          },
          "reference": {
            "type": "string"
          },
          "fundingAccount": {
            "$ref": "#/components/schemas/FundingAccountResponse"
          },
          "requestedBy": {
            "$ref": "#/components/schemas/FundingRequestActorResponse"
          },
          "requestedOn": {
            "type": "string",
            "format": "date-time"
          },
          "sentTo": {
            "$ref": "#/components/schemas/FundingRequestAddresseeResponse"
          },
          "decidedBy": {
            "$ref": "#/components/schemas/FundingRequestActorResponse"
          },
          "decidedOn": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "declineReason": {
            "type": "string",
            "nullable": true
          },
          "cancelledBy": {
            "$ref": "#/components/schemas/FundingRequestActorResponse"
          },
          "cancelledOn": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "FundingRequestStatus": {
        "enum": [
          "Sent",
          "Confirmed",
          "Declined",
          "Cancelled"
        ],
        "type": "string"
      },
      "FundsHolderResponse": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "type": {
            "$ref": "#/components/schemas/FundsHolderType"
          },
          "status": {
            "$ref": "#/components/schemas/FundsHolderStatus"
          }
        },
        "additionalProperties": false
      },
      "FundsHolderStatus": {
        "enum": [
          "Pending",
          "Active",
          "Rejected"
        ],
        "type": "string"
      },
      "FundsHolderType": {
        "enum": [
          "OrganizationAccount",
          "SettlementFund"
        ],
        "type": "string"
      },
      "HttpValidationProblemDetails": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "nullable": true
          },
          "title": {
            "type": "string",
            "nullable": true
          },
          "status": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "detail": {
            "type": "string",
            "nullable": true
          },
          "instance": {
            "type": "string",
            "nullable": true
          },
          "errors": {
            "type": "object",
            "additionalProperties": {
              "type": "array",
              "items": {
                "type": "string"
              }
            }
          }
        },
        "additionalProperties": {}
      },
      "InitiatePayoutInstructionRequest": {
        "type": "object",
        "properties": {
          "channel": {
            "type": "string",
            "description": "A channel that is used to deliver the Payout Instruction. Valid values are 'email' and 'none' (none will not actually perform any action)"
          }
        },
        "additionalProperties": false
      },
      "InvitationResponse": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "inviter": {
            "type": "string"
          },
          "invitee": {
            "type": "string"
          },
          "organizationId": {
            "type": "string"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "expiresAt": {
            "type": "string",
            "format": "date-time"
          },
          "subClient": {
            "$ref": "#/components/schemas/SubClientResponse"
          }
        },
        "additionalProperties": false
      },
      "PagedCollectionOfBankAccountResponse": {
        "type": "object",
        "properties": {
          "pageNumber": {
            "type": "integer",
            "format": "int32"
          },
          "pageSize": {
            "type": "integer",
            "format": "int32"
          },
          "totalPages": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "totalItems": {
            "type": "integer",
            "format": "int32"
          },
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BankAccountResponse"
            }
          }
        },
        "additionalProperties": false
      },
      "PagedCollectionOfBankAccountWithdrawalAccountResponse": {
        "type": "object",
        "properties": {
          "pageNumber": {
            "type": "integer",
            "format": "int32"
          },
          "pageSize": {
            "type": "integer",
            "format": "int32"
          },
          "totalPages": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "totalItems": {
            "type": "integer",
            "format": "int32"
          },
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BankAccountWithdrawalAccountResponse"
            }
          }
        },
        "additionalProperties": false
      },
      "PagedCollectionOfDistributionWithDetailsResponse": {
        "type": "object",
        "properties": {
          "pageNumber": {
            "type": "integer",
            "format": "int32"
          },
          "pageSize": {
            "type": "integer",
            "format": "int32"
          },
          "totalPages": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "totalItems": {
            "type": "integer",
            "format": "int32"
          },
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/DistributionWithDetailsResponse"
            }
          }
        },
        "additionalProperties": false
      },
      "PagedCollectionOfDistributionsBankAccountTransactionResponse": {
        "type": "object",
        "properties": {
          "pageNumber": {
            "type": "integer",
            "format": "int32"
          },
          "pageSize": {
            "type": "integer",
            "format": "int32"
          },
          "totalPages": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "totalItems": {
            "type": "integer",
            "format": "int32"
          },
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/DistributionsBankAccountTransactionResponse"
            }
          }
        },
        "additionalProperties": false
      },
      "PagedCollectionOfFundingRequestResponse": {
        "type": "object",
        "properties": {
          "pageNumber": {
            "type": "integer",
            "format": "int32"
          },
          "pageSize": {
            "type": "integer",
            "format": "int32"
          },
          "totalPages": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "totalItems": {
            "type": "integer",
            "format": "int32"
          },
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FundingRequestResponse"
            }
          }
        },
        "additionalProperties": false
      },
      "PagedCollectionOfFundsHolderResponse": {
        "type": "object",
        "properties": {
          "pageNumber": {
            "type": "integer",
            "format": "int32"
          },
          "pageSize": {
            "type": "integer",
            "format": "int32"
          },
          "totalPages": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "totalItems": {
            "type": "integer",
            "format": "int32"
          },
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FundsHolderResponse"
            }
          }
        },
        "additionalProperties": false
      },
      "PagedCollectionOfInvitationResponse": {
        "type": "object",
        "properties": {
          "pageNumber": {
            "type": "integer",
            "format": "int32"
          },
          "pageSize": {
            "type": "integer",
            "format": "int32"
          },
          "totalPages": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "totalItems": {
            "type": "integer",
            "format": "int32"
          },
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/InvitationResponse"
            }
          }
        },
        "additionalProperties": false
      },
      "PagedCollectionOfPayoutInstructionUploadRowResponse": {
        "type": "object",
        "properties": {
          "pageNumber": {
            "type": "integer",
            "format": "int32"
          },
          "pageSize": {
            "type": "integer",
            "format": "int32"
          },
          "totalPages": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "totalItems": {
            "type": "integer",
            "format": "int32"
          },
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PayoutInstructionUploadRowResponse"
            }
          }
        },
        "additionalProperties": false
      },
      "PagedCollectionOfTemplateResponse": {
        "type": "object",
        "properties": {
          "pageNumber": {
            "type": "integer",
            "format": "int32"
          },
          "pageSize": {
            "type": "integer",
            "format": "int32"
          },
          "totalPages": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "totalItems": {
            "type": "integer",
            "format": "int32"
          },
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TemplateResponse"
            }
          }
        },
        "additionalProperties": false
      },
      "PagedCollectionOfUserResponse": {
        "type": "object",
        "properties": {
          "pageNumber": {
            "type": "integer",
            "format": "int32"
          },
          "pageSize": {
            "type": "integer",
            "format": "int32"
          },
          "totalPages": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "totalItems": {
            "type": "integer",
            "format": "int32"
          },
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/UserResponse"
            }
          }
        },
        "additionalProperties": false
      },
      "PagedCollectionOfV3PayoutInstructionResponse": {
        "type": "object",
        "properties": {
          "pageNumber": {
            "type": "integer",
            "format": "int32"
          },
          "pageSize": {
            "type": "integer",
            "format": "int32"
          },
          "totalPages": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "totalItems": {
            "type": "integer",
            "format": "int32"
          },
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/V3PayoutInstructionResponse"
            }
          }
        },
        "additionalProperties": false
      },
      "PayoutActivityMetrics": {
        "type": "object",
        "properties": {
          "count": {
            "type": "integer",
            "description": "Number of payout activities",
            "format": "int32"
          },
          "amount": {
            "type": "number",
            "description": "Total monetary amount of payout activities",
            "format": "double"
          }
        },
        "additionalProperties": false
      },
      "PayoutInstructionActivityResponse": {
        "type": "object",
        "properties": {
          "messageId": {
            "type": "string",
            "description": "Unique identifier for the activity message.",
            "format": "uuid",
            "nullable": true
          },
          "messageType": {
            "type": "string",
            "description": "Type of message associated with this activity."
          },
          "timestamp": {
            "type": "string",
            "description": "Date and time when the activity occurred.",
            "format": "date-time",
            "nullable": true
          },
          "type": {
            "type": "string",
            "description": "Category or classification of the activity."
          },
          "description": {
            "type": "string",
            "description": "Human-readable description of the activity."
          },
          "details": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "Additional contextual information about the activity as key-value pairs.",
            "nullable": true
          },
          "initiatedByUserId": {
            "type": "string",
            "description": "Id of the user who performed the action, as returned by GET /v3/distribution-manager/users. Deleted users are not returned there. Null when no user is recorded, for example for automatic actions.",
            "format": "uuid",
            "nullable": true
          },
          "initiatedByClientId": {
            "type": "string",
            "description": "Client id of the machine-to-machine application that performed the action. Null when no application is recorded, for example for automatic actions.",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "PayoutInstructionPayoutResponse": {
        "type": "object",
        "properties": {
          "payoutInstructionId": {
            "type": "string",
            "description": "The unique identifier of the payout instruction associated with this payout.",
            "format": "uuid"
          },
          "payoutMethodId": {
            "type": "string",
            "description": "The unique identifier of the payout method used for this payout.",
            "format": "uuid"
          },
          "status": {
            "$ref": "#/components/schemas/PayoutInstructionStatus"
          },
          "requestedOn": {
            "type": "string",
            "description": "The date and time when the payout was requested by the beneficiary.",
            "format": "date-time",
            "nullable": true
          },
          "completedOn": {
            "type": "string",
            "description": "The date and time when the payout was completed successfully.",
            "format": "date-time",
            "nullable": true
          },
          "externalIdentifiers": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "External identifiers related to the payout, specific to the payment method (e.g., transaction IDs, payment references).",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "PayoutInstructionStatus": {
        "enum": [
          "Draft",
          "Ready",
          "PushInitiated",
          "Initiated",
          "InitiationFailed",
          "PayoutMethodSelected",
          "Requested",
          "Restored",
          "Reinitiated",
          "ExpiryRequested",
          "Fulfilled",
          "Expired",
          "Cancelled"
        ],
        "type": "string"
      },
      "PayoutInstructionUploadRowOutcome": {
        "enum": [
          "Pending",
          "Ready",
          "Draft",
          "Skipped",
          "Failed"
        ],
        "type": "string"
      },
      "PayoutInstructionUploadRowResponse": {
        "required": [
          "externalId",
          "outcome",
          "rowNumber"
        ],
        "type": "object",
        "properties": {
          "rowNumber": {
            "type": "integer",
            "description": "The row's line number in the uploaded file. The header is line 1, so the first data row is line 2.",
            "format": "int32"
          },
          "externalId": {
            "type": "string",
            "description": "The value of the file's 'Id' column for this row — your own identifier for the payout instruction."
          },
          "outcome": {
            "$ref": "#/components/schemas/PayoutInstructionUploadRowOutcome"
          },
          "payoutInstructionId": {
            "type": "string",
            "description": "The payout instruction this row created or updated. Null while the row is Pending, and for Skipped and Failed rows — a Skipped row's payout instruction can be found by filtering the payout instructions list on its externalId.",
            "format": "uuid",
            "nullable": true
          },
          "processedAt": {
            "type": "string",
            "description": "When the row reached its outcome, in UTC. Null while the row is Pending.",
            "format": "date-time",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "PayoutInstructionUploadStatusResponse": {
        "required": [
          "batchId",
          "detectedTagColumns",
          "draftRows",
          "failedRows",
          "isComplete",
          "pendingRows",
          "processedRows",
          "readyRows",
          "skippedRows",
          "totalRows"
        ],
        "type": "object",
        "properties": {
          "batchId": {
            "type": "string",
            "description": "The upload batch this status refers to.",
            "format": "uuid"
          },
          "totalRows": {
            "type": "integer",
            "description": "Total rows in the uploaded file, counted at upload time.",
            "format": "int32"
          },
          "processedRows": {
            "type": "integer",
            "description": "Rows processed so far (created as a new payout instruction, or resolved as a duplicate) — always exact, never an estimate.",
            "format": "int32"
          },
          "pendingRows": {
            "type": "integer",
            "description": "Rows not yet processed. Processing is complete once this reaches zero.",
            "format": "int32"
          },
          "readyRows": {
            "type": "integer",
            "description": "Processed rows that are Ready — complete and eligible for initiation.",
            "format": "int32"
          },
          "draftRows": {
            "type": "integer",
            "description": "Processed rows saved as Draft — incomplete or invalid details (e.g. missing email); fix and re-upload to make them payable.",
            "format": "int32"
          },
          "skippedRows": {
            "type": "integer",
            "description": "Processed rows skipped because the payout instruction had already advanced past Ready/Draft — nothing to import. List them through the upload-status rows endpoint with outcome=Skipped.",
            "format": "int32"
          },
          "failedRows": {
            "type": "integer",
            "description": "Rows that failed to process because the pipeline faulted. List them through the upload-status rows endpoint with outcome=Failed and upload the affected rows again; contact Talli support if they keep failing.",
            "format": "int32"
          },
          "isComplete": {
            "type": "boolean",
            "description": "True once every row in the file has been processed."
          },
          "detectedTagColumns": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Columns of the uploaded file that were imported as tags, in file order. Empty for a file without tag columns."
          }
        },
        "additionalProperties": false
      },
      "PayoutMethodCategoryApiContract": {
        "enum": [
          "PrepaidCards",
          "GiftCards",
          "ACHTransfer",
          "VenmoTransfer",
          "PayPalTransfer",
          "PayPalV2Transfer",
          "VenmoV2Transfer",
          "PaperCheck",
          "CheckTransfer"
        ],
        "type": "string"
      },
      "PayoutMethodDisableReason": {
        "enum": [
          "Default",
          "InvalidPhoneNumber",
          "AmountNotSupported",
          "IncommBufferExhausted"
        ],
        "type": "string"
      },
      "PayoutMethodResponse": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Unique identifier for the payout method.",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "Display name of the payout method."
          },
          "category": {
            "$ref": "#/components/schemas/PayoutMethodCategoryApiContract"
          },
          "iconUrl": {
            "type": "string",
            "description": "URL for the payout method's icon or logo."
          },
          "isValidPhoneNumberRequired": {
            "type": "boolean",
            "description": "Indicates whether a valid phone number is required for this payout method."
          },
          "isActive": {
            "type": "boolean",
            "description": "Informs whether a payout method is active."
          },
          "description": {
            "type": "string",
            "description": "Optional description providing additional information about the payout method.",
            "nullable": true
          },
          "minAmount": {
            "type": "number",
            "description": "Optional minimum amount that can be processed with this payout method.",
            "format": "double",
            "nullable": true
          },
          "maxAmount": {
            "type": "number",
            "description": "Optional maximum amount that can be processed with this payout method.",
            "format": "double",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "PayoutMethodUsage": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Unique identifier of the payout method",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "description": "Name of the payout method"
          },
          "category": {
            "$ref": "#/components/schemas/PayoutMethodCategoryApiContract"
          },
          "usage": {
            "$ref": "#/components/schemas/UsageMetrics"
          }
        },
        "additionalProperties": false
      },
      "PayoutsHistoryPeriod": {
        "type": "object",
        "properties": {
          "from": {
            "type": "string",
            "description": "Start date and time of the report period (inclusive)",
            "format": "date-time"
          },
          "to": {
            "type": "string",
            "description": "End date and time of the report period (inclusive)",
            "format": "date-time"
          },
          "days": {
            "type": "integer",
            "description": "Total number of days in the report period",
            "format": "int32"
          }
        },
        "additionalProperties": false
      },
      "PayoutsHistorySummary": {
        "type": "object",
        "properties": {
          "payoutsSent": {
            "$ref": "#/components/schemas/PayoutActivityMetrics"
          },
          "payoutsRedeemed": {
            "$ref": "#/components/schemas/PayoutActivityMetrics"
          },
          "averagePayoutAmount": {
            "type": "number",
            "description": "Average monetary amount per payout sent during the report period",
            "format": "double"
          },
          "averageDailyPayouts": {
            "type": "number",
            "description": "Average number of payouts sent per day during the report period",
            "format": "double"
          }
        },
        "additionalProperties": false
      },
      "ProblemDetails": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "nullable": true
          },
          "title": {
            "type": "string",
            "nullable": true
          },
          "status": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "detail": {
            "type": "string",
            "nullable": true
          },
          "instance": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": {}
      },
      "ReassignDistributionSubClientRequest": {
        "type": "object",
        "properties": {
          "subClientId": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "RefundDistributionRequest": {
        "required": [
          "description"
        ],
        "type": "object",
        "properties": {
          "withdrawalAccountId": {
            "type": "string",
            "format": "uuid"
          },
          "amount": {
            "type": "number",
            "format": "double"
          },
          "method": {
            "$ref": "#/components/schemas/TransferMethod"
          },
          "description": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "ReinitiatePayoutInstructionRequest": {
        "type": "object",
        "properties": {
          "channel": {
            "type": "string"
          },
          "reason": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "RenameBankAccountRequest": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "RoleResponse": {
        "required": [
          "id",
          "name",
          "permissions"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "permissions": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "additionalProperties": false
      },
      "RoleWithoutPermissionsResponse": {
        "required": [
          "id",
          "name"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "SendNotificationPreviewRequest": {
        "type": "object",
        "properties": {
          "templateId": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          },
          "templateType": {
            "$ref": "#/components/schemas/TemplateType"
          },
          "contentFields": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "nullable": true
          },
          "recipient": {
            "type": "string"
          },
          "dynamicFields": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "nullable": true
          },
          "distributionId": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "SendPayoutInstructionReminderRequest": {
        "type": "object",
        "additionalProperties": false
      },
      "SetBrandCompanyDetailsRequest": {
        "type": "object",
        "properties": {
          "displayName": {
            "type": "string"
          },
          "companyName": {
            "type": "string",
            "nullable": true
          },
          "companyAddress": {
            "$ref": "#/components/schemas/CompanyAddress"
          },
          "supportEmail": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "SetBrandSlugRequest": {
        "type": "object",
        "properties": {
          "slug": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "SetDistributionPasswordRequest": {
        "type": "object",
        "properties": {
          "distributionPassword": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "SortDirection": {
        "enum": [
          "Ascending",
          "Descending"
        ],
        "type": "string"
      },
      "StateCode": {
        "enum": [
          "AL",
          "AK",
          "AR",
          "AZ",
          "CA",
          "CO",
          "CT",
          "DC",
          "DE",
          "FL",
          "GA",
          "HI",
          "IA",
          "ID",
          "IL",
          "IN",
          "KS",
          "KY",
          "LA",
          "MA",
          "MD",
          "ME",
          "MI",
          "MN",
          "MO",
          "MS",
          "MT",
          "NC",
          "ND",
          "NE",
          "NH",
          "NJ",
          "NM",
          "NV",
          "NY",
          "OK",
          "OH",
          "OR",
          "PA",
          "RI",
          "SC",
          "SD",
          "TN",
          "TX",
          "UT",
          "VA",
          "VT",
          "WA",
          "WI",
          "WV",
          "WY",
          "PR",
          "AS",
          "GU",
          "MP",
          "VI"
        ],
        "type": "string"
      },
      "SubClientResponse": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "SubClientSummaryResponse": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string"
          },
          "memberCount": {
            "type": "integer",
            "format": "int32"
          }
        },
        "additionalProperties": false
      },
      "TagAchTransferDistributionRequest": {
        "type": "object",
        "properties": {
          "distributionId": {
            "type": "string",
            "format": "uuid"
          }
        },
        "additionalProperties": false
      },
      "TaxCollectionMode": {
        "enum": [
          "None",
          "Standard"
        ],
        "type": "string"
      },
      "TaxExportRequest": {
        "required": [
          "zipPassword"
        ],
        "type": "object",
        "properties": {
          "scope": {
            "$ref": "#/components/schemas/TaxExportScope"
          },
          "distributionId": {
            "type": "string",
            "description": "The distribution whose completed W-9 records to export. Required when scope is Distribution.",
            "format": "uuid",
            "nullable": true
          },
          "from": {
            "type": "string",
            "description": "Inclusive start of the fulfillment-date range (UTC instant). Required when scope is DateRange.",
            "format": "date-time",
            "nullable": true
          },
          "to": {
            "type": "string",
            "description": "Inclusive end of the fulfillment-date range (UTC instant). Required when scope is DateRange.",
            "format": "date-time",
            "nullable": true
          },
          "payoutInstructionId": {
            "type": "string",
            "description": "The payout instruction whose W-9 record to export. Required when scope is Beneficiary.",
            "format": "uuid",
            "nullable": true
          },
          "includeNotFulfilledPayouts": {
            "type": "boolean",
            "description": "Include payout instructions that were never fulfilled. Default false; ignored for DateRange."
          },
          "zipPassword": {
            "type": "string",
            "description": "Password used to AES-encrypt the returned ZIP. Minimum 12 characters, must include an uppercase letter, a lowercase letter, a digit, and a special character. Never stored."
          }
        },
        "additionalProperties": false
      },
      "TaxExportScope": {
        "enum": [
          "Distribution",
          "DateRange",
          "Beneficiary"
        ],
        "type": "string"
      },
      "TemplateLayoutResponse": {
        "type": "object",
        "properties": {
          "externalTemplateId": {
            "type": "string",
            "description": "External identifier for the template, typically used for reference in external systems."
          },
          "contentFieldDefinitions": {
            "type": "object",
            "additionalProperties": {
              "$ref": "#/components/schemas/ContentFieldDefinitionResponse"
            },
            "description": "The dictionary is used to store context fields. The template consists of content fields."
          }
        },
        "additionalProperties": false
      },
      "TemplateResponse": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The unique identifier for the template.",
            "format": "uuid"
          },
          "templateType": {
            "$ref": "#/components/schemas/TemplateType"
          },
          "name": {
            "type": "string",
            "description": "The name of the template."
          },
          "isActive": {
            "type": "boolean",
            "description": "Indicates whether a template is active or not. If this is disabled, this template will not be used.",
            "nullable": true
          },
          "contentFields": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "The dictionary is used to store context fields. The template consists of content fields.When creating new template, all of the content fields need to be provided. The required content fields are defined in 'Template Type Schema' model."
          }
        },
        "additionalProperties": false
      },
      "TemplateType": {
        "enum": [
          "InitiateEmail",
          "ReminderEmail"
        ],
        "type": "string"
      },
      "TemplateTypeSchemaResponse": {
        "type": "object",
        "properties": {
          "templateType": {
            "$ref": "#/components/schemas/TemplateType"
          },
          "description": {
            "type": "string",
            "description": "Description of the template type."
          },
          "dynamicFieldsSchema": {
            "type": "object",
            "additionalProperties": {
              "$ref": "#/components/schemas/DynamicFieldResponse"
            },
            "description": "Dictionary is used to store template model elements for a template type. Template model elements can be used in content fields. Elements can refer to an entire distribution (e.g., expiry date) or to a unique user (e.g., first name)."
          },
          "layout": {
            "$ref": "#/components/schemas/TemplateLayoutResponse"
          }
        },
        "additionalProperties": false
      },
      "TransferMethod": {
        "enum": [
          "AchNextDay",
          "AchSameDay"
        ],
        "type": "string"
      },
      "UpdateCredentialRequest": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "UpdateSubClientRequest": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "UpdateTemplateRequest": {
        "type": "object",
        "properties": {
          "templateType": {
            "$ref": "#/components/schemas/TemplateType"
          },
          "name": {
            "type": "string",
            "description": "The name of the template."
          },
          "isActive": {
            "type": "boolean",
            "description": "Indicates whether a template is active or not. If this is disabled, this template will not be used.",
            "nullable": true
          },
          "contentFields": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "The dictionary is used to store context fields. The template consists of content fields.",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "UpdateUserSubClientRequest": {
        "type": "object",
        "properties": {
          "subClientId": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "UploadPayoutInstructionsFileResponse": {
        "required": [
          "batchId",
          "detectedTagColumns"
        ],
        "type": "object",
        "properties": {
          "batchId": {
            "type": "string",
            "description": "Identifier for this upload.",
            "format": "uuid"
          },
          "detectedTagColumns": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Columns of the uploaded file that are not known columns and are imported as tags, in file order."
          }
        },
        "additionalProperties": false
      },
      "UsageMetrics": {
        "type": "object",
        "properties": {
          "count": {
            "type": "integer",
            "description": "Total count of instances",
            "format": "int32"
          },
          "amount": {
            "type": "number",
            "description": "Total monetary amount associated with the instances",
            "format": "double"
          },
          "percentageByCount": {
            "type": "number",
            "description": "Percentage representation based on count relative to the total",
            "format": "double"
          },
          "percentageByAmount": {
            "type": "number",
            "description": "Percentage representation based on amount relative to the total",
            "format": "double"
          }
        },
        "additionalProperties": false
      },
      "UserResponse": {
        "required": [
          "createdOn",
          "id",
          "role",
          "userEmail"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "userEmail": {
            "type": "string"
          },
          "firstName": {
            "type": "string",
            "nullable": true
          },
          "lastName": {
            "type": "string",
            "nullable": true
          },
          "createdOn": {
            "type": "string",
            "format": "date-time"
          },
          "subClient": {
            "$ref": "#/components/schemas/SubClientResponse"
          },
          "role": {
            "$ref": "#/components/schemas/RoleWithoutPermissionsResponse"
          }
        },
        "additionalProperties": false
      },
      "UserRole": {
        "enum": [
          "TalliAdmin",
          "TalliCustomerService",
          "OrgAdmin",
          "OrgViewer",
          "TalliDeveloper",
          "OrgManager",
          "SubClientViewer",
          "TalliSubClientManager"
        ],
        "type": "string"
      },
      "V3PayoutInstructionResponse": {
        "required": [
          "email",
          "externalId",
          "tags"
        ],
        "type": "object",
        "properties": {
          "payoutInstructionId": {
            "type": "string",
            "description": "The unique identifier for the payout instruction.",
            "format": "uuid"
          },
          "distributionId": {
            "type": "string",
            "description": "The identifier of the distribution this payout instruction belongs to.",
            "format": "uuid"
          },
          "bankAccountId": {
            "type": "string",
            "description": "The identifier of the bank account this payout instruction belongs to.",
            "format": "uuid"
          },
          "amount": {
            "type": "number",
            "description": "The monetary amount of the payout instruction.",
            "format": "double",
            "nullable": true
          },
          "firstName": {
            "type": "string",
            "description": "The first name of the beneficiary.",
            "nullable": true
          },
          "lastName": {
            "type": "string",
            "description": "The last name of the beneficiary.",
            "nullable": true
          },
          "email": {
            "type": "string",
            "description": "The email address of the beneficiary. This is the primary contact method."
          },
          "phoneNumber": {
            "type": "string",
            "description": "The phone number of the beneficiary. May be required for certain payout methods.",
            "nullable": true
          },
          "status": {
            "$ref": "#/components/schemas/PayoutInstructionStatus"
          },
          "cancellationReason": {
            "$ref": "#/components/schemas/CancellationReason"
          },
          "selectedPayoutMethodId": {
            "type": "string",
            "description": "The identifier of the payout method selected by the beneficiary, if any.",
            "format": "uuid",
            "nullable": true
          },
          "fulfilledOn": {
            "type": "string",
            "description": "The redemption date for this payout instruction if in fulfilled status",
            "format": "date-time",
            "nullable": true
          },
          "externalId": {
            "type": "string",
            "description": "An external identifier for this payout instruction, used for integration with client systems."
          },
          "subClientId": {
            "type": "string",
            "description": "The sub-client that owns this payout instruction, if any.",
            "format": "uuid",
            "nullable": true
          },
          "tags": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "Free-form key/value labels for this payout instruction. Empty when it has no tags."
          },
          "isDirectPayout": {
            "type": "boolean",
            "description": "True when this payout was requested directly by the distribution manager, with no beneficiary notification."
          },
          "nextReminderDate": {
            "type": "string",
            "description": "The next reminder date for this payout instruction if automatic reminders are enabled, otherwise null.",
            "format": "date-time",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "WithdrawFromBankAccountRequest": {
        "required": [
          "description"
        ],
        "type": "object",
        "properties": {
          "withdrawalAccountId": {
            "type": "string",
            "format": "uuid"
          },
          "amount": {
            "type": "number",
            "format": "double"
          },
          "method": {
            "$ref": "#/components/schemas/TransferMethod"
          },
          "description": {
            "type": "string"
          }
        },
        "additionalProperties": false
      }
    },
    "securitySchemes": {
      "oauth2": {
        "type": "oauth2",
        "description": "Auth0 Authentication (OAuth2). Integrations use the Client Credentials flow.",
        "flows": {
          "clientCredentials": {
            "tokenUrl": "https://talli-ai.us.auth0.com/oauth/token",
            "scopes": {
              "distributions:view": "distributions:view",
              "distributions:create": "distributions:create",
              "distributions:edit": "distributions:edit",
              "distributions:setPassword": "distributions:setPassword",
              "fundingRequests:view": "fundingRequests:view",
              "fundingRequests:manage": "fundingRequests:manage",
              "fundingRequests:respond": "fundingRequests:respond",
              "users:manage": "users:manage",
              "users:view": "users:view",
              "payoutInstructions:view": "payoutInstructions:view",
              "payoutInstructions:sendReminder": "payoutInstructions:sendReminder",
              "payoutInstructions:cancel": "payoutInstructions:cancel",
              "payoutInstructions:tryRestore": "payoutInstructions:tryRestore",
              "payoutInstructions:create": "payoutInstructions:create",
              "payoutInstructions:update": "payoutInstructions:update",
              "payoutInstructions:initiate": "payoutInstructions:initiate",
              "payoutInstructions:reinitiate": "payoutInstructions:reinitiate",
              "payoutInstructions:directPayout": "payoutInstructions:directPayout",
              "payoutInstructions:exportClaimLink": "payoutInstructions:exportClaimLink",
              "payoutMethods:view": "payoutMethods:view",
              "reports:view": "reports:view",
              "sub-clients:manage": "sub-clients:manage",
              "fundsHolders:view": "fundsHolders:view",
              "fundsHolders:manage": "fundsHolders:manage",
              "linkedAccounts:create": "linkedAccounts:create",
              "templates:view": "templates:view",
              "templates:create": "templates:create",
              "templates:edit": "templates:edit",
              "templates:sendPreview": "templates:sendPreview",
              "roles:view": "roles:view",
              "invitations:view": "invitations:view",
              "invitations:create": "invitations:create",
              "invitations:delete": "invitations:delete",
              "bankAccounts:view": "bankAccounts:view",
              "bankAccounts:create": "bankAccounts:create",
              "bankAccounts:withdraw": "bankAccounts:withdraw",
              "organizationSettings:view": "organizationSettings:view",
              "organizationSettings:manage": "organizationSettings:manage",
              "transfers:tagCampaign": "transfers:tagCampaign",
              "tax:manage": "tax:manage",
              "credentials:view": "credentials:view",
              "credentials:manage": "credentials:manage"
            }
          },
          "authorizationCode": {
            "authorizationUrl": "https://talli-ai.us.auth0.com/authorize",
            "tokenUrl": "https://talli-ai.us.auth0.com/oauth/token",
            "scopes": {
              "distributions:view": "distributions:view",
              "distributions:create": "distributions:create",
              "distributions:edit": "distributions:edit",
              "distributions:setPassword": "distributions:setPassword",
              "fundingRequests:view": "fundingRequests:view",
              "fundingRequests:manage": "fundingRequests:manage",
              "fundingRequests:respond": "fundingRequests:respond",
              "users:manage": "users:manage",
              "users:view": "users:view",
              "payoutInstructions:view": "payoutInstructions:view",
              "payoutInstructions:sendReminder": "payoutInstructions:sendReminder",
              "payoutInstructions:cancel": "payoutInstructions:cancel",
              "payoutInstructions:tryRestore": "payoutInstructions:tryRestore",
              "payoutInstructions:create": "payoutInstructions:create",
              "payoutInstructions:update": "payoutInstructions:update",
              "payoutInstructions:initiate": "payoutInstructions:initiate",
              "payoutInstructions:reinitiate": "payoutInstructions:reinitiate",
              "payoutInstructions:directPayout": "payoutInstructions:directPayout",
              "payoutInstructions:exportClaimLink": "payoutInstructions:exportClaimLink",
              "payoutMethods:view": "payoutMethods:view",
              "reports:view": "reports:view",
              "sub-clients:manage": "sub-clients:manage",
              "fundsHolders:view": "fundsHolders:view",
              "fundsHolders:manage": "fundsHolders:manage",
              "linkedAccounts:create": "linkedAccounts:create",
              "templates:view": "templates:view",
              "templates:create": "templates:create",
              "templates:edit": "templates:edit",
              "templates:sendPreview": "templates:sendPreview",
              "roles:view": "roles:view",
              "invitations:view": "invitations:view",
              "invitations:create": "invitations:create",
              "invitations:delete": "invitations:delete",
              "bankAccounts:view": "bankAccounts:view",
              "bankAccounts:create": "bankAccounts:create",
              "bankAccounts:withdraw": "bankAccounts:withdraw",
              "organizationSettings:view": "organizationSettings:view",
              "organizationSettings:manage": "organizationSettings:manage",
              "transfers:tagCampaign": "transfers:tagCampaign",
              "tax:manage": "tax:manage",
              "credentials:view": "credentials:view",
              "credentials:manage": "credentials:manage"
            }
          }
        }
      },
      "oauth2-token-only": {
        "type": "apiKey",
        "description": "Standard Authorization header using the Bearer scheme. Example: \"bearer {token}\"",
        "name": "Authorization",
        "in": "header"
      }
    }
  },
  "tags": [
    {
      "name": "distributions",
      "description": "Endpoints for creating and managing distributions. A distribution represents a payout of funds to multiple beneficiaries. This is the V3 rename of campaigns."
    },
    {
      "name": "payout-instructions",
      "description": "Endpoints for creating and managing payout instructions. A payout instruction represents an intention to pay a specific amount of money to a beneficiary. It is associated with one and only one distribution. "
    },
    {
      "name": "payout-methods",
      "description": "Endpoints for viewing available payout methods, such as ACH, PayPal, and gift cards."
    },
    {
      "name": "reports",
      "description": "Endpoints for retrieving analytics and reporting data about distributions and payouts."
    },
    {
      "name": "funds-holders",
      "description": "Endpoints for creating and viewing funds holders. A funds holder is an account connected to a business entity that can be used as a source of funds for one or more distributions; each corresponds to a separate bank account in our payment system with its own banking details."
    },
    {
      "name": "templates",
      "description": "Endpoints for creating and managing notification templates, including retrieving template-type schemas and sending preview notifications."
    },
    {
      "name": "users",
      "description": "Endpoints for viewing and managing members of your organization, including changing a member's role and removing members."
    },
    {
      "name": "roles",
      "description": "Endpoints for viewing the roles that can be assigned to members of your organization."
    },
    {
      "name": "invitations",
      "description": "Endpoints for sending and managing invitations for members to join your organization."
    },
    {
      "name": "bank-accounts",
      "description": "Endpoints for creating and managing bank accounts, including transactions, withdrawal accounts, and withdrawals."
    },
    {
      "name": "brand-configuration",
      "description": "Authenticated endpoints for managing the organisation's white-label brand configuration: slug, colours, logo, favicon, and company details."
    },
    {
      "name": "credentials",
      "description": "Endpoints for API credentials. A credential is a client id and secret that an integration exchanges for an access token."
    }
  ]
}