> ## Documentation Index
> Fetch the complete documentation index at: https://docs.agentwonderland.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Publish an Endpoint

> Turn an API operation into a paid Agent Wonderland listing

Builders publish endpoint listings. Each listing points to your API, describes the input shape, sets a price, and chooses where it should appear.

## Create A Draft

Start from whichever source is easiest:

* paste an OpenAPI URL or document
* paste a curl request
* describe one endpoint to the Assistant
* create a workspace file directly

Imported endpoints start as inactive drafts. Nothing is public, searchable, or payable until you activate and publish it.

## Review The Contract

Each endpoint needs:

| Field                    | Why it matters                                           |
| ------------------------ | -------------------------------------------------------- |
| Name and description     | What consumers and agents see in search                  |
| Input schema             | Validates requests before payment                        |
| Upstream method and path | Where Agent Wonderland sends the paid request            |
| Price                    | The per-run charge, or pack-backed pricing if configured |
| Distribution settings    | Catalog, MCP search, AgentCard, and x402 exposure        |

Your upstream endpoint must be reachable over HTTPS and return JSON, raw binary with a matching `Content-Type`, or a 202 async response with a `poll_url`.

## Use Files When Needed

The Files view exposes the same workspace configuration the Assistant edits:

```text theme={null}
provider.yaml
apis/<apiSlug>/api.yaml
apis/<apiSlug>/auth.yaml
apis/<apiSlug>/pricing.yaml
apis/<apiSlug>/distribution.yaml
apis/<apiSlug>/endpoints/<endpointSlug>.yaml
apis/<apiSlug>/tests/<endpointSlug>.json
```

Secrets are never stored in those files. Enter bearer tokens or custom header keys through secure fields; the workspace stores only a secret reference.

## Publish

Before publishing, confirm:

* Stripe Connect is complete.
* Required secrets are saved.
* The endpoint has a price.
* Validation has no blocking errors.
* The endpoint is marked active.

Publishing applies active workspace endpoint files to live runtime records. Live endpoints can appear in the Agent Wonderland catalog, MCP search, AgentCards, direct x402 routes, and external Bazaar-style discovery after settlement activity is observed.

## Operate

Use Endpoints to watch status, failures, revenue, latency, direct run URLs, and distribution health. Use the Assistant when you want to change copy, adjust pricing, explain a validation issue, or prepare a publish action.
