> For the complete documentation index, see [llms.txt](https://docs.prophetmarket.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.prophetmarket.ai/get-started/api/overview.md).

# Overview

## The Endpoint

All API requests are sent to a single GraphQL endpoint:

```
POST https://app.prophetmarket.ai/graphql
Content-Type: application/json
```

A service discovery document is available at `https://app.prophetmarket.ai/api`, which returns the GraphQL path, a health path, and the service version.

## The Public Boundary

The API is divided into public and authenticated surfaces.

| Area                        | Public                                   | Requires Authentication |
| --------------------------- | ---------------------------------------- | ----------------------- |
| Markets, categories, topics | Listing, filtering, single fetch         | None                    |
| Prices                      | Order book, trades, history              | None                    |
| Resolution                  | Outcome, model votes, transparency       | None                    |
| Configuration               | Betting config, market config, geo check | None                    |
| Positions and balances      | None                                     | Required                |
| Orders and trading          | None                                     | Required                |
| Market creation             | None                                     | Required                |
| Wallet operations           | None                                     | Required                |

Unauthenticated requests to protected fields return a `UNAUTHORIZED` error with a null data payload, rather than an HTTP error status. See [Conventions](broken://pages/211c07926b3764cf8b5ba360ea483316ddca6d33) for error handling.

## Operations

The schema exposes queries, mutations, and subscriptions:

* **Queries:** Used for fetching data (markets, prices, configurations).
* **Subscriptions:** Used for real-time updates via WebSockets.
* **Mutations:** Used for state changes (trading, market creation, wallet operations). Mutations are almost entirely account-scoped and require authentication.

{% hint style="danger" %}
**Order signing is EIP-712**

Placing a settled order requires requesting signing parameters, signing a typed data structure with the account's key, and submitting the signature. It is not a single mutation call.
{% endhint %}

## Rate Limits

Implement backoff, cache aggressively, and do not assume a tight polling loop will always work. Where a [subscription](broken://pages/720f2647cf95b16a4a54f7485457e3f26764248a) exists for the data you want, use it instead of polling.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://docs.prophetmarket.ai/get-started/api/overview.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
