{"id":13703502,"url":"https://github.com/xDimGG/node-steamapi","last_synced_at":"2025-05-05T07:31:06.559Z","repository":{"id":33731655,"uuid":"101834848","full_name":"xDimGG/node-steamapi","owner":"xDimGG","description":"An object-oriented Steam API wrapper for Node.js developers.","archived":false,"fork":false,"pushed_at":"2025-04-15T01:30:37.000Z","size":246,"stargazers_count":194,"open_issues_count":5,"forks_count":48,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-04-22T19:49:19.094Z","etag":null,"topics":["api-wrapper","node","nodejs","object-oriented","promise","steam-api"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/steamapi","language":"TypeScript","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/xDimGG.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-08-30T03:45:42.000Z","updated_at":"2025-04-15T01:30:41.000Z","dependencies_parsed_at":"2024-01-19T00:24:09.080Z","dependency_job_id":"c08cfe14-fc03-4360-907b-72df97d58725","html_url":"https://github.com/xDimGG/node-steamapi","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xDimGG%2Fnode-steamapi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xDimGG%2Fnode-steamapi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xDimGG%2Fnode-steamapi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xDimGG%2Fnode-steamapi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/xDimGG","download_url":"https://codeload.github.com/xDimGG/node-steamapi/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252228473,"owners_count":21715169,"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","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-wrapper","node","nodejs","object-oriented","promise","steam-api"],"created_at":"2024-08-02T21:00:55.939Z","updated_at":"2025-05-05T07:31:06.552Z","avatar_url":"https://github.com/xDimGG.png","language":"TypeScript","funding_links":[],"categories":["Packages"],"sub_categories":["Node.js"],"readme":"## SteamAPI\n\u003cdiv align=\"center\"\u003e\n\t\u003cp\u003e\n\t\t\u003ca href=\"https://www.npmjs.com/package/steamapi\"\u003e\u003cimg src=\"https://nodei.co/npm/steamapi.png?compact=true\" alt=\"\" /\u003e\u003c/a\u003e\n\t\u003c/p\u003e\n\t\u003cp\u003e\n\t\t\u003ca href=\"https://www.npmjs.com/package/steamapi\"\u003e\u003cimg src=\"https://img.shields.io/npm/v/steamapi.svg?maxAge=3600\" alt=\"NPM\" /\u003e\u003c/a\u003e\n\t\t\u003ca href=\"https://discord.gg/6d698nhnKx\"\u003e\u003cimg src=\"https://img.shields.io/discord/1119337655780520057?maxAge=3600\" alt=\"Discord\" /\u003e\u003c/a\u003e\n\t\u003c/p\u003e\n\u003c/div\u003e\n\n## Documentation\nA list of all the methods SteamAPI provides is available [here](https://github.com/xDimGG/node-steamapi/blob/master/docs/classes/default.md#methods).\n\n## Breaking changes from 2.x to 3.x\n- CommonJS Modules -\u003e ES Modules\n- Import using `import` statement instead of `require()`\n- SteamAPI constructor now takes false as the first parameter if you don't want to supply a key\n- Options for constructor have changes from `{ enabled, expires, disableWarnings }` to `{ language, currency, headers, baseAPI, baseStore, baseActions, inMemoryCacheEnabled, gameDetailCacheEnabled, gameDetailCacheTTL, userResolveCacheEnabled, userResolveCacheTTL }`\n- Custom caching may be enabled by setting `inMemoryCacheEnabled: false` and setting `\u003cSteamAPI\u003e.gameDetailCache`/`\u003cSteamAPI\u003e.userResolveCache`. Must implement `CacheMap\u003cK, V\u003e` interface in src/Cache.ts\n- getFeaturedGames() returns object instead of array\n- Server#game -\u003e Server#gameDir\n- App IDs are passed as numbers not strings (although a string will probably still work)\n- Any other changes to the API can be found in https://github.com/xDimGG/node-steamapi/blob/master/PORT.md\n\n## Future plans for 4.x\n- Allow `getGameDetails` to return either a GameDetails object or a map of string to GameDetails depending on if the user supplied a single id or an array of ids.\n- Maybe separate groups of endpoints into different classes so there isn't just a monolithic SteamAPI class? Not quite sure how they would be grouped.\n- Add some convenience methods to the Cache class to reduce double logic in SteamAPI.ts\n\n## Setup\n### Installation\n```\nnpm i steamapi\n```\n### Getting an API Key\nOnce signed into Steam, head over to http://steamcommunity.com/dev/apikey to generate an API key.\n### Usage\nFirst, we start by making a SteamAPI \"user\".\n```js\nimport SteamAPI from 'steamapi';\n\nconst steam = new SteamAPI('steam token');\n```\nNow, we can call methods on the `steam` object.\n\nFor example, let's retrieve the SteamID64 of a user. SteamAPI provides a `resolve` method, which accepts URLs and IDs.\n```js\nsteam.resolve('https://steamcommunity.com/id/DimGG').then(id =\u003e {\n\tconsole.log(id); // 76561198146931523\n});\n```\nNow let's take that ID, and fetch the user's profile.\n```js\nsteam.getUserSummary('76561198146931523').then(summary =\u003e {\n\tconsole.log(summary);\n\t/**\n\tUserSummary {\n\t\tsteamID: '76561198146931523',\n\t\tavatar: {\n\t\t\tsmall: 'https://avatars.steamstatic.com/7875e33529232d95cad28ea1054897618907fa03.jpg',\n\t\t\tmedium: 'https://avatars.steamstatic.com/7875e33529232d95cad28ea1054897618907fa03_medium.jpg',\n\t\t\tlarge: 'https://avatars.steamstatic.com/7875e33529232d95cad28ea1054897618907fa03_full.jpg',\n\t\t\thash: '7875e33529232d95cad28ea1054897618907fa03'\n\t\t},\n\t\turl: 'https://steamcommunity.com/id/DimGG/',\n\t\tvisible: true,\n\t\tpersonaState: 0,\n\t\tpersonaStateFlags: 0,\n\t\tallowsComments: true,\n\t\tnickname: 'dim',\n\t\tlastLogOffTimestamp: 1704553877,\n\t\tcreatedTimestamp: 1406393110,\n\t\trealName: undefined,\n\t\tprimaryGroupID: '103582791457347196',\n\t\tgameID: undefined,\n\t\tgameName: undefined,\n\t\tgameServerIP: undefined,\n\t\tgameServerID: undefined,\n\t\tcountryCode: 'US',\n\t\tstateCode: undefined,\n\t\tcityID: undefined\n\t}\n\t*/\n});\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FxDimGG%2Fnode-steamapi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FxDimGG%2Fnode-steamapi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FxDimGG%2Fnode-steamapi/lists"}