> Documentation index: https://roxyapi.com/llms.txt. Building an integration? Read https://roxyapi.com/AGENTS.md first.

# Astrology API quickstart

Your first API call in three steps.

## 1. Get your API key

Already a customer? [Get your API key](/account?tab=keys) from your account. New here? Pick a plan on [pricing](/pricing) and the key lands in your inbox seconds after checkout. No approval queue.

Want to explore first? The [API Playground](/api-reference) lets you browse every endpoint and see real request and response shapes. Try live calls without an API key. Keep production keys on your backend.

## 2. Call your first endpoint

Pick a language tab and paste.


### curl
```bash
curl -X POST https://roxyapi.com/api/v2/tarot/daily \
  -H "X-API-Key: $ROXY_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### TypeScript SDK
```bash
npm install @roxyapi/sdk
```

```typescript
import { createRoxy } from '@roxyapi/sdk';

const roxy = createRoxy(process.env.ROXY_API_KEY!);

const { data } = await roxy.tarot.getDailyCard({ body: {} });
console.log(data.card.name);      // "The Star"
console.log(data.dailyMessage);   // concise daily guidance
```

### Python SDK
```bash
pip install roxy-sdk
```

```python
from roxy_sdk import create_roxy

roxy = create_roxy("your-api-key")

card = roxy.tarot.get_daily_card()
print(card["card"]["name"])       # "The Star"
print(card["dailyMessage"])
```

### PHP SDK
```bash
composer require roxyapi/sdk
```

```php
<?php

use function RoxyAPI\Sdk\createRoxy;

$roxy = createRoxy(getenv('ROXY_API_KEY'));

$card = $roxy->tarot->getDailyCard();
echo $card['card']['name'];    // "The Star"
echo $card['dailyMessage'];
```

### C# SDK
```bash
dotnet add package RoxyApi.Sdk
```

```csharp
using RoxyApi;

var roxy = new RoxyClient(Environment.GetEnvironmentVariable("ROXY_API_KEY")!);

var card = await roxy.Tarot.Daily.PostAsync(new());
Console.WriteLine(card!.Card!.Name);    // "The Star"
Console.WriteLine(card.DailyMessage);   // concise daily guidance
```

### MCP
Register RoxyAPI as an MCP server and a runtime agent (ChatGPT, Claude Desktop, Gemini, n8n) can call every RoxyAPI endpoint in natural language. The quick live test below uses the tarot domain server. Building the integration in a coding agent like Claude Code or Cursor instead? Point those at the keyless docs server, not a calculation server. Full setup in the [MCP guide](/docs/mcp).

```bash
claude mcp add-json --scope user roxy-tarot \
  '{"type":"http","url":"https://roxyapi.com/mcp/tarot","headers":{"X-API-Key":"YOUR_KEY"}}'
```

Then ask Claude: "draw me a tarot card."

## 3. See the response

```json
{
  "date": "2026-04-23",
  "card": {
    "name": "The Star",
    "arcana": "major",
    "keywords": ["Hope", "faith", "renewal"],
    "meaning": "A welcome reprieve after upheaval...",
    "imageUrl": "https://roxyapi.com/img/tarot/major/star.jpg"
  },
  "dailyMessage": "Your card for today: The Star..."
}
```

That is it. Every RoxyAPI endpoint works the same way: send a request, get typed JSON back.

## What to do next

- **Ship production code.** The [SDK guide](/docs/sdk) covers the typed TypeScript, Python, PHP, C#, and Go clients, error handling, and framework examples.
- **Build with AI agents.** The [MCP guide](/docs/mcp) covers the keyless docs server for coding agents (Claude Code, Cursor, Copilot) and the per-domain servers for runtime agents (ChatGPT, Claude Desktop, Gemini, n8n). One command per server, then the agent picks the right tool from natural language.
- **Pick the right endpoint.** Every [domain guide](/docs/guides/astrology) lists the most-used endpoints in order, with copy-paste code per domain.
- **Browse every endpoint.** The [API reference](/api-reference) lets you call any of the 261+ endpoints live in the keyless playground.

## Prefer to vibe-code?

If you are building in Cursor, Claude Code, Bolt, Lovable, or Next.js, paste one of our [AI Prompts](/docs/prompts) and the agent scaffolds a working app end to end. No endpoint-picking required.

## Coding agent? Read AGENTS.md first

If you are an AI coding agent (Cursor, Codex, Windsurf, Aider, Claude Code, Gemini CLI), point yourself at <a href="/AGENTS.md" target="_blank" rel="noopener" title="AGENTS.md execution playbook - Rule 0, common tasks, body shapes, gotchas, no filler. Built for blind agents to ship apps without combing the full docs site.">AGENTS.md</a> first. It is the tight execution playbook with Rule 0 (location first), all common-task body shapes, the error contract, field gotchas, and a jq recipe for reading the OpenAPI spec. Built for blind agents to ship without crawling the full docs site.
