Forum Discussion
Hi Will_H ,
Good day to you! Thank you for your reply.
1. What endpoint is being queried?
I am using the endpoint /{cf_uri}/Contact/Supplier
https://arl2.api.myob.com/accountright/${myobCompanyFileId}/Contact/Supplier
2. What headers I am specifying?
headers: {
'Authorization': `Bearer ${token.access_token}`,
'x-myobapi-key': clientId,
'x-myobapi-version': 'v2',
'Accept-Encoding': 'gzip,deflate',
'Content-Type': 'application/json'
}
Thank you for the links that you have sent. I have browsed through them and would like to give some feedback.
Endpoint documentation for that API should be here:
https://developer.myob.com/api/myob-business-api/v2/contact/supplier/
This is the official MYOB Documentation Webpage, but it is outdated. The Documentation states that only CompanyName is required when IsIndividual is false. However POSTing a body like
{
CompanyName: "PolarBear",
IsIndividual: false
}
Will result in the same error as above
For the Postman link, I would like to thank the MYOB Team for creating this collection. I have heavily referenced it in my building of API Calls.
I copied the Body of the example of the contact/supplier API End Point in the Postman Collection but still get the same error as shown in my original post.
Thanks again for your reply and hope to hear from you soon!
Looking for something else?
Search the Community Forum for answers or find your topic and get the conversation started!
Find technical support and help for all MYOB products in our online help centre
Dig into MYOB Academy for free courses, learning paths and live events to help build your business with MYOB.