# Use these docs with AI

> Open any page in ChatGPT or Claude, copy it as Markdown, or give an assistant llms.txt and the OpenAPI file.

Source: https://rais.app/docs/ai-tools

Every page of these docs is also available as plain Markdown, and the whole documentation has machine-readable indexes, so you can use it in the AI tools you already work with.

## On every page

The **Copy page** button and the menu next to it, at the top of each page, do these things:

- **Copy page** (also **Copy page as Markdown**) copies the page as Markdown, ready to paste into a chat or an editor.
- **View as Markdown** opens the Markdown version of the page: add `.md` to any docs address, for example `https://rais.app/docs/payments.md`.
- **Open in ChatGPT** and **Open in Claude** start a conversation that asks the assistant to read the Markdown address of the page, so you can ask questions about it. The address in the prompt is always the public one on rais.app.
- **Copy llms.txt URL** and **Copy OpenAPI URL** copy the address of the two files below, to give to a tool that asks for one.

## Files for assistants

| File | What it is |
| --- | --- |
| [`/llms.txt`](https://rais.app/llms.txt) | An index of the documentation: one line per page, with its title, its Markdown address and a one-sentence description. The place an assistant should start. |
| [`/llms-full.txt`](https://rais.app/llms-full.txt) | Every page of the documentation in a single Markdown file. Use it when you want an assistant to answer from all of it. |
| [`/openapi.json`](https://rais.app/openapi.json) | The OpenAPI 3.1 description of every endpoint, with schemas and examples. Use it to generate a client, a Postman collection or tests. |
| `/docs/<page>.md` | One page as Markdown. API reference pages too, for example `/docs/api/create-payment.md`. |

All of them are public, need no authentication, and are the same content as the pages you read here: they are generated from it. The OpenAPI file describes the same API the pages document, and carries the production address `https://api.rais.app/v1` as its server.

## Prompts that work

- "Read https://rais.app/docs/webhooks.md and write a Laravel controller that verifies the Rais-Signature header and marks an order as paid once."
- "Using https://rais.app/openapi.json, generate a typed Python client for the payments and refunds endpoints."
- "Read https://rais.app/llms.txt, then explain what I need to do before I can take live payments."

## Be careful

- Check generated code against the [API reference](https://rais.app/docs/api.md). The details that assistants get wrong most often are **amounts** (integers in centimes: `500000` is 5,000.00 DA), the **raw body** in signature verification, and the idempotency key.
- **Never paste a secret key** or a webhook signing secret into an AI tool, an issue or a chat. Use placeholders such as `rais_sk_test_...`.
- Assistants can be out of date. When an answer disagrees with these pages, the pages are right.
