> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.sofer.ai/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.sofer.ai/_mcp/server.

# Outline

POST https://api.sofer.ai/v1/timestamps/outline
Content-Type: application/json

Outline of topics discussed by timestamp, generated end-to-end from a transcription ID.

This endpoint will:
1) Fetch the transcript and word-level timestamps for the given transcription
2) Generate chapter topics (title + starting_phrase) using an LLM from the transcript text
3) Align each topic's starting phrase to timestamps

Reference: https://docs.sofer.ai/api-reference/timestamps/outline

## Authentication

- `Authorization` header (bearer token, required) — Bearer authentication of the form `Bearer <token>`, where token is your auth token.

## Request

### Body (application/json)

This endpoint expects an OutlineRequest.

- `transcription_id` (UUID, required) — ID of the transcription to process end-to-end
- `monotone` (boolean, optional) — If true, each topic is searched after the previous topic's start (with a small backoff)
- `conclusion_bias` (boolean, optional) — If true and a title includes the word "conclusion", search in the last third of the audio

## Response

### 200

- `list of OutlineTopic`

## Errors

### 401 Authentication Error

Authentication error

### 429 Rate Limit Error

Rate limit exceeded, or you have used up your quota

## Types

### OutlineTopic

- `title` (string, required) — Title of the topic
- `starting_phrase` (string, required) — Starting phrase that was searched for
- `matched_text` (string, required) — The transcript text segment best matching the starting phrase
- `score_norm` (double, required) — Normalized alignment score in [0,1]
- `confidence` (enum, required) — Confidence bucket derived from the normalized score
  - Allowed values: `HIGH`, `MEDIUM`, `LOW`, `NONE`
- `start_time_sec` (double, optional) — Start time in seconds for the best-aligned phrase (if found)
- `token_span` (list of integer, optional) — Optional span of token indices [start, end) for the best match
- `matched_content` (integer, optional) — Number of matched content tokens (excludes stopwords/fillers)
- `content_coverage` (double, optional) — Fraction of content tokens in the phrase that were matched
- `longest_content_run_soft` (integer, optional) — Longest soft contiguous run of content-token matches
- `longest_content_run_strict` (integer, optional) — Longest strict contiguous run of content-token matches

## Examples

**Request**

```json
{
  "transcription_id": "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"
}
```

**Response**

```json
[
  {
    "title": "title",
    "starting_phrase": "starting_phrase",
    "matched_text": "matched_text",
    "score_norm": 1.1,
    "confidence": "HIGH",
    "start_time_sec": 1.1,
    "token_span": [
      1,
      1
    ],
    "matched_content": 1,
    "content_coverage": 1.1,
    "longest_content_run_soft": 1,
    "longest_content_run_strict": 1
  },
  {
    "title": "title",
    "starting_phrase": "starting_phrase",
    "matched_text": "matched_text",
    "score_norm": 1.1,
    "confidence": "HIGH",
    "start_time_sec": 1.1,
    "token_span": [
      1,
      1
    ],
    "matched_content": 1,
    "content_coverage": 1.1,
    "longest_content_run_soft": 1,
    "longest_content_run_strict": 1
  }
]
```

**SDK Code**

```python
import requests

url = "https://api.sofer.ai/v1/timestamps/outline"

payload = { "transcription_id": "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32" }
headers = {
    "Authorization": "Bearer <apiKey>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript
const url = 'https://api.sofer.ai/v1/timestamps/outline';
const options = {
  method: 'POST',
  headers: {Authorization: 'Bearer <apiKey>', 'Content-Type': 'application/json'},
  body: '{"transcription_id":"d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.sofer.ai/v1/timestamps/outline"

	payload := strings.NewReader("{\n  \"transcription_id\": \"d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32\"\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Authorization", "Bearer <apiKey>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api.sofer.ai/v1/timestamps/outline")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <apiKey>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"transcription_id\": \"d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32\"\n}"

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.sofer.ai/v1/timestamps/outline")
  .header("Authorization", "Bearer <apiKey>")
  .header("Content-Type", "application/json")
  .body("{\n  \"transcription_id\": \"d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32\"\n}")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.sofer.ai/v1/timestamps/outline', [
  'body' => '{
  "transcription_id": "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"
}',
  'headers' => [
    'Authorization' => 'Bearer <apiKey>',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://api.sofer.ai/v1/timestamps/outline");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer <apiKey>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"transcription_id\": \"d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32\"\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "Authorization": "Bearer <apiKey>",
  "Content-Type": "application/json"
]
let parameters = ["transcription_id": "d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32"] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.sofer.ai/v1/timestamps/outline")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```