Skip to content

Commercial Invoice

A commercial document which consists of an itemised account of goods or services delivered, together with a demand for payment.

KTDDE Requirements

https://www.digitalizetrade.org/ktdde/trade-documents/INV

This schema is based on the data elements defined here.

Data Model

CommercialInvoice<<vtd-core.VerifiableCredential>>issuer:PartyissuanceDate:DateTimecredentialSubject:CredentialSubjectvtd-core.CredentialSubject:CredentialSubjectCredentialSubjectinvoiceNumber:TextcontractNumber:Textamount:Decimalcurrency:Textbuyer:vtd-core.Partyseller:vtd-core.Partyattr:Textattr2:Texttest:SampleClassSampleClassattr:Text

Example

{
  "issuer": {
    "id": "https://jargon.sh",
    "address": {
      "street": "The quick brown fox jumps over the lazy dog.",
      "city": "The quick brown fox jumps over the lazy dog.",
      "state": "The quick brown fox jumps over the lazy dog.",
      "zip": 12345
    }
  },
  "issuanceDate": "1970-01-01T00:00:00Z",
  "credentialSubject": {},
  "vtd-core.CredentialSubject": {
    "invoiceNumber": "The quick brown fox jumps over the lazy dog.",
    "contractNumber": "The quick brown fox jumps over the lazy dog.",
    "amount": 3.141579,
    "currency": "The quick brown fox jumps over the lazy dog.",
    "buyer": {
      "id": "https://jargon.sh",
      "address": {
        "street": "The quick brown fox jumps over the lazy dog.",
        "city": "The quick brown fox jumps over the lazy dog.",
        "state": "The quick brown fox jumps over the lazy dog.",
        "zip": 12345
      }
    },
    "seller": {
      "id": "https://jargon.sh",
      "address": {
        "street": "The quick brown fox jumps over the lazy dog.",
        "city": "The quick brown fox jumps over the lazy dog.",
        "state": "The quick brown fox jumps over the lazy dog.",
        "zip": 12345
      }
    },
    "attr": "The quick brown fox jumps over the lazy dog.",
    "attr2": "The quick brown fox jumps over the lazy dog.",
    "test": {
      "attr": "The quick brown fox jumps over the lazy dog."
    }
  }
}

Schema

{
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "issuer": {
      "$ref": "#/$defs/Party",
      "description": ""
    },
    "issuanceDate": {
      "type": "string",
      "format": "date-time",
      "description": ""
    },
    "credentialSubject": {
      "$ref": "#/$defs/CredentialSubject",
      "description": ""
    },
    "vtd-core.CredentialSubject": {
      "$ref": "#/$defs/CredentialSubject",
      "description": ""
    }
  },
  "description": "",
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$defs": {
    "Party": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "type": {
          "type": "string",
          "default": "Party",
          "enum": [
            "Party"
          ]
        },
        "id": {
          "type": "string",
          "format": "uri",
          "description": "A unique number that identifies a customer"
        },
        "address": {
          "$ref": "#/$defs/Address",
          "description": "The shipping address for the customer where they would like their orders delivered"
        }
      },
      "description": ""
    },
    "Address": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "street": {
          "type": "string",
          "description": "The street component of the address"
        },
        "city": {
          "type": "string",
          "description": "The city compomnent of the address"
        },
        "state": {
          "type": "string",
          "description": "The state component of the address"
        },
        "zip": {
          "type": "number",
          "description": "Zip or postal code for the address"
        }
      },
      "description": ""
    },
    "CredentialSubject": {
      "type": "object",
      "additionalProperties": false,
      "properties": {},
      "description": ""
    }
  }
}