Patch · Schema

Patch Order

A carbon credit or removal order placed through the Patch API.

ClimateCarbon CreditsCarbon RemovalOffsetsAPI-FirstEmbedded ClimateMarketplaceSustainabilityOpenAPISDKs

Properties

Name Type Description
id string
created_at string
production boolean
state string
amount integer Total mass in grams.
unit string
price integer Subtotal in minor currency units.
patch_fee integer
currency string
registry_url stringnull
metadata object
issued_to object
line_items array
View JSON Schema on GitHub

JSON Schema

patch-io-order-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/patch-io/main/json-schema/patch-io-order-schema.json",
  "title": "Patch Order",
  "description": "A carbon credit or removal order placed through the Patch API.",
  "type": "object",
  "required": ["id", "state"],
  "properties": {
    "id": { "type": "string" },
    "created_at": { "type": "string", "format": "date-time" },
    "production": { "type": "boolean" },
    "state": {
      "type": "string",
      "enum": ["draft", "placed", "processing", "complete", "cancelled"]
    },
    "amount": { "type": "integer", "description": "Total mass in grams." },
    "unit": { "type": "string" },
    "price": { "type": "integer", "description": "Subtotal in minor currency units." },
    "patch_fee": { "type": "integer" },
    "currency": { "type": "string" },
    "registry_url": { "type": ["string", "null"], "format": "uri" },
    "metadata": { "type": "object", "additionalProperties": true },
    "issued_to": {
      "type": "object",
      "properties": {
        "name": { "type": "string" },
        "email": { "type": "string", "format": "email" }
      }
    },
    "line_items": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": { "type": "string" },
          "vintage_year": { "type": ["integer", "null"] },
          "amount": { "type": "integer" },
          "unit": { "type": "string" },
          "price": { "type": "integer" },
          "currency": { "type": "string" },
          "project": {
            "type": "object",
            "properties": {
              "id": { "type": "string" },
              "name": { "type": "string" }
            }
          }
        }
      }
    }
  }
}