From 7be0f6d651ca58640cf6348a5aa166807d71477a Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Sat, 6 Oct 2018 00:42:15 +0200 Subject: [PATCH] Clean up the tables --- content/en/api/rest/apps.md | 14 ++++++----- content/en/api/rest/domain-blocks.md | 12 +++++----- content/en/api/rest/filters.md | 28 +++++++++++----------- content/en/api/rest/lists.md | 24 +++++++++---------- content/en/api/rest/media.md | 18 +++++++------- content/en/api/rest/notifications.md | 36 ++++++++++++++-------------- content/en/api/rest/reports.md | 10 ++++---- content/en/api/rest/search.md | 2 +- content/en/api/rest/timelines.md | 8 +++---- 9 files changed, 77 insertions(+), 75 deletions(-) diff --git a/content/en/api/rest/apps.md b/content/en/api/rest/apps.md index e2eca584..e1b04c74 100644 --- a/content/en/api/rest/apps.md +++ b/content/en/api/rest/apps.md @@ -18,9 +18,11 @@ Returns [App]({{< relref "entities.md#app" >}}) with `client_id` and `client_sec ### Parameters -|Name|Description|Required|Default| -|----|-----------|:------:|:-----:| -| `client_name` | Name of your application | Required || -| `redirect_uris` | Where the user should be redirected after authorization (for no redirect, use `urn:ietf:wg:oauth:2.0:oob`) | Required || -| `scopes` | Space separated list of [scopes]({{< relref "permissions.md" >}}) | Required || -| `website` | URL to the homepage of your app | Optional || +|Name|Description|Required| +|----|-----------|:------:| +| `client_name` | Name of your application | Required | +| `redirect_uris` | Where the user should be redirected after authorization | Required | +| `scopes` | Space separated list of [scopes]({{< relref "permissions.md" >}}) | Required | +| `website` | URL to the homepage of your app | Optional | + +> To display the authorization code to the end-user instead of redirecting to a web page, use `urn:ietf:wg:oauth:2.0:oob` in `redirect_uris` diff --git a/content/en/api/rest/domain-blocks.md b/content/en/api/rest/domain-blocks.md index e5335d4e..1d29d0dd 100644 --- a/content/en/api/rest/domain-blocks.md +++ b/content/en/api/rest/domain-blocks.md @@ -36,9 +36,9 @@ Block a domain to hide all public posts from it, all notifications from it, and ### Parameters -|Name|Description|Required|Default| -|----|-----------|:------:|:-----:| -| `domain` | Domain to block| Required || +|Name|Description|Required| +|----|-----------|:------:| +| `domain` | Domain to block| Required | ## DELETE /api/v1/domain_blocks @@ -50,6 +50,6 @@ Remove a domain block. ### Parameters -|Name|Description|Required|Default| -|----|-----------|:------:|:-----:| -| `domain` | Domain to block| Required || +|Name|Description|Required| +|----|-----------|:------:| +| `domain` | Domain to unblock| Required | diff --git a/content/en/api/rest/filters.md b/content/en/api/rest/filters.md index dfbe9cc3..e8421a35 100644 --- a/content/en/api/rest/filters.md +++ b/content/en/api/rest/filters.md @@ -28,13 +28,13 @@ Returns [Filter]({{< relref "entities.md#filter" >}}) ### Parameters -|Name|Description|Required|Default| -|----|-----------|:------:|:-----:| -| `phrase` | Keyword or phrase to filter | Required || -| `context` | Array of strings that means filtering context. Each string is one of `home`, `notifications`, `public`, `thread`. At least one context must be specified. | Required || -| `irreversible` | Irreversible filtering will only work in `home` and `notifications` contexts by fully dropping the records. Otherwise, filtering is up to the client. | Optional || -| `whole_word` | Whether to consider word boundaries when matching | Optional || -| `expires_in` | Number that indicates seconds. Filter will be expire in seconds after API processed. Null or blank string means "don't change" | Optional | Unlimited | +|Name|Description|Required| +|----|-----------|:------:| +| `phrase` | Keyword or phrase to filter | Required | +| `context` | Array of strings that means filtering context. Each string is one of `home`, `notifications`, `public`, `thread`. At least one context must be specified. | Required | +| `irreversible` | Irreversible filtering will only work in `home` and `notifications` contexts by fully dropping the records. Otherwise, filtering is up to the client. | Optional | +| `whole_word` | Whether to consider word boundaries when matching | Optional | +| `expires_in` | Number that indicates seconds. Filter will be expire in seconds after API processed. Null or blank string means "don't change" | Optional | ## GET /api/v1/filters/:id @@ -58,13 +58,13 @@ Returns [Filter]({{< relref "entities.md#filter" >}}) ### Parameters -|Name|Description|Required|Default| -|----|-----------|:------:|:-----:| -| `phrase` | Keyword or phrase to filter | Required || -| `context` | Array of strings that means filtering context. Each string is one of `home`, `notifications`, `public`, `thread`. At least one context must be specified. | Required || -| `irreversible` | Irreversible filtering will only work in `home` and `notifications` contexts by fully dropping the records. Otherwise, filtering is up to the client. | Optional || -| `whole_word` | Whether to consider word boundaries when matching | Optional || -| `expires_in` | Number that indicates seconds. Filter will be expire in seconds after API processed. Null or blank string means "don't change" | Optional | Unlimited | +|Name|Description|Required| +|----|-----------|:------:| +| `phrase` | Keyword or phrase to filter | Required | +| `context` | Array of strings that means filtering context. Each string is one of `home`, `notifications`, `public`, `thread`. At least one context must be specified. | Required | +| `irreversible` | Irreversible filtering will only work in `home` and `notifications` contexts by fully dropping the records. Otherwise, filtering is up to the client. | Optional | +| `whole_word` | Whether to consider word boundaries when matching | Optional | +| `expires_in` | Number that indicates seconds. Filter will be expire in seconds after API processed. Null or blank string means "don't change" | Optional | ## DELETE /api/v1/filters/:id diff --git a/content/en/api/rest/lists.md b/content/en/api/rest/lists.md index ddb16fb5..d48a4527 100644 --- a/content/en/api/rest/lists.md +++ b/content/en/api/rest/lists.md @@ -68,9 +68,9 @@ Returns [List]({{< relref "entities.md#list" >}}) ### Parameters -|Name|Description|Required|Default| -|----|-----------|:------:|:-----:| -| `title` | The title of the list | Required || +|Name|Description|Required| +|----|-----------|:------:| +| `title` | The title of the list | Required | ## PUT /api/v1/lists/:id @@ -84,9 +84,9 @@ Returns [List]({{< relref "entities.md#list" >}}) ### Parameters -|Name|Description|Required|Default| -|----|-----------|:------:|:-----:| -| `title` | The title of the list | Required || +|Name|Description|Required| +|----|-----------|:------:| +| `title` | The title of the list | Required | ## DELETE /api/v1/lists/:id @@ -108,9 +108,9 @@ Add accounts to a list. ### Parameters -|Name|Description|Required|Default| -|----|-----------|:------:|:-----:| -| `account_ids` | Array of account IDs | Required || +|Name|Description|Required| +|----|-----------|:------:| +| `account_ids` | Array of account IDs | Required | ## DELETE /api/v1/lists/:id/accounts @@ -122,6 +122,6 @@ Remove accounts from a list. ### Parameters -|Name|Description|Required|Default| -|----|-----------|:------:|:-----:| -| `account_ids` | Array of account IDs | Required || +|Name|Description|Required| +|----|-----------|:------:| +| `account_ids` | Array of account IDs | Required | diff --git a/content/en/api/rest/media.md b/content/en/api/rest/media.md index eac016f3..7c4a3c4e 100644 --- a/content/en/api/rest/media.md +++ b/content/en/api/rest/media.md @@ -18,11 +18,11 @@ Returns [Attachment]({{< relref "entities.md#attachment" >}}) ### Parameters -|Name|Description|Required|Default| -|----|-----------|:------:|:-----:| -| `file` | Media to be uploaded (encoded using `multipart/form-data`) | Required || -| `description` | A plain-text description of the media for accessibility (max 420 chars) | Optional || -| `focus` | Two floating points, comma-delimited. See [focal points](#focal-points) | Optional || +|Name|Description|Required| +|----|-----------|:------:| +| `file` | Media file encoded using `multipart/form-data` | Required | +| `description` | A plain-text description of the media for accessibility (max 420 chars) | Optional | +| `focus` | Two floating points, comma-delimited. See [focal points](#focal-points) | Optional | ## PUT /api/v1/media/:id @@ -36,10 +36,10 @@ Returns [Attachment]({{< relref "entities.md#attachment" >}}) ### Parameters -|Name|Description|Required|Default| -|----|-----------|:------:|:-----:| -| `description` | A plain-text description of the media for accessibility (max 420 chars) | Optional || -| `focus` | Two floating points, comma-delimited. See [focal points](#focal-points) | Optional || +|Name|Description|Required| +|----|-----------|:------:| +| `description` | A plain-text description of the media for accessibility (max 420 chars) | Optional | +| `focus` | Two floating points, comma-delimited. See [focal points](#focal-points) | Optional | ## Focal points diff --git a/content/en/api/rest/notifications.md b/content/en/api/rest/notifications.md index d44a5e81..3e8d8d64 100644 --- a/content/en/api/rest/notifications.md +++ b/content/en/api/rest/notifications.md @@ -55,9 +55,9 @@ Delete a single notification from the server. ### Parameters -|Name|Description|Required|Default| -|----|-----------|:------:|:-----:| -| `id` | Notification ID | Required || +|Name|Description|Required| +|----|-----------|:------:| +| `id` | Notification ID | Required | ## POST /api/v1/push/subscription @@ -73,15 +73,15 @@ Returns [Push Subscription]({{< relref "entities.md#push-subscription" >}}) ### Parameters -|Name|Description|Required|Default| -|----|-----------|:------:|:-----:| -| `subscription[endpoint]` | Endpoint URL that called when notification is happen. | Required || -| `subscription[keys][p256dh]` | User agent public key. Base64 encoded string of public key of ECDH key using 'prime256v1' curve. | Required || -| `subscription[keys][auth]` | Auth secret. Base64 encoded string of 16 bytes of random data. | Required || -| `data[alerts][follow]` | Boolean of whether you want to receive follow notification event. | Optional || -| `data[alerts][favourite]` | Boolean of whether you want to receive favourite notification event. | Optional || -| `data[alerts][reblog]` | Boolean of whether you want to receive reblog notification event. | Optional || -| `data[alerts][mention]` | Boolean of whether you want to receive mention notification event. | Optional || +|Name|Description|Required| +|----|-----------|:------:| +| `subscription[endpoint]` | Endpoint URL that called when notification is happen. | Required | +| `subscription[keys][p256dh]` | User agent public key. Base64 encoded string of public key of ECDH key using 'prime256v1' curve. | Required | +| `subscription[keys][auth]` | Auth secret. Base64 encoded string of 16 bytes of random data. | Required | +| `data[alerts][follow]` | Boolean of whether you want to receive follow notification event. | Optional | +| `data[alerts][favourite]` | Boolean of whether you want to receive favourite notification event. | Optional | +| `data[alerts][reblog]` | Boolean of whether you want to receive reblog notification event. | Optional | +| `data[alerts][mention]` | Boolean of whether you want to receive mention notification event. | Optional | ## GET /api/v1/push/subscription @@ -103,12 +103,12 @@ Returns [Push Subscription]({{< relref "entities.md#push-subscription" >}}) ### Parameters -|Name|Description|Required|Default| -|----|-----------|:------:|:-----:| -| `data[alerts][follow]` | Boolean of whether you want to receive follow notification event. | Optional || -| `data[alerts][favourite]` | Boolean of whether you want to receive favourite notification event. | Optional || -| `data[alerts][reblog]` | Boolean of whether you want to receive reblog notification event. | Optional || -| `data[alerts][mention]` | Boolean of whether you want to receive mention notification event. | Optional || +|Name|Description|Required| +|----|-----------|:------:| +| `data[alerts][follow]` | Boolean of whether you want to receive follow notification event. | Optional | +| `data[alerts][favourite]` | Boolean of whether you want to receive favourite notification event. | Optional | +| `data[alerts][reblog]` | Boolean of whether you want to receive reblog notification event. | Optional | +| `data[alerts][mention]` | Boolean of whether you want to receive mention notification event. | Optional | ## DELETE /api/v1/push/subscription diff --git a/content/en/api/rest/reports.md b/content/en/api/rest/reports.md index a081880d..7f4a670b 100644 --- a/content/en/api/rest/reports.md +++ b/content/en/api/rest/reports.md @@ -16,8 +16,8 @@ Report an account. ### Parameters -|Name|Description|Required|Default| -|----|-----------|:------:|:-----:| -| `account_id` | The ID of the account to report | Required || -| `status_ids` | The IDs of statuses to report as array | Optional || -| `comment` | Reason for the report (up to 1,000 characters) | Optional || +|Name|Description|Required| +|----|-----------|:------:| +| `account_id` | The ID of the account to report | Required | +| `status_ids` | The IDs of statuses to report as array | Optional | +| `comment` | Reason for the report (up to 1,000 characters) | Optional | diff --git a/content/en/api/rest/search.md b/content/en/api/rest/search.md index b515e91c..356b2241 100644 --- a/content/en/api/rest/search.md +++ b/content/en/api/rest/search.md @@ -21,4 +21,4 @@ Returns [Results]({{< relref "entities.md#results" >}}) |Name|Description|Required|Default| |----|-----------|:------:|:-----:| | `q` | The search query | Required || -| `resolve` | | Optional || +| `resolve` | Attempt WebFinger look-up | Optional |false| diff --git a/content/en/api/rest/timelines.md b/content/en/api/rest/timelines.md index 5249d8eb..8f771c48 100644 --- a/content/en/api/rest/timelines.md +++ b/content/en/api/rest/timelines.md @@ -42,8 +42,8 @@ Returns array of [Status]({{< relref "entities.md#status" >}}) |Name|Description|Required|Default| |----|-----------|:------:|:-----:| -| `local` | Only local statuses | Optional || -| `only_media` | Only statuses with media attachments | Optional || +| `local` | Only local statuses | Optional |false| +| `only_media` | Only statuses with media attachments | Optional |false| | `max_id` | Return results older than ID | Optional || | `since_id` | Return results newer than ID | Optional || | `limit` | Maximum number of results | Optional | 20 | @@ -66,8 +66,8 @@ Returns array of [Status]({{< relref "entities.md#status" >}}) |Name|Description|Required|Default| |----|-----------|:------:|:-----:| -| `local` | Only local statuses | Optional || -| `only_media` | Only statuses with media attachments | Optional || +| `local` | Only local statuses | Optional |false| +| `only_media` | Only statuses with media attachments | Optional |false| | `max_id` | Return results older than ID | Optional || | `since_id` | Return results newer than ID | Optional || | `limit` | Maximum number of results | Optional | 20 |