---
title: "Edit a document"
method: PUT
path: "/v2/doc/{doc_hash_id}"
tags: ["Document V2"]
---

# Edit a document

`PUT /v2/doc/{doc_hash_id}`

## Path parameters

- `doc_hash_id` string, required

## Request body

- BaseDocumentEditV2
  - `serial_number` string — Serial Number (deprecated, please use New Serial Number)
  - `serial_number_v2` SerialNumber
    - `prefix` string
    - `doc_number` integer
    - `suffix` string
  - `document_type` 'invoice' | 'subscription' | 'pro_forma_invoice' | 'estimate' | 'sales_return' | 'purchase_return' | 'delivery_challan', required — Value should always be the string 'invoice'
  - `document_date` string, required — DD-MM-YYYY
  - `party` Party
    - `id` string, required — Unique id for each party.
    - `type` 'customer' | 'vendor', required — Party type, use only specified values. Party type customer can be used for creating invoices, sales returns, estimates, pro forma invoices and delivery challans. Party type vendor can be used for creating purchases, purchase orders & purchase returns, .
    - `name` string, required — Name of the Party
    - `country_code` string — Party Phone Number Country code
    - `phone_number` string — Party Phone Number
    - `company_name` string — Company Name
    - `email` string — Party Email
    - `gstin` string — GSTIN
    - `shipping_address` ShippingAddressV2
      - `addr_id` integer — Address ID. Value should be n >= 0 and n <= 999999, It will automatically update the existing address if the address ID already exists.
      - `addr_id_v2` string — Address ID. It must be alphanumeric, not empty, and up to 16 characters long.
      - `address_line1` string, required — Address Line 1
      - `address_line2` string, required — Address Line 2
      - `city` string, required — City
      - `state` 'JAMMU AND KASHMIR' | 'HIMACHAL PRADESH' | 'PUNJAB' | 'CHANDIGARH' | 'UTTARAKHAND' | 'HARYANA' | 'DELHI' | 'RAJASTHAN' | 'UTTAR PRADESH' | 'BIHAR' | 'SIKKIM' | 'ARUNACHAL PRADESH' | 'NAGALAND' | 'MANIPUR' | 'MIZORAM' | 'TRIPURA' | 'MEGHALAYA' | 'ASSAM' | 'WEST BENGAL' | 'JHARKHAND' | 'ODISHA' | 'CHHATTISGARH' | 'MADHYA PRADESH' | 'GUJARAT' | 'DADRA & NAGAR HAVELI & DAMAN & DIU' | 'MAHARASHTRA' | 'ANDHRAPRADESH(BEFOREADDED)' | 'KARNATAKA' | 'GOA' | 'LAKSHWADEEP' | 'KERALA' | 'TAMIL NADU' | 'PUDUCHERRY' | 'ANDAMAN & NICOBAR' | 'TELANGANA' | 'ANDHRA PRADESH' | 'LADAKH(NEWLYADDED)' | 'OTHER TERRITORY', required — State. Select OTHER TERRITORY for countries other than India. You can copy the state details from https://developers.getswipe.in/api-reference/references#state-details
      - `country` 'Afghanistan' | 'Albania' | 'Algeria' | 'Andorra' | 'Angola' | 'Antigua and Barbuda' | 'Argentina' | 'Armenia' | 'Australia' | 'Austria' | 'Azerbaijan' | 'Bahamas' | 'Bahrain' | 'Bangladesh' | 'Barbados' | 'Belarus' | 'Belgium' | 'Belize' | 'Benin' | 'Bhutan' | 'Bolivia' | 'Bosnia and Herzegovina' | 'Botswana' | 'Brazil' | 'Brunei' | 'Bulgaria' | 'Burkina Faso' | 'Burundi' | 'Cabo Verde' | 'Cambodia' | 'Cameroon' | 'Canada' | 'Central African Republic' | 'Chad' | 'Chile' | 'China' | 'Colombia' | 'Comoros' | 'Congo, Democratic Republic of the' | 'Congo, Republic of the' | 'Costa Rica' | 'Croatia' | 'Cuba' | 'Cyprus' | 'Czechia' | 'Denmark' | 'Djibouti' | 'Dominica' | 'Dominican Republic' | 'Ecuador' | 'Egypt' | 'El Salvador' | 'Equatorial Guinea' | 'Eritrea' | 'Estonia' | 'Eswatini' | 'Ethiopia' | 'Fiji' | 'Finland' | 'France' | 'Gabon' | 'Gambia' | 'Georgia' | 'Germany' | 'Ghana' | 'Greece' | 'Grenada' | 'Guatemala' | 'Guinea' | 'Guinea-Bissau' | 'Guyana' | 'Haiti' | 'Honduras' | 'Hungary' | 'Iceland' | 'India' | 'Indonesia' | 'Iran' | 'Iraq' | 'Ireland' | 'Israel' | 'Italy' | 'Jamaica' | 'Japan' | 'Jordan' | 'Kazakhstan' | 'Kenya' | 'Kiribati' | 'Korea, North' | 'Korea, South' | 'Kosovo' | 'Kuwait' | 'Kyrgyzstan' | 'Laos' | 'Latvia' | 'Lebanon' | 'Lesotho' | 'Liberia' | 'Libya' | 'Liechtenstein' | 'Lithuania' | 'Luxembourg' | 'Madagascar' | 'Malawi' | 'Malaysia' | 'Maldives' | 'Mali' | 'Malta' | 'Marshall Islands' | 'Mauritania' | 'Mauritius' | 'Mexico' | 'Micronesia' | 'Moldova' | 'Monaco' | 'Mongolia' | 'Montenegro' | 'Morocco' | 'Mozambique' | 'Myanmar' | 'Namibia' | 'Nauru' | 'Nepal' | 'Netherlands' | 'New Zealand' | 'Nicaragua' | 'Niger' | 'Nigeria' | 'North Macedonia' | 'Norway' | 'Oman' | 'Pakistan' | 'Palau' | 'Palestine' | 'Panama' | 'Papua New Guinea' | 'Paraguay' | 'Peru' | 'Philippines' | 'Poland' | 'Portugal' | 'Qatar' | 'Romania' | 'Russia' | 'Rwanda' | 'Saint Kitts and Nevis' | 'Saint Lucia' | 'Saint Vincent and the Grenadines' | 'Samoa' | 'San Marino' | 'Sao Tome and Principe' | 'Saudi Arabia' | 'Senegal' | 'Serbia' | 'Seychelles' | 'Sierra Leone' | 'Singapore' | 'Slovakia' | 'Slovenia' | 'Solomon Islands' | 'Somalia' | 'South Africa' | 'South Sudan' | 'Spain' | 'Sri Lanka' | 'Sudan' | 'Suriname' | 'Sweden' | 'Switzerland' | 'Syria' | 'Taiwan' | 'Tajikistan' | 'Tanzania' | 'Thailand' | 'Timor-Leste' | 'Togo' | 'Tonga' | 'Trinidad and Tobago' | 'Tunisia' | 'Turkey' | 'Turkmenistan' | 'Tuvalu' | 'Uganda' | 'Ukraine' | 'United Arab Emirates' | 'United Kingdom' | 'United States' | 'Uruguay' | 'Uzbekistan' | 'Vanuatu' | 'Vatican City' | 'Venezuela' | 'Vietnam' | 'Yemen' | 'Zambia' | 'Zimbabwe', required — Country. You can copy the country details from https://developers.getswipe.in/api-reference/references#country-array
      - `pincode` string, required — Pincode
    - `billing_address` ShippingAddressV2
      - `addr_id` integer — Address ID. Value should be n >= 0 and n <= 999999, It will automatically update the existing address if the address ID already exists.
      - `addr_id_v2` string — Address ID. It must be alphanumeric, not empty, and up to 16 characters long.
      - `address_line1` string, required — Address Line 1
      - `address_line2` string, required — Address Line 2
      - `city` string, required — City
      - `state` 'JAMMU AND KASHMIR' | 'HIMACHAL PRADESH' | 'PUNJAB' | 'CHANDIGARH' | 'UTTARAKHAND' | 'HARYANA' | 'DELHI' | 'RAJASTHAN' | 'UTTAR PRADESH' | 'BIHAR' | 'SIKKIM' | 'ARUNACHAL PRADESH' | 'NAGALAND' | 'MANIPUR' | 'MIZORAM' | 'TRIPURA' | 'MEGHALAYA' | 'ASSAM' | 'WEST BENGAL' | 'JHARKHAND' | 'ODISHA' | 'CHHATTISGARH' | 'MADHYA PRADESH' | 'GUJARAT' | 'DADRA & NAGAR HAVELI & DAMAN & DIU' | 'MAHARASHTRA' | 'ANDHRAPRADESH(BEFOREADDED)' | 'KARNATAKA' | 'GOA' | 'LAKSHWADEEP' | 'KERALA' | 'TAMIL NADU' | 'PUDUCHERRY' | 'ANDAMAN & NICOBAR' | 'TELANGANA' | 'ANDHRA PRADESH' | 'LADAKH(NEWLYADDED)' | 'OTHER TERRITORY', required — State. Select OTHER TERRITORY for countries other than India. You can copy the state details from https://developers.getswipe.in/api-reference/references#state-details
      - `country` 'Afghanistan' | 'Albania' | 'Algeria' | 'Andorra' | 'Angola' | 'Antigua and Barbuda' | 'Argentina' | 'Armenia' | 'Australia' | 'Austria' | 'Azerbaijan' | 'Bahamas' | 'Bahrain' | 'Bangladesh' | 'Barbados' | 'Belarus' | 'Belgium' | 'Belize' | 'Benin' | 'Bhutan' | 'Bolivia' | 'Bosnia and Herzegovina' | 'Botswana' | 'Brazil' | 'Brunei' | 'Bulgaria' | 'Burkina Faso' | 'Burundi' | 'Cabo Verde' | 'Cambodia' | 'Cameroon' | 'Canada' | 'Central African Republic' | 'Chad' | 'Chile' | 'China' | 'Colombia' | 'Comoros' | 'Congo, Democratic Republic of the' | 'Congo, Republic of the' | 'Costa Rica' | 'Croatia' | 'Cuba' | 'Cyprus' | 'Czechia' | 'Denmark' | 'Djibouti' | 'Dominica' | 'Dominican Republic' | 'Ecuador' | 'Egypt' | 'El Salvador' | 'Equatorial Guinea' | 'Eritrea' | 'Estonia' | 'Eswatini' | 'Ethiopia' | 'Fiji' | 'Finland' | 'France' | 'Gabon' | 'Gambia' | 'Georgia' | 'Germany' | 'Ghana' | 'Greece' | 'Grenada' | 'Guatemala' | 'Guinea' | 'Guinea-Bissau' | 'Guyana' | 'Haiti' | 'Honduras' | 'Hungary' | 'Iceland' | 'India' | 'Indonesia' | 'Iran' | 'Iraq' | 'Ireland' | 'Israel' | 'Italy' | 'Jamaica' | 'Japan' | 'Jordan' | 'Kazakhstan' | 'Kenya' | 'Kiribati' | 'Korea, North' | 'Korea, South' | 'Kosovo' | 'Kuwait' | 'Kyrgyzstan' | 'Laos' | 'Latvia' | 'Lebanon' | 'Lesotho' | 'Liberia' | 'Libya' | 'Liechtenstein' | 'Lithuania' | 'Luxembourg' | 'Madagascar' | 'Malawi' | 'Malaysia' | 'Maldives' | 'Mali' | 'Malta' | 'Marshall Islands' | 'Mauritania' | 'Mauritius' | 'Mexico' | 'Micronesia' | 'Moldova' | 'Monaco' | 'Mongolia' | 'Montenegro' | 'Morocco' | 'Mozambique' | 'Myanmar' | 'Namibia' | 'Nauru' | 'Nepal' | 'Netherlands' | 'New Zealand' | 'Nicaragua' | 'Niger' | 'Nigeria' | 'North Macedonia' | 'Norway' | 'Oman' | 'Pakistan' | 'Palau' | 'Palestine' | 'Panama' | 'Papua New Guinea' | 'Paraguay' | 'Peru' | 'Philippines' | 'Poland' | 'Portugal' | 'Qatar' | 'Romania' | 'Russia' | 'Rwanda' | 'Saint Kitts and Nevis' | 'Saint Lucia' | 'Saint Vincent and the Grenadines' | 'Samoa' | 'San Marino' | 'Sao Tome and Principe' | 'Saudi Arabia' | 'Senegal' | 'Serbia' | 'Seychelles' | 'Sierra Leone' | 'Singapore' | 'Slovakia' | 'Slovenia' | 'Solomon Islands' | 'Somalia' | 'South Africa' | 'South Sudan' | 'Spain' | 'Sri Lanka' | 'Sudan' | 'Suriname' | 'Sweden' | 'Switzerland' | 'Syria' | 'Taiwan' | 'Tajikistan' | 'Tanzania' | 'Thailand' | 'Timor-Leste' | 'Togo' | 'Tonga' | 'Trinidad and Tobago' | 'Tunisia' | 'Turkey' | 'Turkmenistan' | 'Tuvalu' | 'Uganda' | 'Ukraine' | 'United Arab Emirates' | 'United Kingdom' | 'United States' | 'Uruguay' | 'Uzbekistan' | 'Vanuatu' | 'Vatican City' | 'Venezuela' | 'Vietnam' | 'Yemen' | 'Zambia' | 'Zimbabwe', required — Country. You can copy the country details from https://developers.getswipe.in/api-reference/references#country-array
      - `pincode` string, required — Pincode
  - `due_date` string — DD-MM-YYYY
  - `reference` string — Any references you want to add to the doc
  - `notes` string — Notes to show in invoice - please check template in swipe application to see where this is displayed
  - `terms` string — Terms to show in invoice - please check template in swipe application to see where this is displayed
  - `items` DocItemV2[], required — Array of Products/Services, refer Item Object below for parameters
    - `id` string, required — Unique id for each item. If a new id is sent, a new Item with the below details will be automatically created. if existing Item id is sent the details will not override the original item details. They will be applicable only to the current documents. Use update item to actually update the item details in swipe
    - `name` string, required — Name of the Product
    - `quantity` number, required — Quantity
    - `unit_price` number, required — Price per item without Tax
    - `tax_rate` number — Tax percentage for each item . Only valid tax rates are accepted
    - `price_with_tax` number, required — Price per item with Tax
    - `net_amount` number, required — Net Amount
    - `total_amount` number, required — Item total amount (Net Amount + Tax). We calculate the discount amount by multiplying the item's quantity, unit price, and discount percentage. If a discount amount is provided instead, we reverse-calculate the percentage. If no discount is given, it is set to 0.
    - `discount_percent` number — Discount Percent
    - `discount_amount` number — Discount Amount, will be ignored if discount_percent is provided
    - `description` string — Item Description
    - `hsn_code` string — HSN Code. HSN Code can only be of length 4,6 & 8
    - `item_type` 'Product' | 'Service', required — Product or Service enum
    - `unit` string — Item quantity unit. You can find the GST-approved units in the UQC Codes section at: https://einvoice1.gst.gov.in/Others/MasterCodes.
    - `category` string — Category
    - `custom_columns` ItemCustomFields[] — Item Custom Fields. Custom fields should already be added in Swipe Portal.
      - `label` string, required
      - `value` string, required
  - `extra_discount` number — Adjustment on overall invoice, doesn’t effect any tax amounts.
  - `round_off` boolean — Should Round Off total amount
  - `bank_details` BankDetails
    - `account_number` string, required — Account Number
    - `ifsc` string, required — IFSC Code
    - `bank_name` string, required — Bank Name
    - `branch` string, required — Branch
  - `tds_id` integer — You can check the tds id and details mapping from https://developers.getswipe.in/api-reference/references#tds-tax-deducted-at-source
  - `tcs_id` integer — You can check the tcs id and details mapping from https://developers.getswipe.in/api-reference/references#tcs-tax-collected-at-source
  - `charges_and_deductions` AdditionalChargesDeductionsV2[] — Array of Charges and Deductions, refer Additional Charges Deductions Object for parameters
    - `id` integer, required — Unique ID for the charge/deduction. 0 < id <= 999999
    - `name` string, required — Name of the charge/deduction.
    - `amount` number, required — Total Amount
    - `tax_rate` number, required — Tax Rate
    - `sac_code` string — SAC Code
    - `type` 'charge' | 'deduction', required — Type
  - `company_shipping_address` ShippingAddressV2
    - `addr_id` integer — Address ID. Value should be n >= 0 and n <= 999999, It will automatically update the existing address if the address ID already exists.
    - `addr_id_v2` string — Address ID. It must be alphanumeric, not empty, and up to 16 characters long.
    - `address_line1` string, required — Address Line 1
    - `address_line2` string, required — Address Line 2
    - `city` string, required — City
    - `state` 'JAMMU AND KASHMIR' | 'HIMACHAL PRADESH' | 'PUNJAB' | 'CHANDIGARH' | 'UTTARAKHAND' | 'HARYANA' | 'DELHI' | 'RAJASTHAN' | 'UTTAR PRADESH' | 'BIHAR' | 'SIKKIM' | 'ARUNACHAL PRADESH' | 'NAGALAND' | 'MANIPUR' | 'MIZORAM' | 'TRIPURA' | 'MEGHALAYA' | 'ASSAM' | 'WEST BENGAL' | 'JHARKHAND' | 'ODISHA' | 'CHHATTISGARH' | 'MADHYA PRADESH' | 'GUJARAT' | 'DADRA & NAGAR HAVELI & DAMAN & DIU' | 'MAHARASHTRA' | 'ANDHRAPRADESH(BEFOREADDED)' | 'KARNATAKA' | 'GOA' | 'LAKSHWADEEP' | 'KERALA' | 'TAMIL NADU' | 'PUDUCHERRY' | 'ANDAMAN & NICOBAR' | 'TELANGANA' | 'ANDHRA PRADESH' | 'LADAKH(NEWLYADDED)' | 'OTHER TERRITORY', required — State. Select OTHER TERRITORY for countries other than India. You can copy the state details from https://developers.getswipe.in/api-reference/references#state-details
    - `country` 'Afghanistan' | 'Albania' | 'Algeria' | 'Andorra' | 'Angola' | 'Antigua and Barbuda' | 'Argentina' | 'Armenia' | 'Australia' | 'Austria' | 'Azerbaijan' | 'Bahamas' | 'Bahrain' | 'Bangladesh' | 'Barbados' | 'Belarus' | 'Belgium' | 'Belize' | 'Benin' | 'Bhutan' | 'Bolivia' | 'Bosnia and Herzegovina' | 'Botswana' | 'Brazil' | 'Brunei' | 'Bulgaria' | 'Burkina Faso' | 'Burundi' | 'Cabo Verde' | 'Cambodia' | 'Cameroon' | 'Canada' | 'Central African Republic' | 'Chad' | 'Chile' | 'China' | 'Colombia' | 'Comoros' | 'Congo, Democratic Republic of the' | 'Congo, Republic of the' | 'Costa Rica' | 'Croatia' | 'Cuba' | 'Cyprus' | 'Czechia' | 'Denmark' | 'Djibouti' | 'Dominica' | 'Dominican Republic' | 'Ecuador' | 'Egypt' | 'El Salvador' | 'Equatorial Guinea' | 'Eritrea' | 'Estonia' | 'Eswatini' | 'Ethiopia' | 'Fiji' | 'Finland' | 'France' | 'Gabon' | 'Gambia' | 'Georgia' | 'Germany' | 'Ghana' | 'Greece' | 'Grenada' | 'Guatemala' | 'Guinea' | 'Guinea-Bissau' | 'Guyana' | 'Haiti' | 'Honduras' | 'Hungary' | 'Iceland' | 'India' | 'Indonesia' | 'Iran' | 'Iraq' | 'Ireland' | 'Israel' | 'Italy' | 'Jamaica' | 'Japan' | 'Jordan' | 'Kazakhstan' | 'Kenya' | 'Kiribati' | 'Korea, North' | 'Korea, South' | 'Kosovo' | 'Kuwait' | 'Kyrgyzstan' | 'Laos' | 'Latvia' | 'Lebanon' | 'Lesotho' | 'Liberia' | 'Libya' | 'Liechtenstein' | 'Lithuania' | 'Luxembourg' | 'Madagascar' | 'Malawi' | 'Malaysia' | 'Maldives' | 'Mali' | 'Malta' | 'Marshall Islands' | 'Mauritania' | 'Mauritius' | 'Mexico' | 'Micronesia' | 'Moldova' | 'Monaco' | 'Mongolia' | 'Montenegro' | 'Morocco' | 'Mozambique' | 'Myanmar' | 'Namibia' | 'Nauru' | 'Nepal' | 'Netherlands' | 'New Zealand' | 'Nicaragua' | 'Niger' | 'Nigeria' | 'North Macedonia' | 'Norway' | 'Oman' | 'Pakistan' | 'Palau' | 'Palestine' | 'Panama' | 'Papua New Guinea' | 'Paraguay' | 'Peru' | 'Philippines' | 'Poland' | 'Portugal' | 'Qatar' | 'Romania' | 'Russia' | 'Rwanda' | 'Saint Kitts and Nevis' | 'Saint Lucia' | 'Saint Vincent and the Grenadines' | 'Samoa' | 'San Marino' | 'Sao Tome and Principe' | 'Saudi Arabia' | 'Senegal' | 'Serbia' | 'Seychelles' | 'Sierra Leone' | 'Singapore' | 'Slovakia' | 'Slovenia' | 'Solomon Islands' | 'Somalia' | 'South Africa' | 'South Sudan' | 'Spain' | 'Sri Lanka' | 'Sudan' | 'Suriname' | 'Sweden' | 'Switzerland' | 'Syria' | 'Taiwan' | 'Tajikistan' | 'Tanzania' | 'Thailand' | 'Timor-Leste' | 'Togo' | 'Tonga' | 'Trinidad and Tobago' | 'Tunisia' | 'Turkey' | 'Turkmenistan' | 'Tuvalu' | 'Uganda' | 'Ukraine' | 'United Arab Emirates' | 'United Kingdom' | 'United States' | 'Uruguay' | 'Uzbekistan' | 'Vanuatu' | 'Vatican City' | 'Venezuela' | 'Vietnam' | 'Yemen' | 'Zambia' | 'Zimbabwe', required — Country. You can copy the country details from https://developers.getswipe.in/api-reference/references#country-array
    - `pincode` string, required — Pincode
  - `company_billing_address` ShippingAddressV2
    - `addr_id` integer — Address ID. Value should be n >= 0 and n <= 999999, It will automatically update the existing address if the address ID already exists.
    - `addr_id_v2` string — Address ID. It must be alphanumeric, not empty, and up to 16 characters long.
    - `address_line1` string, required — Address Line 1
    - `address_line2` string, required — Address Line 2
    - `city` string, required — City
    - `state` 'JAMMU AND KASHMIR' | 'HIMACHAL PRADESH' | 'PUNJAB' | 'CHANDIGARH' | 'UTTARAKHAND' | 'HARYANA' | 'DELHI' | 'RAJASTHAN' | 'UTTAR PRADESH' | 'BIHAR' | 'SIKKIM' | 'ARUNACHAL PRADESH' | 'NAGALAND' | 'MANIPUR' | 'MIZORAM' | 'TRIPURA' | 'MEGHALAYA' | 'ASSAM' | 'WEST BENGAL' | 'JHARKHAND' | 'ODISHA' | 'CHHATTISGARH' | 'MADHYA PRADESH' | 'GUJARAT' | 'DADRA & NAGAR HAVELI & DAMAN & DIU' | 'MAHARASHTRA' | 'ANDHRAPRADESH(BEFOREADDED)' | 'KARNATAKA' | 'GOA' | 'LAKSHWADEEP' | 'KERALA' | 'TAMIL NADU' | 'PUDUCHERRY' | 'ANDAMAN & NICOBAR' | 'TELANGANA' | 'ANDHRA PRADESH' | 'LADAKH(NEWLYADDED)' | 'OTHER TERRITORY', required — State. Select OTHER TERRITORY for countries other than India. You can copy the state details from https://developers.getswipe.in/api-reference/references#state-details
    - `country` 'Afghanistan' | 'Albania' | 'Algeria' | 'Andorra' | 'Angola' | 'Antigua and Barbuda' | 'Argentina' | 'Armenia' | 'Australia' | 'Austria' | 'Azerbaijan' | 'Bahamas' | 'Bahrain' | 'Bangladesh' | 'Barbados' | 'Belarus' | 'Belgium' | 'Belize' | 'Benin' | 'Bhutan' | 'Bolivia' | 'Bosnia and Herzegovina' | 'Botswana' | 'Brazil' | 'Brunei' | 'Bulgaria' | 'Burkina Faso' | 'Burundi' | 'Cabo Verde' | 'Cambodia' | 'Cameroon' | 'Canada' | 'Central African Republic' | 'Chad' | 'Chile' | 'China' | 'Colombia' | 'Comoros' | 'Congo, Democratic Republic of the' | 'Congo, Republic of the' | 'Costa Rica' | 'Croatia' | 'Cuba' | 'Cyprus' | 'Czechia' | 'Denmark' | 'Djibouti' | 'Dominica' | 'Dominican Republic' | 'Ecuador' | 'Egypt' | 'El Salvador' | 'Equatorial Guinea' | 'Eritrea' | 'Estonia' | 'Eswatini' | 'Ethiopia' | 'Fiji' | 'Finland' | 'France' | 'Gabon' | 'Gambia' | 'Georgia' | 'Germany' | 'Ghana' | 'Greece' | 'Grenada' | 'Guatemala' | 'Guinea' | 'Guinea-Bissau' | 'Guyana' | 'Haiti' | 'Honduras' | 'Hungary' | 'Iceland' | 'India' | 'Indonesia' | 'Iran' | 'Iraq' | 'Ireland' | 'Israel' | 'Italy' | 'Jamaica' | 'Japan' | 'Jordan' | 'Kazakhstan' | 'Kenya' | 'Kiribati' | 'Korea, North' | 'Korea, South' | 'Kosovo' | 'Kuwait' | 'Kyrgyzstan' | 'Laos' | 'Latvia' | 'Lebanon' | 'Lesotho' | 'Liberia' | 'Libya' | 'Liechtenstein' | 'Lithuania' | 'Luxembourg' | 'Madagascar' | 'Malawi' | 'Malaysia' | 'Maldives' | 'Mali' | 'Malta' | 'Marshall Islands' | 'Mauritania' | 'Mauritius' | 'Mexico' | 'Micronesia' | 'Moldova' | 'Monaco' | 'Mongolia' | 'Montenegro' | 'Morocco' | 'Mozambique' | 'Myanmar' | 'Namibia' | 'Nauru' | 'Nepal' | 'Netherlands' | 'New Zealand' | 'Nicaragua' | 'Niger' | 'Nigeria' | 'North Macedonia' | 'Norway' | 'Oman' | 'Pakistan' | 'Palau' | 'Palestine' | 'Panama' | 'Papua New Guinea' | 'Paraguay' | 'Peru' | 'Philippines' | 'Poland' | 'Portugal' | 'Qatar' | 'Romania' | 'Russia' | 'Rwanda' | 'Saint Kitts and Nevis' | 'Saint Lucia' | 'Saint Vincent and the Grenadines' | 'Samoa' | 'San Marino' | 'Sao Tome and Principe' | 'Saudi Arabia' | 'Senegal' | 'Serbia' | 'Seychelles' | 'Sierra Leone' | 'Singapore' | 'Slovakia' | 'Slovenia' | 'Solomon Islands' | 'Somalia' | 'South Africa' | 'South Sudan' | 'Spain' | 'Sri Lanka' | 'Sudan' | 'Suriname' | 'Sweden' | 'Switzerland' | 'Syria' | 'Taiwan' | 'Tajikistan' | 'Tanzania' | 'Thailand' | 'Timor-Leste' | 'Togo' | 'Tonga' | 'Trinidad and Tobago' | 'Tunisia' | 'Turkey' | 'Turkmenistan' | 'Tuvalu' | 'Uganda' | 'Ukraine' | 'United Arab Emirates' | 'United Kingdom' | 'United States' | 'Uruguay' | 'Uzbekistan' | 'Vanuatu' | 'Vatican City' | 'Venezuela' | 'Vietnam' | 'Yemen' | 'Zambia' | 'Zimbabwe', required — Country. You can copy the country details from https://developers.getswipe.in/api-reference/references#country-array
    - `pincode` string, required — Pincode
  - `is_export` boolean — Is Export
  - `is_multi_currency` boolean — Is Multi Currency
  - `export_invoice_details` ExportInvoiceDetailsV2
    - `shipping_bill_date` string — Shipping Bill Date [DD-MM-YYYY]
    - `shipping_bill_number` string — Shipping Bill Number
    - `shipping_port_code` string — Shipping Port Code
    - `export_type` 'Export under bond/LUT' | 'Export with IGST' | 'SEZ with IGST Payment' | 'SEZ without IGST Payment' | 'Deemed Export' | 'Multi Currency', required — Export Type
    - `conversion_factor` number, required — The conversion factor represents the rate used to convert foreign currencies into Indian rupees. For example, if you're invoicing in dollars, and 1 dollar equals 84 rupees, the conversion factor would be 84
    - `country_id` 'Afghanistan' | 'Albania' | 'Algeria' | 'Andorra' | 'Angola' | 'Antigua and Barbuda' | 'Argentina' | 'Armenia' | 'Australia' | 'Austria' | 'Azerbaijan' | 'Bahamas' | 'Bahrain' | 'Bangladesh' | 'Barbados' | 'Belarus' | 'Belgium' | 'Belize' | 'Benin' | 'Bhutan' | 'Bolivia' | 'Bosnia and Herzegovina' | 'Botswana' | 'Brazil' | 'Brunei' | 'Bulgaria' | 'Burkina Faso' | 'Burundi' | 'Cabo Verde' | 'Cambodia' | 'Cameroon' | 'Canada' | 'Central African Republic' | 'Chad' | 'Chile' | 'China' | 'Colombia' | 'Comoros' | 'Congo, Democratic Republic of the' | 'Congo, Republic of the' | 'Costa Rica' | 'Croatia' | 'Cuba' | 'Cyprus' | 'Czechia' | 'Denmark' | 'Djibouti' | 'Dominica' | 'Dominican Republic' | 'Ecuador' | 'Egypt' | 'El Salvador' | 'Equatorial Guinea' | 'Eritrea' | 'Estonia' | 'Eswatini' | 'Ethiopia' | 'Fiji' | 'Finland' | 'France' | 'Gabon' | 'Gambia' | 'Georgia' | 'Germany' | 'Ghana' | 'Greece' | 'Grenada' | 'Guatemala' | 'Guinea' | 'Guinea-Bissau' | 'Guyana' | 'Haiti' | 'Honduras' | 'Hungary' | 'Iceland' | 'India' | 'Indonesia' | 'Iran' | 'Iraq' | 'Ireland' | 'Israel' | 'Italy' | 'Jamaica' | 'Japan' | 'Jordan' | 'Kazakhstan' | 'Kenya' | 'Kiribati' | 'Korea, North' | 'Korea, South' | 'Kosovo' | 'Kuwait' | 'Kyrgyzstan' | 'Laos' | 'Latvia' | 'Lebanon' | 'Lesotho' | 'Liberia' | 'Libya' | 'Liechtenstein' | 'Lithuania' | 'Luxembourg' | 'Madagascar' | 'Malawi' | 'Malaysia' | 'Maldives' | 'Mali' | 'Malta' | 'Marshall Islands' | 'Mauritania' | 'Mauritius' | 'Mexico' | 'Micronesia' | 'Moldova' | 'Monaco' | 'Mongolia' | 'Montenegro' | 'Morocco' | 'Mozambique' | 'Myanmar' | 'Namibia' | 'Nauru' | 'Nepal' | 'Netherlands' | 'New Zealand' | 'Nicaragua' | 'Niger' | 'Nigeria' | 'North Macedonia' | 'Norway' | 'Oman' | 'Pakistan' | 'Palau' | 'Palestine' | 'Panama' | 'Papua New Guinea' | 'Paraguay' | 'Peru' | 'Philippines' | 'Poland' | 'Portugal' | 'Qatar' | 'Romania' | 'Russia' | 'Rwanda' | 'Saint Kitts and Nevis' | 'Saint Lucia' | 'Saint Vincent and the Grenadines' | 'Samoa' | 'San Marino' | 'Sao Tome and Principe' | 'Saudi Arabia' | 'Senegal' | 'Serbia' | 'Seychelles' | 'Sierra Leone' | 'Singapore' | 'Slovakia' | 'Slovenia' | 'Solomon Islands' | 'Somalia' | 'South Africa' | 'South Sudan' | 'Spain' | 'Sri Lanka' | 'Sudan' | 'Suriname' | 'Sweden' | 'Switzerland' | 'Syria' | 'Taiwan' | 'Tajikistan' | 'Tanzania' | 'Thailand' | 'Timor-Leste' | 'Togo' | 'Tonga' | 'Trinidad and Tobago' | 'Tunisia' | 'Turkey' | 'Turkmenistan' | 'Tuvalu' | 'Uganda' | 'Ukraine' | 'United Arab Emirates' | 'United Kingdom' | 'United States' | 'Uruguay' | 'Uzbekistan' | 'Vanuatu' | 'Vatican City' | 'Venezuela' | 'Vietnam' | 'Yemen' | 'Zambia' | 'Zimbabwe' — Country ID
    - `currency_id` 'AED' | 'AFN' | 'ALL' | 'AMD' | 'ANG' | 'AOA' | 'ARS' | 'AUD' | 'AWG' | 'AZN' | 'BAM' | 'BBD' | 'BDT' | 'BGN' | 'BHD' | 'BIF' | 'BMD' | 'BND' | 'BOB' | 'BRL' | 'BSD' | 'BTN' | 'BWP' | 'BYN' | 'BZD' | 'CAD' | 'CDF' | 'CHF' | 'CLP' | 'CNY' | 'COP' | 'CRC' | 'CUP' | 'CVE' | 'CZK' | 'DJF' | 'DKK' | 'DOP' | 'DZD' | 'EGP' | 'ERN' | 'ETB' | 'EUR' | 'FJD' | 'FKP' | 'FOK' | 'GBP' | 'GEL' | 'GGP' | 'GHS' | 'GIP' | 'GMD' | 'GNF' | 'GTQ' | 'GYD' | 'HKD' | 'HNL' | 'HRK' | 'HTG' | 'HUF' | 'IDR' | 'ILS' | 'IMP' | 'INR' | 'IQD' | 'IRR' | 'ISK' | 'JEP' | 'JMD' | 'JOD' | 'JPY' | 'KES' | 'KGS' | 'KHR' | 'KID' | 'KMF' | 'KRW' | 'KWD' | 'KYD' | 'KZT' | 'LAK' | 'LBP' | 'LKR' | 'LRD' | 'LSL' | 'LYD' | 'MAD' | 'MDL' | 'MGA' | 'MKD' | 'MMK' | 'MNT' | 'MOP' | 'MRU' | 'MUR' | 'MVR' | 'MWK' | 'MXN' | 'MYR' | 'MZN' | 'NAD' | 'NGN' | 'NIO' | 'NOK' | 'NPR' | 'NZD' | 'OMR' | 'PAB' | 'PEN' | 'PGK' | 'PHP' | 'PKR' | 'PLN' | 'PYG' | 'QAR' | 'RON' | 'RSD' | 'RUB' | 'RWF' | 'SAR' | 'SBD' | 'SCR' | 'SDG' | 'SEK' | 'SGD' | 'SHP' | 'SLE' | 'SLL' | 'SOS' | 'SRD' | 'SSP' | 'STN' | 'SYP' | 'SZL' | 'THB' | 'TJS' | 'TMT' | 'TND' | 'TOP' | 'TRY' | 'TTD' | 'TVD' | 'TWD' | 'TZS' | 'UAH' | 'UGX' | 'USD' | 'UYU' | 'UZS' | 'VES' | 'VND' | 'VUV' | 'WST' | 'XAF' | 'XCD' | 'XDR' | 'XOF' | 'XPF' | 'YER' | 'ZAR' | 'ZMW' | 'ZWL' — Currency ID, if not provided, the default country currency will be used, please refer to the currency list from https://developers.getswipe.in/api-reference/references#currency-details
  - `is_subscription` boolean — Is Subscription
  - `subscription_details` Subscription
    - `start_time` string, date — Start Time [DD-MM-YYYY]
    - `end_time` string, date — End Time [DD-MM-YYYY]
    - `repeat` integer — Repeat in value, Frequency of the repetition
    - `repeat_type` 'days' | 'weeks' | 'months' | 'years' — Repeat type, Entity of the repetition
    - `send_email` boolean
    - `send_sms` boolean
    - `send_wtsp` boolean
  - `convert` Convert
    - `convert_from` 'invoice' | 'estimate' | 'pro_forma_invoice' | 'sales_return' | 'purchase_return', required — The document type which is being converted
    - `hash_id` string, required — Hash ID
  - `custom_headers` CustomHeaders[] — Document Custom Headers. Custom headers should already be added in Swipe Portal.
    - `label` string, required
    - `value` string, required

## Response `200`

Success

- DocCreateResponseV2
  - `success` boolean
  - `message` string — Success Message
  - `error_code` string — Error Code
  - `errors` object — Error details
  - `data` DocCreateData
    - `hash_id` string — Hash ID
    - `serial_number` string — Serial Number
    - `irn` string — IRN
    - `qr_code` string — QR Code

## Other responses

- `400` — Error
- `401` — Unauthorized
- `500` — Server Error

---

[API](https://skmtc.dev/getswipe/apis/swipeapi.md) · [All operations](https://skmtc.dev/getswipe/apis/swipeapi/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/getswipe/swipeapi/revisions/80fcaf1a3463/schema)
