agwidarsito
4 years agoUser
All POST API endpoints returning empty response
Hello,
So it appears that the POST endpoints for customer, invoice and job no longer return a response body. They work, in a sense that customers, jobs and invoices are indeed created, and a response code of 201 is sent back. But the response has a content-length of zero and an empty body, which is not valid JSON (it used to be).
Is anyone else having this issue? It can easily be reproduced below:
POST /accountright/ID_HERE/Contact/Customer HTTP/1.1 Host: api.myob.com Authorization: Bearer TOKEN_HERE x-myobapi-key: KEY_HERE x-myobapi-version: v2 Content-Type: application/json Accept: application/json Content-Length: 648 {"CompanyName":"Vokke Test 12","Addresses":[{"Location":"1","Street":"12 Fairweather Pde","City":"Officer","State":"VIC","PostCode":"3809","Country":"Australia","Phone1":null,"Email":"adrian@test.com.au","ContactName":"Adrian Gray"}],"IsIndividual":false,"SellingDetails":{"ABN":null,"TaxCode":{"UID":"bd0f9821-4437-4ec2-9c95-c1bdbdd26c7b"},"FreightTaxCode":{"UID":"bd0f9821-4437-4ec2-9c95-c1bdbdd26c7b"},"IncomeAccount":{"UID":"82efbb1a-56e4-4bca-825c-283c8fcb4163"},"Terms":{"PaymentIsDue":"CashOnDelivery","DiscountDate":0,"BalanceDueDate":0,"DiscountForEarlyPayment":0,"MonthlyChargeForLatePayment":0,"VolumeDiscount":0},"Credit":{"Limit":0}}}
Again, this works but the response is empty. Confirmed via PostMan.