Title: Cache Exchange Conversion
Last modified: August 8, 2019

---

# Cache Exchange Conversion

 *  [roadsunknown](https://wordpress.org/support/users/roadsunknown/)
 * (@roadsunknown)
 * [6 years, 10 months ago](https://wordpress.org/support/topic/cache-exchange-conversion/)
 * Question about how caching works.
 * Added 10 shortcodes to convert currency on a single post: 1 x USD to KRW, 8 x
   KRW to USD, 1 x USD to COP.
 * The post is not published yet but so far 15 API requests appear on openexchangerates.
   org only from testing. The Exchange Rates Cache is set to 900 (cannot go above
   1000 but only need to check exchange rates 1x per day).
 * Is each set of exchange rates cached, i.e. USD to KRW, KRW to USD, USD to COP
   for a total of 3? Or, is each shortcode instance cached for a total of 10? Or,
   some other calculation?
 * My original assumption was the exchange rates are requested via API once per 
   cache period and every conversion calculation is performed without further API
   requests. Otherwise, the number of API requests will be significant, but that
   does not seem to be the case.
 * What is the proper calculation to estimate how many API requests if for example
   10 views (per day, per post) on 5 posts with 10 convert shortcodes (per post)?
 * Thanks for the help.

Viewing 3 replies - 1 through 3 (of 3 total)

 *  Plugin Contributor [David Artiss](https://wordpress.org/support/users/dartiss/)
 * (@dartiss)
 * [6 years, 10 months ago](https://wordpress.org/support/topic/cache-exchange-conversion/#post-11811561)
 * Hi,
 * If I remember correctly, I don’t use the cache when you preview the ticket (to
   ensure that it’s always shown as the latest, correct, figure). Otherwise, it 
   should be one cache per shortcode.
 *  Thread Starter [roadsunknown](https://wordpress.org/support/users/roadsunknown/)
 * (@roadsunknown)
 * [6 years, 10 months ago](https://wordpress.org/support/topic/cache-exchange-conversion/#post-11811622)
 * Thanks for the quick reply. No cache on preview makes sense. One cache per shortcode
   should be okay. Will follow up once published if API requests are higher than
   expected.
 *  Plugin Contributor [David Artiss](https://wordpress.org/support/users/dartiss/)
 * (@dartiss)
 * [6 years, 10 months ago](https://wordpress.org/support/topic/cache-exchange-conversion/#post-11811712)
 * Sure. Thank you.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Cache Exchange Conversion’ is closed to new replies.

 * ![](https://ps.w.org/artiss-currency-converter/assets/icon.svg?rev=3021002)
 * [Open Currency Converter](https://wordpress.org/plugins/artiss-currency-converter/)
 * [Support Threads](https://wordpress.org/support/plugin/artiss-currency-converter/)
 * [Active Topics](https://wordpress.org/support/plugin/artiss-currency-converter/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/artiss-currency-converter/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/artiss-currency-converter/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [David Artiss](https://wordpress.org/support/users/dartiss/)
 * Last activity: [6 years, 10 months ago](https://wordpress.org/support/topic/cache-exchange-conversion/#post-11811712)
 * Status: not resolved