> Portal Navigation: > > - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version. > - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages). > - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`). > - Top-level index of all portals: https://dev.wix.com/docs/llms.txt > - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt # Method name: getConversionRate(identifiers: GetConversionRateIdentifiers) # Method package: wixEcomV2 # Method menu location: wixEcomV2 --> currencies --> getConversionRate # Method Link: https://dev.wix.com/docs/velo/apis/wix-ecom-v2/currencies/get-conversion-rate.md # Method Description: Returns the conversion rate between 2 currencies. # Method Code Examples: *** Note: do not assume any prop names or enum values other than the ones in the example. ## Return the conversion rate and timestamp (dashboard page code) ```javascript import { currencies } from 'wix-ecom.v2'; currencies.getConversionRate('USD', 'GBP') .then((conversionRate) => { const rate = conversionRate.rate; const timestamp = conversionRate.rateTimestamp; }); /* Promise resolves to: * { * "rate": { * value: "20", * decimalPlaces: 2 * }, * "rateTimestamp": "2020-03-15T20:00:00.181Z" * } */ ``` ## Return the conversion rate and timestamp (export from backend code) ```javascript import { Permissions, webMethod } from 'wix-web-module'; import { currencies } from 'wix-ecom.v2'; export const getConversionRate = webMethod(Permissions.Anyone, async () => { try { const conversionRate = await currencies.getConversionRate('USD', 'GBP'); const rate = conversionRate.rate; const timestamp = conversionRate.rateTimestamp; return conversionRate; } catch (error) { console.error(error); // Handle the error } }); getConversionRate() .then((conversionRate) => { const rate = conversionRate.rate; const timestamp = conversionRate.rateTimestamp; }); /* Promise resolves to: * { * "rate": { * value: "20", * decimalPlaces: 2 * }, * "rateTimestamp": "2020-03-15T20:00:00.181Z" * } */ ``` ---