{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/unit-co/main/json-schema/unit-co-create-payment-request-schema.json",
  "title": "CreatePaymentRequest",
  "x-generated": "2026-10-12",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/unit-co-payments-api-openapi.yml#/components/schemas/CreatePaymentRequest",
  "type": "object",
  "required": [
    "data"
  ],
  "properties": {
    "data": {
      "type": "object",
      "required": [
        "type",
        "attributes"
      ],
      "properties": {
        "type": {
          "type": "string",
          "enum": [
            "bookPayment",
            "achPayment",
            "wirePayment"
          ]
        },
        "attributes": {
          "type": "object",
          "properties": {
            "amount": {
              "type": "integer",
              "description": "Amount in cents."
            },
            "direction": {
              "type": "string",
              "enum": [
                "Credit",
                "Debit"
              ]
            },
            "description": {
              "type": "string"
            },
            "idempotencyKey": {
              "type": "string"
            }
          }
        }
      }
    }
  }
}