Skip to content

Commit

Permalink
Updating schema documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
samlown committed Jul 19, 2024
1 parent fb8877c commit 05e4709
Show file tree
Hide file tree
Showing 9 changed files with 76 additions and 73 deletions.
26 changes: 13 additions & 13 deletions draft-0/bill/charge.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,17 @@ Charge represents a surchange applied to the complete document independent from

## Properties

| Title | Property | Type | Req. | Description |
|-------------|-----------|-------------------------------------------|------|-------------------------------------------------------------------------------------------------------------------------------------------|
| UUID | `uuid` | string | | Universally Unique Identifier. |
| Key | `key` | [cbc.Key](/draft-0/cbc/key) | | Key for grouping or identifying charges for tax purposes. |
| Index | `i` | integer | | Line number inside the list of charges (calculated). |
| Reference | `ref` | string | | Code to used to refer to the this charge |
| Base | `base` | [num.Amount](/draft-0/num/amount) | | Base represents the value used as a base for percent calculations. If not already provided, we'll take the invoices sum before discounts. |
| Percent | `percent` | [num.Percentage](/draft-0/num/percentage) | | Percentage to apply to the invoice's Sum |
| Amount | `amount` | [num.Amount](/draft-0/num/amount) | | Amount to apply (calculated if percent present) |
| Taxes | `taxes` | [tax.Set](/draft-0/tax/set) | | List of taxes to apply to the charge |
| Reason Code | `code` | string | | Code for why was this charge applied? |
| Reason | `reason` | string | | Text description as to why the charge was applied |
| Meta | `meta` | [cbc.Meta](/draft-0/cbc/meta) | | Additional semi-structured information. |
| Title | Property | Type | Req. | Description |
|-------------|-----------|-------------------------------------------|------|----------------------------------------------------------------------------------------------------------|
| UUID | `uuid` | string | | Universally Unique Identifier. |
| Key | `key` | [cbc.Key](/draft-0/cbc/key) | | Key for grouping or identifying charges for tax purposes. |
| Index | `i` | integer | | Line number inside the list of charges (calculated). |
| Reference | `ref` | string | | Code to used to refer to the this charge |
| Base | `base` | [num.Amount](/draft-0/num/amount) | | Base represents the value used as a base for percent calculations instead of the invoice's sum of lines. |
| Percent | `percent` | [num.Percentage](/draft-0/num/percentage) | | Percentage to apply to the Base or Invoice Sum |
| Amount | `amount` | [num.Amount](/draft-0/num/amount) | | Amount to apply (calculated if percent present) |
| Taxes | `taxes` | [tax.Set](/draft-0/tax/set) | | List of taxes to apply to the charge |
| Reason Code | `code` | string | | Code for why was this charge applied? |
| Reason | `reason` | string | | Text description as to why the charge was applied |
| Meta | `meta` | [cbc.Meta](/draft-0/cbc/meta) | | Additional semi-structured information. |

1 change: 1 addition & 0 deletions draft-0/bill/correction_options.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ CorrectionOptions defines a structure used to pass configuration options to corr
|------------|--------------|--------------------------------------------|------|-------------------------------------------------------------------|
| Type | `type` | [cbc.Key](/draft-0/cbc/key) | true | The type of corrective invoice to produce. |
| Issue Date | `issue_date` | [cal.Date](/draft-0/cal/date) | | When the new corrective invoice's issue date should be set to. |
| Series | `series` | string | | Series to assign to the new corrective invoice. |
| Stamps | `stamps` | array of [head.Stamp](/draft-0/head/stamp) | | Stamps of the previous document to include in the preceding data. |
| Reason | `reason` | string | | Human readable reason for the corrective operation. |
| Extensions | `ext` | [tax.Extensions](/draft-0/tax/extensions) | | Extensions for region specific requirements. |
Expand Down
24 changes: 12 additions & 12 deletions draft-0/bill/discount.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,16 @@ Discount represents an allowance applied to the complete document independent fr

## Properties

| Title | Property | Type | Req. | Description |
|-------------|-----------|-------------------------------------------|------|--------------------------------------------------------------------------------------------------------------------------|
| UUID | `uuid` | string | | Universally Unique Identifier. |
| Index | `i` | integer | | Line number inside the list of discounts (calculated) |
| Reference | `ref` | string | | Reference or ID for this Discount |
| Base | `base` | [num.Amount](/draft-0/num/amount) | | Base represents the value used as a base for percent calculations. If not already provided, we'll take the invoices sum. |
| Percent | `percent` | [num.Percentage](/draft-0/num/percentage) | | Percentage to apply to the invoice's Sum. |
| Amount | `amount` | [num.Amount](/draft-0/num/amount) | | Amount to apply (calculated if percent present). |
| Taxes | `taxes` | [tax.Set](/draft-0/tax/set) | | List of taxes to apply to the discount |
| Reason Code | `code` | string | | Code for the reason this discount applied |
| Reason | `reason` | string | | Text description as to why the discount was applied |
| Meta | `meta` | [cbc.Meta](/draft-0/cbc/meta) | | Additional semi-structured information. |
| Title | Property | Type | Req. | Description |
|-------------|-----------|-------------------------------------------|------|----------------------------------------------------------------------------------------------------------|
| UUID | `uuid` | string | | Universally Unique Identifier. |
| Index | `i` | integer | | Line number inside the list of discounts (calculated) |
| Reference | `ref` | string | | Reference or ID for this Discount |
| Base | `base` | [num.Amount](/draft-0/num/amount) | | Base represents the value used as a base for percent calculations instead of the invoice's sum of lines. |
| Percent | `percent` | [num.Percentage](/draft-0/num/percentage) | | Percentage to apply to the base or invoice's sum. |
| Amount | `amount` | [num.Amount](/draft-0/num/amount) | | Amount to apply (calculated if percent present). |
| Taxes | `taxes` | [tax.Set](/draft-0/tax/set) | | List of taxes to apply to the discount |
| Reason Code | `code` | string | | Code for the reason this discount applied |
| Reason | `reason` | string | | Text description as to why the discount was applied |
| Meta | `meta` | [cbc.Meta](/draft-0/cbc/meta) | | Additional semi-structured information. |

35 changes: 18 additions & 17 deletions draft-0/org/party.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -11,21 +11,22 @@ Party represents a person or business entity.

## Properties

| Title | Property | Type | Req. | Description |
|-------------------|----------------|--------------------------------------------------|------|-------------------------------------------------------------------------------------------------------------------------------------------|
| UUID | `uuid` | string | | Universally Unique Identifier. |
| Name | `name` | string | true | Legal name or representation of the organization. |
| Alias | `alias` | string | | Alternate short name. |
| Tax Identity | `tax_id` | [tax.Identity](/draft-0/tax/identity) | | The entity's legal ID code used for tax purposes. They may have other numbers, but we're only interested in those valid for tax purposes. |
| Identities | `identities` | array of [org.Identity](/draft-0/org/identity) | | Set of codes used to identify the party in other systems. |
| People | `people` | array of [org.Person](/draft-0/org/person) | | Details of physical people who represent the party. |
| Inboxes | `inboxes` | array of [org.Inbox](/draft-0/org/inbox) | | Digital inboxes used for forwarding electronic versions of documents |
| Postal Addresses | `addresses` | array of [org.Address](/draft-0/org/address) | | Regular post addresses for where information should be sent if needed. |
| Email Addresses | `emails` | array of [org.Email](/draft-0/org/email) | | Electronic mail addresses |
| Websites | `websites` | array of [org.Website](/draft-0/org/website) | | Public websites that provide further information about the party. |
| Telephone Numbers | `telephones` | array of [org.Telephone](/draft-0/org/telephone) | | Regular telephone numbers |
| Registration | `registration` | [org.Registration](/draft-0/org/registration) | | Additional registration details about the company that may need to be included in a document. |
| Logos | `logos` | array of [org.Image](/draft-0/org/image) | | Images that can be used to identify the party visually. |
| Ext | `ext` | [tax.Extensions](/draft-0/tax/extensions) | | Extension code map for any additional regime specific codes that may be required. |
| Meta | `meta` | [cbc.Meta](/draft-0/cbc/meta) | | Any additional semi-structured information that does not fit into the rest of the party. |
| Title | Property | Type | Req. | Description |
|-------------------|----------------|--------------------------------------------------|------|------------------------------------------------------------------------------------------------------------------------------------------------|
| UUID | `uuid` | string | | Universally Unique Identifier. |
| Name | `name` | string | true | Legal name or representation of the organization. |
| Alias | `alias` | string | | Alternate short name. |
| Label | `label` | string | | Label can be used to provide a custom label for the party in a given context in a single language, for example "Supplier", "Host", or similar. |
| Tax Identity | `tax_id` | [tax.Identity](/draft-0/tax/identity) | | The entity's legal ID code used for tax purposes. They may have other numbers, but we're only interested in those valid for tax purposes. |
| Identities | `identities` | array of [org.Identity](/draft-0/org/identity) | | Set of codes used to identify the party in other systems. |
| People | `people` | array of [org.Person](/draft-0/org/person) | | Details of physical people who represent the party. |
| Inboxes | `inboxes` | array of [org.Inbox](/draft-0/org/inbox) | | Digital inboxes used for forwarding electronic versions of documents |
| Postal Addresses | `addresses` | array of [org.Address](/draft-0/org/address) | | Regular post addresses for where information should be sent if needed. |
| Email Addresses | `emails` | array of [org.Email](/draft-0/org/email) | | Electronic mail addresses |
| Websites | `websites` | array of [org.Website](/draft-0/org/website) | | Public websites that provide further information about the party. |
| Telephone Numbers | `telephones` | array of [org.Telephone](/draft-0/org/telephone) | | Regular telephone numbers |
| Registration | `registration` | [org.Registration](/draft-0/org/registration) | | Additional registration details about the company that may need to be included in a document. |
| Logos | `logos` | array of [org.Image](/draft-0/org/image) | | Images that can be used to identify the party visually. |
| Ext | `ext` | [tax.Extensions](/draft-0/tax/extensions) | | Extension code map for any additional regime specific codes that may be required. |
| Meta | `meta` | [cbc.Meta](/draft-0/cbc/meta) | | Any additional semi-structured information that does not fit into the rest of the party. |

1 change: 1 addition & 0 deletions draft-0/org/registration.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,5 @@ Registration is used in countries that require additional information to be asso
| Section | `section` | string | | |
| Page | `page` | string | | |
| Entry | `entry` | string | | |
| Other | `other` | string | | |

Loading

0 comments on commit 05e4709

Please sign in to comment.