{
  "agentsJson": "0.1.0",
  "info": {
    "title": "AplusZ flight fares",
    "version": "1.0.0",
    "description": "I want to fly from <city A> to <city B> - what is the cheapest fare, what was the 6-month low, and which date is cheapest to book?",
    "contact": {
      "email": "dagrang@gmail.com",
      "url": "https://aplusz.app"
    }
  },
  "sources": [
    {
      "id": "aplusz-api",
      "path": "https://aplusz.app/openapi.json",
      "description": "Keyless fare read API"
    }
  ],
  "flows": [
    {
      "id": "cheapest-fare-for-named-cities",
      "title": "Cheapest fare between two cities the user named in plain language",
      "description": "Resolve two spoken city names to IATA codes, then read the fare record for that pair.",
      "actions": [
        {
          "id": "resolve-origin",
          "sourceId": "aplusz-api",
          "operationId": "listCities"
        },
        {
          "id": "resolve-destination",
          "sourceId": "aplusz-api",
          "operationId": "listCities"
        },
        {
          "id": "read-fare",
          "sourceId": "aplusz-api",
          "operationId": "getFare"
        }
      ],
      "links": [
        {
          "origin": {
            "actionId": "resolve-origin",
            "fieldPath": "cities[0].iata"
          },
          "target": {
            "actionId": "read-fare",
            "fieldPath": "from"
          }
        },
        {
          "origin": {
            "actionId": "resolve-destination",
            "fieldPath": "cities[0].iata"
          },
          "target": {
            "actionId": "read-fare",
            "fieldPath": "to"
          }
        }
      ]
    },
    {
      "id": "cheapest-destinations-then-detail",
      "title": "Find the cheapest places to fly from one city, then price the one the user picks",
      "description": "List destinations by price from an origin, then read the full record for the chosen destination.",
      "actions": [
        {
          "id": "list",
          "sourceId": "aplusz-api",
          "operationId": "listRoutes"
        },
        {
          "id": "detail",
          "sourceId": "aplusz-api",
          "operationId": "getFare"
        }
      ],
      "links": [
        {
          "origin": {
            "actionId": "list",
            "fieldPath": "routes[0].to"
          },
          "target": {
            "actionId": "detail",
            "fieldPath": "to"
          }
        }
      ]
    }
  ]
}