# Async APIs

The AsyncAPI kind is designed for asynchronous workloads, in which the user submits a request to start the processing and retrieves the result later, either by polling or through a webhook.

The design is summarized in the image below.

![](https://user-images.githubusercontent.com/7456627/111491999-9b67f100-873c-11eb-87f0-effcf4aab01b.png)

The Async Gateway is responsible for submitting the workloads to the queue and for the retrieval of the respective workload status and results. Cortex fully manages the Async Gateway and the queue. Autoscaling is provided based on the average number of messages in the queue.

## Use-cases

AsyncAPI is a good fit for users who want to submit longer workloads (such as video, audio or document processing), and do not need the result immediately or synchronously.

{% hint style="info" %}
AsyncAPI is still in a beta state.
{% endhint %}


---

# 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.cortexlabs.com/0.33/workloads/async-apis.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.
