If you’re running Dolibarr v22 and your Multi-Currency Module suddenly stopped syncing exchange rates — throwing an invalid_access_key error from CurrencyLayer — you’re not alone. The fix takes about 30 seconds.
The Problem
CurrencyLayer migrated their API infrastructure to a new domain under APILayer, but Dolibarr v22’s default endpoint URL still points to the old one. The result: your API key is perfectly valid, but the legacy endpoint no longer recognizes it.
Here’s the error you’ll see when testing the connection or when your scheduled CRON job tries to sync rates:
{
"success": false,
"error": {
"code": 101,
"type": "invalid_access_key",
"info": "You have not supplied a valid API Access Key. [Technical Support: support@apilayer.com]"
}
}
This is misleading — your key isn’t actually invalid. It just needs to be sent to the right place.
The Fix
Navigate to Setup → Modules/Applications → Multi-Currency, or go directly to:
/admin/multicurrency.php
Find the API endpoint URL field. It will contain the old default:
https://api.currencylayer.com/live?access_key=__MULTICURRENCY_APP_KEY__&source=__MULTICURRENCY_APP_SOURCE__
Replace it with CurrencyLayer’s current endpoint:
https://api.apilayer.com/currency_data/live?base=__MULTICURRENCY_APP_SOURCE__
Note two changes here:
- The domain moved from
api.currencylayer.comtoapi.apilayer.com/currency_data - The
sourceparameter was renamed tobase, and theaccess_keyparameter is no longer passed in the URL (it’s handled differently by the new endpoint)
Hit save, then use the manual sync button to confirm rates pull correctly before relying on your CRON job again.
Will This Be Fixed in Future Versions?
I believe this will be addressed in Dolibarr v23, but if you’re running v22.0.x and don’t plan to upgrade immediately, this manual endpoint change gets you back up and running right away.
I originally posted this fix on the Dolibarr international forum — check the thread there for any additional community discussion or updates.
Quick Checklist
- Go to
/admin/multicurrency.php - Update the API endpoint URL to the new
api.apilayer.comdomain - Test with the manual sync button
- Confirm your CRON job runs clean on the next scheduled cycle
That’s it. Thirty seconds and your multi-currency rates are flowing again.