# AI skill

The CSPR.cloud API skill is a compact context package for AI coding agents that need to answer questions or generate code against the CSPR.cloud REST API, Streaming API, and Casper Node proxy.

The skill does not copy the full API documentation. It keeps CSPR.cloud-wide rules in the skill file and points agents to the public documentation for endpoint-specific details.

## Skill files

The skill package contains a single required file:

```
cspr-cloud/
  SKILL.md
```

## Installation

Install the skill by downloading the [CSPR.cloud API skill archive](https://casper-assets.s3.us-east-1.amazonaws.com/ai/cspr-cloud-skill.zip) and copying the unpacked `cspr-cloud` directory into the skill directory used by your AI coding tool.

```bash
unzip cspr-cloud-skill.zip
```

For Codex:

```bash
mkdir -p ~/.codex/skills
cp -R cspr-cloud ~/.codex/skills/
```

For Claude Code:

```bash
mkdir -p ~/.claude/skills
cp -R cspr-cloud ~/.claude/skills/
```

The installed directory must contain the `SKILL.md` file at its root.

Maintainers can update the source file from `docs/agentic-skills/cspr-cloud/SKILL.md` in this repository. Public users should use the GitBook download and do not need repository access.

## API key

CSPR.cloud APIs require an access token. Request an access token through [CSPR.cloud](https://cspr.cloud/) and keep it outside source control.

The recommended local setup is an environment variable:

```bash
export CSPR_CLOUD_API_KEY="your-access-token"
```

Ask the agent to read the token from `CSPR_CLOUD_API_KEY` and send it in the `Authorization` header. Do not put CSPR.cloud access tokens in browser code.

For runnable examples, the agent should check for `CSPR_CLOUD_API_KEY` and fail fast or ask you to set it when it is missing. For illustrative snippets, it should use a placeholder instead of a real token.

## Usage

Ask your agent to use the `cspr-cloud` skill when working with CSPR.cloud API requests, response parsing, pagination, optional includes, streaming subscriptions, or examples for Casper dApps.

The skill is designed to make the agent open only the relevant public documentation page for the current task instead of ingesting the whole documentation set.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.cspr.cloud/documentation/ai-skill.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
