CS2 Inspect Library - v4.0.0
    Preparing search index...

    Class CS2Inspect

    Main CS2 Inspect URL API class

    Index

    Constructors

    Methods

    • Creates an inspect URL from an EconItem

      Parameters

      Returns string

      The generated inspect URL

    • Decodes a MASKED inspect URL into an EconItem (synchronous, offline)

      Only works with MASKED URLs (URLs containing encoded protobuf data). Does NOT work with UNMASKED URLs (market/inventory links) - use inspectItem() instead.

      Parameters

      • url: string

        The MASKED inspect URL to decode

      Returns EconItem

      The decoded item data

      Error if URL is unmasked or invalid

    • Decodes a MASKED inspect URL into an EconItem (synchronous, offline)

      Parameters

      • url: string

        The MASKED inspect URL to decode

      Returns EconItem

      The decoded item data

      Use decodeMaskedUrl() instead for clearer naming

    • Checks if a URL is a valid inspect URL

      Parameters

      • url: string

        The URL to check

      Returns boolean

      True if valid, false otherwise

      Use analyzeUrl() and check for errors instead, or use validateUrl() for detailed validation

    • Normalizes an inspect URL to standard format

      Parameters

      • url: string

        The URL to normalize

      Returns string

      Normalized URL

    • Gets basic URL information without full decoding

      Parameters

      • url: string

        The URL to analyze

      Returns {
          type: "masked" | "unmasked" | "invalid";
          isQuoted: boolean;
          hasValidFormat: boolean;
          estimatedSize?: number;
      }

      Basic URL information

    • Inspects ANY inspect URL (both masked and unmasked) - Universal method

      Works with MASKED URLs (decoded offline using protobuf data) and UNMASKED URLs (fetched via Steam client). Automatically detects URL type.

      Parameters

      • url: string

        Any valid inspect URL (masked or unmasked)

      Returns Promise<EconItem | SteamInspectResult>

      Promise resolving to the decoded item data

      Error if Steam client is required but not available

    • Inspects ANY inspect URL (both masked and unmasked) - Universal method

      Parameters

      • url: string

        Any valid inspect URL (masked or unmasked)

      Returns Promise<EconItem | SteamInspectResult>

      Promise resolving to the decoded item data

      Use inspectItem() instead for clearer naming

    • Initialize Steam client for unmasked URL support

      Returns Promise<void>

      Promise that resolves when Steam client is ready

    • Check if Steam client is available and ready

      Returns boolean

      True if Steam client is ready for inspection

    • Get Steam client status and statistics

      Returns {
          status: SteamClientStatus;
          queueLength: number;
          isAvailable: boolean;
          unmaskedSupport: boolean;
      }

      Steam client status information

    • Check if a URL requires Steam client for inspection

      Parameters

      • url: string

        The URL to check

      Returns boolean

      True if URL requires Steam client

    • Disconnect Steam client

      Returns Promise<void>