> ## Documentation Index
> Fetch the complete documentation index at: https://docs.prod.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# REST API

> Call any internal or external REST API from Prod AI

## Setting up REST API

### 1. Add integration

Select **REST API** from the&#x20;
**integrations page**.

### 2. Configure settings

Fill out the form with the following settings:

| Field | Required | Description |
| - | - | - |
| Base URL | ✓ | The main endpoint address of the API that serves as the root for all requests |
| Authentication | ✓ | The [authentication type](https://docs.prod.ai/integrations/auth/authentication-types.md) you want to use. See detailed instructions for setting up API auth in our docs on [Authentication & authorization](https://docs.prod.ai/integrations/auth) |
| Headers | ✗ | List of headers that will be added to requests to your API |
| Params | ✗ | List of query parameters that will be added to requests to your API |

#### OpenAPI Specifications

OpenAPI specs help coding agents understand how to work with your API. To upload an OpenAPI specification to a REST API integration:

1. Select **Upload OpenAPI** in the top-right corner
2. From the uploader, select a JSON or YAML file containing your API's OpenAPI spec (version 2.0 or later)
3. Click **Ok** to upload

Once your API's spec has been uploaded, you can manage your spec and explore docs from the **API Specification** tab.

##### Replacing an OpenAPI specification

To replace an API specification, such as to upload a new version, you can click on the button in the top-right labeled with the name of specification, e.g. `spec-name.yaml`, and upload a new specification.

### 3. Test and save

Click **Test Connection** to check that Prod AI can connect to your API.

After connecting successfully, click **Create** to save the integration.

**REST API connected!**
You can now build
[apps](https://docs.prod.ai/coding-agents/apps.md) and [agents](https://docs.prod.ai/coding-agents/agents.md) with REST API.

## Supported OpenAPI specs

Prod AI supports uploading the following specification versions:

* OpenAPI 3.0 and 3.1
* Swagger 2.0

Specification files can be provided in any of the following formats:

* JSON
* YAML
* X-YAML


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.