# steamwebapi

> Steam Web API Node.js SDK

Latest version **0.0.4** (published 2018-04-22) · Unlicense license · 0 weekly downloads

## Install

```sh
npm install steamwebapi
pnpm add steamwebapi
yarn add steamwebapi
bun add steamwebapi
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.4 |
| Published | 2018-04-22 |
| First published | 2014-06-05 |
| Weekly downloads | 0 |
| License | Unlicense |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 1.1 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Sean Kennedy |
| Maintainers | ksean |
| Keywords | steam, api, node, sdk, web, nodejs, steamwebapi |

## Links

- npm: https://www.npmjs.com/package/steamwebapi
- Repository: https://github.com/ksean/steamwebapi-node-sdk
- Issues: https://github.com/ksean/steamwebapi-node-sdk/issues
- npm.io page: https://npm.io/package/steamwebapi

## Dependencies (1)

- [xmlhttprequest](https://npm.io/package/xmlhttprequest.md) ~1.8.0

## Alternatives

- [@opentelemetry/exporter-zipkin](https://npm.io/package/@opentelemetry/exporter-zipkin.md) — 14.8M weekly downloads
- [pusher-js](https://npm.io/package/pusher-js.md) — 2.0M weekly downloads
- [browserify](https://npm.io/package/browserify.md) — 1.7M weekly downloads
- [sqs-consumer](https://npm.io/package/sqs-consumer.md) — 1.7M weekly downloads
- [@sanity/eventsource](https://npm.io/package/@sanity/eventsource.md) — 930.8K weekly downloads

## Recent versions

- 0.0.4 (latest) — 2018-04-22
- 0.0.3 — 2018-04-21
- 0.0.2 — 2014-08-19
- 0.0.1 — 2014-06-05

## README

Steam Web API Node.js SDK
=========

![Travis CI](https://travis-ci.org/ksean/steamwebapi-node-sdk.svg?branch=master)

Node.js SDK for interfacing with Steam's Web API.

## Requirements

Node.js >= 6.0

## Installation

Run the following command:  
```javascript
npm install steamwebapi
```

## Usage

Require the SDK in your module by adding the following code  
```javascript
var SteamWebAPI = require('steamwebapi');
```

Set your API Key _(Optional, but required for most API requests)_
```javascript
SteamWebAPI.setAPIKey('***My Steam API Key***');
```

Set your response format (Default `json`)
```javascript
SteamWebAPI.setFormat('xml');
```

## Example

Example for retrieving a list of the 5 most recently played games for a given Steam 64 bit ID, and logging the response in console:
```javascript
SteamWebAPI.getRecentlyPlayedGames('76561198020275445', 5, function(response) {
    console.log(response);
});
```

Handling any errors in your request:
```javascript
SteamWebAPI.getRecentlyPlayedGames('76561198020275445', 5, function(response) {
    if (typeof response.error !== 'undefined') {
        console.log(response.error)
    }
    ...
});
```


## Testing

`npm test`

## Documentation

The official Steam documentation is found at: [https://developer.valvesoftware.com/wiki/Steam_Web_API](https://developer.valvesoftware.com/wiki/Steam_Web_API)

SDK Documentation:

`out/module-SteamWebAPI.html`

### Supported Enpoints:

+ `getFriendList`
+ `getGlobalAchievementPercentagesForApp`
+ `getGlobalStatsForGame`
+ `getNewsForApp`
+ `getOwnedGames`
+ `getPlayerAchievements`
+ `getPlayerSummaries`
+ `getRecentlyPlayedGames`
+ `getUserStatsForGame`
+ `isPlayingSharedGame`


## License
[The Unlicense](http://unlicense.org/)

## Latest version

`0.0.4`

---
_Source: https://npm.io/package/steamwebapi · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
