Introducing Socket Firewall: Free, Proactive Protection for Your Software Supply Chain.Learn More
Socket
Book a DemoInstallSign in
Socket

steam-miniprofile

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

steam-miniprofile

Fetches miniprofile data on any steam user

latest
Source
npmnpm
Version
0.0.8
Version published
Maintainers
1
Created
Source

node-steam-miniprofile

Table of Contents

  • Introduction
  • Getting Started

Introduction

A module to fetch Steam miniprofile data on any Steam user. This wraps around the https://steamcommunity.com/miniprofile/<ACCOUNTID>/json endpoint.

Getting Started

You can download this from npm using the following command.

npm install steam-miniprofile
Usage

This module exports two functions, getMiniprofile and getMiniprofileByID64 which both return a Promise that resolves to a Miniprofile.

Example
const accountid = "120816906";
const steamid64 = "76561198081082634";
...
const miniprofile = await getMiniprofile(accountid);
console.log(miniprofile.level);
...
const { level, ... } = await getMiniprofileByID64(steamid64);
console.log(level);
...
Types

The interface Miniprofile can be found below.

interface MiniProfile {
    level: number;
    level_class: string; // Determines badge
    avatar_url: string; // Full image url
    persona_name: string; // Current display name

    favorite_badge?: {
        name: string;
        xp: string;
        level: number;
        description: string;
        icon: string;
    },
    profile_background?: {
        "video/webm": string;
        "video/mp4": string;
        image: string; 
    },
    avatar_frame?: string;
}

FAQs

Package last updated on 11 Jul 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts