Test mode
Build against saved sample data with a test key. It costs nothing, never reaches a supplier and always answers the same way.
A test key, one that starts vl_test_, answers from saved sample data instead of searching suppliers. Use it to build and test your integration. Then switch to a live key, and your code stays the same.
What a test key returns
| Product | What you get, whatever you ask for |
|---|---|
| Flights Search API | One saved search: San Francisco (SFO) to Tokyo Narita (NRT), 9 to 16 February 2027. |
| Hotels Search API | The same saved San Francisco hotels for any search, and one saved hotel, The Westin St. Francis San Francisco on Union Square, for any rates call. The sample stay is 9 to 12 February 2027, for two adults and a child of 7. |
The request is still checked. A malformed date or a missing field fails just as it would with a live key, so test mode catches request bugs.
The saved flight search is a round trip, so its results have two directions even when you ask for a one-way trip.
How to tell which mode answered
Every answer says so in meta.mode:
{
"data": { },
"meta": { "request_id": "req_41ab9c", "mode": "test" }
}mode is test for a test key and live for a live key.
What is the same, and what isn't
- The same: request validation, the response shapes, errors, headers, and paging through results.
- Not the same: the prices and places are samples, and don't change with your request. Don't show test results to travellers.
- Separate: test and live calls are counted separately against your limits, and have their own searches. A
search_idfrom a test key can't be read with a live key.