From a8d647cca365dec1c036c055783d9cd3ef632973 Mon Sep 17 00:00:00 2001 From: Chewing_Bever Date: Thu, 16 Jun 2022 22:38:42 +0200 Subject: [PATCH] fix(docs): use versioned endpoints in HTTP API docs --- docs/api/source/includes/_logs.md | 14 +++++++------- docs/api/source/includes/_targets.md | 14 +++++++------- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/docs/api/source/includes/_logs.md b/docs/api/source/includes/_logs.md index a38bf48..2797e60 100644 --- a/docs/api/source/includes/_logs.md +++ b/docs/api/source/includes/_logs.md @@ -13,7 +13,7 @@ Endpoints for interacting with stored build logs. ```shell curl \ -H 'X-Api-Key: secret' \ - https://example.com/api/logs?offset=10&limit=20 + https://example.com/api/v1/logs?offset=10&limit=20 ``` > JSON output format @@ -38,7 +38,7 @@ Retrieve a list of build logs. ### HTTP Request -`GET /api/logs` +`GET /api/v1/logs` ### Query Parameters @@ -58,7 +58,7 @@ exit_codes | Comma-separated list of exit codes to limit result to; using `!` as ```shell curl \ -H 'X-Api-Key: secret' \ - https://example.com/api/logs/1 + https://example.com/api/v1/logs/1 ``` > JSON output format @@ -81,7 +81,7 @@ Retrieve info about a specific build log. ### HTTP Request -`GET /api/logs/:id` +`GET /api/v1/logs/:id` ### URL Parameters @@ -94,7 +94,7 @@ id | ID of requested log ```shell curl \ -H 'X-Api-Key: secret' \ - https://example.com/api/logs/15/content + https://example.com/api/v1/logs/15/content ``` Retrieve the contents of a build log. The response is the build log in @@ -102,7 +102,7 @@ plaintext. ### HTTP Request -`GET /api/logs/:id/content` +`GET /api/v1/logs/:id/content` ### URL Parameters @@ -123,7 +123,7 @@ Publish a new build log to the server. ### HTTP Request -`POST /api/logs` +`POST /api/v1/logs` ### Query parameters diff --git a/docs/api/source/includes/_targets.md b/docs/api/source/includes/_targets.md index 05cf001..f7ea21e 100644 --- a/docs/api/source/includes/_targets.md +++ b/docs/api/source/includes/_targets.md @@ -13,7 +13,7 @@ Endpoints for interacting with the list of targets stored on the server. ```shell curl \ -H 'X-Api-Key: secret' \ - https://example.com/api/targets?offset=10&limit=20 + https://example.com/api/v1/targets?offset=10&limit=20 ``` > JSON output format @@ -44,7 +44,7 @@ Retrieve a list of targets. ### HTTP Request -`GET /api/targets` +`GET /api/v1/targets` ### Query Parameters @@ -59,7 +59,7 @@ repo | Limit results to targets that publish to the given repo. ```shell curl \ -H 'X-Api-Key: secret' \ - https://example.com/api/targets/1 + https://example.com/api/v1/targets/1 ``` > JSON output format @@ -88,7 +88,7 @@ Get info about a specific target. ### HTTP Request -`GET /api/targets/:id` +`GET /api/v1/targets/:id` ### URL Parameters @@ -102,7 +102,7 @@ Create a new target with the given data. ### HTTP Request -`POST /api/targets` +`POST /api/v1/targets` ### Query Parameters @@ -120,7 +120,7 @@ Modify the data of an existing target. ### HTTP Request -`PATCH /api/targets/:id` +`PATCH /api/v1/targets/:id` ### URL Parameters @@ -144,7 +144,7 @@ Remove a target from the server. ### HTTP Request -`DELETE /api/targets/:id` +`DELETE /api/v1/targets/:id` ### URL Parameters