# Create an Invoice

## Request URL

```
POST: {{HOST}}/invoicing/v1/invoice
```

## Request Headers

```
X-Cleartax-AuthToken: {{USER_AUTH_TOKEN}}
gstin: {{gstin_number}}
pan: {{pan_number}}
branch: {{branch_name}}
vendor: {{vendor_name}}
creator-pan: {{pan_number}}
```

| PARAMETER             | DESCRIPTION                                                                                                                    | EXAMPLE VALUE                         |
| --------------------- | ------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------- |
| X-Cleartax-Auth-Token | Mandatory. The auth token generated from ClearTax user id and password.                                                        | 208c5df0-b252-4271-a23d- 61b384b58bfc |
| gstin                 | Mandatory. GSTIN number (Should be Empty for Cash Memo). GSTIN should be same as Seller GSTIN                                  | 29AAFCD5862R000                       |
| pan                   | Optional. PAN number                                                                                                           | AAFCD5862R                            |
| branch                | Optional. Branch Name                                                                                                          | Bangalore                             |
| vendor                | Conditional. For invoice generation on behalf of Vendors. Should be empty for Self generating Invoices                         | Vendor Name                           |
| creator-pan           | Conditional. Pan number of business entity that is creating invoices for vendors. Should be empty for Self generating Invoices | PAN number for creator                |

## Request Payload Schema

<table><thead><tr><th width="228.65188300984806">PARAMETER</th><th width="155">PARAMETER TYPE</th><th>DESCRIPTION</th></tr></thead><tbody><tr><td>documentDetails</td><td>Object</td><td>Mandatory. This section includes parameters such as type of document, e-commerce provider’s GSTIN, tax currency code, timestamp,etc.</td></tr><tr><td>sellerDetails</td><td>Object</td><td>Mandatory. This section includes parameters such as the name of the seller, GSTIN, contact details, the logo of the seller’s business, etc.</td></tr><tr><td>dispatchDetails</td><td>Object</td><td>Optional. This section includes parameters such as the details of the person who dispatches the goods.</td></tr><tr><td>buyerDetails</td><td>Object</td><td>Conditional. Buyer details object. Mandatory for Non-B2C transactions and Cash Memo. This section includes parameters such as the name of the buyer, GSTIN, contact details, place of supply, etc.</td></tr><tr><td>shippingDetails</td><td>Object</td><td>Optional. This section includes the details of the person to whom the goods are to be shipped.</td></tr><tr><td>exportDetails</td><td>Object</td><td><p>Optional. Export details object. This section includes parameters such as export duty, export country code/port code, shipping details, etc.</p><p>It is required only in the case of exports.</p></td></tr><tr><td>additionalDiscounts</td><td>List</td><td>Optional. This section includes parameters such as the discount amount and the reason for the same. Examples for an additional discount: Target discount, festival sale discount, etc.</td></tr><tr><td>additionalCharges</td><td>List</td><td><p>Optional. This section includes parameters such as the additional charges amount and the reason for the same.</p><p>An example for additional charges would be packing charges, insurance, freight etc.</p></td></tr><tr><td>paymentInstrumentDetailsAndTerms</td><td>Object</td><td>Optional. This section includes parameters such as supplier’s bank account details, credit period, the interest rate in case of delay and other payment terms.</td></tr><tr><td>paymentReceivedDetails</td><td>List</td><td>Optional. This section includes parameters such as payer’s name, payment mode, date of payment, amount paid, etc.</td></tr><tr><td>metadata</td><td>Object</td><td>Mandatory. Additional metadata. This section includes parameters like terms and conditions for the document, notes, signature image, etc.</td></tr><tr><td>referenceDocuments</td><td>Object</td><td><p>Conditional. Details of referenced documents. This section includes parameters related to the linked documents and order reference details.</p><p>It is mandatory where credit notes, debit notes and refund notes are issued.</p></td></tr><tr><td>additionalDocumentDetails</td><td>List</td><td>Optional. This section includes parameters such as attachment type (document/URL/QR code) and description of the same.</td></tr><tr><td>lineItems</td><td>List</td><td>Mandatory. Line Items. This section includes parameters such as item serial number, item name, description, quantity, HSN code, tax rate, tax amount, etc.</td></tr><tr><td>valueDetails</td><td>Object</td><td>Optional. Total Value Details. This section includes parameters related to total value details.</td></tr><tr><td>shouldGenerateEInvoice</td><td>Boolean</td><td>Optional. This flag will be used to generate E-Invoice. If successful IRN or Payment QR Code will be returned else Error Details.</td></tr></tbody></table>

### Document Details

<table><thead><tr><th>PARAMETER</th><th>PARAMETER TYPE</th><th width="264">FIELD VALIDATIONS</th><th width="387">DESCRIPTION</th></tr></thead><tbody><tr><td>timestamp</td><td>DateTimeFormat (dd-MM-yyyy HH:mm:ss)</td><td><p>Date: minLength: 10</p><p>maxLength: 10,</p><p>pattern: "^[0-3][0-9]\-[0-1][0-9]\-[2][0][1-2][0-9]$"  <br>Time: minLength: 8<br>maxLength: 8,<br>Format: 24 hours<br><strong>Note:</strong> If time is unknown, then pass 00:00:00</p></td><td><p>Mandatory. Date and time of the creation of the Invoice is recorded here.</p><p>For eg.- 22-01-2022 02:30:45</p><p>It is proof of the moment or time that helps to know when the validity of the invoice starts.</p></td></tr><tr><td>documentType</td><td>Document Type (ENUM)</td><td>Document Type :  <a href="resources-and-master/document-types">ENUM</a></td><td><p>Mandatory. A correct document type needs to be passed here.</p><p>An invoice can be in different forms. For example, tax invoice, credit note, debit note, delivery challan, refund voucher, cash memo, advance receipt, etc.</p><p>Each type of invoice has different usage.</p><p>It is important to mention the type of document at the top to help identify it easily.</p></td></tr><tr><td>supplyType</td><td>Supply Type (ENUM)</td><td>Supply Type : <a href="resources-and-master/supply-types">ENUM</a></td><td><p>Conditional. Mandatory for non Cash Memo documents. The supply type of the transaction should be captured here.</p><p>Here are the types of supplies: </p><p>Selling goods or services to another business (B2B) </p><p>Selling goods or services to the customer (B2C) Selling goods or services to </p><p>SEZ by making GST payment </p><p>Selling goods or services to SEZ without making GST payment </p><p>Exporting goods or services by making GST payment </p><p>Exporting goods or services without making GST payment </p><p>Deemed exports </p><p>Distribution of Input Tax Credit (ITC) by Input Service Distributor (ISD) to its branches Bill of Supply</p></td></tr><tr><td>orderId</td><td>String</td><td><p>Should be unique for each document. If repeated, will be considered a duplicate request.</p><p>For example- 1001001112</p><p>Alphanumeric characters &#x26; special characters (/ . - ) are allowed.</p></td><td><p>Mandatory. OrderId. Order number or order ID is a unique number assigned to every order by the seller to keep track of it.</p><p>It is useful to the seller to identify the order placed by the customer and find details for the same order depending on the data set up in their system.</p><p>For example, if a customer places an order, the said order is assigned a unique number which is never assigned again to any other document. Even if there is a credit note or debit note for referring to the said order, the order ID of such documents will be different.</p><p>Eg: If a user issues an invoice to the customer with order id ABC and later due to some changes a credit note has to be issued against it then the order id should be different such as XYZ</p></td></tr><tr><td>documentNoPrefix</td><td>String</td><td><p>Alphabets and numbers are allowed here.</p><p>You can also use special characters- “/”, “-”.</p><p>The first character cannot be 0, “/”, “-” Prefix should end with a “/” or “-”</p><p>Min length: 1</p><p>Max length: 10</p><p>For tax invoices, the maximum allowable length for a complete invoice number is 16 characters (Prefix + Serial number)</p></td><td><p>Mandatory. Document prefix. The document prefix should be passed here. It is a tag added at the beginning of the document number. It can be letters or numbers that can help further identify the transactions.</p><p>A prefix in a document number makes them instantly recognisable.</p><p>We will add the next incremental number to the prefix to create a complete invoice number. For example, a company can choose to enter prefix RJS/for its branches in Rajasthan and prefix GJR/for its Gujarat branches,</p><p>In response, the invoice number will be RJS/456 or GJR/897</p></td></tr><tr><td>isReverseChargeApplicable</td><td>Boolean</td><td><p>The default value is False</p><p>It can be set as "True" in case of B2B invoices, B2B Credit Note and B2B Debit Note.</p></td><td>Optional. The input value will be “True” if the tax liability is payable under the reverse charge mechanism, i.e. when the liability to pay GST is on the <strong>recipient of goods or services</strong> instead of the supplier. The reverse charge is applicable only on notified categories of goods or services.</td></tr><tr><td>isIgstApplicableOnIntraState</td><td>Boolean</td><td>If “True” is selected, then note that- IGST needs to be levied irrespective of the supplier state and place of supply. Reverse charge applicability will always be “Yes”.</td><td><p>Optional. If “True” is selected, it indicates that the supply is intrastate but chargeable to IGST.</p><p>By default, it will be “False”.</p><p>For example, it will be “True” in the case of transfer of Priority Sector Lending Certificate (PSLC) by a bank to another bank under RBI regulations within the same state.</p></td></tr><tr><td>ecommerceProviderGstin</td><td>String</td><td><p>minLength: 15</p><p>maxLength: 15</p><p>pattern: "^([0-9]{2}[0-9A-Z]{13})$"<br><strong>The tax collector's GSTIN should be passed here.</strong></p></td><td><p>Optional. E-commerce Provide GSTIN. GSTIN of e-commerce provider should be tagged here.</p><p>GSTIN is a unique 15-digit unique identification number which is also called a GST registration number.</p><p>When an e-commerce provider is involved in a transaction between seller and buyer, the GSTIN of the e-commerce provider should be mentioned for TCS purposes.<br>Examples of e-commerce providers: Amazon, Flipkart, Meesho.</p></td></tr><tr><td>documentCurrencyCode</td><td>Currency Code (ENUM)</td><td>minLength: 3<br>maxLength: 3,<br>pattern : Alphabets<br><a href="resources-and-master/currency-master">ENUM</a></td><td><p>Optional. It is a three-letter alphabetic code that represents various currencies used for the transactions.</p><p>The default document currency code is “INR”.</p></td></tr><tr><td>taxCurrencyCode</td><td>Currency Code (ENUM)</td><td>minLength: 3<br>maxLength: 3,<br>pattern : Alphabets<br><a href="resources-and-master/currency-master">ENUM</a></td><td>Optional. It is a three-letter alphabetic code that represents various currencies used for the transaction. The tax currency code will always be “INR”.</td></tr><tr><td>documentPeriodDetails</td><td>Object</td><td>                -</td><td>Optional. Document Period Details. This section includes the start date and the end date for the summary invoices.</td></tr><tr><td>customFields</td><td>Custom Fields (List)</td><td>                 -</td><td>Optional. It is a section where the user can add any number of custom fields and put them in the object.</td></tr></tbody></table>

### Document Period Details

<table><thead><tr><th>PARAMETER</th><th>PARAMETER TYPE</th><th width="269">FIELD VALIDATIONS</th><th width="337">DESCRIPTION</th></tr></thead><tbody><tr><td>startDate</td><td>Date (dd-MM-yyyy)</td><td><p>Date : minLength: 10</p><p>maxLength: 10,</p><p>pattern: "^[0-3][0-9]\-[0-1][0-9]\-[2][0][1-2][0-9]$".  Future dates are not acceptable.</p><p>For Eg.- DD-MM-YYYY</p></td><td><p>Optional. Start Date for the Transaction. The start date of the invoice to be passed here.</p><p>It is the date of initiation of the transaction.</p><p>For example:</p><p>If the goods are supplied on the 1st day of the month and the invoice for the same is generated at the end of the month. Then the start date of the invoice will be the 1st day of the month.</p></td></tr><tr><td>endDate</td><td>Date (dd-MM-yyyy)</td><td><p>Date : minLength: 10</p><p>maxLength: 10,</p><p>pattern: "^[0-3][0-9]\-[0-1][0-9]\-[2][0][1-2][0-9]$". Future dates are not accepted.</p><p>For Eg.- DD-MM-YYYY</p></td><td><p>Optional. End date for the Transaction. This is the end date of a summary Invoice generated for a transaction spanning across more than one day.</p><p>Summary Invoice can be also called a consolidated invoice. It is an invoice that aggregates many transactions onto a single document, enabling a single payment each month. This is mostly followed by the enterprises who have multiple transactions with their customers in a month for which consolidating monthly transactions of the customers becomes easier.</p><p>Please note, this is not the invoice payment due date.</p></td></tr></tbody></table>

### Custom Fields

<table><thead><tr><th>PARAMETER</th><th>PARAMETER TYPE</th><th>FIELD VALIDATIONS</th><th width="439">DESCRIPTION</th></tr></thead><tbody><tr><td>name</td><td>String</td><td>               -</td><td><p>Optional. Name for the custom key. These are sample custom fields. In case the user wants to add certain information at the invoice level which should be printed on the invoice, the user can define their own custom fields and add in this object.</p><p>Eg: if a maintenance company wants to add the sq ft. area of the property on the top of the invoice</p><p>Or an insurance company wants to add the insurance number on top of the invoice.</p><p>In these cases, the user can add any number of custom fields and put them in the object.</p></td></tr><tr><td>value</td><td>String</td><td>               -</td><td>Optional. Value for the custom key.</td></tr></tbody></table>

### Seller Details

<table><thead><tr><th>PARAMETER</th><th width="249.33333333333331">PARAMETER TYPE</th><th width="261">FIELD VALIDATIONS</th><th width="333">DESCRIPTION</th></tr></thead><tbody><tr><td>tradeName</td><td>String</td><td><p>minLength: 3</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$".<br>The characters can be alphanumeric or special characters.</p></td><td><p>Optional. Trade Name. Trade name of the supplier to be passed here.</p><p>A trade name in GST is the name through which the business is normally called and the name used for advertising and marketing of the company.</p><p>Eg.- ClearTax’s legal name is Defmacro Software Pvt. Ltd. However, it is normally known by ClearTax.</p></td></tr><tr><td>legalName</td><td>String</td><td><p>minLength: 3</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"</p></td><td>Mandatory. Legal Name. The name entered at the time of the formation of the business or incorporation of the company should pass.</td></tr><tr><td>address</td><td>Address (Object)</td><td>               -</td><td>Mandatory. Address Details. This section includes parameters such as address line 1, line 2, pincode, state code, etc.</td></tr><tr><td>gstin</td><td>String</td><td><p>minLength: 15</p><p>maxLength: 15</p><p>pattern: "([0-9]{2}[0-9A-Z]{13})"</p></td><td><p>Mandatory except for Cash Memo. GSTIN. The seller’s GSTIN should be tagged here.</p><p>GSTIN is a unique 15-digit Goods and Services Tax Identification Number or GST registration number.</p><p>The dealers who are registered under the GST law are provided with the GSTIN.</p></td></tr><tr><td>pan</td><td>String</td><td><p>minLength: 10</p><p>maxLength: 10</p><p>pattern: "([0-9A-Z]{10})"</p></td><td>Optional. Seller’s Permanent Account Number (PAN) to be passed here.</td></tr><tr><td>phone</td><td>String</td><td><p>minLength: 6</p><p>maxLength: 12</p><p>pattern: "^([0-9]{6,12})$"</p></td><td>Optional. Supplier’s phone number details to be passed here.</td></tr><tr><td>email</td><td>String</td><td><p>minLength: 6</p><p>maxLength: 100</p><p>pattern: "^[a-zA-Z0-9+_.-]+@[a-zA-Z0-9.-]+$"</p></td><td>Optional. Seller’s email ID details need to be passed here. Every invoice needs the business information on it, and apart from the business name, address, and phone number, the email address of the supplier is also necessary.</td></tr><tr><td>logoImage</td><td>String</td><td> The image URL or base64 of the image is to be passed here.</td><td><p>Optional. A logo image of the supplier is to be printed on the invoice.</p><p>The logo image on the invoice helps make the document easily recognisable.</p><p>The image provided is to be printed on the PDF.</p><p>The image can be provided in 3 forms to the team:<br> A static image during onboarding will be added to the settings of user.<br>The URL of the image can be passed here.<br> Base64 of the Image</p></td></tr></tbody></table>

#### Address

<table><thead><tr><th>PARAMETER</th><th width="249.33333333333331">PARAMETER TYPE</th><th width="233">FIELD VALIDATIONS</th><th width="330">DESCRIPTION</th></tr></thead><tbody><tr><td>line1</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"</p></td><td><p>Mandatory. Address Line 1. Primary address information of the business is required here.</p><p>The document will show the first line of the address of the business in this field. If the address exceeds the maximum length, it can be continued in line 2.</p></td></tr><tr><td>line2</td><td>String</td><td><p>minLength: 3</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"</p></td><td>Optional. Address Line 2. If the address is not completed in line 1, continue it in line 2.</td></tr><tr><td>location</td><td>String</td><td><p>minLength: 3</p><p>maxLength: 50</p><p>pattern: "^([^\\\"])*$"</p></td><td>Mandatory. Location. City should be passed here.</td></tr><tr><td>pincode</td><td>String</td><td><p>minimum: 100000</p><p>maximum: 999999<br><a href="resources-and-master/pincode-master">ENUM</a></p></td><td>Mandatory. The pincode number needs to be passed here.</td></tr><tr><td>stateCode</td><td>String</td><td>            <a href="resources-and-master/state-master"> ENUM</a></td><td>Mandatory. The state code of the GSTIN needs to be passed here.</td></tr></tbody></table>

### Dispatch Details

<table><thead><tr><th>PARAMETER</th><th>PARAMETER TYPE</th><th width="249">FIELD VALIDATIONS</th><th width="318">DESCRIPTION</th></tr></thead><tbody><tr><td>gstin</td><td>String</td><td><p>minLength: 15</p><p>maxLength: 15</p><p>pattern: "([0-9]{2}[0-9A-Z]{13})"</p></td><td>Optional. GSTIN of the person dispatching the goods.</td></tr><tr><td>pan</td><td>String</td><td><p>minLength: 10</p><p>maxLength: 10</p><p>pattern: "([0-9A-Z]{10})"</p></td><td>Optional. Permanent Account Number (PAN) of the person dispatching the goods.</td></tr><tr><td>tradeName</td><td>String</td><td><p>minLength: 3</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"</p></td><td>Optional. Trade name of the entity dispatching the goods</td></tr><tr><td>legalName</td><td>String</td><td><p>minLength: 3</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"</p></td><td>Mandatory. Legal name of the entity dispatching the goods</td></tr><tr><td>address</td><td>Address (Object)</td><td>                -</td><td><p>Conditional. This section includes parameters such as address line 1, line 2, pincode, state code, etc.</p><p>This is required only if the ‘dispatch from’ address is different from the seller’s address. It is not applicable for advance receipt of the goods.</p></td></tr></tbody></table>

### Buyer Details

<table><thead><tr><th width="166.07639032121494">PARAMETER</th><th>PARAMETER TYPE</th><th width="256">FIELD VALIDATIONS</th><th width="303">DESCRIPTION</th></tr></thead><tbody><tr><td>name</td><td>String</td><td><p>minLength: 3</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"</p></td><td>Mandatory for B2B, EXPWP, EXPWOP, SEZWP, SEZWOP, DEXP<br>Optional for B2C, BOS and Cash Memo</td></tr><tr><td>tradeName</td><td>String</td><td><p>minLength: 3</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"</p></td><td>Optional. A trade name in GST is the name through which the business is normally called and the name used for advertising and marketing of the company.</td></tr><tr><td>legalName</td><td>String</td><td><p>minLength: 3</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"</p></td><td>Conditional (Mandatory for non B2C). Legal Name of the buyer. The name entered at the time of the formation of the business or incorporation of the company should pass.</td></tr><tr><td>address</td><td>Address (Object)</td><td></td><td>Conditional (Mandatory for non B2C). Address Details. This section includes parameters such as address line 1, line 2, pincode, state code, etc.</td></tr><tr><td>gstin</td><td>String</td><td><p>minLength: 15</p><p>maxLength: 15</p><p>pattern: "([0-9]{2}[0-9A-Z]{13})".<br>For export buyer’s, GSTIN should be “URP”</p></td><td>Optional. GSTIN of the buyer. GSTIN is a unique 15-digit Goods and Services Tax Identification Number or GST registration number.</td></tr><tr><td>pan</td><td>String</td><td><p>minLength: 10</p><p>maxLength: 10</p><p>pattern: "([0-9A-Z]{10})"</p></td><td>Optional. Buyer’s Permanent Account Number (PAN).</td></tr><tr><td>phone</td><td>String</td><td><p>minLength: 6</p><p>maxLength: 12</p><p>pattern: "^([0-9]{6,12})$"</p></td><td>Optional. Buyer’s phone number.</td></tr><tr><td>email</td><td>String</td><td><p>minLength: 6</p><p>maxLength: 100</p><p>pattern: "^[a-zA-Z0-9+_.-]+@[a-zA-Z0-9.-]+$"</p></td><td>Optional. Email of the buyer.</td></tr><tr><td>placeOfSupply</td><td>String</td><td>      <a href="resources-and-master/state-master">    ENUM</a></td><td><p>Mandatory . The place of supply of the goods or services should be passed here.</p><p>The place of supply of goods or services under GST decides whether the transaction should be considered as intrastate to charge CGST &#x26; SGST/UTGST or considered as interstate to charge IGST.</p></td></tr></tbody></table>

### Shipping Details

<table><thead><tr><th width="214.5173682555058">PARAMETER</th><th width="243.44307863044628">PARAMETER TYPE</th><th width="245">FIELD VALIDATIONS</th><th width="315">DESCRIPTION</th></tr></thead><tbody><tr><td>name</td><td>String</td><td><p>minLength: 3</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"</p></td><td>Optional. Name of the person to whom the goods are shipped.</td></tr><tr><td>tradeName</td><td>String</td><td><p>minLength: 3</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"</p></td><td>Optional. Trade name of the organisation shipping the goods. A trade name in GST is the name through which the business is normally called and the name used for advertising and marketing of the company.</td></tr><tr><td>legalName</td><td>String</td><td><p>minLength: 3</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"</p></td><td>Mandatory. The legal name of the person to whom the goods are shipped. The name entered at the time of the formation of the business or incorporation of the company (customer) should pass.</td></tr><tr><td>address</td><td>Address (Object)</td><td>              -</td><td><p>Conditional. This section includes parameters such as address line 1, line 2, pincode, state code, etc.</p><p>This is required only if the ‘ship to’ address is different from the buyer’s address. It is not applicable for advance receipt of the goods.</p></td></tr><tr><td>gstin</td><td>String</td><td><p>minLength: 15</p><p>maxLength: 15</p><p>pattern: "([0-9]{2}[0-9A-Z]{13})"</p></td><td>Optional. GSTIN of the person to whom the goods are shipped.</td></tr><tr><td>phone</td><td>String</td><td><p>minLength: 6</p><p>maxLength: 12</p><p>pattern: "^([0-9]{6,12})$"</p></td><td>Optional. Phone numbers of individuals who receive the shipped goods</td></tr><tr><td>pan</td><td>String</td><td><p>minLength: 10</p><p>maxLength: 10</p><p>pattern: "([0-9A-Z]{10})"</p></td><td>Optional. Permanent Account Number (PAN) of individuals who receive the shipped goods.</td></tr></tbody></table>

### Export Details

<table><thead><tr><th>PARAMETER</th><th width="249.33333333333331">PARAMETER TYPE</th><th width="252">FIELD VALIDATIONS</th><th width="282">DESCRIPTION</th></tr></thead><tbody><tr><td>countryCode</td><td>Country Code(ENUM)</td><td>minLength : 2<br>maxLength: 2,<br>pattern: "([A-Z]{2})"</td><td>Optional. Country codes need to be passed here in case the supply type is EXPWP or EXPWOP, i.e. in the case of exports. Using the country codes, one can easily find out information about a shipment and its country.</td></tr><tr><td>shippingPortCode</td><td>Shipping Port Code(ENUM)</td><td>minLength: 6<br>maxLength: 6</td><td><p>Optional. Shipping Port Code. The shipping bill is a document for customs clearance for the export of goods.</p><p>The shipping bill includes the shipping port code, shipping bill date and shipping bill number.</p><p>Exporters supplying goods with payment of IGST will need shipping bill details for claiming refund of IGST so paid.</p><p>This is because the shipping bill having GST invoice details is considered as an application for claiming a refund of IGST paid on such exports.</p></td></tr><tr><td>conversionFactor</td><td>Decimal</td><td><p> Only numbers accepted.</p><p>Decimals are allowed.</p><p>To be filled only if the supply type is “EXPWP” or “EXPWOP”.</p></td><td><p>Optional. The conversion factor means the exchange rate needs to be passed here.</p><p>The exchange rate is specified on the Bill of Export issued by Custom authorities.</p><p>If exchange rates are known, currency conversions can be done by dividing the current currency by the exchange rate.</p></td></tr><tr><td>shippingBillNumber</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 20</p><p>pattern: "^([^\\\"])*$"<br>Inputs are required only in the case of exports of goods.</p></td><td><p>Optional. The shipping bill is a document for customs clearance for the export of goods.</p><p>The shipping bill includes the shipping port code, shipping bill date and shipping bill number.</p><p>Exporters supplying goods with payment of IGST will need shipping bill details for claiming refund of IGST so paid. This is because the shipping bill with GST invoice details is considered as an application for claiming a refund of IGST paid on such exports.</p></td></tr><tr><td>shippingBillDate</td><td>Date (dd-MM-yyyy)</td><td><p>minLength: 10</p><p>maxLength: 10</p><p>pattern: "^[0-3][0-9]\-[0-1][0-9]\-[2][0][1-2][0-9]$"<br>Future dates are not acceptable.</p><p>Input is required only in the case of exports of goods.</p></td><td><p>Optional. The shipping bill date is the date mentioned on the shipping bill.</p><p>The shipping bill is an essential document required for getting customs clearance to export goods.</p><p>The shipping bill includes the shipping port code, shipping bill date and shipping bill number.</p><p>Exporters supplying goods with payment of IGST will need shipping bill details for claiming refund of IGST so paid.</p><p>This is because the shipping bill with GST invoice details is considered as an application for claiming a refund of IGST paid on such exports.</p></td></tr><tr><td>exportDuty</td><td>Decimal</td><td> Inputs are required only in the case of exports.</td><td><p>Optional. The tax levied on the export of goods is called an export duty.</p><p>The tax rate needs to be passed here.</p></td></tr></tbody></table>

### Additional Discounts

| PARAMETER | PARAMETER TYPE | FIELD VALIDATIONS   | DESCRIPTION                                                                                                                                                                        |
| --------- | -------------- | ------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| reason    | Reason         | Alpha-Numeric value | <p>Optional. The reason for additional discount given to the customer at invoice level should be passed here.</p><p>For example, target discount, festival sale discount, etc.</p> |
| amount    | Decimal        | Only Numeric        | Optional. The additional discount amount.                                                                                                                                          |

### Additional Charges

| PARAMETER | PARAMETER TYPE | FIELD VALIDATIONS   | DESCRIPTION                                                                                                                                                  |
| --------- | -------------- | ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| reason    | Reason         | Alpha-Numeric value | <p>Optional. The reason for additional charges levied to the customer should be passed here.</p><p>For example, Shipping charges or Packing Charges etc.</p> |
| amount    | Decimal        | Only Numeric        | Optional. Additional charges.                                                                                                                                |

### Payment Instrument and Terms

<table><thead><tr><th>PARAMETER</th><th width="152">PARAMETER TYPE</th><th width="248">FIELD VALIDATIONS</th><th width="323">DESCRIPTION</th></tr></thead><tbody><tr><td>accountName</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"</p></td><td><p>Optional. Name of the bank account of where the payment of the invoice would be expected should be passed here.</p><p>The bank account name mentioned in the document will enable the buyer to make payment to the correct bank account.</p></td></tr><tr><td>ifscCode</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 11</p><p>pattern: "^([^\\\"])*$"</p></td><td><p>Optional. IFSC code of the respective bank account should be entered.</p><p>The IFSC code mentioned in the document will enable the customer to make payment to the supplier in their bank account.</p></td></tr><tr><td>accountNumber</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 18</p><p>pattern: "^([^\\\"])*$"</p></td><td><p>Optional. A valid bank account number of where the payment of the invoice would be expected should be passed here.</p><p>The bank account number mentioned in the document will enable the buyer to make payment to the correct bank account.</p></td></tr><tr><td>upiId</td><td>String</td><td>yourname@bankname</td><td><p>Optional. The UPI ID of the seller should be passed here.</p><p>By sending the UPI ID, the seller sends a virtual payment address of their bank account to the customer. The customer can use the same UPI ID while making payments to the seller’s bank account.</p></td></tr><tr><td>paymentTerms</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"</p></td><td><p>Optional. The terms of payment should be entered.</p><p>Eg: Cash payments are not allowed.</p><p>Cash on Delivery.</p></td></tr><tr><td>paymentInstruction</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"<br>Eg: The amount of advance and the installment details if any.</p></td><td>Optional. Payment instructions should be passed here.</td></tr><tr><td>creditDays</td><td>Integer</td><td><p>minimum: 0</p><p>maximum: 9999</p></td><td><p>Optional. The number of credit days should be passed here.</p><p>Credit days are the number of days which the customer is allowed to wait before paying the amount of an invoice.</p></td></tr><tr><td>creditTransferTerms</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 100</p></td><td><p>Optional. The payment terms should be mentioned by the supplier.</p><p>Eg: Interest rate in case of delay in payment, payment due in advance, payment due upon receipt, etc.</p></td></tr><tr><td>directDebitTerms</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"</p></td><td>Optional. Direct debit is a procedure where sellers are allowed to automatically take funds from the bank account of buyers as per the agreed terms. If there is any ‘direct debit’ agreement between the seller and buyer, the terms of the same should be mentioned here.</td></tr></tbody></table>

### Payment Received Details

<table><thead><tr><th>PARAMETER</th><th width="157.33333333333331">PARAMETER TYPE</th><th width="241">FIELD VALIDATIONS</th><th width="333">DESCRIPTION</th></tr></thead><tbody><tr><td>payerName</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"</p></td><td>Optional. The name of the payer.</td></tr><tr><td>paymentMode</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 18</p><p>pattern: "^([^\\\"])*$"</p></td><td><p>Optional. Mode of payment should be passed here.</p><p>For Eg: Cash UPI Net Banking</p></td></tr><tr><td>paymentTransactionId</td><td>String</td><td>                 -</td><td>Optional. Payment transaction ID should be passed here.</td></tr><tr><td>paymentDate</td><td>DD-MM-YYYY</td><td><p>minLength: 10</p><p>maxLength: 10,</p><p>pattern: "^[0-3][0-9]\-[0-1][0-9]\-[2][0][1-2][0-9]$". </p></td><td>Optional. Date of payment of the supply should be passed here.</td></tr><tr><td>paidAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99</p></td><td>Optional. Amount received from the customer should be passed here.</td></tr></tbody></table>

### Invoice Metadata Details

<table><thead><tr><th width="212">PARAMETER</th><th>PARAMETER TYPE</th><th width="246">FIELD VALIDATIONS</th><th width="309">DESCRIPTION</th></tr></thead><tbody><tr><td>termsAndCondition</td><td>String</td><td></td><td>Optional. Terms and conditions for printing on the document to be passed here.</td></tr><tr><td>notes</td><td>String</td><td></td><td>Optional. Notes for the invoice should be passed here.</td></tr><tr><td>documentLinkingId</td><td>String</td><td>All documents created and linked on the “Linked Document Schema” should have the same documentLinkingId</td><td><p>Optional. For all the documents that are linked in the “Linked Document Schema” you can use this field as an alias to search for all related documents.</p><p>Eg: your company might have a Job id or Project id and all documents created against it are linked. You could use the same alias here and use it to search all documents related to that Job or Project.</p></td></tr><tr><td>signatureImage</td><td>String</td><td>The signature image should be provided</td><td><p>Optional. Signature image of the supplier should be passed here.</p><p>The image can be provided in 3 forms to the team: A static image during onboarding will be added to the settings of user. The URL of the image can be passed here. Base64 of the image.</p></td></tr><tr><td>printTemplateId</td><td>String</td><td>Note : Custom Print Template ID please reachout to ClearTax Support</td><td>Optional. You will be provided with a unique printTemplateid for your documents. Where all the information is printed on that template id. Please request the engineering team at Clear for the respective value.</td></tr></tbody></table>

### Reference Document Details

<table><thead><tr><th>PARAMETER</th><th width="150">PARAMETER TYPE</th><th width="247">FIELD VALIDATIONS</th><th width="278">DESCRIPTION</th></tr></thead><tbody><tr><td>linkedDocumentsDetails</td><td>List</td><td><p>minLength: 1<br>maxLength: 16.</p><p>It should end with "/" or "-" only.</p></td><td>Conditional. It is a conditional field. This section includes parameters related such as document type, document number and document date of the original Invoice. Mandatory for Credit Note, Debit Note and Refund Notes</td></tr><tr><td>orderReferenceDetails</td><td>List</td><td></td><td>Optional. This section includes parameters such as contract reference number, purchase order reference number, project reference number, etc.</td></tr></tbody></table>

### Linked Document Details

<table><thead><tr><th>PARAMETER</th><th width="249.33333333333331">PARAMTER TYPE</th><th width="244">FIELD VALIDATIONS</th><th width="306">DESCRIPTION</th></tr></thead><tbody><tr><td>documentNumber</td><td>String</td><td><p>minLength: 1<br>maxLength: 16.</p><p>It should end with "/" or "-" only.<br>The first letter cannot be 0, “/”, “-”.</p></td><td><p>Mandatory. The document number of the documents linked with the transaction should be passed here.</p><p>Use this field to link connected documents to each other.</p><p>Eg: Invoice 1234 could be connected to Credit Note 4567 and an Advance Voucher of 7890.</p></td></tr><tr><td>documentDate</td><td>Date (dd-MM-yyyy)</td><td><p>minLength: 10</p><p>maxLength: 10,</p><p>pattern: "^[0-3][0-9]\/[0-1][0-9]\/[2][0][1-2][0-9]$".<br>Mandatory for Credit Notes,Debit Notes and Refund Notes.</p><p>Future dates are not acceptable.</p><p>For Eg: <strong>DD-MM-YYYY</strong></p></td><td><p>Mandatory. The date of the documents linked with the transaction should be passed here.</p><p>Use this field to link connected documents to each other.</p><p>Eg: Invoice 1234 could be connected to Credit Note 4567 and an Advance Voucher of 7890.</p></td></tr><tr><td>documentType</td><td>Document Type (ENUM)</td><td>Document Type :  Invoice, Credit Note, Debit Note</td><td><p>Mandatory. The type of the document linked should be passed here.</p><p>It can be an Invoice, Cash Memo, Credit Note, etc.</p><p>Use this field to link connected documents to each other.</p><p>Eg: Invoice 1234 could be connected to Credit Note 4567 and an Advance Voucher of 7890.</p></td></tr></tbody></table>

### Order Reference Details

<table><thead><tr><th>PARAMETER</th><th width="249.33333333333331">PARAMETER TYPE</th><th width="248">FIELD VALIDATIONS</th><th width="332">DESCRIPTION</th></tr></thead><tbody><tr><td>receiptAdviceNo</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 20</p><p>pattern: "^([^\\\"])*$"<br>The characters can be alphanumeric</p></td><td>Optional. Receipt advice number of goods supplied should be passed here.</td></tr><tr><td>receiptAdviceDate</td><td>Date (dd-MM-yyyy)</td><td><p>minLength: 10</p><p>maxLength: 10</p><p>pattern: "^[0-3][0-9]\-[0-1][0-9]\-[2][0][1-2][0-9]$"</p></td><td>Optional. Receipt advice date of the goods supplied should be passed here.</td></tr><tr><td>batchReferenceNo</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 20</p><p>pattern: "^([^\\\"])*$"</p></td><td><p>Optional. The reference number of the batch of sales should be passed here.</p><p>Use this in accordance to the terminology used in your organisation. The terminology may vary so you can choose to map it according to these fields.</p></td></tr><tr><td>contractReferenceNo</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 20</p><p>pattern: "^([^\\\"])*$"</p></td><td><p>Optional. The number of the contract to be referenced should be passed here.</p><p>Use this in accordance to the terminology used in your organisation. The terminology may vary so you can choose to map it according to these fields.</p></td></tr><tr><td>otherReferenceNo</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 20</p><p>pattern: "^([^\\\"])*$"</p></td><td><p>Optional. Any other reference number of the contract to be referenced should be passed here.</p><p>Use this in accordance to the terminology used in your organisation. The terminology may vary so you can choose to map it according to these fields.</p></td></tr><tr><td>projectReferenceNo</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 20</p><p>pattern: "^([^\\\"])*$"</p></td><td><p>Optional. The project number to be referenced in the invoice should be passed here.</p><p>Use this in accordance to the terminology used in your organisation. The terminology may vary so you can choose to map it according to these fields.</p></td></tr><tr><td>poReferenceNo</td><td>String</td><td><p>minLength: 1</p><p>maxLength: 16</p><p>pattern: "^([^\\\"])*$"</p></td><td><p>Optional. The number of the purchase order to be referenced should be passed here.</p><p>Use this in accordance to the terminology used in your organisation. The terminology may vary so you can choose to map it according to these fields.</p></td></tr><tr><td>poReferenceDate</td><td>Date (dd-MM-yyyy)</td><td><p>minLength: 10</p><p>maxLength: 10</p><p>pattern: "^[0-3][0-9]\-[0-1][0-9]\-[2][0][1-2][0-9]$"</p></td><td>Optional. The date of the purchase order to be referenced should be passed here. <br>Use this in accordance to the terminology used in your organisation. The terminology may vary so you can choose to map it according to these fields.</td></tr></tbody></table>

### Additional Document Details

<table><thead><tr><th width="167">PARAMETER</th><th width="158.33333333333331">PARAMETER TYPE</th><th width="258.25">FIELD VALIDATIONS</th><th width="250">DESCRIPTION</th></tr></thead><tbody><tr><td>id</td><td>String</td><td>                 -</td><td>Optional. ID</td></tr><tr><td>attachmentType</td><td>String</td><td><p>minLength: 3</p><p>maxLength: 100</p><p>pattern: "^([^\\\"])*$"<br>The attachment type can be URL, doc, QR code.</p></td><td><p>Mandatory. The attachment type should be passed here.</p><p>The attachment type can be URL or doc or QR code.</p></td></tr><tr><td>value</td><td>String</td><td>                  -</td><td>Mandatory. Value.</td></tr><tr><td>description</td><td>String</td><td><p>minLength: 3</p><p>maxLength: 1000</p><p>pattern: "^([^\\\"])*$"</p></td><td>Optional. Description of the additional document attached should be passed here.</td></tr></tbody></table>

### Line Item Details

{% hint style="warning" %}
Either of Price per unit and Quantity or Taxable Amount should be Present.
{% endhint %}

<table><thead><tr><th>PARAMETER</th><th>PARAMETER TYPE</th><th width="253">FIELD VALIDATIONS</th><th width="302">DESCRIPTION</th></tr></thead><tbody><tr><td>serialNumber</td><td>Number</td><td><p>minLength: 1</p><p>maxLength: 6</p><p>pattern: "^([0-9]{1,6})$"</p></td><td>Optional. The serial number of items should be entered. Ideally start with 1 to the number of items to be put in the invoice.</td></tr><tr><td>name</td><td>String</td><td><p>Min length: 3</p><p>Max length: 3006</p><p>Pattern: "^([^\"])*$"</p></td><td>Mandatory. The name of the item should be passed here. It will be the data that should be shown in the invoice item table</td></tr><tr><td>description</td><td>String</td><td><p>minLength: 3</p><p>maxLength: 300</p><p>pattern: "^([^\\\"])*$"<br>If not provided, then it will be blank.</p></td><td><p>Optional. The item description should be passed here.</p><p>Examples for the description would be refrigerators, televisions, washing machines, etc.</p></td></tr><tr><td>isService</td><td>Boolean</td><td><p>minLength: 1</p><p>maxLength: 1, </p><p>Values: "Y", "N"</p></td><td>Optional. True if IsService, False for Goods.</td></tr><tr><td>hsnCode</td><td>String</td><td><p>minLength: 6</p><p>maxLength: 8</p><p>pattern: "^(?!0+$)([0-9]{4}|[0-9]{6}|[0-9]{8})$"<br>If supply is of service, then the HSN code should start with "99"</p></td><td>Conditional. HSN code for the goods and SAC code for services should be passed here.</td></tr><tr><td>skuCode</td><td>String</td><td>Alpha-Numeric</td><td>Optional. The SKU code of the item should be passed here. The SKU code is created &#x26; maintained by the user system.</td></tr><tr><td>taxRate</td><td>Decimal</td><td><p>minimum: 0, </p><p>maximum: 999.999<br>Applicable, if supply is taxable.</p><p>The tax rate slab has a total of 11 tax rates (0, 0.1, 0.25, 1, 1.5, 3, 5, 7.5, 12, 18, 28)</p><p>If the CGST &#x26; SGST rate is provided, then the tax rate is the SGST rate + CGST rate.</p><p>If the IGST rate is provided then the tax rate is the IGST rate.</p></td><td>Conditional. Tax rate for the supply should be passed here.</td></tr><tr><td>pricePerUnit</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 999999999999.999</p></td><td>Optional. Price per unit of the items should be passed here. The price mentioned here is the price without tax.</td></tr><tr><td>discountPerUnit</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 999999999999.99</p></td><td>Optional. The discount per unit of the item should be passed here.</td></tr><tr><td>taxableAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 999999999999.99<br>Taxable value can be computed as-></p><p>(Quantity x Price per unit) - Total discount amount.</p></td><td><p>Conditional. Taxable amounts should be passed here.</p><p>If this is not provided then it will be auto computed, given if price per unit is present</p></td></tr><tr><td>cessRate</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 999.999</p></td><td><p>Optional. Cess rate as per the item should be passed here.</p><p>Where the goods or service attracts GST cess, it should be calculated on the basis of the taxable value of the supply and as provided in the GST cess rate schedule.</p><p>For example, motor vehicles used for transport shall be charged a cess of 15%.</p></td></tr><tr><td>stateCessRate</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 999.999</p></td><td>Optional. State cess rate should be entered, if any applicable.</td></tr><tr><td>cessNonAdvolAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 999999999999.99<br>Eg: The export of shellac and lac based products attract cess at the rate of Rs. 2.30 per quintal.</p></td><td><p>Optional. “Cess non-advol amount” means non-advolerum cess, i.e. it is charged fixed in terms of quantity and not charged as a percentage on value.</p><p>Notified cess as per quantity will be passed here.</p></td></tr><tr><td>stateCessNonAdvolAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 999999999999.99<br>Eg: The export of shellac and lac based products attract cess at the rate of Rs. 2.30 per quintal.</p></td><td><p>Optional. “Cess non-advol amount” means non-advolerum cess, i.e. it is charged fixed in terms of quantity and not charged as a percentage on value.</p><p>Notified cess as per quantity will be passed here.</p></td></tr><tr><td>quantity</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 999999999999.99<br>For services - it will be “0” or “1”</p></td><td>Optional. The quantity of the supply item should be passed here.</td></tr><tr><td>unitOfMeasurement</td><td>UOM (ENUM)</td><td><p>minLength: 3</p><p>maxLength: 8<br>Mandatory in case of the supply of goods.</p></td><td><p>Conditional. The unit of measurement of goods should be passed here.</p><p>For example: For 10 kilograms of wheat, the unit of measurement is ‘Kilogram’ and the UQC is “KGS”.</p></td></tr><tr><td>otherCharges</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 999999999999.99</p></td><td>Optional. The other charges should be passed here.</td></tr><tr><td>taxCategory</td><td>Tax Category (ENUM)</td><td><p> ENUM:<br>NIL_RATED</p><p>NONGST</p><p>EXEMPT</p></td><td>Optional. Default value in case of Bill of Supply is taken as NIL_RATED</td></tr><tr><td>customFields</td><td>List (Custom Fields)</td><td>              -</td><td>Optional. It is a section where the user can add any number of custom fields and put them in the object.</td></tr><tr><td>discount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99</p></td><td>Optional. The discount amount of supply should be passed here.</td></tr><tr><td>igstAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99<br>If “Intrastate supply attracts IGST” is equal to “true”, then IGST will be applicable ( even if the place of supply and supplier state are the same).<br>If IGST is applicable in SEZ transactions or any other transactions, always IGST will be applicable. In case SEZ developer is the supplier, then only IGST tax rates are applicable irrespective of supplier state code and place of supply code.<br>If applicable, then compute it as-></p><p>Taxable value x Tax Rate.<br></p></td><td><p>Optional. IGST amount as per the item should be passed here.</p><p>Applicable if the place of supply is different from the supplier state.</p></td></tr><tr><td>sgstAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99<br>Applicable when the place of supply = supplier state except if igstOnIntraStateTransaction is “true”.</p><p>Not applicable, if supply type is “Bill of supply”</p><p>If applicable, then compute it as-></p><p>Taxable value x taxable rate/2</p></td><td>Optional. SGST amount as per the item should be passed here.</td></tr><tr><td>cgstAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99<br><br>This field is applicable when the place of supply = supplier state except when igstOnIntraStateTransaction is “true”.</p><p>It is not applicable if the supply type is “Bill of supply”<br>If applicable, then compute it as -></p><p>Taxable value x taxable rate/2</p></td><td>Optional.CGST amount as per the item should be passed here.</td></tr><tr><td>cessAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99</p></td><td>Optional. Cess amount should be passed here.</td></tr><tr><td>stateCessAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99<br><br>Should be computed as-></p><p>Taxable value *state cess rate</p></td><td><p>Optional. The state cess amount of the supply should be passed here.</p><p>Where the goods or service attracts GST cess, it should be calculated on the basis of the taxable value of the supply and as provided in the GST cess rate schedule.</p></td></tr><tr><td>grossAmount</td><td>Decimal</td><td><p> minimum: 0</p><p>maximum: 99999999999999.99</p></td><td>Optional. The gross total amount of the supply should be passed here.oss Amount</td></tr><tr><td>totalItemValue</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99</p></td><td>Conditional. Total value of the item should be passed here.</td></tr></tbody></table>

### Value Details

If the below fields are left blank we will compute it using the Item list details. If the data is not blank then we will validate with your computation

<table><thead><tr><th>PARAMETER</th><th>PARAMETER TYPE</th><th width="256">FIELD VALIDATIONS</th><th width="301">DESCRIPTION</th></tr></thead><tbody><tr><td>totalTaxableAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99</p></td><td>Optional. The total taxable amount is to be passed here.</td></tr><tr><td>totalCgstAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99</p></td><td>Optional. The total CGST amount should be passed here.</td></tr><tr><td>totalIgstAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99</p></td><td>Optional. The total IGST amount should be passed here.</td></tr><tr><td>totalSgstAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99</p></td><td>Optional. The total SGST amount should be passed here.</td></tr><tr><td>totalCessAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99</p></td><td>Optional. The total cess amount should be passed here.</td></tr><tr><td>totalStateCessAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99</p></td><td>Optional. The total state cess amount should be passed here.</td></tr><tr><td>totalDiscountAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99</p></td><td>Optional. The total discount amount should be passed here.</td></tr><tr><td>totalAdditionalChargeAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99</p></td><td>Optional. Total of additional charges levied to be passed here.</td></tr><tr><td>totalRoundOffAmount</td><td>Decimal</td><td><p>minimum: -99.99</p><p>maximum: 99.99</p></td><td>Optional. The total round off amount should be passed here.</td></tr><tr><td>totalAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99</p></td><td>Optional. The total amount of supply to be passed here.</td></tr><tr><td>totalTaxAmount</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99</p></td><td>Optional. The total tax amount should be passed here.</td></tr><tr><td>totalAmountInForeignCurrency</td><td>Decimal</td><td><p>minimum: 0</p><p>maximum: 99999999999999.99</p></td><td><p>Optional. The amount in foreign currency to be passed here.</p><p>This is applicable in the case of exports.</p></td></tr></tbody></table>

## Sample Request&#x20;

{% tabs %}
{% tab title="JSON" %}
```json
{
    "documentDetails": {
        "timestamp": "21-12-2021 00:00:00",
        "documentType": "Tax Invoice",
        "supplyType": "B2B",
        "orderId": "OrderId-1",
        "documentNoPrefix": "INV/",
        "isReverseChargeApplicable": false,
        "isIgstApplicableOnIntraState": false,
        "ecommerceProviderGstin": null,
        "documentCurrencyCode": "INR",
        "taxCurrencyCode": "INR",
        "documentPeriodDetails": {
            "startDate": "01-12-2021",
            "endDate": "15-12-2021"
        },
        "customFields": [
            {
                "name": "key",
                "value": "value"
            }
        ]
    },
    "sellerDetails": {
        "tradeName": "ClearTax",
        "legalName": "DEFMACRO SOFTWARE PRIVATE LIMITED",
        "address": {
            "line1": "Block 1, First Floor",
            "line2": "HOSUR MAIN ROAD, Bengaluru (Bangalore) Urban",
            "location": "BANGALORE",
            "pincode": "560058",
            "state": "KARNATAKA",
            "stateCode": "24"
        },
        "pan": "AAFCD5862R",
        "gstin": "29AAFCD5862R000",
        "logoImage": "",
        "phone": "022-3322322",
        "email": "support@cleartax.in"
    },
    "dispatchDetails": {
        "pan": "AAFCD5862R",
        "gstin": "29AAFCD5862R000",
        "tradeName": "ClearTax",
        "legalName": "DEFMACRO SOFTWARE PRIVATE LIMITED",
        "address": {
            "line1": "Block 1, First Floor",
            "line2": "HOSUR MAIN ROAD, Bengaluru (Bangalore) Urban",
            "location": "BANGALORE",
            "pincode": "560058",
            "state": "KARNATAKA",
            "stateCode": "24"
        }
    },
    "buyerDetails": {
        "name": null,
        "tradeName": "AMAZON INDIA",
        "legalName": "PREM LATA KOTHARI",
        "address": {
            "line1": "6/101, GALI NO 4",
            "line2": "VISHWAS NAGAR, DELHI, ",
            "location": "East Delhi",
            "pincode": "110032",
            "state": "Delhi",
            "stateCode": "7"
        },
        "placeOfSupply": "Delhi",
        "pan": "ACZPK9220B",
        "gstin": "07ACZPK9220B1ZG",
        "phone": "121323232333",
        "email": "admin@amazon.com"
    },
    "shippingDetails": {
        "name": null,
        "tradeName": "AMAZON INDIA",
        "legalName": "PREM LATA KOTHARI",
        "gstin": "07ACZPK9220B1ZG",
        "pan": "ACZPK9220B",
        "address": {
            "line1": "6/101, GALI NO 4",
            "line2": "VISHWAS NAGAR, DELHI, ",
            "location": "East Delhi",
            "pincode": "110032",
            "state": "Delhi",
            "stateCode": "7"
        }
    },
    "exportDetails": {
        "countryCode": "US",
        "shippingPortCode": "INADA6",
        "conversionFactor": 0.013,
        "shippingBillNumber": "SPA1332432",
        "shippingBillDate": "23-12-2021",
        "exportDuty": 10.0
    },
    "additionalDiscounts": [
        {
            "reason": "Festival Coupon CHRS",
            "amount": 5.0
        }
    ],
    "additionalCharges": [
        {
            "reason": "Packing",
            "amount": 5.0
        }
    ],
    "paymentInstrumentDetailsAndTerms": {
        "accountName": "ClearTax",
        "ifscCode": "SBIN11000",
        "accountNumber": "5697389713210",
        "upiId": "cleartax@ybl",
        "paymentTerms": "Cash payments not accepted",
        "paymentInstruction": "",
        "creditDays": 100,
        "creditTransferTerms": "1% credit card charge",
        "directDebitTerms": ""
    },
    "paymentReceivedDetails": [
        {
            "payerName": "ABCDE",
            "paymentMode": "Cash",
            "paidAmount": 100
        }
    ],
    "metadata": {
        "notes": "",
        "signatureImage": "",
        "printTemplateId": "3f27cfb5-d7d8-44cd-a323-7e36f02e54cb"
    },
    "referenceDocuments": {
        "linkedDocumentsDetails": [
            {
                "documentNumber": "INV22",
                "documentDate": "11-12-2021",
                "documentType": "INV"
            },
            {
                "documentNumber": "INV23",
                "documentDate": "11-12-2021",
                "documentType": "INV"
            }
        ],
        "orderReferenceDetails": [
            {
                "receiptAdviceNo": "Doc/003",
                "receiptAdviceDate": "01-08-2020",
                "batchReferenceNo": "Abc001",
                "contractReferenceNo": "Co123",
                "otherReferenceNo": "Yo456",
                "projectReferenceNo": "Doc-456",
                "poReferenceNo": "Doc-789",
                "poReferenceDate": "01-08-2020"
            }
        ]
    },
    "additionalDocumentDetails": [
        {
            "id": "1",
            "attachmentType": "URL",
            "value": "https://einv-apisandbox.nic.in",
            "description": "Document Test"
        },
        {
            "id": "2",
            "attachmentType": "DOCUMENT",
            "value": "base64 of the document",
            "description": "Document Test"
        }
    ],
    "lineItems": [
        {
            "serialNumber": 1,
            "name": "Biscuit",
            "description": "Snacks",
            "isService": false,
            "hsnCode": "19053100",
            "skuCode": "S0222",
            "taxRate": 5.0,
            "pricePerUnit": 100.0,
            "discountPerUnit": null,
            "taxableAmount": 200.0,
            "cessRate": null,
            "stateCessRate": null,
            "cessNonAdvolAmount": null,
            "stateCessNonAdvolAmount": null,
            "quantity": 2,
            "unitOfMeasurement": "PAC",
            "otherCharges": null,
            "taxCategory": null,
            "customFields": [
                {
                    "name": "flavour",
                    "value": "vanilla"
                }
            ],
            "discount": null,
            "igstAmount": 10.0,
            "cgstAmount": null,
            "sgstAmount": null,
            "cessAmount": null,
            "stateCessAmount": null,
            "grossAmount": 200.0,
            "totalItemValue": 210.0
        }
    ],
    "valueDetails": {
        "totalTaxableAmount": 200.0,
        "totalCgstAmount": null,
        "totalIgstAmount": 10.0,
        "totalSgstAmount": null,
        "totalCessAmount": null,
        "totalStateCessAmount": null,
        "totalDiscountAmount": 5.0,
        "totalAdditionalChargeAmount": 5.0,
        "totalRoundOffAmount": null,
        "totalAmount": 210.0,
        "totalTaxAmount": 10.0,
        "totalAmountInForeignCurrency": null
    }
}
```
{% endtab %}
{% endtabs %}

## Sample Response

{% tabs %}
{% tab title="JSON - SUCCESS RESPONSE" %}
```json
{
    "documentId": "65e58dfa9ff80d1609f1b66f",
    "documentNumber": "ALLBD-3",
    "documentType": "DBN",
    "documentTimestamp": "08-02-2024 00:00:00",
    "documentDownloadUrl": "/v1/invoice/65e58dfa9ff80d1609f1b66f/download",
    "documentValueDetails": {
        "totalTaxableAmount": 75.00,
        "totalCgstAmount": 0.00,
        "totalIgstAmount": 0.00,
        "totalSgstAmount": 0.00,
        "totalCessAmount": 0.00,
        "totalStateCessAmount": 0.00,
        "totalDiscountAmount": 0.00,
        "totalAdditionalChargeAmount": 0.00,
        "totalRoundOffAmount": 0.00,
        "totalAmount": 75.00,
        "totalTaxAmount": 0.00,
        "totalAmountInForeignCurrency": 0.00,
        "totalCessNonAdVolAmount": null,
        "totalCgstItcValue": null,
        "totalSgstItcValue": null,
        "totalIgstItcValue": null,
        "totalCessItcValue": null
    },
    "errorDetails": null
}
```
{% endtab %}

{% tab title="JSON - SUCCESS RESPONSE WITH IRN" %}
```json
{
    "documentId": "65e5a4129ff80d1609f1b8a9",
    "documentNumber": "ALLBD-4",
    "documentType": "DBN",
    "documentTimestamp": "08-02-2024 00:00:00",
    "documentDownloadUrl": "/v1/invoice/65e5a4129ff80d1609f1b8a9/download",
    "documentValueDetails": {
        "totalTaxableAmount": 75.00,
        "totalCgstAmount": 0.00,
        "totalIgstAmount": 0.00,
        "totalSgstAmount": 0.00,
        "totalCessAmount": 0.00,
        "totalStateCessAmount": 0.00,
        "totalDiscountAmount": 0.00,
        "totalAdditionalChargeAmount": 0.00,
        "totalRoundOffAmount": 0.00,
        "totalAmount": 75.00,
        "totalTaxAmount": 0.00,
        "totalAmountInForeignCurrency": 0.00,
        "totalCessNonAdVolAmount": null,
        "totalCgstItcValue": null,
        "totalSgstItcValue": null,
        "totalIgstItcValue": null,
        "totalCessItcValue": null
    },
    "errorDetails": null,
    "einvoiceDetails": {
        "irn": "0bfcaf42020efa55a8fc24e1256c15d54c8b293486bfdc3675ee14d045f516d2",
        "acknowledgementNumber": 142410016639672,
        "acknowledgementDate": "2024-03-04 16:06:03",
        "signedQRCode": "eyJhbGciOiJSUzI1NiIsImtpZCI6IjE1MTNCODIxRUU0NkM3NDlBNjNCODZFMzE4QkY3MTEwOTkyODdEMUYiLCJ4NXQiOiJGUk80SWU1R3gwbW1PNGJqR0w5eEVKa29mUjgiLCJ0eXAiOiJKV1QifQ.eyJkYXRhIjoie1wiU2VsbGVyR3N0aW5cIjpcIjA5QUFGQ0Q1ODYyUjAwNlwiLFwiQnV5ZXJHc3RpblwiOlwiMjlBQUZDRDU4NjJSMVpSXCIsXCJEb2NOb1wiOlwiQUxMQkQtNFwiLFwiRG9jVHlwXCI6XCJEQk5cIixcIkRvY0R0XCI6XCIwOC8wMi8yMDI0XCIsXCJUb3RJbnZWYWxcIjo3NS4wMCxcIkl0ZW1DbnRcIjoxLFwiTWFpbkhzbkNvZGVcIjpcIjg1MjQ5MTAwXCIsXCJJcm5cIjpcIjBiZmNhZjQyMDIwZWZhNTVhOGZjMjRlMTI1NmMxNWQ1NGM4YjI5MzQ4NmJmZGMzNjc1ZWUxNGQwNDVmNTE2ZDJcIixcIklybkR0XCI6XCIyMDI0LTAzLTA0IDE2OjA2OjAzXCJ9IiwiaXNzIjoiTklDIFNhbmRib3gifQ.T5B6vgW-4fYpCHlgJsk5G_HoLlcxE4LsiaJlSqN5SDQkoi2FMmy7y5XCNYZ-dhcohIJLO9vMiXGvjHtPVqEniJLOnYDFIfi5zf9otdaf9QfNA5kXqIwZCq7iHc5MvZOD7wEgc87xcM1x0StpZMZkCDO8s7Gtc916FdbU9lI3M-puXIWECv_MMQuesHM_3PvkwCW_zyIOQQtynzPa-AP8trwGKtoy4r2dP6i1-SseD0Xh4iJz7TzNw7Z6-H8RoJ3Wi8zcSutyYFqS9vK5zWLc4tL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ALLBD-5",
    "documentType": "DBN",
    "documentTimestamp": "08-02-2024 00:00:00",
    "documentDownloadUrl": "/v1/invoice/65e5a4c29ff80d1609f1b8ad/download",
    "documentValueDetails": {
        "totalTaxableAmount": 75.00,
        "totalCgstAmount": 0.00,
        "totalIgstAmount": 0.00,
        "totalSgstAmount": 0.00,
        "totalCessAmount": 0.00,
        "totalStateCessAmount": 0.00,
        "totalDiscountAmount": 0.00,
        "totalAdditionalChargeAmount": 0.00,
        "totalRoundOffAmount": 0.00,
        "totalAmount": 75.00,
        "totalTaxAmount": 0.00,
        "totalAmountInForeignCurrency": 0.00,
        "totalCessNonAdVolAmount": null,
        "totalCgstItcValue": null,
        "totalSgstItcValue": null,
        "totalIgstItcValue": null,
        "totalCessItcValue": null
    },
    "errorDetails": null,
    "einvoiceDetails": {
        "paymentQrCode": "iVBORw0KGgoAAAANSUhEUgAAAcIAAAHCAQAAAABUY/ToAAAHF0lEQVR4Xu2bQY7rRgxE2/BCSx9BN7EvZsACdDH5JjqCl1oI7tQrtiexMoCCv8mCamD8JTWrB6DJYpGaX+ofrqlsn/zXdSD31oHcWwdybx3IvXUg99aB3FsHcm8dyL3VkFMppXvWcda/9757l3Pt3pe1LLfXY+7qq/T1Xe4yecnglBH51I/sH7VcL3VeTrIvN9n7jEXPqm4fVWc8wjgfEqtnHUpX5WB7dCmXgc2176aLLe+6feHgvMjXWS6sYwXU6ykHOfr0LDx/y43EhfpYe+WgElKu7hWMqxJS9jZZuEqK1I/8eObBedae4Dd8+3zdOUP5eYXVfsnPJMjgeFntfmw5PgvyZy1UweVU16KypwXRy5ncKiy7f1gmQ06E1mRSJ77k6l61bwyiJz85rc5O1+/8zIJ8Sx0ER11F5R1J6vyUgz9KSudCbZTCjEjLgTd7DrwJtyrwiuvhcsOthWfyd7PPhoSeHHiyP/NAMUemmq3wMmq8VQDdZkRW8u6FVgq2UgFslKWm5SSkb8Vvj6RIVDZJKt+SlZbkJxq85ludZhVRG5flQ0LbNHOqgrA4cU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OxuyoXMVCXR6Zqg1J4xlz8dsuIpF9xRxIsjvcohfFCktTE9Q9OG9lIiERvL3hUTQu1z7MAfMtVR2ya32JiecqIpM458Dru7EfLbympASVljrecqvN2OpkHaWcqDiUHIPW/41Acj2xAjUt1oq5SIkVeXODHWWxfPV7qXfY6D+Aa2zf3p0NOhNvV05KofSNI3k+G/Z3OxQF6D0A6JEHGyAS2spWfelAyOl2ZoFRuh6RIhCT1n+STMyXEFXPVSWqOf1QnqV/BfUdfFiQxJ3oq2EuIT4XAg60YKoXq/Hsed0uJVPJVz5OkvOMMTisV6VRJ14X5wG++TYJ8IpgmkHB8ZaTNR0GEzuxiaTmqTP2ugkmQqIMmJFFNpneVwqakcKvsB4qim76ESOjd/YoMxg/bM85VptLCCQnRk72byVIWpMMNj1b+03Chc7FqWmyPnBKXEZHMLr+/lSTIp5t/JakdLPvSaytuWeYyKyltxEqGbNcYAEcskKnxJ2yuAKI2w9ekSPmsdEgERVqF8pHkqM7wqNK1mvLZ2DBYEiT2HfLbTYsTsvsxrcShXR2ZmhMpZnLF6xAGpGG8kLRp4T0S0Rf5+c3xqZDhOCaRFkw3XH1CdT6jX/GkoPT+InIiLRZAOgQXT5E4Q+HmClCiFP7i2wxI/ci3A02uTG9Q+cQYJd6NyK2fP+1bYwKVDklCgrREIAQfiHNd4uCOtq6jX+Fv/dHlCZF/sA7k3jqQe+tA7q0DubcO5N46kHvrQO6tA7m3/hfkX7R6/DQ4NiKIAAAAAElFTkSuQmCC"
    }
}
```
{% endtab %}

{% tab title="JSON - SUCCESS INVOICE CREATION WITH E-INVOICE FAILURE" %}
```json
{
 "documentId": "65e5a4c29ff80d1546f1b8ad"
 "documentNumber": "INV/GJ/1001",
 "documentType": "INV",
 "documentTimestamp": "21-12-2021 00:00:00",
 "documentDownloadUrl": "/v1/invoice/123e4567-e89b-12d3-a456-
426614174000/download",
 "documentValueDetails": {
 "totalTaxableAmount": 200.0,
 "totalCgstAmount": null,
 "totalIgstAmount": 10.0,
 "totalSgstAmount": null,
 "totalCessAmount": null,
 "totalStateCessAmount": null,
 "totalDiscountAmount": 5.0,
 "totalAdditionalChargeAmount": 5.0,
 "totalRoundOffAmount": null,
 "totalAmount": 210.0,
 "totalTaxAmount": 10.0,
 "totalAmountInForeignCurrency": null
 },
 "errorDetails": null,
 "warningDetails": [
    {
     "code": "200001",
     "message": "E-Invoice cannot be generated for B2C documents",
     "source": "CLEARTAX",
     "path": "documentDetails.supplyType"
    }
 ]
}
```
{% endtab %}
{% endtabs %}

{% tabs %}
{% tab title="JSON - FAILURE RESPONSE" %}
```json
{
 "errorDetails": [
 {
    "errorCode": "6002",
    "errorMessage": "Invalid value for the field
   documentDetails.supplyType. Send the correct the value and try again",
    "errorSource": "CLEARTAX",
    "path": "documentDetails.supplyType"
  }
 ]
}
```
{% endtab %}

{% tab title="JSON - FAILURE RESPONSE" %}
```json
[
    {
        "ErrorList": [
            {
                "ErrorCode": "100202",
                "ErrorMessage": "NIC servers are not responding. Please try again after sometime",
                "ErrorSource": "GOVT"
            }
        ],
        "DocumentNumber": "KL2AL",
        "DocumentDate": "30/03/2021",
        "DocumentType": "DBN",
        "Gstin": "24AAFCD5862R005"
    }
]
```
{% endtab %}
{% endtabs %}
