API access to use on other app

Can i access my ledger through the API ? because when i try to access bank and cash accounts i get 401 no authorization message, any idea why ?

1 Like

Welcome, as a new user you are encouraged to familiarize yourself with FAQ - Manager Forum most important related to posting (assuming you searched the forum first and used the guides) is;

Be specific. Do not just tell us a feature does not work. Explain what you have done and why you think there is an issue. If your question relates to an apparent software problem (rather than an accounting topic), tell us your operating system (including the version), Manager edition (desktop, server, or cloud), and exactly what you think is wrong. If possible, post screen shots illustrating the problem.

Also:

Manager advances very quickly, simplifying and adding features and capabilities. Sometimes, bugs occur with new releases. But these are usually fixed rapidly, often within minutes. So if you encounter a problem with the desktop or server editions, update Manager, even if you recently did. (The cloud edition is always up to date.) You can check the latest version at https://www.manager.io/desktop/download/ .

Could you explain or share the code you are using to access the API, so that we can identify where the issue might be and provide appropriate suggestions?

Hello @Mabaega,

i used postman to check it first. i attached the pictures

here i got response 200

but here i got response 401

did i do something wrong ?

Try like this

Create Access Token

Add X-API-KEY to Header

i did like you did but still unauthorized

with global i get the access

I didn’t really understand how to use Postman, I just guessed and it worked.

I don’t see any X-API-KEY variable in your Authorization.

image
change this Key to X-API-KEY

Did you add the correct key for the api key, it should be “X-API-KEY”? the resulting query should contain “–header 'X-API-KEY: ****”

1 Like

Thank you so much Ahmad, @eko and @Mabaega! Your solutions were spot on, and they worked perfectly. You all did an amazing job—I really appreciate your help! :raised_hands:

2 Likes