| Availability |
Odoo Online
Odoo.sh
On Premise
|
| Lines of code | 168 |
| Technical Name |
bi_currency_rate |
| License | LGPL-3 |
| Website | https://www.mhdsyarif.com |
| Versions | 15.0 16.0 |
| Availability |
Odoo Online
Odoo.sh
On Premise
|
| Lines of code | 168 |
| Technical Name |
bi_currency_rate |
| License | LGPL-3 |
| Website | https://www.mhdsyarif.com |
| Versions | 15.0 16.0 |
Bank Indonesia Currency Rate Integration
This Odoo module integrates with Bank Indonesia’s official exchange rate data, ensuring your accounting and financial transactions always use the latest rates.
✨ Features
- Automatic Daily Updates
Fetches exchange rates directly from Bank Indonesia every working day via a scheduled cron job. - USD JISDOR Support
Uses the official Jakarta Interbank Spot Dollar Rate (JISDOR) for USD/IDR. - Multi-Currency Support
Updates all active currencies in Odoo (excluding IDR) using Bank Indonesia’s Transaction Rates.
The module calculates the mid-rate from buy & sell values. - Dynamic Currency Detection
No hardcoding required. Only currencies marked as active in Odoo are updated. - Multi-Company Ready
Rates are created and stored per company, supporting multi-company environments seamlessly. - Audit-Ready
Ensures compliance with Indonesian accounting standards by using official BI rates and detailed logging.
🛠 Technical Details
- Extends the
res.currency.ratemodel with a custom methodfetch_bi_rates. - Scrapes official BI pages for:
- JISDOR (USD/IDR).
- Transaction Rates (all other currencies).
- Calculates mid-rates from BI’s buy and sell values.
- Stores rates per company for accounting and reporting.
- Includes robust error handling and logging for transparency.
🚀 Installation
- Download or clone this repository.
- Zip the folder
bi_currency_rate. - Upload and install the module in Odoo Apps.
- The cron job will run daily at 11:30 WIB (GMT+7) to fetch BI rates automatically (weekends excluded).
📌 Usage
- Navigate to Accounting > Configuration > Currencies and ensure your currencies are active.
- The module will automatically update rates for all active currencies except IDR.
- You can also trigger the update manually in Python:
self.env['res.currency.rate'].fetch_bi_rates()
🖼️ Screenshot
Example view of currency rates updated in Odoo:
📑 Notes
- Logs can be checked in
odoo.logfor detailed information about updates, skipped currencies, or parsing issues. - This module scrapes exchange rate data directly from the official Bank Indonesia HTML pages. If Bank Indonesia changes the HTML structure or layout, the parsing logic in the code must be updated accordingly to ensure continued functionality.
🐞 Issue
Report or track issues here https://github.com/mhdsyarif/odoo-addons/issues
Please log in to comment on this module