MRT Outlines API
The MRT Outlines API manages Machine-Readable Template (MRT) outlines that structure document content with hierarchical sections.Get MRT Outline
Retrieve a complete MRT outline with all sections ordered by index.Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
outline_id | string | Yes | UUID of outline |
Request Example
Response
Status Codes
- 200 OK: Outline retrieved successfully
- 400 Bad Request: Authentication failed or outline not found
- 403 Forbidden: User not authorized (different organization)
- 500 Internal Server Error: Database error
Update MRT Outline
Full replacement (PUT) of an MRT outline. All existing sections are deleted and replaced with provided structure.Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
outline_id | string | Yes | UUID of outline |
Request Body
Request Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
document_metadata | object | Yes | Outline metadata |
sections | array | Yes | Section dictionaries (at least one required) |
connector_data_id | string | No | Data connector ID |
endpoint_analysis | string | No | Analysis text |
rule_type_to_table_like_status | object | No | Rule type mappings |
Section Parameters
Each section must include:| Parameter | Type | Required | Description |
|---|---|---|---|
section_id | string | Yes | Unique section identifier |
order_index | integer | Yes | Position in outline |
level | integer | Yes | Nesting level |
title | string | Yes | Section title |
content | string | No | Section content |
Request Example
Python Example
Response
Status Codes
- 200 OK: Outline updated successfully
- 400 Bad Request: Invalid outline structure or missing sections
- 401 Unauthorized: Missing or invalid Bearer token
- 403 Forbidden: User not authorized
- 404 Not Found: Outline not found
- 500 Internal Server Error: Database error
Important Notes
- Full Replacement: This is a PUT operation, not a PATCH. All sections are replaced.
- Section Order:
order_indexmust be unique across all sections - Hierarchical Structure: Sections support multiple nesting levels via the
levelparameter - Cascading Delete: Old sections and all associated data are deleted before insert