Zoho Inventory API - List All Item Groups returns invalid JSON

Zoho Inventory API - List All Item Groups returns invalid JSON

Hello,

I have been using Zoho Inventory API, I raised this problem to your team nearly a year ago and had to work around it, but it seems your system is still returning an invalid JSON response.

The details:

When using the Inventory API resource for Item Group "GET /itemgroups/" the response received is not in the format described by the API docs. The doc here describes a JSON where the item groups are returned as a collection, as so: 

  1. {
  2.       "code": 0,
  3.       "message": "success",
  4.       "itemgroups": [
  5.             {
  6.                   "group_id": 622547000000193091,
  7.                   "group_name": "Bags",
  8.                   "product_type": "goods",
  9.                   ........
  10.             },
  11.             {...},
  12.             {...}
  13.       ]
  14. }
Which would be fine, except instead of the documented format I receive a response with JSON in the following form:

  1. {
  2.       "code": 0,
  3.       "message": "success",
  4.       "itemgroups": {
  5.             "group_id": 622547000000193091,
  6.             "group_name": "Bags",
  7.             "product_type": "goods",
  8.             ........
  9.       },
  10.       "itemgroups": {
  11.             ......
  12.       },
  13.       "itemgroups": {
  14.             ......
  15.       },
  16.       "itemgroups": [
  17.             {
  18.                   "group_id": 622547000000193091,
  19.                   "group_name": "Bags",
  20.                   "product_type": "goods",
  21.                   ........
  22.             },
  23.             {...},
  24.             {...}
  25.       ]
  26. }

As you can see the response I receive has the 'item_groups' field repeated as an object of each Item Group, and also receive an 'item_groups' field as a collection of each Item Group.

Using a statically typed language I have no reliable way of parsing this absurd deviation of a JSON response. I haven't event been able to parse the content with third party tools because it is simply an invalid JSON.

I imagine this response is an error because I don't believe any other resources provide this kind of response.

Please issue a fix because I have hit a wall because of this problem.

Thanks,

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




                              ご検討中の方