# Junior API

API for the Junior platform: retrieve call transcripts and metadata, and create projects. All endpoints require an API key issued by the Junior team. Write endpoints additionally require the organization to be enabled for the write surface.

Version: 1.0.0

## Servers

```
https://api.junior.ai/v1
```

## Security

### bearerAuth

API key issued by Junior, sent as `Authorization: Bearer jr_live_…`. Keys are shown once at issuance — store securely.

Type: http
Scheme: bearer

## Download OpenAPI description

[Junior API](https://api.docs.junior.ai/_bundle/openapi.yaml)

## Calls

Read call (interview) records, metadata, and transcripts. List first, then fetch a single call by `call_id` for the full record.

### List calls

 - [GET /calls](https://api.docs.junior.ai/openapi/calls/listcalls.md): Returns a paginated list of calls (ID and duration) within a date range. Calls are ordered by created_at DESC with id as a stable tiebreaker.

### Get a single call

 - [GET /calls/{call_id}](https://api.docs.junior.ai/openapi/calls/getcall.md): Returns interview metadata, optional summary, and one or more transcript entries. Which entries appear depends on the request flags AND the organization's allowed_fields permissions.

## Projects

Create projects and look up the billing offices a project can be assigned to. Requires the organization to be enabled for the write surface.

### List billing offices

 - [GET /billing-offices](https://api.docs.junior.ai/openapi/projects/listbillingoffices.md): Lists your organization's billing offices — the valid values to pass as billing_office_name when creating a project. Returns names only (plus which is the default), never internal IDs.

### Create a project

 - [POST /projects](https://api.docs.junior.ai/openapi/projects/createproject.md): Creates a project for the authenticated key's organization, with a lead and optional member users (given by email, resolved to profiles WITHIN that organization). Requires the organization to be enabled for the write surface.

