Retrieve a chapter
curl --request GET \
--url https://api.relettr.com/v1/chapters/{chapter_id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.relettr.com/v1/chapters/{chapter_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.relettr.com/v1/chapters/{chapter_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": "ch_7Kq2mXaB3cD4eF5gH6iJ7k",
"object": "chapter",
"livemode": true,
"status": "awaiting_upload",
"series_id": "<string>",
"number": 123,
"source_language": "ko",
"target_language": "en",
"options": {
"layout": "strip",
"translate_sfx": false,
"output": {
"layout": "original",
"strip": false,
"format": "png",
"quality": 90
},
"on_mask_failure": "hold",
"auto_start": false,
"max_credits": 2
},
"uploads": [
{
"index": 123,
"method": "PUT",
"url": "<string>",
"headers": {},
"expires_at": "2023-11-07T05:31:56Z"
}
],
"quote": {
"credits": 462,
"parts": 21,
"breakdown": {
"ocr": 123,
"translate": 123,
"clean_letter": 123,
"sfx": 123
}
},
"credits": {
"held": 123,
"charged": 123,
"refunded": 123
},
"progress": {
"step": "read",
"percent": 50,
"parts_total": 123,
"parts_done": 123,
"steps": [
{
"name": "read",
"status": "pending"
}
]
},
"queue": {
"position": 123,
"estimated_start_at": "2023-11-07T05:31:56Z",
"gpu": "online"
},
"review": {
"open": 123,
"accepted": 123,
"zones": [
{
"id": "<string>",
"page": 123,
"box": [
123
],
"reason": "<string>"
}
]
},
"warnings": [
{
"code": "missing_glyphs",
"page": 123,
"region_ids": [
"<string>"
]
}
],
"error": {
"code": "invalid_image",
"message": "<string>",
"step": "<string>",
"file_index": 123
},
"result_version": 123,
"metadata": {},
"created_at": "2023-11-07T05:31:56Z",
"started_at": "2023-11-07T05:31:56Z",
"completed_at": "2023-11-07T05:31:56Z"
}{
"error": {
"type": "invalid_request",
"code": "parameter_invalid",
"message": "<string>",
"request_id": "<string>",
"param": "files[3].content_type",
"doc_url": "<string>"
}
}{
"error": {
"type": "invalid_request",
"code": "parameter_invalid",
"message": "<string>",
"request_id": "<string>",
"param": "files[3].content_type",
"doc_url": "<string>"
}
}{
"error": {
"type": "invalid_request",
"code": "parameter_invalid",
"message": "<string>",
"request_id": "<string>",
"param": "files[3].content_type",
"doc_url": "<string>"
}
}{
"error": {
"type": "invalid_request",
"code": "parameter_invalid",
"message": "<string>",
"request_id": "<string>",
"param": "files[3].content_type",
"doc_url": "<string>"
}
}{
"error": {
"type": "invalid_request",
"code": "parameter_invalid",
"message": "<string>",
"request_id": "<string>",
"param": "files[3].content_type",
"doc_url": "<string>"
}
}Chapters
Retrieve a chapter
Returns status, progress, quote, credits, queue position, review state,
warnings and error. The response carries an ETag; send it back as
If-None-Match to get 304 Not Modified with no body. A 304 counts as
0.2 of a request against your rate limit.
Poll every 30–60 s while queued and every 5–10 s while processing,
or use webhooks.
GET
/
chapters
/
{chapter_id}
Retrieve a chapter
curl --request GET \
--url https://api.relettr.com/v1/chapters/{chapter_id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.relettr.com/v1/chapters/{chapter_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.relettr.com/v1/chapters/{chapter_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": "ch_7Kq2mXaB3cD4eF5gH6iJ7k",
"object": "chapter",
"livemode": true,
"status": "awaiting_upload",
"series_id": "<string>",
"number": 123,
"source_language": "ko",
"target_language": "en",
"options": {
"layout": "strip",
"translate_sfx": false,
"output": {
"layout": "original",
"strip": false,
"format": "png",
"quality": 90
},
"on_mask_failure": "hold",
"auto_start": false,
"max_credits": 2
},
"uploads": [
{
"index": 123,
"method": "PUT",
"url": "<string>",
"headers": {},
"expires_at": "2023-11-07T05:31:56Z"
}
],
"quote": {
"credits": 462,
"parts": 21,
"breakdown": {
"ocr": 123,
"translate": 123,
"clean_letter": 123,
"sfx": 123
}
},
"credits": {
"held": 123,
"charged": 123,
"refunded": 123
},
"progress": {
"step": "read",
"percent": 50,
"parts_total": 123,
"parts_done": 123,
"steps": [
{
"name": "read",
"status": "pending"
}
]
},
"queue": {
"position": 123,
"estimated_start_at": "2023-11-07T05:31:56Z",
"gpu": "online"
},
"review": {
"open": 123,
"accepted": 123,
"zones": [
{
"id": "<string>",
"page": 123,
"box": [
123
],
"reason": "<string>"
}
]
},
"warnings": [
{
"code": "missing_glyphs",
"page": 123,
"region_ids": [
"<string>"
]
}
],
"error": {
"code": "invalid_image",
"message": "<string>",
"step": "<string>",
"file_index": 123
},
"result_version": 123,
"metadata": {},
"created_at": "2023-11-07T05:31:56Z",
"started_at": "2023-11-07T05:31:56Z",
"completed_at": "2023-11-07T05:31:56Z"
}{
"error": {
"type": "invalid_request",
"code": "parameter_invalid",
"message": "<string>",
"request_id": "<string>",
"param": "files[3].content_type",
"doc_url": "<string>"
}
}{
"error": {
"type": "invalid_request",
"code": "parameter_invalid",
"message": "<string>",
"request_id": "<string>",
"param": "files[3].content_type",
"doc_url": "<string>"
}
}{
"error": {
"type": "invalid_request",
"code": "parameter_invalid",
"message": "<string>",
"request_id": "<string>",
"param": "files[3].content_type",
"doc_url": "<string>"
}
}{
"error": {
"type": "invalid_request",
"code": "parameter_invalid",
"message": "<string>",
"request_id": "<string>",
"param": "files[3].content_type",
"doc_url": "<string>"
}
}{
"error": {
"type": "invalid_request",
"code": "parameter_invalid",
"message": "<string>",
"request_id": "<string>",
"param": "files[3].content_type",
"doc_url": "<string>"
}
}Authorizations
Response
The chapter.