API | Room charges | Discounts in your JSON

rodfpangearodfpangea Member Posts: 2

Hello team, 


We are requesting a small change to how you send your discounts to our system for room charging (in the JSON).  

Currently, you are sending nine items in your JSON for one discount. I am wondering if this can be combined into one (REF A)?

We are currently storing each JSON object in our database and obviously this bloats both our systems. Can we optimize this? 

Looking forward to hearing your reply,

Rod


REF A:

 "productGroupName": "Discounts",

                    "productId": 484011,

                    "name": "Friends & Family \u2013 15% (nonalcoholic)",

                    "amount": 1,

                    "price": 0,

                    "totalPriceWithoutVat": 0,

                    "vatPercentage": 0

                },

                {

                    "productGroupName": "Discounts",

                    "productId": 484011,

                    "name": "Friends & Family \u2013 15% (default)",

                    "amount": 1,

                    "price": 0,

                    "totalPriceWithoutVat": 0,

                    "vatPercentage": 0

                },

                {

                    "productGroupName": "Discounts",

                    "productId": 484011,

                    "name": "Friends & Family \u2013 15% (bakedsweets)",

                    "amount": 1,

                    "price": 0,

                    "totalPriceWithoutVat": 0,

                    "vatPercentage": 0

                },

                {

                    "productGroupName": "Discounts",

                    "productId": 484011,

                    "name": "Friends & Family \u2013 15% (prepfood)",

                    "amount": 1,

                    "price": 0,

                    "totalPriceWithoutVat": 0,

                    "vatPercentage": 0

                },

                {

                    "productGroupName": "Discounts",

                    "productId": 484011,

                    "name": "Friends & Family \u2013 15% (gstpst)",

                    "amount": 1,

                    "price": 0,

                    "totalPriceWithoutVat": 0,

                    "vatPercentage": 0

                },

                {

                    "productGroupName": "Discounts",

                    "productId": 484011,

                    "name": "Friends & Family \u2013 15% (notax)",

                    "amount": 1,

                    "price": 0,

                    "totalPriceWithoutVat": 0,

                    "vatPercentage": 0

                },

                {

                    "productGroupName": "Discounts",

                    "productId": 484011,

                    "name": "Friends & Family \u2013 15% (gst)",

                    "amount": 1,

                    "price": -0.460000000000000019984014443252817727625370025634765625,

                    "totalPriceWithoutVat": -0.440000000000000002220446049250313080847263336181640625,

                    "vatPercentage": 0

                },

                {

                    "productGroupName": "Discounts",

                    "productId": 484011,

                    "name": "Friends & Family \u2013 15% (alcbeverages)",

                    "amount": 1,

                    "price": 0,

                    "totalPriceWithoutVat": 0,

                    "vatPercentage": 0

                },

                {

                    "productGroupName": "Discounts",

                    "productId": 484011,

                    "name": "Friends & Family \u2013 15% (gstlst)",

                    "amount": 1,

                    "price": 0,

                    "totalPriceWithoutVat": 0,

                    "vatPercentage": 0

1 comment

Sign In or Register to comment.