From dc91cb71f46b7e473f42c0648bca59b1bc57b9c1 Mon Sep 17 00:00:00 2001 From: Benjamin Collins Date: Fri, 20 Oct 2023 04:05:47 +0900 Subject: [PATCH] feat: add items shipped --- .../credentials/EInvoiceCredential.yml | 123 +++++++++++++++++- 1 file changed, 122 insertions(+), 1 deletion(-) diff --git a/docs/openapi/components/schemas/credentials/EInvoiceCredential.yml b/docs/openapi/components/schemas/credentials/EInvoiceCredential.yml index 210e96c5d..230d8041a 100644 --- a/docs/openapi/components/schemas/credentials/EInvoiceCredential.yml +++ b/docs/openapi/components/schemas/credentials/EInvoiceCredential.yml @@ -197,7 +197,10 @@ properties: additionalProperties: false required: - type + - linkedDocuments - buyer + - consignee + - itemsShipped type: object properties: type: @@ -211,6 +214,36 @@ properties: type: string enum: - Invoice + linkedDocuments: + title: Documents Linked or Referenced + description: References to other documents which can be used to support the claims of the current document + type: array + minItems: 0 + maxItems: 10 + items: + type: object + additionalProperties: false + required: + - type + - documentId + - documentType + properties: + type: + const: LinkedDocument + default: LinkedDocument + documentId: + title: Document Identifier + description: The Identifier of the document being referenced + type: string + documentType: + title: Document Type + description: The type of the document being referenced + type: enum + - MillTestReport + - PurchaseOrder + - PackingList + - BillOfLading + - CertificationOfOrigin buyer: title: Buyer description: Importer of record. Party placing the order or paying the invoice. @@ -421,6 +454,65 @@ properties: - type minItems: 0 maxItems: 1 + itemsShipped: + title: Items Shipped + description: Itemized list of shipped goods. + type: array + items: + type: object + additionalProperties: false + properties: + type: + type: array + readOnly: true + const: + - TradeLineItem + default: + - TradeLineItem + items: + type: string + enum: + - TradeLineItem + name: + title: Name + description: Name of the Tradeline item. + type: string + description: + title: Description of product + type: string + productIdentifier: + title: Product Identifier + description: The product identifier, such as ISBN. + type: string + price: + title: Price + description: >- + The offer price of a product, or of a price component when attached to + PriceSpecification and its subtypes. + type: number + priceCurrency: + title: Price Currency + description: >- + The currency of the price, or a price component when attached to + PriceSpecification and its subtypes. + type: string + netWeight: + title: Trade Line Item Net Weight + description: A measure of the net weight (mass). + type: number + netWeightUnit: + title: Net Weight Unit + description: Unit of measurement for Mass + enum: + - gram + - kilogram + - tonne + - pounds + additionalProperties: false + required: + - type + minItems: 1 + maxItems: 1000 proof: title: proof description: A JSON Web Signature proof for a credential as defined by the VC data model @@ -468,7 +560,24 @@ example: |- "type": [ "Organization" ], - "id": "did:web:prime-steel.example.com", + "linkedDocuments" : [ + { + "type": "LinkedDocument", + "documentId": "a5d1ca6c-2c06-4039-9ff9-a75d7a695c8d", + "documentType": "PurchaseOrder" + }, + { + "type": "LinkedDocument", + "documentId": "63153", + "documentType": "MillTestReport" + }, + { + "type": "LinkedDocument", + "documentId": "63153", + "documentType": "CertificationOfOrigin" + } + ], + "id": "urn:uuid:9dae7ea0-25f7-4a59-b95d-8a5599a40311", "name": "American Prime Steel Inc.", "location": { "type": [ @@ -549,6 +658,18 @@ example: |- } } } + ], + "itemsShipped" : [ + { + "type": "TradeLineItem", + "name": "Rebar", + "description": "Round Rebar used for Construction", + "productIdentifier": "rn19082-a", + "price": 1000, + "priceCurrency": "USD", + "netWeight": 1, + "netWeightUnit": "tonne" + } ] } } \ No newline at end of file