tmijail / Odoo-Power-BI-Connector

Query Odoo from Power BI.
Mozilla Public License 2.0
76 stars 52 forks source link

Odoo API key compatibility #13

Closed simonriskjaer closed 1 year ago

simonriskjaer commented 1 year ago

From Odoo V14 API keys can be used instead of traditional username/pass as auth method. When 2-factor auth is enabled for a user, an authentication error occurs:

image

The API key is thus mandatory when using the JsonRPC API with a user that has 2-factor auth enabled.

Being able to choose authentication method by API key would solve this issue.

https://www.odoo.com/documentation/16.0/developer/api/external_api.html#api-keys

tmijail commented 1 year ago

If I recall correctly, you can just use the API key instead of the password.

From your link:

The way to use API Keys in your scripts is to simply replace your password by the key

Could you check?

simonriskjaer commented 1 year ago

Yep - that does seem to work just fine.

Thank you for investigating, and sorry for the inconvenience.