From 3878d8978fcb58c1fc18a856d9c4ef7a707684de Mon Sep 17 00:00:00 2001 From: Rodrigo Soares Date: Thu, 26 Jun 2025 16:05:19 -0300 Subject: [PATCH 1/2] Update defaults and add info regarding the truncation header --- source/rest-v2.html.md | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/source/rest-v2.html.md b/source/rest-v2.html.md index 8e360a2f131..3cbce847a00 100644 --- a/source/rest-v2.html.md +++ b/source/rest-v2.html.md @@ -33,9 +33,9 @@ API keys are passed via the `Authorization` header as demonstrated in the code s Many endpoints in the API support pagination to help manage large result sets. When using pagination, the following query parameters are available: | Parameter | Type | Description | -| --------- | ------- | ------------------------------------------------------ | +| --------- | ------- |--------------------------------------------------------| | page | Integer | Page number to retrieve (default: returns all results) | -| per_page | Integer | Number of items per page (default: 25, max: 100) | +| per_page | Integer | Number of items per page (default: 1000, max: 1000) | When pagination is used, the following headers are included in the response: @@ -46,6 +46,12 @@ When pagination is used, the following headers are included in the response: | X-Next-Page | Next page number (if available) | | X-Prev-Page | Previous page number (if available) | +If no pagination parameters are provided, the API will return all results in a single response, up to a maximum of 1000 items, and include the following header in the response: + +| Header | Description | +|----------------------|--------------------------------------------------------------| +| X-Response-Truncated | Set to `true` if there are more items than the maximum allowed | + ### API Path structure The base path of an API request is: `https://api.publitas.com/v2/` From b360ce40066894994f63901e27362d15a1c4b7e4 Mon Sep 17 00:00:00 2001 From: Rodrigo Soares Date: Fri, 27 Jun 2025 07:21:23 -0300 Subject: [PATCH 2/2] Fix header --- source/rest-v2.html.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/source/rest-v2.html.md b/source/rest-v2.html.md index 3cbce847a00..d7f800fb848 100644 --- a/source/rest-v2.html.md +++ b/source/rest-v2.html.md @@ -48,9 +48,9 @@ When pagination is used, the following headers are included in the response: If no pagination parameters are provided, the API will return all results in a single response, up to a maximum of 1000 items, and include the following header in the response: -| Header | Description | -|----------------------|--------------------------------------------------------------| -| X-Response-Truncated | Set to `true` if there are more items than the maximum allowed | +| Header | Description | +|--------------------|--------------------------------------------------------------| +| X-Result-Truncated | Set to `true` if there are more items than the maximum allowed | ### API Path structure