# API

The Agile API input and output formats are specified by [Protocol Buffers](https://developers.google.com/protocol-buffers/), known colloquially as protobufs. Unlike typical protobufs endpoints, the Agile endpoints support JSON for input and output in addition to the protobufs binary format. To use JSON in both the input and the output, specify the headers "`Content-Type: application/json`" and "`Accept: application/json`" in the request.

API keys are currently optional, and are included in the HTTP header `agile-api-key;` you can request keys from Agile in the #development channel of our [Discord](https://discord.gg/874ntdw) server. In the future, API keys will be required to access the API.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.agilefi.org/api.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
