Create invoice returning code 2, the request passed is not valid.

Create invoice returning code 2, the request passed is not valid.

Hello,

I've successfully create contacts and sales orders, but have not been able to create an invoice via the API.
I tried different combinations but the error is always the same.. 

My request is as follows:
  1. {
  2.     "adjustment": 0,
  3.     "adjustment_description": "Adjustment",
  4.     "currency": "USD",
  5.     "currency_id": "551422000000000097",
  6.     "customer_id": "551422000000059003",
  7.     "date": "2017-02-09",
  8.     "discount": 0,
  9.     "discount_type": "entity_level",
  10.     "exchange_rate": 1,
  11.     "invoice_number": "INV-000004",
  12.     "is_inclusive_tax": false,
  13.     "line_items": [
  14.         {
  15.             "description": "laptop description",
  16.             "discount": 0.0,
  17.             "item_id": "551422000000057007",
  18.             "item_order": 0,
  19.             "quantity": 2.0,
  20.             "rate": 122.0,
  21.             "tax_id": "551422000000059015",
  22.             "unit": "qty"
  23.         }
  24.     ],
  25.     "notes": "Thanks for your business.",
  26.     "payment_options": {
  27.         "payment_gateways": [
  28.             {
  29.                 "": "authorize_net"
  30.             }
  31.         ]
  32.     },
  33.     "payment_terms": 30,
  34.     "payment_terms_label": "Net 30",
  35.     "salesorder_id": "551422000000059039",
  36.     "salesperson_name": "Lara",
  37.     "shipping_charge": 7,
  38.     "terms": "Terms"
  39. }



    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 コンテンツ




                              ご検討中の方