WORLDBOOK

Worldbooks | WebMCP | Search | Submit WebMCP

steam WebMCP

Browser tool configuration for steam

URL Pattern: ^https?://store\.steampowered\.com(/.*)?$
Allowed Extra Domains: example.com, store.steampowered.com

Tools (1)

steam_top_sellers()

Steam top selling games

Parameters

limit number - Number of games

JavaScript Handler

(params) => {
  const args = Object.assign({"limit": 10}, params || {});
  let data = null;
  let __wbContextUrl = globalThis.location?.href || '';
  let __wbContextDocument = globalThis.document || null;
    const __wbDefault = (value, fallback) => (value === undefined || value === null || value === '' ? fallback : value);
    const __wbJoin = (value, separator) => Array.isArray(value) ? value.join(separator) : (value ?? '');
    const __wbGet = (value, path) => {
      if (!path) return value;
      return String(path).split('.').reduce((acc, part) => (acc == null ? undefined : acc[part]), value);
    };
    const __wbBaseUrl = () => (__wbContextUrl || globalThis.location?.href || 'https://example.com/');
    const __wbResolve = (target, base) => {
      if (target == null) return '';
      const text = String(target);
      try {
        return /^https?:/i.test(text) ? text : new URL(text, base || __wbBaseUrl()).toString();
      } catch (_error) {
        return text;
      }
    };
    const __wbFetch = async (target, options) => {
      const url = __wbResolve(target, __wbBaseUrl());
      const resp = await globalThis.fetch(url, Object.assign({ credentials: 'include' }, options || {}));
      if (!resp.ok) {
        throw new Error(`HTTP ${resp.status} for ${url}`);
      }
      const text = await resp.text();
      try {
        return { url, text, data: JSON.parse(text) };
      } catch (_error) {
        return { url, text, data: text };
      }
    };
  return (async () => {
    {
      const __wbResp = await __wbFetch("https://store.steampowered.com/api/featuredcategories/");
      data = __wbResp.data;
    }
    data = __wbGet(data, "top_sellers.items");
    {
      const source = Array.isArray(data) ? data : (data == null ? [] : [data]);
      data = source.map((item, index) => ({
        "rank": index + 1,
        "name": item.name,
        "price": item.final_price,
        "discount": item.discount_percent,
        "url": `https://store.steampowered.com/app/${item.id}`,
      }));
    }
    if (Array.isArray(data)) data = data.slice(0, Number(args.limit) || 0);
    return data;
  })();
}

WebMCP clients

Use mcp-chrome, or fetch the same tools from the public API in your own browser automation runtime.

Get Extension →

How to Use WebMCP

WebMCP tools are designed for browser extensions or automation frameworks. The browser extension matches the current URL against the pattern and executes the JavaScript handler when the tool is invoked.

API Endpoint:

GET /api/webmcp/match?url=https://www.steam.com/...

Third-party clients can use the same endpoint as mcp-chrome. Execute the returned JavaScript handler in your own browser page context.