{"id":30060029,"url":"https://github.com/tiaanduplessis/coinmarketcap-api","last_synced_at":"2025-08-08T01:41:39.120Z","repository":{"id":24012055,"uuid":"100388129","full_name":"tiaanduplessis/coinmarketcap-api","owner":"tiaanduplessis","description":"CoinMarketCap API wrapper for node","archived":false,"fork":false,"pushed_at":"2023-01-13T17:53:26.000Z","size":1838,"stargazers_count":120,"open_issues_count":11,"forks_count":36,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-07-29T20:37:27.864Z","etag":null,"topics":["api","coinmarketcap","wrapper"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tiaanduplessis.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-08-15T14:53:38.000Z","updated_at":"2025-03-05T20:40:38.000Z","dependencies_parsed_at":"2023-01-14T13:25:15.711Z","dependency_job_id":null,"html_url":"https://github.com/tiaanduplessis/coinmarketcap-api","commit_stats":null,"previous_names":[],"tags_count":17,"template":false,"template_full_name":null,"purl":"pkg:github/tiaanduplessis/coinmarketcap-api","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tiaanduplessis%2Fcoinmarketcap-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tiaanduplessis%2Fcoinmarketcap-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tiaanduplessis%2Fcoinmarketcap-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tiaanduplessis%2Fcoinmarketcap-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tiaanduplessis","download_url":"https://codeload.github.com/tiaanduplessis/coinmarketcap-api/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tiaanduplessis%2Fcoinmarketcap-api/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":269352394,"owners_count":24402671,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-07T02:00:09.698Z","response_time":73,"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":["api","coinmarketcap","wrapper"],"created_at":"2025-08-08T01:41:27.098Z","updated_at":"2025-08-08T01:41:39.097Z","avatar_url":"https://github.com/tiaanduplessis.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# coinmarketcap-api\n\n[![Greenkeeper badge](https://badges.greenkeeper.io/tiaanduplessis/coinmarketcap-api.svg)](https://greenkeeper.io/) [![npm package version](https://img.shields.io/npm/v/coinmarketcap-api.svg?style=flat-square)](https://npmjs.org/package/coinmarketcap-api)\n[![npm downloads](https://img.shields.io/npm/dm/coinmarketcap-api.svg?style=flat-square)](https://npmjs.org/package/coinmarketcap-api) [![Standard JS linter](https://img.shields.io/badge/code%20style-standard-brightgreen.svg?style=flat-square)](https://github.com/feross/standard) [![Codecov](https://codecov.io/gh/tiaanduplessis/coinmarketcap-api/branch/master/graph/badge.svg?style=flat-square)](https://codecov.io/gh/tiaanduplessis/coinmarketcap-api)  [![travis ci build status](https://img.shields.io/travis/tiaanduplessis/coinmarketcap-api.svg?style=flat-square)](https://travis-ci.org/tiaanduplessis/coinmarketcap-api)  [![project license](https://img.shields.io/npm/l/coinmarketcap-api.svg?style=flat-square)](https://github.com/tiaanduplessis/coinmarketcap-api/blob/master/LICENSE) [![make a pull request](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](http://makeapullrequest.com)  \n\n\u003e CoinMarketCap API wrapper for node\n\nThis wrapper is based on the free tier of [the CoinMarketCap Professional API](https://pro.coinmarketcap.com/api/v1#section/Introduction).\nYou can get your API key [here](https://pro.coinmarketcap.com/pricing).\n\n## Table of Contents\n\n-   [Install](#install)\n-   [Usage](#usage)\n-   [API](#api)\n-   [Contribute](#contribute)\n-   [License](#license)\n\n## Install\n\n```sh\n$ npm install coinmarketcap-api\n# OR\n$ yarn add coinmarketcap-api\n```\n\n## Usage\n\n```js\nconst CoinMarketCap = require('coinmarketcap-api')\n\nconst apiKey = 'api key'\nconst client = new CoinMarketCap(apiKey)\n\nclient.getTickers().then(console.log).catch(console.error)\nclient.getGlobal().then(console.log).catch(console.error)\n```\n\nCheck out the [CoinMarketCap Pro API documentation](https://pro.coinmarketcap.com/api/v1#section/Introduction) for more information!\n\n## API\n\n\u003c!-- Generated by documentation.js. Update this documentation by updating the source code. --\u003e\n\n#### Table of Contents\n\n-   [constructor](#constructor)\n    -   [Parameters](#parameters)\n-   [getIdMap](#getidmap)\n    -   [Parameters](#parameters-1)\n    -   [Examples](#examples)\n-   [getMetadata](#getmetadata)\n    -   [Parameters](#parameters-2)\n    -   [Examples](#examples-1)\n-   [getTickers](#gettickers)\n    -   [Parameters](#parameters-3)\n    -   [Examples](#examples-2)\n-   [getQuotes](#getquotes)\n    -   [Parameters](#parameters-4)\n    -   [Examples](#examples-3)\n-   [getGlobal](#getglobal)\n    -   [Parameters](#parameters-5)\n    -   [Examples](#examples-4)\n\n### constructor\n\n#### Parameters\n\n-   `apiKey` **[String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** API key for accessing the CoinMarketCap API\n-   `Options` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)?** Options for the CoinMarketCap instance (optional, default `{}`)\n    -   `Options.version`   (optional, default `'v1'`)\n    -   `Options.fetcher`   (optional, default `fetch`)\n    -   `Options.config`   (optional, default `{}`)\n\n### getIdMap\n\nGet a paginated list of all cryptocurrencies by CoinMarketCap ID.\n\n#### Parameters\n\n-   `args`   (optional, default `{}`)\n-   `options` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)?** Options for the request:\n    -   `options.listingStatus` **[String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** active or inactive coins (optional, default `\"active\"`)\n    -   `options.start` **([Number](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Number) \\| [String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String))** Return results from rank start and above (optional, default `1`)\n    -   `options.limit` **([Number](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Number) \\| [String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String))?** Only returns limit number of results\n    -   `options.symbol` **([Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)\u0026lt;[String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)\u003e | [String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String))?** Comma separated list of symbols, will ignore the other options\n    -   `options.sort` **[String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** Sort results by the options at \u003chttps://coinmarketcap.com/api/documentation/v1/#operation/getV1CryptocurrencyMap\u003e (optional, default `\"id\"`)\n\n#### Examples\n\n```javascript\nconst client = new CoinMarketCap('api key')\nclient.getIdMap().then(console.log).catch(console.error)\nclient.getIdMap({listingStatus: 'inactive', limit: 10}).then(console.log).catch(console.error)\nclient.getIdMap({symbol: 'BTC,ETH'}).then(console.log).catch(console.error)\nclient.getIdMap({symbol: ['BTC', 'ETH']}).then(console.log).catch(console.error)\nclient.getIdMap({sort: 'cmc_rank'}).then(console.log).catch(console.error)\n```\n\n### getMetadata\n\nGet static metadata for one or more cryptocurrencies.\nEither id or symbol is required, but passing in both is not allowed.\n\n#### Parameters\n\n-   `args`   (optional, default `{}`)\n-   `options` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)?** Options for the request:\n    -   `options.id` **([Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array) \\| [String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String) \\| [Number](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Number))?** One or more comma separated cryptocurrency IDs\n    -   `options.symbol` **([Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)\u0026lt;[String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)\u003e | [String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String))** One or more comma separated cryptocurrency symbols\n\n#### Examples\n\n```javascript\nconst client = new CoinMarketCap('api key')\nclient.getMetadata({id: '1'}).then(console.log).catch(console.error)\nclient.getMetadata({id: [1, 2]}).then(console.log).catch(console.error)\nclient.getMetadata({symbol: 'BTC,ETH'}).then(console.log).catch(console.error)\nclient.getMetadata({symbol: ['BTC', 'ETH']}).then(console.log).catch(console.error)\n```\n\n### getTickers\n\nGet information on all tickers.\nStart and limit options can only be used when currency or ID is not given.\nCurrency and ID cannot be passed in at the same time.\n\n#### Parameters\n\n-   `args`   (optional, default `{}`)\n-   `options` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)?** Options for the request\n    -   `options.start` **([Number](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Number) \\| [String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String))** Return results from rank start and above (optional, default `1`)\n    -   `options.limit` **([Number](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Number) \\| [String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String))** Only returns limit number of results [1..5000] (optional, default `100`)\n    -   `options.convert` **([Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)\u0026lt;[String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)\u003e | [String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String))** Return info in terms of another currency (optional, default `\"USD\"`)\n    -   `options.sort` **[String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** Sort results by the options at \u003chttps://pro.coinmarketcap.com/api/v1#operation/getV1CryptocurrencyListingsLatest\u003e (optional, default `\"market_cap\"`)\n    -   `options.sortDir` **[String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)?** Direction in which to order cryptocurrencies (\"asc\" | \"desc\")\n    -   `options.cryptocurrencyType` **[String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** Type of cryptocurrency to include (\"all\" | \"coins\" | \"tokens\") (optional, default `\"all\"`)\n\n#### Examples\n\n```javascript\nconst client = new CoinMarketCap('api key')\nclient.getTickers({limit: 3}).then(console.log).catch(console.error)\nclient.getTickers({convert: 'EUR'}).then(console.log).catch(console.error)\nclient.getTickers({start: 0, limit: 5}).then(console.log).catch(console.error)\nclient.getTickers({sort: 'name'}).then(console.log).catch(console.error)\n```\n\n### getQuotes\n\nGet latest market quote for 1 or more cryptocurrencies.\n\n#### Parameters\n\n-   `args`   (optional, default `{}`)\n-   `options` **[Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)?** Options for the request:\n    -   `options.id` **([Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array) \\| [String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String) \\| [Number](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Number))?** One or more comma separated cryptocurrency IDs\n    -   `options.symbol` **([Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)\u0026lt;[String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)\u003e | [String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String))?** One or more comma separated cryptocurrency symbols\n    -   `options.convert` **([Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)\u0026lt;[String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)\u003e | [String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String))** Return quotes in terms of another currency (optional, default `\"USD\"`)\n\n#### Examples\n\n```javascript\nconst client = new CoinMarketCap('api key')\nclient.getQuotes({id: '1'}).then(console.log).catch(console.error)\nclient.getQuotes({id: [1, 2], convert: 'USD,EUR'}).then(console.log).catch(console.error)\nclient.getQuotes({symbol: 'BTC,ETH'}).then(console.log).catch(console.error)\nclient.getQuotes({symbol: ['BTC', 'ETH']}).then(console.log).catch(console.error)\n```\n\n### getGlobal\n\nGet global information\n\n#### Parameters\n\n-   `convert`  \n-   `options` **([Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object) \\| [Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)\u0026lt;[String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)\u003e | [String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String))?** Options for the request:\n    -   `options.convert` **([Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)\u0026lt;[String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)\u003e | [String](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String))** Return quotes in terms of another currency (optional, default `\"USD\"`)\n\n#### Examples\n\n```javascript\nconst client = new CoinMarketCap()\nclient.getGlobal('GBP').then(console.log).catch(console.error)\nclient.getGlobal({convert: 'GBP'}).then(console.log).catch(console.error)\n```\n\n## Contributing\n\nContributions are welcome!\n\n1.  Fork it.\n2.  Create your feature branch: `git checkout -b my-new-feature`\n3.  Commit your changes: `git commit -am 'Add some feature'`\n4.  Push to the branch: `git push origin my-new-feature`\n5.  Submit a pull request :D\n\nOr open up [a issue](https://github.com/tiaanduplessis/coinmarketcap-api/issues).\n\n## License\n\nLicensed under the MIT License.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftiaanduplessis%2Fcoinmarketcap-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftiaanduplessis%2Fcoinmarketcap-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftiaanduplessis%2Fcoinmarketcap-api/lists"}