# SwissPay developer docs

Welcome. This is the reference for the **SwissPay API** — the public endpoints you can call today to create payments and manage customers.

{% hint style="info" %}
SwissPay is in **closed beta**. The API is available in test mode against `https://staging.swisspay.ai`. To request access, write to <info@swisspay.ai>.
{% endhint %}

## I want to…

* **Make my first API call** → [Quickstart](/api-reference/quickstart.md)
* **Get an API key** → [Authentication](/api-reference/authentication.md)
* **Understand idempotent retries** → [Idempotency](/api-reference/idempotency.md)
* **Handle declines and errors correctly** → [Errors](/api-reference/errors.md)
* **Use test cards in sandbox** → [Test cards](/api-reference/test-cards.md)
* **Create a payment** → [Payments](/api-reference/payments.md)
* **Create a customer** → [Customers](/api-reference/customers.md)
* **Let an AI agent call the API** → [Using the API with AI agents (MCP)](/api-reference/using-with-ai-agents.md)
* **Get the OpenAPI spec** → [OpenAPI specification](/api-reference/openapi.md)

## Need help?

* Look something up in the [glossary](/reference/glossary.md).
* Email <support@swisspay.ai> — we usually respond within one business day.
* Report a security issue: see [Responsible disclosure](/security/responsible-disclosure.md).


---

# 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://support.swisspay.ai/readme.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.
