refresh-tarkovdev-schemalisted
Install: claude install-skill diegosouzapw/awesome-omni-skill
# Refresh Tarkov.dev Schema Skill
Use this skill when updating the tarkov.dev GraphQL schema or regenerating the Go client.
---
## When to Use
- Tarkov.dev API has added new fields or types you need
- GraphQL queries are failing with "unknown field" errors
- You want to use new data that's available in the API
- After a major tarkov.dev API update
- Setting up the project for the first time (if schema is missing)
## Quick Update
```bash
# Fetch latest schema and regenerate client
task tarkovdev
```
This runs two steps:
1. `tarkovdev:get-schema` - Downloads the latest schema from tarkov.dev
2. `tarkovdev:regenerate` - Regenerates Go code from your queries
## Step-by-Step Process
### Step 1: Fetch Latest Schema
```bash
task tarkovdev:get-schema
```
**What it does:**
- Introspects the tarkov.dev GraphQL API at `https://api.tarkov.dev/graphql`
- Writes the schema to `internal/tarkovdev/schemas/schema.graphql`
**Requirements:**
- `graphql-inspector` CLI tool (installed via `task deps:install:node`)
- Internet connection to reach api.tarkov.dev
### Step 2: Update Your Queries (if needed)
If you want to use new fields, update your queries in:
```
internal/tarkovdev/schemas/queries.graphql
```
**Example:** Adding a new field to an existing query
```graphql
query GetWeapons {
items(type: weapon) {
id
name
# Add new fields here
weight
basePrice
}
}
```
### Step 3: Regenerate Go Client
```bash
task tarkovdev:regenerate
```
**What it does:**
-