remix-shop-items
Create, update, delete, and integrate Remix shop items. Use when a game needs Bits items, consumables, one-time unlocks, tier unlocks, store icons, or purchase handling in @remix-gg/sdk code.
Best use case
remix-shop-items is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Create, update, delete, and integrate Remix shop items. Use when a game needs Bits items, consumables, one-time unlocks, tier unlocks, store icons, or purchase handling in @remix-gg/sdk code.
Teams using remix-shop-items should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/remix-shop-items/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How remix-shop-items Compares
| Feature / Agent | remix-shop-items | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Create, update, delete, and integrate Remix shop items. Use when a game needs Bits items, consumables, one-time unlocks, tier unlocks, store icons, or purchase handling in @remix-gg/sdk code.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
# Manage Shop Items Workflow
## Overview
This skill guides you through creating, managing, and integrating shop items
for games on the Remix platform.
## Prerequisites
- A game must already exist.
- Reuse `gameId` from task context first, then `.remix-cli.json`, then legacy `.remix-mcp.json` when available.
- Use the official CLI or MCP toolchain when possible instead of handwritten HTTP.
## Steps
### 1. Check for Existing Game ID
Read task context or prior tool results first. Otherwise, read `.remix-cli.json`
or legacy `.remix-mcp.json` in the current directory. If either exists and
contains a `gameId`, use that value.
Only if neither file exists or neither has a `gameId` should you
follow the **upload-game** workflow to create one.
### 2. Manage Shop Items
#### List All Items
Always list current items first so you reuse the right `itemId`, avoid duplicate slugs, and see whether an item is already `PENDING`, `ACTIVE`, or `INACTIVE`.
#### Create an Item
```
POST https://api.remix.gg/v1/games/{gameId}/items
Authorization: Bearer $REMIX_API_KEY
Content-Type: application/json
{
"name": "Extra Life",
"slug": "extra-life",
"itemType": "CONSUMABLE",
"bitsCost": 50,
"description": "Spend one to restore a life after game over.",
"iconUrl": "https://asset-url.png"
}
```
- `itemType` is one of `CONSUMABLE`, `ONE_TIME`, or `TIER_UNLOCK`
- `bitsCost` is required for `CONSUMABLE` and `ONE_TIME`
- `tier` is required for `TIER_UNLOCK`
- new items start as `PENDING`
- when using MCP, `createShopItem` can auto-generate an icon if `iconUrl` is omitted for `CONSUMABLE` or `ONE_TIME`
#### Update an Item
```
POST https://api.remix.gg/v1/games/{gameId}/items/{itemId}
Authorization: Bearer $REMIX_API_KEY
Content-Type: application/json
{ "bitsCost": 75, "name": "Extra Life Pack" }
```
Accepts a partial body -- only include fields you want to change.
#### Delete an Item
```
DELETE https://api.remix.gg/v1/games/{gameId}/items/{itemId}
Authorization: Bearer $REMIX_API_KEY
```
### 3. Integrate Shop Items in Game Code
Add the RemixSDK shop integration to your game:
```js
const sdk = window.RemixSDK
await sdk.ready()
function getConsumableBalance(slug, spentKey) {
const purchased = sdk.getItemPurchaseCount(slug)
const spent = Number(sdk.gameState?.[spentKey] || 0)
return Math.max(0, purchased - spent)
}
async function buyExtraLife() {
const result = await sdk.purchase({ item: 'extra-life' })
if (!result.success) showPurchaseError()
}
sdk.onPurchaseComplete(({ success, item }) => {
if (!success || item !== 'extra-life') return
const currentState = sdk.gameState || {}
const spent = Number(currentState.extraLivesSpent || 0)
sdk.singlePlayer.actions.saveGameState({
gameState: {
...currentState,
extraLivesSpent: Math.max(0, spent - 1),
},
})
})
```
## Wrong Patterns
Do NOT do any of the following:
- **Granting items without listening to `onPurchaseComplete`.** Always wait for
the callback before giving the player anything. The purchase may fail or be
cancelled.
- **Using `singlePlayer.actions.purchase(...)` in new code.** Call `sdk.purchase({ item: 'slug' })`.
- **Using `localStorage` to track purchases.** The platform handles purchase
state. Use `hasItem()`, `getItemPurchaseCount()`, `inventory`, and `shopItems`.
- **Hardcoding prices or item metadata in game state.** Read item metadata from
the platform and only persist usage counters in `gameState`.
## Tips
- Use `CONSUMABLE` for repeatable purchases, `ONE_TIME` for permanent unlocks,
and `TIER_UNLOCK` for progression-style items.
- Run `sdk.onPurchaseComplete(...)` even if you also await `sdk.purchase(...)`.
- Use `sdk.getShopItem(slug)` or `sdk.shopItems` when the game needs current
price or icon metadata.Related Skills
remix-upload-game
Upload and validate HTML game code for Remix. Use when creating or updating a draft version through the CLI, MCP tools, or direct REST calls.
remix-upload-asset
Upload images, audio, or 3D models as hosted game assets
remix-submission-rules
Validation and publish constraints for Remix game submissions
remix-save-game
Add save and load game state functionality via RemixSDK
remix-rest-snippets
REST client snippets for Remix agent publishing
remix-open-game
Open a game in the Remix Studio browser for preview and editing
remix-multiplayer
Enable multiplayer support for a Remix game
remix-game-sdk
Reference for the current @remix-gg/sdk runtime. Use when generating or repairing Remix game code, shop item integrations, save-state flows, multiplayer hooks, or host-safe mobile UI behavior.
remix-game-creation
Create a new game draft via the Remix API
remix-game-best-practices
Mobile-first game creation best practices for Remix
remix-cli
Use the official Remix CLI for authentication, config inspection, game creation, uploads, and analytics. Trigger this skill when a task involves `remix login`, `remix whoami`, `.remix-cli.json`, `REMIX_API_KEY`, or terminal-based game management on Remix.
remix-api-reference
OpenAPI-first endpoint reference for Remix game publishing REST routes