Add Game ID
Adds a Steam AppID to HLTB game ID mapping in backend/game_ids.lua.
Input Formats
The skill accepts three input formats:
1. Steam App ID (preferred)
code
/add-game-id 1004640
2. Steam Game Name
code
/add-game-id "FINAL FANTASY TACTICS - The Ivalice Chronicles"
3. Full Mapping
code
/add-game-id 1004640 -> 169173
Instructions
If given an App ID (numeric input):
- •Fetch the Steam store page to verify the AppID exists:
https://store.steampowered.com/app/{APPID} - •Search HLTB for the game (see "Searching HLTB" below)
- •Present confirmation summary and ask user to confirm the mapping
If given a Steam name only:
- •Search for the Steam app ID: WebSearch
{game_name} site:store.steampowered.com - •Extract the AppID from the Steam URL (format:
store.steampowered.com/app/{APPID}/...) - •Verify by fetching:
https://store.steampowered.com/app/{APPID} - •Search HLTB for the game (see "Searching HLTB" below)
- •Present confirmation summary and ask user to confirm the mapping
If given a full mapping (contains ->):
- •Parse the arguments to extract the AppID and HLTB ID
- •Verify the AppID by fetching:
https://store.steampowered.com/app/{APPID} - •Verify the HLTB ID by fetching:
https://howlongtobeat.com/game/{HLTB_ID} - •Proceed directly to adding the mapping
Searching HLTB
Note: Claude cannot directly access howlongtobeat.com, so use IsThereAnyDeal as a proxy.
- •Use WebSearch:
{game_name} IsThereAnyDeal - •Find the IsThereAnyDeal game page in results (format:
isthereanydeal.com/game/{slug}/info/) - •Fetch the IsThereAnyDeal page to get the HLTB game ID and name
- •Construct the HLTB URL:
https://howlongtobeat.com/game/{id}
Confirmation Output Format
Always present this exact format before asking for user confirmation:
code
- **AppID:** {appid}
- **Steam name:** "{name from Steam page}"
- **HLTB ID:** {numeric ID}
- **HLTB name:** "{exact name from HLTB}"
- **HLTB page:** {URL}
Adding the mapping (single entry):
- •Read
backend/game_ids.lua - •Find the correct position to maintain numerical order (ascending by AppID)
- •Insert the new mapping:
[{APPID}] = {HLTB_ID}, -- {HLTB game name} - •Report the mapping that was added
Bulk Additions
When adding many entries at once (e.g., from discover-game-ids.js output):
- •Append all new entries to the end of the file (before the closing
}) - •Don't worry about sort order or duplicates
- •Run
/game-id-reviewto sort numerically and remove duplicates
This is much faster than inserting each entry in the correct position.
Verifying Entries via Steam API
After adding entries, verify them against Steam's API to catch mismatches:
bash
node -e "
const ids = [APPID1, APPID2, ...]; // Add your AppIDs here
(async () => {
for (const id of ids) {
const r = await fetch('https://store.steampowered.com/api/appdetails?appids=' + id);
const d = await r.json();
const name = d[id]?.data?.name || 'N/A';
console.log(id + ': ' + name);
await new Promise(r => setTimeout(r, 200));
}
})();
"
Example Workflow
For app ID 1004640:
- •Fetch Steam page:
https://store.steampowered.com/app/1004640 - •Steam name: "FINAL FANTASY TACTICS - The Ivalice Chronicles"
- •WebSearch: "FINAL FANTASY TACTICS IsThereAnyDeal"
- •Fetch IsThereAnyDeal page to get HLTB game ID
- •Present confirmation:
- •AppID: 1004640
- •Steam name: "FINAL FANTASY TACTICS - The Ivalice Chronicles"
- •HLTB ID: 169173
- •HLTB name: "Final Fantasy Tactics: The Ivalice Chronicles"
- •HLTB page: https://howlongtobeat.com/game/169173
- •User confirms mapping
- •Insert into game_ids.lua in numerical order:
[1004640] = 169173, -- Final Fantasy Tactics: The Ivalice Chronicles