> ## Documentation Index
> Fetch the complete documentation index at: https://doc-test-my.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Update a Bill

> Update Bills with this endpoint.

Use this endpoint to update a Bill.

<RequestExample>
  ```bash Curl theme={null}
  curl -u [YOUR_KEY_ID]:[YOUR_KEY_SECRET]
  -X PATCH https://api.razorpay.com/v1/bills/bill_4a5e9ulyzk1mk2
  -d '{
    "store_code": "",
    "customer": {
      "contact": "9000090001",
      "email": "saurav.kumar@example.com"
    },
    "receipt_type": "tax_invoice",
    "receipt_timestamp": 1907416999,
    "receipt_delivery": "digital",
    "line_items": [
      {
        "name": "T-Shirt",
        "quantity": 1,
        "employee_id": "1234",
        "total_amount": 100000
      }
    ],
    "receipt_summary": {
      "total_quantity": 1,
      "sub_total_amount": 100000,
      "currency": "INR",
      "net_payable_amount": 124000,
      "additional_charges": [
        {
          "description": "alteration charge",
          "amount": 2000
        },
        {
          "description": "cash on delivery",
          "amount": 2000
        },
      ],
      "payment_status": "paid"
    },
    "taxes": [
      {
        "name": "cgst",
        "percentage": 1200,
        "amount": 12000
      },
      {
        "name": "sgst",
        "percentage": 1200,
        "amount": 12000
      }
    ],
    "payments": [
      {
        "method": "Bank Transfer",
        "amount": 124000,
        "currency": "INR"
      }
    ]
  }'
  ```
</RequestExample>

<ResponseExample>
  ```json Success theme={null}
  {
    "id": "bill_PYy4RWJWiNcPyE",
    "business_type": "retail",
    "business_category": "events",
    "customer": {
      "contact": "9000090001",
      "name": "d",
      "email": "saurav.kumar@example.com",
      "customer_id": "",
      "age": 2,
      "date_of_birth": "",
      "profession": "",
      "company_name": "",
      "marital_status": "",
      "spouse_name": "",
      "anniversary_date": "",
      "gender": "",
      "gstin": "",
      "billing_address": {
        "address_line_1": "",
        "address_line_2": "",
        "landmark": "",
        "city": "",
        "province": "",
        "pin_code": "",
        "country": ""
      },
      "shipping_address": {
        "address_line_1": "",
        "address_line_2": "",
        "landmark": "",
        "city": "",
        "province": "",
        "pin_code": "",
        "country": ""
      }
    },
    "loyalty": {
      "type": "",
      "card_num": "",
      "card_holder_name": "",
      "points_redeemed": 1
    },
    "store_code": "JK-001",
    "receipt_timestamp": 1907416999,
    "receipt_number": "INV00124992",
    "receipt_type": "tax_invoice",
    "receipt_delivery": "digital",
    "bar_code_number": "",
    "qr_code_number": "T2322 00000009291",
    "billing_pos_number": "bn",
    "pos_category": "traditional_pos",
    "order_number": "",
    "order_service_type": "",
    "delivery_status_url": "",
    "line_items": [
      {
        "name": "T-Shirt",
        "quantity": 1,
        "unit": "",
        "employee_id": "1234",
        "description": "",
        "hsn_code": "",
        "product_code": "",
        "product_uid": "",
        "image_url": "",
        "total_amount": 100000,
        "brand": "",
        "style": "",
        "colour": "",
        "size": "",
        "financier_data": null,
        "taxes": [],
        "tags": [],
        "sub_items": []
      }
    ],
    "receipt_summary": {
      "total_quantity": 1,
      "sub_total_amount": 100000,
      "currency": "INR",
      "net_payable_amount": 124000,
      "additional_charges": [
        {
          "description": "alteration charge",
          "amount": 2000
        },
        {
          "description": "cash on delivery",
          "amount": 2000
        },
      ],
      "payment_status": "paid",
      "discounts": []
    },
    "taxes": [
      {
        "name": "cgst",
        "percentage": 1200,
        "amount": 120
      },
      {
        "name": "sgst",
        "percentage": 1200,
        "amount": 120
      }
    ],
    "payments": [
      {
        "method": "Bank Transfer",
        "currency": "INR",
        "amount": 124000,
        "payment_reference_id": "",
        "financier_data": null
      }
    ],
    "event": {
      "name": "My Party",
      "start_timestamp": 1722911400,
      "end_timestamp": 1722924000,
      "location": "B-wing",
      "room": "Auditorium 1",
      "seats": [
        "gold b1",
        "gold b2",
        "gold b3"
      ]
    },
    "receipt_url": "yourbill.me/PYy4RWJWiNcPyE",
    "created_at": 1907416999,
    "tags": [
      "party1",
      "graduation"
    ]
  }
  ```
</ResponseExample>

## Path Parameters

<ParamField path="id" type="string" required>
  The unique identifier of the Bill.
</ParamField>

## Request Parameters

<ParamField body="store_code" type="string" required>
  Associated store code for the receipt. Required if you have a multi-store setup where you have a single integration and have multiple stores under you.
</ParamField>

<ParamField body="customer" type="object" required>
  Details of the customer. Required if receipt mode is `digital` or `digital_and_print`.
</ParamField>

<ParamField body="contact" type="string" required>
  The customer's phone number. Required if receipt mode is `digital` or `digital_and_print` and `email` is not present.
</ParamField>

<ParamField body="name" type="string">
  The customer's name.
</ParamField>

<ParamField body="email" type="string" required>
  The customer's email address. Required if receipt mode is `digital` or `digital_and_print` and `contact` is not present.
</ParamField>

<ParamField body="customer_id" type="string">
  The customer's customer\_id. Required if receipt mode is `digital` or `digital_and_print` and neither `contact` nor `email` is present.
</ParamField>

<ParamField body="age" type="integer">
  Age of the customer.
</ParamField>

<ParamField body="date_of_birth" type="string">
  Customer's date of birth.
</ParamField>

<ParamField body="pan" type="string">
  PAN number of the billed customer.
</ParamField>

<ParamField body="profession" type="string">
  Customer's current job profile name.
</ParamField>

<ParamField body="company_name" type="string">
  Customer current employer.
</ParamField>

<ParamField body="marital_status" type="string">
  Customer's marital status. Possible values:

  * `married`
  * `unmarried`
</ParamField>

<ParamField body="spouse_name" type="string">
  Name of customer's spouse.
</ParamField>

<ParamField body="anniversary_date" type="string">
  Customer's date of anniversary.
</ParamField>

<ParamField body="gender" type="string">
  Customer gender. Possible values:

  * `male`
  * `female`
  * `other`
</ParamField>

<ParamField body="gstin" type="string">
  Customer's GST number.
</ParamField>

<ParamField body="billing_address" type="object" required>
  Customer's billing address. Required if your `business_type` is `ecommerce`.
</ParamField>

<ParamField body="address_line_1" type="string">
  Customer billing address line 1.
</ParamField>

<ParamField body="address_line_2" type="string">
  Customer billing address line 2.
</ParamField>

<ParamField body="landmark" type="string">
  Customer billing address landmark.
</ParamField>

<ParamField body="city" type="string">
  Customer billing address city.
</ParamField>

<ParamField body="province" type="string">
  Customer billing address province.
</ParamField>

<ParamField body="pin_code" type="string">
  Customer billing address PIN code.
</ParamField>

<ParamField body="country" type="string">
  Customer billing address country.
</ParamField>

<ParamField body="shipping_address" type="object" required>
  Customer's billing address. Required if your `business_type` is `ecommerce`.
</ParamField>

<ParamField body="customer_name" type="string">
  Name of the recipient.
</ParamField>

<ParamField body="contact" type="string">
  The mobile number of the recipient.
</ParamField>

<ParamField body="gstin" type="string">
  GST number of the recipient.
</ParamField>

<ParamField body="pan" type="string">
  PAN number of the recipient.
</ParamField>

<ParamField body="address_line_1" type="string">
  Customer shipping address line 1.
</ParamField>

<ParamField body="address_line_2" type="string">
  Customer shipping address line 2.
</ParamField>

<ParamField body="landmark" type="string">
  Customer shipping address landmark.
</ParamField>

<ParamField body="city" type="string">
  Customer shipping address city.
</ParamField>

<ParamField body="province" type="string">
  Customer shipping address province.
</ParamField>

<ParamField body="pin_code" type="string">
  Customer shipping address PIN code.
</ParamField>

<ParamField body="country" type="string">
  Customer shipping address country.
</ParamField>

<ParamField body="employee" type="object">
  This is an array of objects containing details of the employees associated with the receipt.
</ParamField>

<ParamField body="id" type="string">
  Employee ID/code. Unique identifier of the employee.
</ParamField>

<ParamField body="name" type="string">
  Name of the employee.
</ParamField>

<ParamField body="role" type="string">
  Employee designation/role.
</ParamField>

<ParamField body="loyalty" type="object" required>
  Customer loyalty details.
</ParamField>

<ParamField body="type" type="string">
  Customer loyalty type.
</ParamField>

<ParamField body="card_num" type="string">
  Hashed debit/credit card number provided by the customer.
</ParamField>

<ParamField body="card_holder_name" type="string">
  Name of the card holder.
</ParamField>

<ParamField body="wallet_amount" type="integer">
  Wallet amount after used rewards of the customer.
</ParamField>

<ParamField body="amount_saved" type="integer">
  Amount saved by the customer.
</ParamField>

<ParamField body="points_earned" type="integer">
  Points earned by the customer after a transaction.
</ParamField>

<ParamField body="points_redeemed" type="integer">
  Points redeemed by the customer on a transaction.
</ParamField>

<ParamField body="points_available" type="integer">
  Points available to the customer at the beginning of the transaction.
</ParamField>

<ParamField body="points_balance" type="integer">
  Points available to the customer at the end of the transaction.
</ParamField>

<ParamField body="receipt_type" type="string" required>
  The type of receipt. Possible values:

  * `tax_invoice`
  * `sales_invoice`
  * `sales_return_invoice`
  * `proforma_invoice`
  * `credit_invoice`
  * `purchase_invoice`
  * `debit_invoice`
</ParamField>

<ParamField body="receipt_timestamp" type="integer" required>
  UNIX timestamp of the date and time when the receipt was generated.
</ParamField>

<ParamField body="receipt_delivery" type="string" required>
  Indicates the delivery type of the receipt. Possible values:

  * `digital`
  * `print`
  * `digital_and_print`
</ParamField>

<ParamField body="tags" type="string">
  An array of strings representing relevant tags associated with the invoice.
</ParamField>

<ParamField body="pos_category" type="string">
  The type of POS machine. This is applicable if `business_type` is `retail`. Possible values:

  * `traditional_pos`
  * `kiosk_pos`
</ParamField>

<ParamField body="line_items" type="object" required>
  This is an array of objects containing the product data of the bill. Required if `receipt_type` is not `credit_invoice` or `debit_invoice`.
</ParamField>

<ParamField body="name" type="string" required>
  Name of the product.
</ParamField>

<ParamField body="quantity" type="float" required>
  Quantity of the product.
</ParamField>

<ParamField body="unit_amount" type="integer">
  Price of the product.
</ParamField>

<ParamField body="unit" type="string">
  Type of unit. Possible values:

  * `kg`
  * `g`
  * `mg`
  * `lt`
  * `ml`
  * `pc`
  * `cm`
  * `m`
  * `in`
  * `ft`
  * `set`
</ParamField>

<ParamField body="gross_weight" type="float">
  The total weight of the item, including all materials such as metal, stones, diamonds, and other embellishments.
</ParamField>

<ParamField body="net_weight" type="float">
  The weight of only the metal used in the item, excluding the weight of any diamonds, stones, or other materials.
</ParamField>

<ParamField body="description" type="string">
  Product/Item description.
</ParamField>

<ParamField body="hsn_code" type="string">
  HSN code of the product.
</ParamField>

<ParamField body="product_code" type="string">
  Product/Item code.
</ParamField>

<ParamField body="product_uid" type="string">
  Product/Item UID/SKU Code.
</ParamField>

<ParamField body="image_url" type="string">
  Image URL of the product.
</ParamField>

<ParamField body="total_amount" type="integer" required>
  Total amount of the product.
</ParamField>

<ParamField body="brand" type="string">
  Brand name of the product.
</ParamField>

<ParamField body="style" type="string">
  Product style.
</ParamField>

<ParamField body="colour" type="string">
  Colour of the product.
</ParamField>

<ParamField body="size" type="string">
  Size of the product in `cm`.
</ParamField>

<ParamField body="tags" type="string">
  An array of strings representing relevant tags associated with the item.
</ParamField>

<ParamField body="employee_id" type="string">
  Unique ID of the employee who sold the product.
</ParamField>

<ParamField body="additional_charges" type="object">
  This is an array of objects containing details of the additional charges of the item.
</ParamField>

<ParamField body="description" type="string">
  Description of the additional charge.
</ParamField>

<ParamField body="amount" type="integer">
  Amount of additional charge.
</ParamField>

<ParamField body="percent" type="float">
  Percent calculated on total amount.
</ParamField>

<ParamField body="sub_items" type="object" required>
  An array of objects containing the sub-item details of the item.
</ParamField>

<ParamField body="name" type="string" required>
  Name of the sub-item.
</ParamField>

<ParamField body="quantity" type="integer" required>
  Sub-item quantity.
</ParamField>

<ParamField body="unit_amount" type="integer">
  Price of the sub-item.
</ParamField>

<ParamField body="unit" type="string">
  Type of unit. Possible values:

  * `kg`
  * `g`
  * `mg`
  * `lt`
  * `ml`
  * `pc`
  * `cm`
  * `m`
  * `in`
  * `ft`
  * `set`
</ParamField>

<ParamField body="gross_weight" type="float">
  The total weight of the item, including all materials such as metal, stones, diamonds, and other embellishments.
</ParamField>

<ParamField body="net_weight" type="float">
  The weight of only the metal used in the item, excluding the weight of any diamonds, stones, or other materials.
</ParamField>

<ParamField body="description" type="string">
  Sub-item description.
</ParamField>

<ParamField body="hsn_code" type="string">
  HSN code of the product.
</ParamField>

<ParamField body="product_code" type="string">
  Sub-item code.
</ParamField>

<ParamField body="product_uid" type="string">
  Sub-item UID/SKU Code.
</ParamField>

<ParamField body="image_url" type="string">
  Image URL of the sub-item.
</ParamField>

<ParamField body="total_amount" type="integer" required>
  Total amount of the sub-item.
</ParamField>

<ParamField body="brand" type="string">
  Brand name of the sub-item.
</ParamField>

<ParamField body="style" type="string">
  Sub-item style.
</ParamField>

<ParamField body="colour" type="string">
  Colour of the sub-item.
</ParamField>

<ParamField body="size" type="string">
  Size of the sub-item in `cm`.
</ParamField>

<ParamField body="tags" type="string">
  An array of strings representing relevant tags associated with the sub-item.
</ParamField>

<ParamField body="employee_id" type="string">
  Unique ID of the employee who sold the product.
</ParamField>

<ParamField body="additional_charges" type="object">
  This is an array of objects containing details of the additional charges of the item.
</ParamField>

<ParamField body="description" type="string">
  Description of the additional charge.
</ParamField>

<ParamField body="amount" type="integer">
  Amount of additional charge.
</ParamField>

<ParamField body="percent" type="float">
  Percent calculated on total amount.
</ParamField>

<ParamField body="taxes" type="object">
  This is an array of objects containing the details of the taxes incurred.
</ParamField>

<ParamField body="name" type="string" required>
  Name of the tax. For example, CGST, SGST and so on.
</ParamField>

<ParamField body="percentage" type="float">
  Percentage of tax.
</ParamField>

<ParamField body="amount" type="integer" required>
  Applicable tax calculated on total amount.
</ParamField>

<ParamField body="financier_data" type="object">
  Data of the financier. This is applicable if the product is financed. For example, if the product is purchased on EMI.
</ParamField>

<ParamField body="reference" type="string">
  Unique id of the financier.
</ParamField>

<ParamField body="name" type="string">
  Name of the financier.
</ParamField>

<ParamField body="taxes" type="object">
  This is an array of objects containing the details of the taxes incurred.
</ParamField>

<ParamField body="name" type="string" required>
  Name of the tax. For example, CGST, SGST and so on.
</ParamField>

<ParamField body="percentage" type="float">
  Percentage of tax.
</ParamField>

<ParamField body="amount" type="integer" required>
  Applicable tax calculated on total amount.
</ParamField>

<ParamField body="receipt_summary" type="object" required>
  Details of the receipt.
</ParamField>

<ParamField body="total_quantity" type="integer" required>
  Total product quantity sold in the invoice.
</ParamField>

<ParamField body="sub_total_amount" type="integer">
  The total amount before taxes, discounts and additional fees are added to the invoice.
</ParamField>

<ParamField body="currency" type="string" required>
  The currency of the invoice. Refer to this [sheet](https://curlec.com/docs/build/browser/assets/images/bills-supported-currency-list.xlsx) for the list of supported currencies.
</ParamField>

<ParamField body="total_tax_amount" type="integer">
  Total tax amount in paise.
</ParamField>

<ParamField body="total_tax_percent" type="float">
  Total tax percentage applied on the receipt.
</ParamField>

<ParamField body="net_payable_amount" type="integer" required>
  The total amount payable after adding taxes, discounts and additional fees to the invoice.
</ParamField>

<ParamField body="additional_charges" type="object">
  This is an array of objects containing the details of any additional charges applied on the invoice. If `additional_charges` is present, then `description` and `amount` are required.
</ParamField>

<ParamField body="description" type="string">
  Description of the additional charge.
</ParamField>

<ParamField body="amount" type="integer">
  Amount of the additional charge.
</ParamField>

<ParamField body="percent" type="float">
  Percent calculated on total amount.
</ParamField>

<ParamField body="payment_status" type="string">
  Status of the payment. Possible values:

  * `pending`
  * `authorized`
  * `failed`
  * `declined`
  * `refunded`
  * `cancelled`
  * `processed`
  * `settled`
  * `voided`
  * `success`
  * `paid`
  * `unpaid`
</ParamField>

<ParamField body="change_amount" type="integer">
  Change amount to be returned to the customer if the payment was made in cash.
</ParamField>

<ParamField body="roundup_amount" type="integer">
  Change amount to be returned to the customer if the payment was made in cash.
</ParamField>

<ParamField body="total_discount_percent" type="float">
  Total percentage of the discount on the sub-total amount without the taxes.
</ParamField>

<ParamField body="total_discount_amount" type="integer">
  Total value of the discount on the invoice.
</ParamField>

<ParamField body="discounts" type="object">
  This is an array of objects containing the details of the discount. If product reference (`product_code`, `product_uid`, or `hsn_code`) is present in the object, then the discount will be on the item. If not, the discount will be on the invoice.
</ParamField>

<ParamField body="name" type="string">
  Name of the discount.
</ParamField>

<ParamField body="amount" type="string">
  Amount of the applied discount.
</ParamField>

<ParamField body="percent" type="integer">
  Percentile value of the discounted amount.
</ParamField>

<ParamField body="product_code" type="string">
  Product/Item code.
</ParamField>

<ParamField body="product_uid" type="string">
  Product/Item UID/SKU Code.
</ParamField>

<ParamField body="hsn_code" type="string">
  HSN code of the product.
</ParamField>

<ParamField body="reference_id" type="string">
  Reference ID of the discount.
</ParamField>

<ParamField body="used_wallet_amount" type="string">
  Amount used from the customer's wallet for this transaction.
</ParamField>

<ParamField body="taxes" type="object">
  This is an array of objects containing the details of the taxes incurred.
</ParamField>

<ParamField body="name" type="string" required>
  Name of the tax. For example, CGST, SGST and so on.
</ParamField>

<ParamField body="percentage" type="float">
  Percentage of tax.
</ParamField>

<ParamField body="amount" type="integer" required>
  Applicable tax calculated on total amount.
</ParamField>

<ParamField body="payments" type="object" required>
  This is an array of objects containing the details of the payment.
</ParamField>

<ParamField body="method" type="string" required>
  The mode of payment.
</ParamField>

<ParamField body="currency" type="string" required>
  The currency in which the payment was made.
</ParamField>

<ParamField body="amount" type="integer" required>
  The amount of the payment in paise. For example, if the amount is `1200`. The unit will be `120000`.
</ParamField>

<ParamField body="irn" type="object">
  This object contains IRN ( Invoice Reference Number ) related details. If `irn` is present,
  qr\_code and irn\_number are required.
</ParamField>

<ParamField body="acknowledgement_number" type="string">
  Acknowledgement number of the generated IRN.
</ParamField>

<ParamField body="acknowledgement_date" type="integer">
  Acknowledgement date of the generated IRN.
</ParamField>

<ParamField body="qr_code" type="string" required>
  QR code associated with the IRN. Required if `irn` is present.
</ParamField>

<ParamField body="irn_number" type="string" required>
  E-invoice IRN. Required if IRN is present.
</ParamField>

## Response Parameters

<ResponseField name="id" type="string" required>
  Unique id of the bill generated.
</ResponseField>

<ResponseField name="business_type" type="string" required>
  The type of business. Possible values:

  * `ecommerce`
  * `retail`
</ResponseField>

<ResponseField name="business_category" type="string" required>
  The category the business falls under. Possible values:

  * `events`
  * `food_and_beverages`
  * `retail_and_consumer_goods`
  * `other_services`
</ResponseField>

<ResponseField name="customer" type="object" required>
  Details of the customer. Required if receipt mode is `digital` or `digital_and_print`.
</ResponseField>

<ResponseField name="contact" type="string" required>
  The customer's phone number. Required if receipt mode is `digital` or `digital_and_print` and `email` is not present.
</ResponseField>

<ResponseField name="name" type="string">
  The customer's name.
</ResponseField>

<ResponseField name="email" type="string" required>
  The customer's email address. Required if receipt mode is `digital` or `digital_and_print` & `contact` not present.
</ResponseField>

<ResponseField name="customer_id" type="string">
  The customer's customer\_id. Required if receipt mode is `digital` or `digital_and_print` and neither `contact` nor `email` is present.
</ResponseField>

<ResponseField name="age" type="integer">
  Age of the customer.
</ResponseField>

<ResponseField name="date_of_birth" type="string">
  Customer's date of birth.
</ResponseField>

<ResponseField name="profession" type="string">
  Customer's current job profile name.
</ResponseField>

<ResponseField name="company_name" type="string">
  Customer current employer.
</ResponseField>

<ResponseField name="date_of_birth" type="string">
  Customer's date of birth.
</ResponseField>

<ResponseField name="marital_status" type="string">
  Customer's marital status. Possible values:

  * `married`
  * `unmarried`
</ResponseField>

<ResponseField name="spouse_name" type="string">
  Name of customer's spouse.
</ResponseField>

<ResponseField name="anniversary_date" type="string">
  Customer's date of anniversary.
</ResponseField>

<ResponseField name="gender" type="string">
  Customer gender. Possible values:

  * `male`
  * `female`
  * `other`
</ResponseField>

<ResponseField name="gstin" type="string">
  Customer's GST number.
</ResponseField>

<ResponseField name="billing_address" type="object" required>
  Customer's billing address. Required if your `business_type` is `ecommerce`.
</ResponseField>

<ResponseField name="address_line_1" type="string">
  Customer billing address line 1.
</ResponseField>

<ResponseField name="address_line_2" type="string">
  Customer billing address line 2.
</ResponseField>

<ResponseField name="landmark" type="string">
  Customer billing address landmark.
</ResponseField>

<ResponseField name="city" type="string">
  Customer billing address city.
</ResponseField>

<ResponseField name="province" type="string">
  Customer billing address province.
</ResponseField>

<ResponseField name="pin_code" type="string">
  Customer billing address PIN code.
</ResponseField>

<ResponseField name="country" type="string">
  Customer billing address country.
</ResponseField>

<ResponseField name="shipping_address" type="object" required>
  Customer's billing address. Required if your `business_type` is `ecommerce`.
</ResponseField>

<ResponseField name="address_line_1" type="string">
  Customer shipping address line 1.
</ResponseField>

<ResponseField name="address_line_2" type="string">
  Customer shipping address line 2.
</ResponseField>

<ResponseField name="landmark" type="string">
  Customer shipping address landmark.
</ResponseField>

<ResponseField name="city" type="string">
  Customer shipping address city.
</ResponseField>

<ResponseField name="province" type="string">
  Customer shipping address province.
</ResponseField>

<ResponseField name="pin_code" type="string">
  Customer shipping address PIN code.
</ResponseField>

<ResponseField name="country" type="string">
  Customer shipping address country.
</ResponseField>

<ResponseField name="loyalty" type="object" required>
  Customer loyalty details.
</ResponseField>

<ResponseField name="type" type="string">
  Customer loyalty type.
</ResponseField>

<ResponseField name="card_num" type="string">
  Hashed debit/credit card number provided by the customer.
</ResponseField>

<ResponseField name="card_holder_name" type="string">
  Name of the card holder.
</ResponseField>

<ResponseField name="wallet_amount" type="integer">
  Wallet amount after used rewards of the customer.
</ResponseField>

<ResponseField name="amount_saved" type="integer">
  Amount saved by the customer.
</ResponseField>

<ResponseField name="points_earned" type="integer">
  Points earned by the customer after a transaction.
</ResponseField>

<ResponseField name="points_redeemed" type="integer">
  Points redeemed by the customer on a transaction.
</ResponseField>

<ResponseField name="points_available" type="integer">
  Points available to the customer at the beginning of the transaction.
</ResponseField>

<ResponseField name="points_balance" type="integer">
  Points available to the customer at the end of the transaction.
</ResponseField>

<ResponseField name="store_code" type="string" required>
  Associated store code for the receipt. Required if you have a multi-store setup where you have a single integration and have multiple stores under you.
</ResponseField>

<ResponseField name="receipt_timestamp" type="integer" required>
  UNIX timestamp of the date and time when the receipt was generated.
</ResponseField>

<ResponseField name="receipt_number" type="string" required>
  Unique receipt number generated for the bill.
</ResponseField>

<ResponseField name="receipt_type" type="string" required>
  The type of receipt. Possible values:

  * `tax_invoice`
  * `sales_invoice`
  * `sales_return_invoice`
  * `proforma_invoice`
  * `credit_invoice`
  * `purchase_invoice`
  * `debit_invoice`
</ResponseField>

<ResponseField name="receipt_delivery" type="string" required>
  Indicates the delivery type of the receipt. Possible values:

  * `digital`
  * `print`
  * `digital_and_print`
</ResponseField>

<ResponseField name="tags" type="string">
  An array of strings representing relevant tags associated with the invoice.
</ResponseField>

<ResponseField name="bar_code_number" type="integer">
  Bar code generated after the transaction. This will be displayed on the digital bill only.
</ResponseField>

<ResponseField name="qr_code_number" type="integer">
  QR code generated after the transaction. This will be displayed on the digital bill only.
</ResponseField>

<ResponseField name="billing_pos_number" type="string">
  POS number of the machine that generated the bill. This is applicable if `business_type` is `retail`.
</ResponseField>

<ResponseField name="pos_category" type="string">
  The type of POS machine. This is applicable if `business_type` is `retail`. Possible values:

  * `traditional_pos`
  * `kiosk_pos`
</ResponseField>

<ResponseField name="order_number" type="string">
  Incremental order number of the generated bill.
</ResponseField>

<ResponseField name="order_service_type" type="string">
  Order service type of the generated bill. This is applicable if `business_category` is `food_and_beverages`. Possible values:

  * `dine_in`
  * `take_away`
</ResponseField>

<ResponseField name="delivery_status_url" type="string">
  Order delivery status. This is applicable if `business_type` is `ecommerce`.
</ResponseField>

<ResponseField name="line_items" type="object" required>
  This is an array of objects containing the product data of the bill. Required if `receipt_type` is not `credit_invoice` or `debit_invoice`.
</ResponseField>

<ResponseField name="name" type="string" required>
  Name of the product.
</ResponseField>

<ResponseField name="quantity" type="float" required>
  Quantity of the product.
</ResponseField>

<ResponseField name="unit_amount" type="integer">
  Price of the product.
</ResponseField>

<ResponseField name="employee_id" type="string">
  Unique ID of the employee who sold the product.
</ResponseField>

<ResponseField name="unit" type="string">
  Type of unit. Possible values:

  * `kg`
  * `g`
  * `mg`
  * `lt`
  * `ml`
  * `pc`
  * `cm`
  * `m`
  * `in`
  * `ft`
  * `set`
</ResponseField>

<ResponseField name="description" type="string">
  Product/Item description.
</ResponseField>

<ResponseField name="hsn_code" type="string">
  HSN code of the product.
</ResponseField>

<ResponseField name="product_code" type="string">
  Product/Item code.
</ResponseField>

<ResponseField name="product_uid" type="string">
  Product/Item UID/SKU Code.
</ResponseField>

<ResponseField name="image_url" type="string">
  Image URL of the product.
</ResponseField>

<ResponseField name="total_amount" type="integer" required>
  Total amount of the product.
</ResponseField>

<ResponseField name="brand" type="string">
  Brand name of the product.
</ResponseField>

<ResponseField name="style" type="string">
  Product style.
</ResponseField>

<ResponseField name="colour" type="string">
  Colour of the product.
</ResponseField>

<ResponseField name="size" type="string">
  Size of the product in `cm`.
</ResponseField>

<ResponseField name="tags" type="string">
  An array of strings representing relevant tags associated with the item.
</ResponseField>

<ResponseField name="sub_items" type="object" required>
  An array of objects containing the sub-item details of the item.
</ResponseField>

<ResponseField name="name" type="string" required>
  Name of the sub-item.
</ResponseField>

<ResponseField name="quantity" type="integer" required>
  Sub-item quantity.
</ResponseField>

<ResponseField name="unit_amount" type="integer">
  Price of the sub-item.
</ResponseField>

<ResponseField name="employee_id" type="string">
  Unique ID of the employee who sold the product.
</ResponseField>

<ResponseField name="unit" type="string">
  Type of unit. Possible values:

  * `kg`
  * `g`
  * `mg`
  * `lt`
  * `ml`
  * `pc`
  * `cm`
  * `m`
  * `in`
  * `ft`
  * `set`
</ResponseField>

<ResponseField name="description" type="string">
  Sub-item description.
</ResponseField>

<ResponseField name="hsn_code" type="string">
  HSN code of the product.
</ResponseField>

<ResponseField name="product_code" type="string">
  Sub-item code.
</ResponseField>

<ResponseField name="product_uid" type="string">
  Sub-item UID/SKU Code.
</ResponseField>

<ResponseField name="image_url" type="string">
  Image URL of the sub-item.
</ResponseField>

<ResponseField name="total_amount" type="integer" required>
  Total amount of the sub-item.
</ResponseField>

<ResponseField name="brand" type="string">
  Brand name of the sub-item.
</ResponseField>

<ResponseField name="style" type="string">
  Sub-item style.
</ResponseField>

<ResponseField name="colour" type="string">
  Colour of the sub-item.
</ResponseField>

<ResponseField name="size" type="string">
  Size of the sub-item in `cm`.
</ResponseField>

<ResponseField name="tags" type="string">
  An array of strings representing relevant tags associated with the sub-item.
</ResponseField>

<ResponseField name="taxes" type="object">
  This is an array of objects containing the details of the taxes incurred.
</ResponseField>

<ResponseField name="name" type="string" required>
  Name of the tax. For example, CGST, SGST and so on.
</ResponseField>

<ResponseField name="percentage" type="float">
  Percentage of tax.
</ResponseField>

<ResponseField name="amount" type="integer" required>
  Applicable tax calculated on total amount.
</ResponseField>

<ResponseField name="taxes" type="object">
  This is an array of objects containing the details of the taxes incurred.
</ResponseField>

<ResponseField name="name" type="string" required>
  Name of the tax. For example, CGST, SGST and so on.
</ResponseField>

<ResponseField name="percentage" type="float">
  Percentage of tax.
</ResponseField>

<ResponseField name="amount" type="integer" required>
  Applicable tax calculated on total amount.
</ResponseField>

<ResponseField name="receipt_summary" type="object" required>
  Details of the receipt.
</ResponseField>

<ResponseField name="total_quantity" type="integer" required>
  Total product quantity sold in the invoice.
</ResponseField>

<ResponseField name="sub_total_amount" type="integer">
  The total amount before taxes, discounts and additional fees are added to the invoice.
</ResponseField>

<ResponseField name="currency" type="string" required>
  The currency of the invoice. Refer to this [sheet](/docs/pos/billme/appendix) for the list of supported currencies.
</ResponseField>

<ResponseField name="total_tax_amount" type="integer">
  Total tax amount in paise.
</ResponseField>

<ResponseField name="total_tax_percent" type="float">
  Total tax percentage applied on the receipt.
</ResponseField>

<ResponseField name="net_payable_amount" type="integer" required>
  The total amount payable after adding taxes, discounts and additional fees to the invoice.
</ResponseField>

<ResponseField name="additional_charges" type="object">
  This is an array of objects containing the details of any additional charges applied on the invoice. If `additional_charges` is present, then `description` and `amount` are required.
</ResponseField>

<ResponseField name="description" type="string">
  Description of the additional charge.
</ResponseField>

<ResponseField name="amount" type="integer">
  Amount of the additional charge.
</ResponseField>

<ResponseField name="percent" type="float">
  Percent calculated on total amount.
</ResponseField>

<ResponseField name="payment_status" type="string">
  Status of the payment. Possible values:

  * `pending`
  * `authorized`
  * `failed`
  * `declined`
  * `refunded`
  * `cancelled`
  * `processed`
  * `settled`
  * `voided`
  * `success`
  * `paid`
  * `unpaid`
</ResponseField>

<ResponseField name="change_amount" type="integer">
  Change amount to be returned to the customer if the payment was made in cash.
</ResponseField>

<ResponseField name="roundup_amount" type="integer">
  Change amount to be returned to the customer if the payment was made in cash.
</ResponseField>

<ResponseField name="total_discount_percent" type="float">
  Total percentage of the discount on the sub-total amount without the taxes.
</ResponseField>

<ResponseField name="total_discount_amount" type="integer">
  Total value of the discount on the invoice.
</ResponseField>

<ResponseField name="discounts" type="object">
  This is an array of objects containing the details of the discount.
</ResponseField>

<ResponseField name="name" type="string">
  Name of the discount.
</ResponseField>

<ResponseField name="amount" type="string">
  Amount of the applied discount.
</ResponseField>

<ResponseField name="percent" type="integer">
  Percentile value of the discounted amount.
</ResponseField>

<ResponseField name="used_wallet_amount" type="string">
  Amount used from the customer's wallet for this transaction.
</ResponseField>

<ResponseField name="taxes" type="object" required>
  This is an array of objects containing the details of the taxes applied. Required if `receipt_type` is `tax_inovice`, `purchase_invoice` or `sales_invoice`.
</ResponseField>

<ResponseField name="name" type="string" required>
  Name of the tax. For example, CGST, SGST and so on.
</ResponseField>

<ResponseField name="percentage" type="float">
  Percentage of tax.
</ResponseField>

<ResponseField name="amount" type="integer" required>
  Applicable tax calculated on total amount.
</ResponseField>

<ResponseField name="payments" type="object" required>
  Details of the payment.
</ResponseField>

<ResponseField name="method" type="string" required>
  The mode of payment.
</ResponseField>

<ResponseField name="currency" type="string" required>
  The currency in which the payment was made.
</ResponseField>

<ResponseField name="amount" type="integer" required>
  The amount of the payment in paise. For example, if the amount is `1200`. The unit will be `120000`.
</ResponseField>

<ResponseField name="payment_reference_id" type="string">
  The Unique id of the payment method.
</ResponseField>

<ResponseField name="financier_data" type="object">
  Details of the financier.
</ResponseField>

<ResponseField name="reference" type="string">
  Unique id of the financier.
</ResponseField>

<ResponseField name="name" type="string">
  Name of the financier.
</ResponseField>

<ResponseField name="event" type="object" required>
  Details of the event booking. Required if `business_category` is `events`.
</ResponseField>

<ResponseField name="name" type="string" required>
  Name of the event.
</ResponseField>

<ResponseField name="start_timestamp" type="integer">
  The exact time in seconds when the event starts.
</ResponseField>

<ResponseField name="end_timestamp" type="integer">
  The exact time in seconds when the event ends.
</ResponseField>

<ResponseField name="location" type="string">
  The location/venue of the event.
</ResponseField>

<ResponseField name="room" type="string">
  The specific room where the event was held.
</ResponseField>

<ResponseField name="seats" type="string">
  The number of seats booked for the event.
</ResponseField>

<ResponseField name="receipt_url" type="string">
  The link to the receipt.
</ResponseField>

<ResponseField name="created_at" type="integer">
  UNIX timestamp of the date when the bill was generated.
</ResponseField>

## Errors

<AccordionGroup>
  <Accordion title="client not authorised to update">
    **Code:** `401`

    The client credentials are unauthorised to make changes to this bill.

    **Solution:** Use authorised credentials to make changes to the bill.
  </Accordion>

  <Accordion title="The quantity must be an integer">
    **Code:** `400`

    The quantity of the product was not written in integer format.

    **Solution:** Write the quantity in integer format.
  </Accordion>

  <Accordion title="Operation failed">
    **Code:** `400`

    There is an internal server error.

    **Solution:** There is a server issue. Raise a support ticket with us to get this resolved.
  </Accordion>

  <Accordion title="Bill not found for given receipt_number">
    **Code:** `400`

    The bill id is incorrect or deleted.

    **Solution:** Add the correct bill id.
  </Accordion>
</AccordionGroup>
