VistaLink in Codex.
Add three lines to Codex's config and it can search hotels, read their content and price direct rates for you.
This works in the Codex CLI and the Codex IDE extension. Both read the same config file, so you set it up once.
Set your key.
Get a free key from onboarding and put it in your shell's environment. Codex reads it from there, so it never sits in a file.
export VISTALINK_API_KEY="vl_live_..."The server also answers without a key, with a lower limit and fewer tools. That is enough to try it, not to build on.
Add the server.
Add this to ~/.codex/config.toml. To set it up for one repository instead, put it in .codex/config.toml there; Codex reads that file once you trust the project.
[mcp_servers.vistalink]
url = "https://api.vistalink.com/mcp"
bearer_token_env_var = "VISTALINK_API_KEY"Codex sends the value of VISTALINK_API_KEY as a bearer token on every request to the server.
Start a new Codex session after saving. In the IDE extension, restart the extension.
We suggest the file over codex mcp add --url. Our server also supports signing in with a Parley account, and that command starts the sign-in flow as soon as it sees it.
Check it works.
List your servers. vistalink should be there, enabled, with Bearer token as its auth.
codex mcp listInside a Codex session, /mcp shows the same list. Then ask:
Find three quiet hotels near the Trevi Fountain in Rome.Codex should call search_hotels and come back with hotels a few streets from the fountain, each with a link to its page.
Building an integration.
When you want Codex to write code against the REST API, not call tools for you, give it the brief for the task. Each one is a single Markdown page: auth, the call, a working request and the rules that trip people up.
- Search: Add hotel search: a traveller’s sentence (or filters) in, ranked hotels out.
- Hotel content: Show a full hotel page: gallery, rooms, policies, reviews and amenities for one hotel.
- Rates: Show the price each hotel charges on its own booking engine for the traveller’s dates.
- Room matching: Match one hotel’s rooms across its own site, its booking engine, booking sites and your own room list.
- Bookings: Book an offer on the hotel’s own engine, with the guest paying the hotel.
To have Codex read them without asking, add this to the AGENTS.md at the root of your repository.
## VistaLink hotel API
Before writing code against the VistaLink API, fetch the brief for the task:
- Search: https://vistalink.com/developers/agents/search
- Hotel content: https://vistalink.com/developers/agents/hotel-content
- Rates: https://vistalink.com/developers/agents/rates
- Room matching: https://vistalink.com/developers/agents/rooms
- Bookings: https://vistalink.com/developers/agents/bookings
Read the API key from the VISTALINK_API_KEY environment variable.
Never write it into code or config.The full reference.
The MCP docs list every tool, the endpoint behind it and its price. OpenAI documents the config options in Codex's MCP guide.