https://github.com/vasar007/steamwebapilib
A .NET wrapper for the Steam API.
https://github.com/vasar007/steamwebapilib
api-wrapper steam steam-api steam-web-api steam-webapi steamapi steamwebapi valve
Last synced: 11 months ago
JSON representation
A .NET wrapper for the Steam API.
- Host: GitHub
- URL: https://github.com/vasar007/steamwebapilib
- Owner: Vasar007
- License: apache-2.0
- Created: 2019-05-14T08:47:30.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2022-12-08T05:33:10.000Z (over 3 years ago)
- Last Synced: 2025-07-21T11:27:58.328Z (11 months ago)
- Topics: api-wrapper, steam, steam-api, steam-web-api, steam-webapi, steamapi, steamwebapi, valve
- Language: C#
- Homepage:
- Size: 59.6 KB
- Stars: 4
- Watchers: 2
- Forks: 1
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# SteamWebApiLib
[](https://www.nuget.org/packages/SteamWebApiLib)
[](https://github.com/Vasar007/SteamWebApiLib/blob/master/LICENSE)
[](https://ci.appveyor.com/project/Vasar007/steamwebapiLib)
[](https://app.fossa.io/projects/git%2Bgithub.com%2FVasar007%2FSteamWebApiLib?ref=badge_shield)
SteamWepApiLib is a .NET wrapper for the Steam API. It provides a set of methods to retrieve various data from the Steam API. Library can interact with Steam Strorefront API and Steam Web API (each API provides a different set of data).
The Steam API is not officially available or documented. So, all data in this library was either collected by trial and error from unofficial API documentation, and is therefore provided as-is.
## Installation
Install [NuGet package](https://www.nuget.org/packages/SteamWebApiLib).
## Usage examples
```cs
using System;
using System.Threading.Tasks;
using SteamWebApiLib;
using SteamWebApiLib.Models.AppDetails;
using SteamWebApiLib.Models.BriefInfo;
using SteamWebApiLib.Models.Featured;
using SteamWebApiLib.Models.FeaturedCategories;
using SteamWebApiLib.Models.PackageDetails;
private static async Task Examples()
{
var steamApiClient = new SteamApiClient();
// Get full list of SteamApps.
SteamAppBriefInfoList steamAppList = await steamApiClient.GetAppListAsync();
Console.WriteLine($"Got {steamAppList.Apps.Length.ToString()} items.");
// Get details for SteamApp with ID 292030 (The Witcher 3: Wild Hunt).
SteamApp steamApp1 = await steamApiClient.GetSteamAppAsync(292030);
Console.WriteLine($"Got response for {steamApp1.Name}.");
// Get details for SteamApp with same ID for region US.
SteamApp steamApp2 = await steamApiClient.GetSteamAppAsync(292030, CountryCode.USA);
Console.WriteLine($"Got response for {steamApp2.Name}.");
// Get details for Package with ID 68179 (Don't Starve Together).
PackageInfo package1 = await steamApiClient.GetPackageInfoAsync(68179);
Console.WriteLine($"Got response for {package1.Name}.");
// Get details for Package with same ID for region JP.
PackageInfo package2 = await steamApiClient.GetPackageInfoAsync(68179, CountryCode.Japan);
Console.WriteLine($"Got response for {package2.Name}.");
// Get a list of featured games.
FeaturedApps featured1 = await steamApiClient.GetFeaturedAppsAsync();
Console.WriteLine($"Got {featured1.FeaturedWin.Length.ToString()} items for Windows.");
// Get a list of featured games for region DE.
FeaturedApps featured2 = await steamApiClient.GetFeaturedAppsAsync(CountryCode.Germany);
Console.WriteLine($"Got {featured2.FeaturedWin.Length.ToString()} items for Windows.");
// Get a list of featured games grouped by category.
FeaturedCategories featuredCategories1 = await steamApiClient.GetFeaturedCategoriesAsync();
Console.WriteLine($"Got {featuredCategories1.TopSellers.Items.Length.ToString()} top sellers items.");
// Get a list of featured games grouped by category for region US.
FeaturedCategories featuredCategories2 = await steamApiClient.GetFeaturedCategoriesAsync(CountryCode.USA);
Console.WriteLine($"Got {featuredCategories2.TopSellers.Items.Length.ToString()} top sellers items.");
}
```
## Dependencies
Target .NET Standard 2.0 and version of C# is 7.1. Project uses further dependencies:
- Newtonsoft.Json v12.0.2;
- Polly v7.1.0.
You can install dependencies using NuGet package manager. Also all dependensies and this project have NuGet packages.
## Additional info
As a basis for project were taken [SteamStorefrontAPI](https://github.com/mmuffins/SteamStorefrontAPI) and [Narochno.Steam](https://github.com/Narochno/Narochno.Steam/).
## License information
This project is licensed under the terms of the [Apache License 2.0](LICENSE).
[](https://app.fossa.io/projects/git%2Bgithub.com%2FVasar007%2FSteamWebApiLib?ref=badge_large)
### Third party software and libraries used
#### [Newtonsoft.Json](https://github.com/JamesNK/Newtonsoft.Json)
Copyright © 2007 James Newton-King
License: [MIT](https://github.com/JamesNK/Newtonsoft.Json/blob/master/LICENSE.md)