# ExtensionFlow API

Base path: `/api/v1`

Authentication: `Authorization: Bearer <token>`.

All API routes are rate limited. API tokens are stored as SHA-256 hashes in `api_tokens` and can be revoked by setting `revoked_at`.

## Pagination

Use `page` and `per_page` query parameters. `per_page` is capped at 100.

## Filtering and search

### Extensions

`GET /api/v1/extensions`

Query parameters:

- `q`: searches extension name, alias, element and vendor.
- `status`: `draft`, `active`, `archived`, `disabled`.
- `type`: `component`, `module`, `plugin`, `package`, `template`, `language`, `custom`.
- `visibility`: `public`, `private`, `unlisted`.

`GET /api/v1/extensions/{id}` returns a single detailed extension.

### Releases

`GET /api/v1/releases`

Query parameters:

- `q`: searches release version and extension name.
- `extension_id`: filters releases by extension.
- `status`: `draft`, `published`, `yanked`, `archived`.
- `channel`: `stable`, `beta`, `nightly`, `lts`.
- `stability`: `alpha`, `beta`, `rc`, `stable`, `lts`.

`GET /api/v1/releases/{id}` returns release details and changelog entries.

### Update XML

`GET /api/v1/updates/{type}/{alias}` returns Joomla-compatible XML.

### Changelog

`GET /api/v1/changelog/{releaseId}` returns grouped entries, Markdown and Joomla release notes.

## Example response

```json
{
  "data": [],
  "pager": {
    "page": 1,
    "total": 0
  }
}
```

© Oleg Kosarev — OlegKosarevDevOpsSolution
