MYOBCommunity
Partner Zone
|
|
Partner Zone

Retrieving Data

3 REPLIES
MYOB Staff Post DeveloperJack
131 Posts
MYOB Staff Post
Australia
DeveloperJack
MYOB Staff Post

131Posts

28Kudos

17Solutions

Re: Retrieving Data

Hi there @SeanOng,

Glad to hear you were able to fix this. For further reference (and for anyone else reading this), we also have a best practice guide for company file authentication. x-myobapi-cftoken is not required it the identity has linked their credentials.

Cheers!

Jack

Jack Skinner
MYOBapi Evangelist

Are you a developer? Check out http://developer.myob.com
Looking for an Add-on? Check out http://myob.com/addons/
Contributing Partner SeanOng
5 Posts
Contributing Partner
Australia
SeanOng
Contributing Partner

5Posts

0Kudos

2Solutions

Accepted Solution Solved Solution

Re: Retrieving Data

Ok, I've managed to get it working - I needed to omit the x-myobapi-cftoken key in the Header, which makes sense anyways since we are using OAuth. But it was confusing since it was documented here: http://developer.myob.com/api/accountright/api-overview/headers/

Contributing Partner SeanOng
5 Posts
Contributing Partner
Australia
SeanOng
Contributing Partner

5Posts

0Kudos

2Solutions

Re: Retrieving Data

Update to this:

 

I found out that you can perform a GET on: https://api.myob.com/accountright and it gives the Company File information. I assume that the cf_guid is the Id field from the json response?

 

I then perform another GET with the following: https://api.myob.com/accountright/xxx/Contact and got an "Access denied". Is there some access I need to turn on? I can access the data using the Desktop Application.

 

 

 

[
    {
        "Id": "xxx",
        "Name": "XXX",
        "LibraryPath": "XXX",
        "ProductVersion": "2018.1",
        "ProductLevel": {
            "Code": 30,
            "Name": "Plus"
        },
        "CheckedOutDate": null,
        "CheckedOutBy": null,
        "Uri": "https://ar1.api.myob.com/accountright/xxx",
        "Country": "AU",
        "LauncherId": "xxx",
        "SerialNumber": "xxx"
    }
]

 

 

 

 

 

Contributing Partner SeanOng
5 Posts
Contributing Partner
Australia
SeanOng
Contributing Partner

5Posts

0Kudos

2Solutions

Solved: Go to Solution

Retrieving Data

I'm quite new to the MYOB APIs - trying to connect via the Cloud. I've managed to successfully authentication and I've now got the ACCESS_TOKEN.

 

According to this page: http://developer.myob.com/api/accountright/api-overview/retrieving-data/

 

We need the {domain} and {cf_guid}. I assume {cf_guid} is the Company File guid.

 

I found that {domain} = https://api.myob.com/accountright/

 

How do I go about finding the {cf_guid}?

Didn't find your answer here?
Try using advanced search to find a post more easily Advanced Search
or
Get the conversation started and make a new post Start a Post