{
  "$schema": "http://json-schema.org/draft-04/schema",
  "title": "Routes",
  "description": "a list of routes from a connector",
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "source_ledger": {"$ref": "IlpAddress.json"},
      "destination_ledger": {"$ref": "IlpAddress.json"},
      "min_message_window": {
        "type": "number",
        "minimum": 0,
        "description": "the minimum difference (in seconds) between the source and destination transfers' expiries"
      },
      "source_account": {
        "$ref": "IlpAddress.json",
        "description": "the connector's account on source_ledger"
      },
      "destination_account": {
        "$ref": "IlpAddress.json",
        "description": "the connector's account on destination_ledger; (this property is only for local routes)"
      },
      "points": {
        "$ref": "Base64.json",
        "description": "a list of points describing the exchange rate curve"
      },
      "paths": {
        "type": "array",
        "items": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "description": "a list of alternative paths from nextLedger and destinationLedger (each path being a list of ledgers)"
      }
    },
    "required": [
      "source_ledger",
      "destination_ledger",
      "min_message_window",
      "source_account"
    ],
    "additionalProperties": false
  }
}
