One tour as the file it would be
GET
/api/v1/tours/{id}/export
const url = 'http://localhost:11044/api/v1/tours/example/export';const options = {method: 'GET', headers: {'X-Embabel-Api-Key': '<X-Embabel-Api-Key>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url http://localhost:11044/api/v1/tours/example/export \ --header 'X-Embabel-Api-Key: <X-Embabel-Api-Key>'What a user hands to somebody else. Round-trips through the import below, and is byte-for-byte the shape this server loads from a realm — so a tour that was exported, edited and re-imported is not a second dialect.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”id
required
string
The tour’s id as listed by GET /tours, or the declaredId its file gave it; 404 when the acting user’s world has no such tour
Query Parameters
Section titled “Query Parameters”username
string
Username to act as, whose world holds the tours; when it resolves to a user it is used in preference to the authenticated principal. Omitted or blank, the authenticated principal acts; 401 when neither resolves
Responses
Section titled “Responses”The tour’s YAML
Media typetext/plain
string
Basic-auth challenge failed
No tour of that id in this world
Media typetext/plain
Why a tour was refused, in the server’s own words
object
error
required
The refusal, as a sentence to show the user
string

