# Wendily API docs > How to integrate with the Wendily API, which lets an AI agent write a trip itinerary (trip, days, and the places, activities, stays, and transport on each day) on a user's behalf. REST, described by OpenAPI 0.6.0, with the same operations as tools on an MCP server. - Base URL: https://sb.wendily.com/functions/v1/api - MCP server: https://wendily.com/mcp (Streamable HTTP; OAuth 2.1, or an API key as the bearer token) - Authentication: `Authorization: Bearer trips_sk_…`, a key the user creates on the Connections page of the Wendily app. Keys are self-serve and free, do not expire, and can be disconnected at any time. - Workflow: call `POST /trips/start` first, before asking the user anything, and keep the returned id. Then `PATCH /trips/{tripId}` with what you learn, add days with `POST /trips/{tripId}/days`, and items with `POST /trips/{tripId}/days/{dayId}/items`. - Conventions: camelCase JSON; success is `{ "data": ... }`; errors are `{ "error": { "code", "message", "details"? } }`; dates `YYYY-MM-DD`, times `HH:MM` in the trip's local time. - Testing: there is no separate sandbox. Trips are private until shared, so test against the live API and archive test trips when done. ## Reference - [OpenAPI specification](https://sb.wendily.com/functions/v1/api/openapi.json): The full API contract. Read this before calling the API. - [API reference](https://wendily.com/docs/api/): The same specification rendered for people. - [MCP server](https://wendily.com/docs/mcp/): How to connect each client, how sign-in works, and every tool. - [Get an API key](https://app.wendily.com/connections): The Connections page, where keys are created and disconnected. - [Agent resource discovery manifest](https://wendily.com/.well-known/ard.json): The API and the MCP server, described for agent discovery. ## Optional - [Wendily overview](https://wendily.com/llms.txt): What Wendily is, for users as well as developers. - [Help](https://wendily.com/help/): Answers to common questions.