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

# API Reference

> Softmaple API documentation for documents and workspaces

## Overview

The Softmaple API provides programmatic access to manage documents, workspaces, and collaboration features. This reference documentation covers all available endpoints and their usage.

## Base URL

All API endpoints are relative to:

```
https://api.softmaple.ink
```

For local development:

```
http://localhost:3000/api
```

## Authentication

Most API endpoints require authentication using Supabase Auth. Include the session token in the Authorization header:

```bash theme={null}
Authorization: Bearer YOUR_SESSION_TOKEN
```

## Available Endpoints

<CardGroup cols={2}>
  <Card title="Document Endpoints" icon="file" href="/api-reference/endpoint/get">
    Manage documents and their content
  </Card>

  <Card title="Workspace Endpoints" icon="folder" href="/api-reference/endpoint/create">
    Create and manage workspaces
  </Card>
</CardGroup>

## Rate Limiting

API requests are limited to:

* 100 requests per minute for authenticated users
* 20 requests per minute for unauthenticated users

## Response Format

All API responses are in JSON format:

```json theme={null}
{
  "success": true,
  "data": { ... },
  "error": null
}
```

## Error Handling

Errors are returned with appropriate HTTP status codes:

* `400` Bad Request - Invalid parameters
* `401` Unauthorized - Missing or invalid authentication
* `403` Forbidden - Insufficient permissions
* `404` Not Found - Resource doesn't exist
* `429` Too Many Requests - Rate limit exceeded
* `500` Internal Server Error - Server-side error


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