---
title: "Create Session"
method: POST
path: "/v1/session/create"
---

# Create Session

`POST /v1/session/create`

## Request

- Base URL: `https://agentpay.tools` (the document declares no server; this is the origin it was published from)
- URL: `https://agentpay.tools/v1/session/create`
- Auth: none declared

Open a budget-capped agent session for $0.01 USDC.

Supports two payment paths:
  Stellar — X-Payment: tx_hash=<hash>,from=<addr>,id=<payment_id>
  Base    — PAYMENT-SIGNATURE: <base64(PaymentPayload JSON)>

On verified payment returns:
  session_id       — unique UUID for this session
  max_spend        — budget cap from request body
  agent_address    — paying agent's address
  gateway_url      — root of agentpay.tools
  tools_endpoint   — where to call tools
  created_at       — ISO 8601 timestamp
  receipt          — tx_hash + network + amount

## Headers

- `x-payment` string, nullable
- `x-agent-address` string, nullable
- `payment-signature` string, nullable

## Request body

- object
  - `agent_address` string, nullable
  - `max_spend` string
  - `label` string, nullable
  - `ttl_seconds` integer, nullable

## Response `200`

Successful Response

- unknown

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/agentpay/apis/agentpay-gateway.md) · [All operations](https://skmtc.dev/agentpay/apis/agentpay-gateway/llms.txt) · [OpenAPI document](https://skmtc.dev/agentpay/apis/agentpay-gateway/revisions/d4dd864c820e?raw)
