---
updatedAt: 2026-07-07T13:34:02.000Z
agentTools:
  projectIndex: https://developer.spendesk.com/llms.txt
---

# Update Payable accounting fields

**Allowed Scopes**: _`experimental:accounting:update`_

Updates accounting fields for one Payable with optimistic locking.

The user associated with the token must have the Controller role in the company. Otherwise, the request fails with a `403` and the `CONTROLLER_ROLE_REQUIRED` error code.

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "Spendesk Public API",
    "description": "Spendesk Public API",
    "version": "1.0",
    "summary": "Spendesk Public API",
    "contact": {
      "email": "support-public-api@spendesk.com",
      "url": "https://developer.spendesk.com/",
      "name": "Spendesk for Developers"
    },
    "termsOfService": "https://www.spendesk.com/en/legals/terms/api-agreement"
  },
  "components": {
    "securitySchemes": {
      "Authentication": {
        "type": "oauth2",
        "description": "A company-level token acts on the company it was issued for. An organisation-level token (experimental) acts on the companies of an organisation: send the target company in the `X-Company-Id` header on every call, except on `GET /v2/companies` and on `/v2/companies/{companyId}/…` routes, which carry the company in the path. See [Organisation-level access](/reference/organisation-level-access).",
        "flows": {
          "clientCredentials": {
            "tokenUrl": "/v1/auth/token",
            "scopes": {
              "analytical-field:read": "Analytical Fields (Read)",
              "bank-fee:read": "Spending Bank Fees (Read)",
              "cost-center:read": "Cost Center (Read)",
              "cost-center:manage": "Cost Center (Manage)",
              "expense-category:read": "Expense Category (Read)",
              "payable:read": "Spending Payables (Read)",
              "payable-attachment:read": "Spending Payable Attachments (Read)",
              "settlement:read": "Spending Settlements (Read)",
              "supplier:read": "Suppliers (Read)",
              "user:read": "Users (Read)",
              "experimental:user:manage": "Users (Manage)",
              "wallet-load:read": "Spending Wallet Loads (Read)",
              "wallet-summary:read": "Spending Wallet Summary (Read)",
              "experimental:accounting-export:read": "Accounting exports (Read)",
              "experimental:accounting-export:write": "Accounting exports (Write)",
              "experimental:accounting:update": "Accounting (Update)",
              "experimental:chart-of-accounts:read": "Chart of Accounts (Read)",
              "experimental:chart-of-accounts:write": "Chart of Accounts (Write)",
              "experimental:purchase-order:read": "Purchase Orders (Read)",
              "experimental:purchase-order:write": "Purchase Orders (Write)",
              "experimental:webhooks:read": "Webhooks (Read)",
              "experimental:webhooks:write": "Webhooks (Write)",
              "experimental:supplier:manage": "Suppliers (Manage)",
              "experimental:company:read": "Companies (Read)",
              "experimental:payable-search:read": "Payable Search (Read)",
              "experimental:payable-attachment:write": "Payable Attachments (Write)",
              "experimental:card:read": "Cards (Read)",
              "experimental:card:write": "Cards (Write)",
              "experimental:request:read": "Requests (Read)",
              "experimental:transaction:read": "Transactions (Read)",
              "experimental:analytical-field-v2:read": "Analytical Fields v2 (Read)",
              "experimental:analytical-field-v2:write": "Analytical Fields v2 (Write)",
              "experimental:expense-category-v2:read": "Expense Category Fields v2 (Read)",
              "experimental:expense-category-v2:write": "Expense Category Fields v2 (Write)",
              "experimental:invoice:read": "Invoices (Read) - experimental",
              "experimental:intake:read": "Intakes (Read)",
              "experimental:intake:write": "Intakes (Write)",
              "experimental:external-reference:read": "External References (Read)",
              "experimental:external-reference:write": "External References (Write)"
            }
          },
          "authorizationCode": {
            "authorizationUrl": "/v1/oauth2/authorize",
            "tokenUrl": "/v1/oauth2/token/create",
            "scopes": {
              "analytical-field:read": "Analytical Fields (Read)",
              "bank-fee:read": "Spending Bank Fees (Read)",
              "cost-center:read": "Cost Center (Read)",
              "cost-center:manage": "Cost Center (Manage)",
              "expense-category:read": "Expense Category (Read)",
              "payable:read": "Spending Payables (Read)",
              "payable-attachment:read": "Spending Payable Attachments (Read)",
              "settlement:read": "Spending Settlements (Read)",
              "supplier:read": "Suppliers (Read)",
              "user:read": "Users (Read)",
              "experimental:user:manage": "Users (Manage)",
              "wallet-load:read": "Spending Wallet Loads (Read)",
              "wallet-summary:read": "Spending Wallet Summary (Read)",
              "experimental:accounting-export:read": "Accounting exports (Read)",
              "experimental:accounting-export:write": "Accounting exports (Write)",
              "experimental:accounting:update": "Accounting (Update)",
              "experimental:chart-of-accounts:read": "Chart of Accounts (Read)",
              "experimental:chart-of-accounts:write": "Chart of Accounts (Write)",
              "experimental:purchase-order:read": "Purchase Orders (Read)",
              "experimental:purchase-order:write": "Purchase Orders (Write)",
              "experimental:webhooks:read": "Webhooks (Read)",
              "experimental:webhooks:write": "Webhooks (Write)",
              "experimental:supplier:manage": "Suppliers (Manage)",
              "experimental:company:read": "Companies (Read)",
              "experimental:payable-search:read": "Payable Search (Read)",
              "experimental:payable-attachment:write": "Payable Attachments (Write)",
              "experimental:card:read": "Cards (Read)",
              "experimental:card:write": "Cards (Write)",
              "experimental:request:read": "Requests (Read)",
              "experimental:transaction:read": "Transactions (Read)",
              "experimental:analytical-field-v2:read": "Analytical Fields v2 (Read)",
              "experimental:analytical-field-v2:write": "Analytical Fields v2 (Write)",
              "experimental:expense-category-v2:read": "Expense Category Fields v2 (Read)",
              "experimental:expense-category-v2:write": "Expense Category Fields v2 (Write)",
              "experimental:invoice:read": "Invoices (Read) - experimental",
              "experimental:intake:read": "Intakes (Read)",
              "experimental:intake:write": "Intakes (Write)",
              "experimental:external-reference:read": "External References (Read)",
              "experimental:external-reference:write": "External References (Write)"
            }
          }
        }
      }
    },
    "schemas": {
      "dateTime": {
        "type": "string",
        "format": "date-time",
        "description": "String containing a UTC datetime expressed in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format like `2023-05-12T14:06:40Z`.",
        "title": "dateTime"
      },
      "badRequest": {
        "type": "object",
        "description": "Bad request",
        "additionalProperties": false,
        "properties": {
          "correlationId": {
            "type": "string"
          },
          "errors": {
            "type": "array",
            "items": {
              "additionalProperties": false,
              "type": "object",
              "properties": {
                "code": {
                  "type": "string",
                  "enum": [
                    "BAD_REQUEST_INCORRECT_OR_MISSING_FIELD",
                    "RESPONSE_TOO_LARGE"
                  ]
                },
                "detail": {
                  "type": "string"
                },
                "source": {
                  "type": "string"
                }
              },
              "required": [
                "code",
                "detail",
                "source"
              ]
            }
          }
        },
        "required": [
          "errors"
        ],
        "title": "badRequest"
      },
      "unauthorized": {
        "type": "object",
        "description": "Unauthorized",
        "additionalProperties": false,
        "properties": {
          "correlationId": {
            "type": "string"
          },
          "errors": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": {
                  "type": "string",
                  "enum": [
                    "AUTHENTICATION_ERROR"
                  ]
                },
                "detail": {
                  "type": "string"
                }
              },
              "required": [
                "code",
                "detail"
              ]
            }
          }
        },
        "required": [
          "errors"
        ],
        "title": "unauthorized"
      },
      "forbiddenControllerRoleRequired": {
        "type": "object",
        "description": "Forbidden",
        "additionalProperties": false,
        "properties": {
          "correlationId": {
            "type": "string"
          },
          "errors": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": false,
              "properties": {
                "code": {
                  "type": "string",
                  "enum": [
                    "FORBIDDEN_ERROR",
                    "CONTROLLER_ROLE_REQUIRED"
                  ]
                },
                "detail": {
                  "type": "string"
                }
              },
              "required": [
                "code",
                "detail"
              ]
            }
          }
        },
        "required": [
          "errors"
        ],
        "title": "forbiddenControllerRoleRequired"
      },
      "notFound": {
        "type": "object",
        "description": "Not Found",
        "additionalProperties": false,
        "properties": {
          "correlationId": {
            "type": "string"
          },
          "errors": {
            "type": "array",
            "items": {
              "additionalProperties": false,
              "type": "object",
              "properties": {
                "code": {
                  "type": "string",
                  "enum": [
                    "NOT_FOUND"
                  ]
                },
                "detail": {
                  "type": "string"
                }
              },
              "required": [
                "code",
                "detail"
              ]
            }
          }
        },
        "required": [
          "errors"
        ],
        "title": "notFound"
      },
      "conflict": {
        "type": "object",
        "description": "Conflict",
        "additionalProperties": false,
        "properties": {
          "correlationId": {
            "type": "string"
          },
          "errors": {
            "type": "array",
            "items": {
              "additionalProperties": false,
              "type": "object",
              "properties": {
                "code": {
                  "type": "string",
                  "enum": [
                    "CONFLICT_ERROR"
                  ]
                },
                "detail": {
                  "type": "string"
                }
              },
              "required": [
                "code",
                "detail"
              ]
            }
          }
        },
        "required": [
          "errors"
        ],
        "title": "conflict"
      },
      "tooLarge": {
        "type": "object",
        "description": "Payload Too Large",
        "additionalProperties": false,
        "properties": {
          "correlationId": {
            "type": "string"
          },
          "errors": {
            "type": "array",
            "items": {
              "additionalProperties": false,
              "type": "object",
              "properties": {
                "code": {
                  "type": "string",
                  "enum": [
                    "LARGE_BODY_ERROR"
                  ]
                },
                "detail": {
                  "type": "string",
                  "enum": [
                    "The request is too large for this endpoint: send a smaller body or a smaller file."
                  ]
                }
              },
              "required": [
                "code",
                "detail"
              ]
            }
          }
        },
        "required": [
          "errors"
        ],
        "title": "tooLarge"
      },
      "unsupportedMediaType": {
        "type": "object",
        "description": "Unsupported Media Type",
        "additionalProperties": false,
        "properties": {
          "correlationId": {
            "type": "string"
          },
          "errors": {
            "type": "array",
            "items": {
              "additionalProperties": false,
              "type": "object",
              "properties": {
                "code": {
                  "type": "string",
                  "enum": [
                    "UNSUPPORTED_MEDIA_TYPE_ERROR"
                  ]
                },
                "detail": {
                  "type": "string",
                  "enum": [
                    "The Content-Type of the request is not supported: send application/json, or application/x-www-form-urlencoded where the endpoint documents it."
                  ]
                }
              },
              "required": [
                "code",
                "detail"
              ]
            }
          }
        },
        "required": [
          "errors"
        ],
        "title": "unsupportedMediaType"
      },
      "tooManyRequests": {
        "type": "object",
        "description": "Too Many Requests",
        "additionalProperties": false,
        "properties": {
          "correlationId": {
            "type": "string"
          },
          "errors": {
            "type": "array",
            "items": {
              "additionalProperties": false,
              "type": "object",
              "properties": {
                "code": {
                  "type": "string",
                  "enum": [
                    "TOO_MANY_REQUESTS"
                  ]
                },
                "detail": {
                  "type": "string"
                }
              },
              "required": [
                "code",
                "detail"
              ]
            }
          }
        },
        "required": [
          "errors"
        ],
        "title": "tooManyRequests"
      },
      "internalServerError": {
        "type": "object",
        "description": "Internal Server Error",
        "additionalProperties": false,
        "properties": {
          "correlationId": {
            "type": "string"
          },
          "errors": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": false,
              "properties": {
                "code": {
                  "type": "string",
                  "enum": [
                    "INTERNAL_SERVER_ERROR"
                  ]
                },
                "detail": {
                  "type": "string",
                  "enum": [
                    "Sorry, something has gone wrong at our end. If this persists please contact support."
                  ]
                }
              },
              "required": [
                "code",
                "detail"
              ]
            }
          }
        },
        "required": [
          "errors"
        ],
        "title": "internalServerError"
      },
      "serviceUnavailableError": {
        "type": "object",
        "description": "Service Unavailable",
        "additionalProperties": false,
        "properties": {
          "correlationId": {
            "type": "string"
          },
          "errors": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": false,
              "properties": {
                "code": {
                  "type": "string",
                  "enum": [
                    "SERVICE_UNAVAILABLE_ERROR"
                  ]
                },
                "detail": {
                  "type": "string"
                }
              },
              "required": [
                "code",
                "detail"
              ]
            }
          }
        },
        "required": [
          "errors"
        ],
        "title": "serviceUnavailableError"
      },
      "webhookEntity": {
        "type": "string",
        "enum": [
          "payables",
          "settlements"
        ],
        "title": "webhookEntity"
      },
      "webhookPayable": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "event": {
            "type": "object",
            "additionalProperties": false,
            "properties": {
              "id": {
                "type": "string",
                "format": "uuid"
              },
              "timestamp": {
                "$ref": "#/components/schemas/dateTime"
              },
              "entity": {
                "$ref": "#/components/schemas/webhookEntity"
              },
              "eventType": {
                "type": "string",
                "enum": [
                  "created",
                  "prepared"
                ]
              }
            },
            "required": [
              "entity",
              "eventType",
              "id",
              "timestamp"
            ]
          },
          "data": {
            "type": "object",
            "additionalProperties": false,
            "properties": {
              "id": {
                "type": "string",
                "format": "uuid"
              },
              "companyId": {
                "type": "string"
              },
              "version": {
                "type": "integer"
              }
            },
            "required": [
              "id",
              "companyId",
              "version"
            ]
          }
        },
        "required": [
          "event",
          "data"
        ],
        "title": "webhookPayable"
      },
      "webhookSettlement": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "event": {
            "type": "object",
            "additionalProperties": false,
            "properties": {
              "id": {
                "type": "string",
                "format": "uuid"
              },
              "timestamp": {
                "$ref": "#/components/schemas/dateTime"
              },
              "entity": {
                "$ref": "#/components/schemas/webhookEntity"
              },
              "eventType": {
                "type": "string",
                "enum": [
                  "created"
                ]
              }
            },
            "required": [
              "entity",
              "eventType",
              "id",
              "timestamp"
            ]
          },
          "data": {
            "type": "object",
            "additionalProperties": false,
            "properties": {
              "id": {
                "type": "string",
                "format": "uuid"
              },
              "companyId": {
                "type": "string"
              },
              "version": {
                "type": "integer"
              }
            },
            "required": [
              "id",
              "companyId",
              "version"
            ]
          }
        },
        "required": [
          "event",
          "data"
        ],
        "title": "webhookSettlement"
      }
    }
  },
  "paths": {
    "/v1/payables/{id}": {
      "patch": {
        "operationId": "v1-patch-payable-accounting-fields",
        "summary": "Update Payable accounting fields",
        "tags": [
          "Payables"
        ],
        "description": "**Allowed Scopes**: _`experimental:accounting:update`_\n\nUpdates accounting fields for one Payable with optimistic locking.\n\nThe user associated with the token must have the Controller role in the company. Otherwise, the request fails with a `403` and the `CONTROLLER_ROLE_REQUIRED` error code.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "additionalProperties": false,
                "properties": {
                  "version": {
                    "type": "number",
                    "description": "The current version of the Payable to update.",
                    "example": 3
                  },
                  "description": {
                    "type": "string",
                    "description": "Description to apply to the Payable.",
                    "example": "Team offsite lunch"
                  },
                  "accountPayableId": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Account payable to apply to the Payable.",
                    "example": "00886d31-f27d-5366-8b05-cd287dc0f43d"
                  },
                  "accountingDate": {
                    "type": "string",
                    "format": "date",
                    "description": "Date in the `YYYY-MM-DD` format."
                  },
                  "lineItems": {
                    "type": "array",
                    "minItems": 1,
                    "description": "Complete replacement for the payable line items. To preserve a line returned by GET /v1/payables/{id}, map financial.grossAmount.amount to grossAmount, expenseAccount.id to expenseAccountId, vatAccount.id or reverseChargeAccount.id to taxAccountId, costCenterId directly, and analyticalProperties fieldId/valueId pairs to analyticalFieldValues; use null only when an account or cost center should remain unassigned. A null taxAccountId is not a tax-exempt, zero-rated, or reverse-charge treatment; changing tax treatment requires the matching company tax account ID. Gross amounts must sum to the payable amount. Tax amounts are recalculated from taxAccountId, clearing manual VAT adjustments.",
                    "items": {
                      "type": "object",
                      "additionalProperties": false,
                      "properties": {
                        "grossAmount": {
                          "type": "integer",
                          "minimum": -9007199254740991,
                          "maximum": 9007199254740991,
                          "description": "Gross amount of this line in the payable currency smallest unit (for example cents for EUR and USD, or yen for JPY).",
                          "example": 12000
                        },
                        "expenseAccountId": {
                          "type": "string",
                          "nullable": true,
                          "description": "Expense account ID, or null to leave the line unassigned.",
                          "example": "exp_acc_123"
                        },
                        "taxAccountId": {
                          "type": "string",
                          "nullable": true,
                          "description": "Tax or reverse-charge account ID. Use null only to leave the line without an assigned tax account. Null does not mean tax-exempt, zero-rated, or reverse charge; those treatments require the matching company tax account ID.",
                          "example": "tax_acc_456"
                        },
                        "costCenterId": {
                          "type": "string",
                          "nullable": true,
                          "description": "Cost center ID, or null to clear it. All lines must use the same value when analytical splitting is disabled.",
                          "example": "cc_789"
                        },
                        "analyticalFieldValues": {
                          "type": "array",
                          "description": "Complete analytical field value set; an empty array clears it. All lines must use the same set when analytical splitting is disabled.",
                          "items": {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                              "fieldId": {
                                "type": "string",
                                "description": "ID of the analytical field.",
                                "example": "field_001"
                              },
                              "valueId": {
                                "type": "string",
                                "description": "ID of the analytical field value.",
                                "example": "val_abc"
                              }
                            },
                            "required": [
                              "fieldId",
                              "valueId"
                            ]
                          }
                        }
                      },
                      "required": [
                        "grossAmount",
                        "expenseAccountId",
                        "taxAccountId",
                        "costCenterId",
                        "analyticalFieldValues"
                      ]
                    }
                  },
                  "amortisation": {
                    "type": "object",
                    "additionalProperties": false,
                    "description": "Prepaid-expense amortisation period to apply to the Payable.",
                    "properties": {
                      "startDate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date in the `YYYY-MM-DD` format."
                      },
                      "endDate": {
                        "type": "string",
                        "format": "date",
                        "description": "Date in the `YYYY-MM-DD` format."
                      }
                    },
                    "required": [
                      "startDate",
                      "endDate"
                    ]
                  }
                },
                "required": [
                  "version"
                ],
                "minProperties": 2,
                "errorMessage": {
                  "minProperties": "must include at least one of description, accountPayableId, accountingDate, lineItems or amortisation"
                }
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string",
              "format": "uuid",
              "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$"
            },
            "example": "bc9cef35-401d-4ea4-b384-ed725e6685cf",
            "in": "path",
            "name": "id",
            "required": true,
            "description": "The ID of the Payable"
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "header",
            "name": "X-Company-Id",
            "required": false,
            "description": "ID of the company the request acts on. Required with an organisation-level token; not needed with a company-level token."
          }
        ],
        "security": [
          {
            "Authentication": [
              "experimental:accounting:update"
            ]
          }
        ],
        "x-roles": [
          "controller",
          "accountOwner"
        ],
        "responses": {
          "200": {
            "description": "Default Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": false,
                  "properties": {
                    "item": {
                      "type": "object",
                      "additionalProperties": false,
                      "properties": {
                        "id": {
                          "type": "string",
                          "format": "uuid",
                          "description": "The ID of the Payable",
                          "pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$",
                          "example": "bc9cef35-401d-4ea4-b384-ed725e6685cf"
                        },
                        "version": {
                          "type": "number",
                          "description": "The updated Payable version."
                        },
                        "bookkeepingStatus": {
                          "type": "string",
                          "description": "The updated bookkeeping status of the Payable."
                        }
                      },
                      "required": [
                        "id",
                        "version",
                        "bookkeepingStatus"
                      ]
                    }
                  },
                  "required": [
                    "item"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Bad request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/badRequest"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/unauthorized"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/forbiddenControllerRoleRequired"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/notFound"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/conflict"
                }
              }
            }
          },
          "413": {
            "description": "Payload Too Large",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/tooLarge"
                }
              }
            }
          },
          "415": {
            "description": "Unsupported Media Type",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/unsupportedMediaType"
                }
              }
            }
          },
          "422": {
            "description": "Default Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": false,
                  "properties": {
                    "reason": {
                      "type": "string",
                      "description": "The payable state is incompatible with this update.",
                      "example": "invalidState"
                    }
                  },
                  "required": [
                    "reason"
                  ]
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "headers": {
              "retry-after": {
                "schema": {
                  "type": "integer"
                },
                "description": "Seconds to wait before retrying the request."
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/tooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/internalServerError"
                }
              }
            }
          },
          "503": {
            "description": "Service Unavailable",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/serviceUnavailableError"
                }
              }
            }
          }
        }
      }
    }
  },
  "servers": [
    {
      "url": "https://public-api.spendesk.com",
      "description": "Production"
    },
    {
      "url": "https://public-api.demo.spendesk.com",
      "description": "Sandbox"
    }
  ],
  "webhooks": {
    "payables-created": {
      "post": {
        "requestBody": {
          "description": "Event linking to a newly created payable. Use `/v1/payables/{id}` to get the full details.",
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/webhookPayable"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Return a 2xx status to indicate that the data was received successfully"
          }
        }
      }
    },
    "payables-prepared": {
      "post": {
        "requestBody": {
          "description": "Event linking to a payable that has been prepared (`eventType` is `prepared`). Use `/v1/payables/{id}` to get the full details.",
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/webhookPayable"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Return a 2xx status to indicate that the data was received successfully"
          }
        }
      }
    },
    "settlement-created": {
      "post": {
        "requestBody": {
          "description": "Event linking to a newly created settlement. Use `/v1/settlements` to get the full details by filtering by id.",
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/webhookSettlement"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Return a 2xx status to indicate that the data was received successfully"
          }
        }
      }
    }
  },
  "tags": [
    {
      "name": "Payables",
      "description": "Payables — invoices, credit notes, card purchases and expense claims — with their attachments. Retrieve them in bulk through snapshots, search them, read one by ID; experimental endpoints let accounting integrations update accounting fields, mark payables ready and write their bookkeeping status back. Part of: [Retrieving Spend Data](/reference/retrieving-snapshots-of-payables), [Building an accounting integration](/reference/building-an-accounting-integration)."
    }
  ]
}
```