# Banana.dev Integration via LowCodeAPI

## Overview

Serverless GPU inference for AI models, providing a CI/CD build pipeline and a simple Python framework (Potassium) to serve your models with automatic scaling.

## Base Endpoint

```
https://api.lowcodeapi.com/bananadev/
```

## Authentication

LowCodeAPI handles authentication automatically. You only need to:

1. **Sign up** at [https://www.banana.dev](https://www.banana.dev)
2. **Get your credentials** from [https://www.banana.dev/account/api-keys](https://www.banana.dev/account/api-keys)
3. **Connect your account** in LowCodeAPI dashboard
4. **Use your `api_token`** in all requests

The `api_token` is your LowCodeAPI authentication token. LowCodeAPI will automatically:
- Fetch your Banana.dev API key
- Apply it to each request with `Authorization` header

**Auth Type**: API Key (Authorization header)

## API Categories

- AI Cloud

## Common Endpoints

### Category: Runs

#### Start a run

**Method**: `POST` | **LowCodeAPI Path**: `/v1/start`

**Full URL**:
```
https://api.lowcodeapi.com/bananadev/v1/start&api_token={api_token}
```


**Body Parameters**:

| `modelKey` | string | Yes | The model key identifier for the model you want to run |
| `modelInputs` | object | Yes | Input parameters for the model inference |
| `startOnly` | boolean | No | If true, only start the run without waiting for completion. Default: false |


**Example Request**:
```bash
curl -X POST "https://api.lowcodeapi.com/bananadev/v1/start?&api_token=YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"modelKey":"value","modelInputs":"value","startOnly":"value"}'
```

**Official Documentation**: [https://docs.banana.dev/api/start](https://docs.banana.dev/api/start)

---

#### Check run status

**Method**: `POST` | **LowCodeAPI Path**: `/v1/check`

**Full URL**:
```
https://api.lowcodeapi.com/bananadev/v1/check&api_token={api_token}
```


**Body Parameters**:

| `id` | string | Yes | The ID of the run to check (returned from the start endpoint) |
| `modelKey` | string | Yes | The model key identifier for the run |


**Example Request**:
```bash
curl -X POST "https://api.lowcodeapi.com/bananadev/v1/check?&api_token=YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"id":"value","modelKey":"value"}'
```

**Official Documentation**: [https://docs.banana.dev/api/check](https://docs.banana.dev/api/check)

---

#### Start and wait for run completion

**Method**: `POST` | **LowCodeAPI Path**: `/v1/run`

**Full URL**:
```
https://api.lowcodeapi.com/bananadev/v1/run&api_token={api_token}
```


**Body Parameters**:

| `modelKey` | string | Yes | The model key identifier for the model you want to run |
| `modelInputs` | object | Yes | Input parameters for the model inference |


**Example Request**:
```bash
curl -X POST "https://api.lowcodeapi.com/bananadev/v1/run?&api_token=YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"modelKey":"value","modelInputs":"value"}'
```

**Official Documentation**: [https://docs.banana.dev/api/run](https://docs.banana.dev/api/run)

---

### Category: Models

#### List all models

**Method**: `GET` | **LowCodeAPI Path**: `/v1/models`

**Full URL**:
```
https://api.lowcodeapi.com/bananadev/v1/models&api_token={api_token}
```


**Example Request**:
```bash
curl -X GET "https://api.lowcodeapi.com/bananadev/v1/models&api_token=YOUR_API_TOKEN" \
  -H "Content-Type: application/json"
```

**Official Documentation**: [https://docs.banana.dev/api/models](https://docs.banana.dev/api/models)

---

#### Get model details

**Method**: `GET` | **LowCodeAPI Path**: `/v1/models/model_key`

**Full URL**:
```
https://api.lowcodeapi.com/bananadev/v1/models/model_key?model_key={model_key}&api_token={api_token}
```


**Path Parameters**:

| `model_key` | string | The model key identifier |

**Note**: Path parameters are passed in the URL path. The LowCodeAPI path uses static parameter names, and the actual values are passed as query parameters with the same names.


**Example Request**:
```bash
curl -X GET "https://api.lowcodeapi.com/bananadev/v1/models/model_key?model_key=VALUE&&api_token=YOUR_API_TOKEN" \
  -H "Content-Type: application/json"
```

**Official Documentation**: [https://docs.banana.dev/api/models](https://docs.banana.dev/api/models)

---

### Category: Account

#### Get account information

**Method**: `GET` | **LowCodeAPI Path**: `/v1/account`

**Full URL**:
```
https://api.lowcodeapi.com/bananadev/v1/account&api_token={api_token}
```


**Example Request**:
```bash
curl -X GET "https://api.lowcodeapi.com/bananadev/v1/account&api_token=YOUR_API_TOKEN" \
  -H "Content-Type: application/json"
```

**Official Documentation**: [https://docs.banana.dev/api/account](https://docs.banana.dev/api/account)

---

#### Get usage statistics

**Method**: `GET` | **LowCodeAPI Path**: `/v1/usage`

**Full URL**:
```
https://api.lowcodeapi.com/bananadev/v1/usage?...&api_token={api_token}
```


**Query Parameters**:

| `startDate` | string | No | Start date for usage statistics (ISO 8601 format) |
| `endDate` | string | No | End date for usage statistics (ISO 8601 format) |


**Example Request**:
```bash
curl -X GET "https://api.lowcodeapi.com/bananadev/v1/usage?...&api_token=YOUR_API_TOKEN" \
  -H "Content-Type: application/json"
```

**Official Documentation**: [https://docs.banana.dev/api/usage](https://docs.banana.dev/api/usage)

---

### Category: Deployment

#### Deploy a model

**Method**: `POST` | **LowCodeAPI Path**: `/v1/deploy`

**Full URL**:
```
https://api.lowcodeapi.com/bananadev/v1/deploy&api_token={api_token}
```


**Body Parameters**:

| `modelKey` | string | Yes | The model key identifier for the model to deploy |
| `source` | string | Yes | Source of the model (e.g., GitHub repository URL, Docker image) |
| `environment` | object | No | Environment variables and configuration for the deployment |


**Example Request**:
```bash
curl -X POST "https://api.lowcodeapi.com/bananadev/v1/deploy?&api_token=YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"modelKey":"value","source":"value","environment":"value"}'
```

**Official Documentation**: [https://docs.banana.dev/api/deploy](https://docs.banana.dev/api/deploy)

---

## Usage Examples

### Example 1: Basic Usage

Get started with Banana.dev API by making your first request.

```bash
# Your example code here
# This demonstrates basic usage
curl -X GET "https://api.lowcodeapi.com/bananadev/?api_token=YOUR_API_TOKEN"
```

### Example 2: Advanced Usage

Explore more advanced features and parameters.

```bash
# Your example code here
# This demonstrates advanced usage
curl -X GET "https://api.lowcodeapi.com/bananadev/?api_token=YOUR_API_TOKEN"
```

## Complete Endpoint Reference

For a complete list of all endpoints and their parameters, refer to:
- **OpenAPI Definition**: `https://backend.lowcodeapi.com/bananadev/definition`
- **Official Provider Documentation**: [https://docs.banana.dev](https://docs.banana.dev)

## Rate Limits & Best Practices

- Check your Banana.dev account for specific rate limits
- Use appropriate error handling and retry logic
- Cache responses when appropriate to reduce API calls

## Error Handling

Standard HTTP status codes apply:
- `400` - Invalid request parameters
- `401` - Unauthorized (check your API key)
- `429` - Rate limit exceeded
- `500` - Internal server error