Skip to main content

Claude Code Integration

Claude Code is Anthropic's terminal coding agent — it edits files in your repo, runs commands, and writes real code on your behalf. That makes it the fastest way to build a Skywalk-powered dashboard, sync job, or internal tool: point Claude Code at the Skywalk API description (llms.txt), describe what you want, and it writes the integration code for you.

This guide is about using Claude Code as a coding partner — the dashboard or service it produces is what actually calls Skywalk at runtime. (If you just want to chat with your data, see Claude Chat Integration instead.)

Quick start: point Claude Code at the API description

The fastest way to get Claude Code building against Skywalk is to give it the Skywalk API description file in your first prompt:

https://api.skywalkapi.com/llms.txt

That single URL contains everything Claude Code needs to start writing code: base URL, the X-API-Key authentication header, every available endpoint, the JSON response format, and the async polling pattern. Claude Code will fetch it on demand, so the endpoint list it codes against is always current.

The walkthrough below makes this durable — persisting the spec in CLAUDE.md so every session inherits it, storing the key safely, and shaping prompts that produce real artifacts rather than one-shot scripts.

Before you start

You'll need:

  • Claude Code installed. See the Claude Code install guidenpm install -g @anthropic-ai/claude-code is the usual one-liner.
  • A Skywalk API key for the project you're integrating with — create one from the API Keys page.

1. Scaffold (or open) your project

mkdir my-skywalk-dashboard && cd my-skywalk-dashboard
claude

You can do this inside an existing repo just as easily — Claude Code will add new files alongside what's there. The key is that you're in the directory where the dashboard or integration code should live.

2. Give Claude Code the Skywalk spec

The simplest way to make every future prompt "Skywalk-aware" is to drop a CLAUDE.md at the project root. Claude Code reads this automatically on every session and uses it as durable context — you don't have to re-explain the API each time.

CLAUDE.md
## Skywalk API

This project integrates with the Skywalk REST API for AppFolio data.

- **Full spec:** https://api.skywalkapi.com/llms.txt — fetch this when generating
or updating any Skywalk-calling code, so the endpoint list is always current.
- **Base URL:** https://api.skywalkapi.com/v1/
- **Auth:** every request needs `X-API-Key: <key>`. Read the key from the
`SKYWALK_API_KEY` environment variable — never hard-code it, never commit it.
- **Async polling:** if a response has `meta.status` of `"updating"` or `"stale"`,
wait 10 seconds and retry. Any client code calling Skywalk must implement this loop.
- **Rate limit:** 1 request per second per key.
- **Response shape:** `{ meta, links, data }`.

llms.txt is the authoritative endpoint catalog. By telling Claude Code to fetch it on demand — rather than pasting endpoint lists into the prompt — the code it generates stays current as Skywalk adds endpoints.

3. Store your API key as an environment variable

Add the key to your shell, not to the repo:

export SKYWALK_API_KEY="sk_live_…"

Then in your app, read it from process.env.SKYWALK_API_KEY / os.environ["SKYWALK_API_KEY"] / whatever your stack uses. Add a .env.example to the repo (with the variable name but no value) and a .env line to .gitignore. If you ask Claude Code to "wire up env handling" in step 4 it will set this up for you.

Good for getting started — not the most secure

Environment variables are the fastest way to start building, but they're not the strongest place to keep a production API key. The value sits in plaintext in your shell's history, in ~/.zshrc or ~/.bashrc if you persist it there, and in the environment of every process you launch from that shell — including anything Claude Code runs. Before you ship the dashboard to teammates or deploy it anywhere shared, move the key into a proper secrets manager (1Password, AWS Secrets Manager, Cloudflare Worker secrets, Vercel/Netlify environment secrets, Doppler, etc.) and rotate the bootstrap key.

4. Ask Claude Code to build it

With CLAUDE.md in place, prompts can stay at the product level — describe what you want, not which endpoints to hit. A few examples that work well:

  • "Scaffold a Next.js dashboard with a sidebar of properties and a main panel that shows the rent roll and cash flow for the selected one. Use shadcn/ui. Read the API key from SKYWALK_API_KEY."
  • "Write a Python ETL that pulls every property's monthly cash flow into a local SQLite database. Idempotent — re-running shouldn't duplicate rows. Include a small CLI."
  • "Build a FastAPI service that exposes /vacancies and /aged-receivables endpoints, each backed by a Skywalk call with the right async polling, and a 5-minute in-memory cache."
  • "Add a daily Cloudflare Worker cron that emails me a markdown summary of work orders older than 30 days, grouped by property."
  • "Generate a typed TypeScript client for the Skywalk endpoints I'll actually use in this project (properties, units, rent roll, cash flow). Include the polling helper."

Claude Code will fetch llms.txt, pick the right endpoints, scaffold the project, install dependencies, write the Skywalk-calling code, and run it to verify. Ask for tests in the same prompt if you want them.

5. Make sure async polling lands in the code

Skywalk endpoints can return meta.status: "updating" while AppFolio refreshes — every client needs a small poll loop. Your CLAUDE.md tells Claude Code to implement this, but it's worth grepping the generated code to confirm. The Manual Context → Async Polling page has reference implementations in Python and TypeScript that you can also paste into a prompt if Claude Code's first pass misses it.

Tips for working with Claude Code on Skywalk projects

  • Let it iterate. Ask it to run the dashboard / script after writing it and fix whatever breaks. The faster the inner loop, the better the final code.
  • Tighten CLAUDE.md over time. When you correct the same thing twice (a date format, an output directory, a preferred chart library), promote that correction into CLAUDE.md so future sessions get it for free.
  • Treat llms.txt as live. Re-fetch it when adding new features — Skywalk adds endpoints periodically, and Claude Code only knows what the latest fetch told it.
  • Keep the key out of generated code. If you see X-API-Key: sk_live_... literal in a diff, push back — it should always come from the env var.

Next steps