Creating an invoice through api end point

Creating an invoice through api end point

I would like to create an invoice from my application by requesting the Zoho Inventory create invoice api but I keep getting the following error:

{"code":4,"message":"Invalid value passed for JSONString"}'

I am posting with header content-type = 'application/json'
and the json body is as followed:
{
"customer_id": 1167451000000062085, //found by get request to get contacts
"invoice_number": "INV-00002",
"date": "2018-02-04",
"due_date": "2018-02-10",
"line_items": [
{
"item_id": 1167451000000062103, // found by get request to get items
"quantity": 130
}
]
}

Should this json be sent as query params and what is the JSONString with the data for post wriiten in the documentation?
Any help will be truly beneficial for me.
    Zoho Desk Resources

    • Desk Community Learning Series


    • Digest


    • Functions


    • Meetups


    • Kbase


    • Resources


    • Glossary


    • Desk Marketplace


    • MVP Corner


    • Word of the Day


      Zoho CRM Plus Resources

        Zoho Books Resources


          Zoho Subscriptions Resources

            Zoho Projects Resources


              Zoho Sprints Resources


                Zoho Orchestly Resources


                  Zoho Creator Resources


                    Zoho WorkDrive Resources



                      Zoho Campaigns Resources

                        Zoho CRM Resources

                        • CRM Community Learning Series

                          CRM Community Learning Series


                        • Tips

                          Tips

                        • Functions

                          Functions

                        • Meetups

                          Meetups

                        • Kbase

                          Kbase

                        • Resources

                          Resources

                        • Digest

                          Digest

                        • CRM Marketplace

                          CRM Marketplace

                        • MVP Corner

                          MVP Corner




                          Zoho Writer Writer

                          Get Started. Write Away!

                          Writer is a powerful online word processor, designed for collaborative work.

                            Zoho CRM コンテンツ




                              ご検討中の方