Skip to Content

UpdateInvoiceStatus

PATCH
/billing/v1/invoices/{invoice_id}/status

Authorization

headerX-API-Key<token>

API key for protected endpoints, supplied in the X-API-Key header.

Path Parameters

invoice_id*invoice_id
Match^[0-9A-Za-z]+$

Request Body

required
application/json
{
  "type": "object",
  "properties": {
    "status": {
      "examples": [
        "INVOICE_STATUS_PAID"
      ],
      "title": "status",
      "$ref": "#/components/schemas/billing.v1.InvoiceStatus",
      "$ref-value": {
        "type": "string",
        "title": "InvoiceStatus",
        "enum": [
          "INVOICE_STATUS_UNSPECIFIED",
          "INVOICE_STATUS_DRAFT",
          "INVOICE_STATUS_OPEN",
          "INVOICE_STATUS_PAID",
          "INVOICE_STATUS_VOID",
          "INVOICE_STATUS_UNCOLLECTIBLE"
        ]
      }
    }
  },
  "title": "UpdateInvoiceStatusRequest",
  "additionalProperties": false
}
status?unknown

Response Body

200application/json

Success

type: unknown

{
  "$ref": "#/components/schemas/billing.v1.Invoice",
  "$ref-value": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "examples": [
          "Z9Y8X7W6V5"
        ],
        "title": "id"
      },
      "org_id": {
        "type": "string",
        "examples": [
          "OR98234j23"
        ],
        "title": "org_id"
      },
      "subscription_id": {
        "type": "string",
        "examples": [
          "AbCdE12345"
        ],
        "title": "subscription_id"
      },
      "amount": {
        "type": "string",
        "examples": [
          "29.99"
        ],
        "title": "amount"
      },
      "currency": {
        "type": "string",
        "examples": [
          "usd"
        ],
        "title": "currency"
      },
      "status": {
        "examples": [
          "INVOICE_STATUS_PAID"
        ],
        "title": "status",
        "$ref": "#/components/schemas/billing.v1.InvoiceStatus",
        "$ref-value": {
          "type": "string",
          "title": "InvoiceStatus",
          "enum": [
            "INVOICE_STATUS_UNSPECIFIED",
            "INVOICE_STATUS_DRAFT",
            "INVOICE_STATUS_OPEN",
            "INVOICE_STATUS_PAID",
            "INVOICE_STATUS_VOID",
            "INVOICE_STATUS_UNCOLLECTIBLE"
          ]
        }
      },
      "due_date": {
        "examples": [
          "2026-01-15T10:30:00Z"
        ],
        "title": "due_date",
        "$ref": "#/components/schemas/google.protobuf.Timestamp",
        "$ref-value": {
          "type": "string",
          "examples": [
            "2023-01-15T01:30:15.01Z",
            "2024-12-25T12:00:00Z"
          ],
          "format": "date-time",
          "description": "A point in time in RFC 3339 format, with up to nanosecond precision. Output uses UTC (`Z`); input may use an offset from UTC."
        }
      },
      "paid_at": {
        "examples": [
          "2026-01-15T10:30:00Z"
        ],
        "title": "paid_at",
        "$ref": "#/components/schemas/google.protobuf.Timestamp",
        "$ref-value": {
          "type": "string",
          "examples": [
            "2023-01-15T01:30:15.01Z",
            "2024-12-25T12:00:00Z"
          ],
          "format": "date-time",
          "description": "A point in time in RFC 3339 format, with up to nanosecond precision. Output uses UTC (`Z`); input may use an offset from UTC."
        }
      },
      "created_at": {
        "examples": [
          "2026-01-15T10:30:00Z"
        ],
        "title": "created_at",
        "$ref": "#/components/schemas/google.protobuf.Timestamp",
        "$ref-value": {
          "type": "string",
          "examples": [
            "2023-01-15T01:30:15.01Z",
            "2024-12-25T12:00:00Z"
          ],
          "format": "date-time",
          "description": "A point in time in RFC 3339 format, with up to nanosecond precision. Output uses UTC (`Z`); input may use an offset from UTC."
        }
      },
      "description": {
        "type": "string",
        "title": "description"
      }
    },
    "title": "Invoice",
    "additionalProperties": false
  }
}
default
curl -X PATCH 'https://api.rixl.com/billing/v1/invoices/Z9Y8X7W6V5/status'

Success

application/json

{
  "$ref": "#/components/schemas/billing.v1.Invoice",
  "$ref-value": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "examples": [
          "Z9Y8X7W6V5"
        ],
        "title": "id"
      },
      "org_id": {
        "type": "string",
        "examples": [
          "OR98234j23"
        ],
        "title": "org_id"
      },
      "subscription_id": {
        "type": "string",
        "examples": [
          "AbCdE12345"
        ],
        "title": "subscription_id"
      },
      "amount": {
        "type": "string",
        "examples": [
          "29.99"
        ],
        "title": "amount"
      },
      "currency": {
        "type": "string",
        "examples": [
          "usd"
        ],
        "title": "currency"
      },
      "status": {
        "examples": [
          "INVOICE_STATUS_PAID"
        ],
        "title": "status",
        "$ref": "#/components/schemas/billing.v1.InvoiceStatus",
        "$ref-value": {
          "type": "string",
          "title": "InvoiceStatus",
          "enum": [
            "INVOICE_STATUS_UNSPECIFIED",
            "INVOICE_STATUS_DRAFT",
            "INVOICE_STATUS_OPEN",
            "INVOICE_STATUS_PAID",
            "INVOICE_STATUS_VOID",
            "INVOICE_STATUS_UNCOLLECTIBLE"
          ]
        }
      },
      "due_date": {
        "examples": [
          "2026-01-15T10:30:00Z"
        ],
        "title": "due_date",
        "$ref": "#/components/schemas/google.protobuf.Timestamp",
        "$ref-value": {
          "type": "string",
          "examples": [
            "2023-01-15T01:30:15.01Z",
            "2024-12-25T12:00:00Z"
          ],
          "format": "date-time",
          "description": "A point in time in RFC 3339 format, with up to nanosecond precision. Output uses UTC (`Z`); input may use an offset from UTC."
        }
      },
      "paid_at": {
        "examples": [
          "2026-01-15T10:30:00Z"
        ],
        "title": "paid_at",
        "$ref": "#/components/schemas/google.protobuf.Timestamp",
        "$ref-value": {
          "type": "string",
          "examples": [
            "2023-01-15T01:30:15.01Z",
            "2024-12-25T12:00:00Z"
          ],
          "format": "date-time",
          "description": "A point in time in RFC 3339 format, with up to nanosecond precision. Output uses UTC (`Z`); input may use an offset from UTC."
        }
      },
      "created_at": {
        "examples": [
          "2026-01-15T10:30:00Z"
        ],
        "title": "created_at",
        "$ref": "#/components/schemas/google.protobuf.Timestamp",
        "$ref-value": {
          "type": "string",
          "examples": [
            "2023-01-15T01:30:15.01Z",
            "2024-12-25T12:00:00Z"
          ],
          "format": "date-time",
          "description": "A point in time in RFC 3339 format, with up to nanosecond precision. Output uses UTC (`Z`); input may use an offset from UTC."
        }
      },
      "description": {
        "type": "string",
        "title": "description"
      }
    },
    "title": "Invoice",
    "additionalProperties": false
  }
}