{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$defs": {
    "Bindings": {
      "properties": {
        "primary": {
          "type": "string"
        },
        "http": {
          "$ref": "#/$defs/HTTPPrefix"
        }
      },
      "type": "object",
      "required": [
        "primary",
        "http"
      ],
      "description": "Bindings names the primary binding and the base of each one offered."
    },
    "Build": {
      "properties": {
        "revision": {
          "type": "string"
        },
        "dirty": {
          "type": "boolean"
        },
        "go": {
          "type": "string"
        }
      },
      "type": "object",
      "required": [
        "revision",
        "dirty",
        "go"
      ],
      "description": "Build identifies the binary that answered: the version-control revision it was built from and whether that tree was dirty, from the binary's build information or from values stamped at link time, else \"unknown\" and true."
    },
    "HTTPBinding": {
      "properties": {
        "method": {
          "type": "string"
        },
        "path": {
          "type": "string"
        }
      },
      "type": "object",
      "required": [
        "method",
        "path"
      ],
      "description": "HTTPBinding carries an operation as one request and one response."
    },
    "HTTPPrefix": {
      "properties": {
        "prefix": {
          "type": "string"
        }
      },
      "type": "object",
      "required": [
        "prefix"
      ],
      "description": "HTTPPrefix is where the application routes of the HTTP binding live."
    },
    "Operation": {
      "properties": {
        "name": {
          "type": "string"
        },
        "kind": {
          "type": "string"
        },
        "doc": {
          "type": "string"
        },
        "params": {
          "items": {
            "$ref": "#/$defs/Param"
          },
          "type": "array"
        },
        "request": {
          "type": "string",
          "description": "body type; \"bytes\" or \"records\" for raw bodies"
        },
        "response": {
          "type": "string",
          "description": "result type; \"bytes\" or \"records\" for raw bodies"
        },
        "errors": {
          "items": {
            "type": "string"
          },
          "type": "array",
          "description": "refusals beyond bad_request"
        },
        "http": {
          "$ref": "#/$defs/HTTPBinding"
        }
      },
      "type": "object",
      "required": [
        "name",
        "kind",
        "doc",
        "params",
        "errors",
        "http"
      ],
      "description": "Operation is one row of api/operations.json."
    },
    "Param": {
      "properties": {
        "name": {
          "type": "string"
        },
        "kind": {
          "type": "string"
        },
        "required": {
          "type": "boolean"
        },
        "doc": {
          "type": "string"
        }
      },
      "type": "object",
      "required": [
        "name",
        "kind",
        "required",
        "doc"
      ],
      "description": "Param is one named input of an operation, outside its body."
    },
    "Refusal": {
      "properties": {
        "name": {
          "type": "string"
        },
        "http": {
          "type": "integer"
        },
        "meaning": {
          "type": "string"
        }
      },
      "type": "object",
      "required": [
        "name",
        "http",
        "meaning"
      ],
      "description": "Refusal is one row of the refusal table: a name the surface defines, the HTTP status the binding maps it to, and its meaning."
    }
  },
  "properties": {
    "service": {
      "type": "string"
    },
    "contract": {
      "type": "string"
    },
    "build": {
      "$ref": "#/$defs/Build"
    },
    "bindings": {
      "$ref": "#/$defs/Bindings"
    },
    "operations": {
      "items": {
        "$ref": "#/$defs/Operation"
      },
      "type": "array"
    },
    "refusals": {
      "items": {
        "$ref": "#/$defs/Refusal"
      },
      "type": "array"
    },
    "files": {
      "items": {
        "type": "string"
      },
      "type": "array"
    },
    "identity": {
      "type": "object"
    }
  },
  "type": "object",
  "required": [
    "service",
    "contract",
    "build",
    "bindings",
    "operations",
    "refusals",
    "files"
  ],
  "title": "Describe",
  "description": "Describe is the document /describe returns."
}
