{"id":49453669,"url":"https://github.com/continuous-software/oxr","last_synced_at":"2026-06-02T05:00:46.326Z","repository":{"id":25177133,"uuid":"28600293","full_name":"continuous-software/oxr","owner":"continuous-software","description":"💱 Advanced node.js wrapper for the Open Exchange Rates API","archived":false,"fork":false,"pushed_at":"2023-01-05T16:36:26.000Z","size":507,"stargazers_count":72,"open_issues_count":3,"forks_count":6,"subscribers_count":5,"default_branch":"master","last_synced_at":"2026-04-16T15:48:42.847Z","etag":null,"topics":["currencies","forex","javascript","money","openexchangerates"],"latest_commit_sha":null,"homepage":"https://openexchangerates.org/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/continuous-software.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-12-29T17:37:10.000Z","updated_at":"2025-04-06T11:24:05.000Z","dependencies_parsed_at":"2023-01-14T02:16:01.410Z","dependency_job_id":null,"html_url":"https://github.com/continuous-software/oxr","commit_stats":null,"previous_names":["continuous-software/open-exchange-rate-promise"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/continuous-software/oxr","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/continuous-software%2Foxr","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/continuous-software%2Foxr/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/continuous-software%2Foxr/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/continuous-software%2Foxr/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/continuous-software","download_url":"https://codeload.github.com/continuous-software/oxr/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/continuous-software%2Foxr/sbom","scorecard":{"id":303563,"data":{"date":"2025-08-11","repo":{"name":"github.com/continuous-software/oxr","commit":"1ef55467cdec77dc4595e8e67b30e0e14836c01e"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":1.4,"checks":[{"name":"Code-Review","score":1,"reason":"Found 2/18 approved changesets -- score normalized to 1","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":0,"reason":"license file not detected","details":["Warn: project does not have a license file"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 14 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":0,"reason":"17 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-968p-4wvh-cqc8","Warn: Project is vulnerable to: GHSA-67hx-6x53-jw92","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg","Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275","Warn: Project is vulnerable to: GHSA-gxpj-cx7g-858c","Warn: Project is vulnerable to: GHSA-2j2x-2gpw-g8fm","Warn: Project is vulnerable to: GHSA-fjxv-7rqg-78g4","Warn: Project is vulnerable to: GHSA-896r-f27r-55mw","Warn: Project is vulnerable to: GHSA-9c47-m6qq-7p4h","Warn: Project is vulnerable to: GHSA-f8q6-p94x-37v3","Warn: Project is vulnerable to: GHSA-hrpp-h998-j3pp","Warn: Project is vulnerable to: GHSA-p8p7-x288-28g6","Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw","Warn: Project is vulnerable to: GHSA-52f5-9888-hmc6","Warn: Project is vulnerable to: GHSA-72xf-g2v4-qvf3","Warn: Project is vulnerable to: GHSA-j8xg-fqg3-53r7"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-17T21:23:53.449Z","repository_id":25177133,"created_at":"2025-08-17T21:23:53.449Z","updated_at":"2025-08-17T21:23:53.449Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33806987,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-02T02:00:07.132Z","response_time":109,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["currencies","forex","javascript","money","openexchangerates"],"created_at":"2026-04-30T04:01:03.703Z","updated_at":"2026-06-02T05:00:46.320Z","avatar_url":"https://github.com/continuous-software.png","language":"JavaScript","funding_links":[],"categories":["📦 Legacy \u0026 Inactive Projects"],"sub_categories":[],"readme":"[![Build Status](https://travis-ci.org/continuous-software/oxr.svg?branch=master)](https://travis-ci.org/continuous-software/oxr) [![Coverage Status](https://coveralls.io/repos/continuous-software/oxr/badge.svg?branch=master)](https://coveralls.io/r/continuous-software/oxr?branch=master)\n\n# Open eXchange Rates\n\nA Node.js client for the [Open Exchange Rates](https://openexchangerates.org) API.  \nOur client is designed to return Promises and provide a flexible caching capability.\n\n## Install\n\n`npm install --save oxr`\n\n## Usage\n\nUse the factory to create any number of client instances using your API keys\n\n```javascript\nvar oxr = require('oxr')\nvar service = oxr.factory({\n  appId: process.env.OXR_APP_ID || '\u003cYOUR_APP_ID\u003e'\n})\n\nservice.latest().then(function(result){\n  var rates = result.rates\n  console.log(rates)\n})\n\n```\n\n## Service API\n\n* [latest(query, options)](https://github.com/continuous-software/oxr#latestquery-options)\n* [historical(date, query, options)](https://github.com/continuous-software/oxr#historicaldate-query-options)\n* [currencies(query, options)](https://github.com/continuous-software/oxr#currenciesquery-options)\n\n### latest(query, options)  \n**@params query** *(optional)* - A map of query string parameters to pass to the http call.  \n**@params options** *(optional)*- An object to merge with the http options sent to the remote API.  \n**@returns** - A promise with the latest rates from openexchangerates.org if resolved, reject with an Instance if the remote API returns an error response or with a standard Error otherwise.\n\n### historical(date, query, options)  \n**@params date** - Date object or a String which would result in a valid Date object if called with the Date constructor.  \n**@params query** *(optional)* - A map of query string parameters to pass to the http call.  \n**@params options** *(optional)* - An object to merge with the http options sent to the remote API.  \n**@returns** - A promise with the rates at the requested date from openexchangerates.org if resolved, reject with an Instance if the remote API returns an error response or with a standard Error otherwise.\n\n### currencies(query, options)  \n**@params query** *(optional)* - A map of query string parameters to pass to the http call.  \n**@params options** *(optional)* - An object to merge with the http options sent to the remote API.  \n**@returns** - A promise with the list of currency codes from openexchangerates.org if resolved, reject with an Instance if the remote API returns an error response or with a standard Error otherwise.\n\n## Cache Decorator\nYou can also decorate the service methods with a cache.  \n\n**@params method** *(optional)* - the method to decorate.\u003cbr\u003e\nDefaults to *latest*\n\n**@params store**\n- **@params store.get(...methodArgs)** - called before a request is sent to the remote API, use this getter to retrieve a value from the cache. can resolve a promise.\n- **@params store.put(value, ...methodArgs)** - called after the request completed, use this setter to store the value in cache. can resolve a promise.\n\n**@params tll** *(optional)* - If the timestamp of the cached rates plus its time to live (ttl) in ms is higher than the current timestamp, the service will call the remote API, otherwise, it will take the value from the cache.\u003cbr\u003e\nDefaults to 24 hours for *latest* and to Infinity for *currencies* and *historical*\n\nIf an error returned from the remote API, the service will fall back to the cached value if any, even if the cache has expired.\n\n**@returns** - decorated service\n\n\n ```javascript\nvar oxr = require('oxr')\nvar service = oxr.factory({\n  appId: process.env.OXR_APP_ID || '\u003cYOUR_APP_ID\u003e'\n})\n\nservice = oxr.cache({\n  method: 'latest',\n  ttl: 7 * 24 * 1000 * 3600,\n  store: {\n    get: function () {\n      return Promise.resolve(this.value)\n    },\n    put: function (value) {\n      this.value = value\n      return Promise.resolve(this.value)\n    }\n  }\n}, service)\n```\n\nYou can decorate the service more than once, with different cache strategy for each method\n```js\nservice = oxr.cache({\n  method: 'historical',\n  store: {\n    cache: {},\n    get: function (date) {\n      return this.cache[date];\n    },\n    put: function (value, date) {\n      this.cache[date] = value;\n    }\n  }\n}, service)\n\n\n// note how the arguments that you pass to the decorated method\n// are also passed to `get` and `put`\nservice.historical('2017-11-16')\n  .then((value) =\u003e { ... })\n```\n\n\n\n\n\n## Error Handling\n\nIf the remote service returns an error, Promises are rejected with an instance of OxrError.\n\n```javascript\nvar oxr = require('oxr')\nvar service = oxr.factory({\n  appId: '\u003cWRONG_APP_ID\u003e'\n})\n\nservice.latest().catch(function (error) {\n  assert(error instanceof oxr.OxrError)\n  assert.equal(error.status, 401)\n  assert.equal(error.message, 'invalid_app_id')\n  assert.equal(error.description, 'Invalid App ID provided - please sign up at https://openexchangerates.org/signup, or contact support@openexchangerates.org. Thanks!')\n})\n```\n\n## Contributing\n\n[![js-standard-style](https://cdn.rawgit.com/feross/standard/master/badge.svg)](https://github.com/feross/standard)\n\n## License\n\nThis module is distributed under the MIT license.\n\n\u003e Copyright (C) 2014 Laurent Renard.\n\u003e\n\u003e Permission is hereby granted, free of charge, to any person\n\u003e obtaining a copy of this software and associated documentation files\n\u003e (the \"Software\"), to deal in the Software without restriction,\n\u003e including without limitation the rights to use, copy, modify, merge,\n\u003e publish, distribute, sublicense, and/or sell copies of the Software,\n\u003e and to permit persons to whom the Software is furnished to do so,\n\u003e subject to the following conditions:\n\u003e\n\u003e The above copyright notice and this permission notice shall be\n\u003e included in all copies or substantial portions of the Software.\n\u003e\n\u003e THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n\u003e EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n\u003e MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n\u003e NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS\n\u003e BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN\n\u003e ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\n\u003e CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\n\u003e SOFTWARE.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcontinuous-software%2Foxr","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcontinuous-software%2Foxr","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcontinuous-software%2Foxr/lists"}