From 06ccb1b714355add899530928ab82db5e6dd624f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Ad=C3=A1mek?= Date: Tue, 14 Jan 2025 20:03:48 +0100 Subject: [PATCH] fix: Another round of OpenAPI fixes (#1412) - missing spaces in text - don't open absolute links from api docs in new window - scroll sidebar for category pages - add margin after sidebar categories - add links to category index pages - update date of the docs switch - remove extra blank lines Closes #1326 --- apify-api/openapi/components/tags.yaml | 315 +++--------------- apify-api/openapi/openapi.yaml | 4 +- .../actor-builds/actor-builds@{buildId}.yaml | 4 +- .../actor-builds@{buildId}@log.yaml | 4 +- .../paths/actor-runs/actor-runs@{runId}.yaml | 8 +- .../actor-runs/actor-runs@{runId}@abort.yaml | 2 +- .../actor-tasks@{actorTaskId}@input.yaml | 1 - ...torTaskId}@run-sync-get-dataset-items.yaml | 24 +- .../actor-tasks@{actorTaskId}@run-sync.yaml | 9 +- .../actor-tasks@{actorTaskId}@runs.yaml | 8 +- apify-api/openapi/paths/actors/acts.yaml | 6 - .../openapi/paths/actors/acts@{actorId}.yaml | 5 - .../paths/actors/acts@{actorId}@builds.yaml | 7 +- .../acts@{actorId}@builds@{buildId}.yaml | 9 +- ...@{actorId}@run-sync-get-dataset-items.yaml | 106 +----- .../paths/actors/acts@{actorId}@runs.yaml | 5 +- .../actors/acts@{actorId}@runs@{runId}.yaml | 14 +- .../acts@{actorId}@runs@{runId}@abort.yaml | 6 +- ...acts@{actorId}@runs@{runId}@metamorph.yaml | 13 +- ...acts@{actorId}@runs@{runId}@resurrect.yaml | 3 - ...ts@{actorId}@versions@{versionNumber}.yaml | 21 +- ...Id}@versions@{versionNumber}@env-vars.yaml | 2 - ...{versionNumber}@env-vars@{envVarName}.yaml | 12 +- .../openapi/paths/datasets/datasets.yaml | 1 - .../paths/datasets/datasets@{datasetId}.yaml | 1 - .../datasets/datasets@{datasetId}@items.yaml | 44 +-- .../paths/logs/logs@{buildOrRunId}.yaml | 4 +- .../paths/request-queues/request-queues.yaml | 12 +- .../request-queues@{queueId}.yaml | 6 +- .../request-queues@{queueId}@head.yaml | 3 - .../request-queues@{queueId}@requests.yaml | 3 - ...quest-queues@{queueId}@requests@batch.yaml | 8 - ...queues@{queueId}@requests@{requestId}.yaml | 4 - apify-api/openapi/paths/store/store.yaml | 2 - .../webhook-dispatches.yaml | 3 - .../openapi/paths/webhooks/webhooks.yaml | 23 -- .../paths/webhooks/webhooks@{webhookId}.yaml | 5 - apify-docs-theme/src/theme/MDXComponents/A.js | 4 + apify-docs-theme/src/theme/custom.css | 4 + apify-docs-theme/static/js/custom.js | 6 +- docusaurus.config.js | 5 +- src/theme/DocCard/index.js | 30 +- 42 files changed, 146 insertions(+), 610 deletions(-) diff --git a/apify-api/openapi/components/tags.yaml b/apify-api/openapi/components/tags.yaml index 3dbfe44b5..baa466a58 100644 --- a/apify-api/openapi/components/tags.yaml +++ b/apify-api/openapi/components/tags.yaml @@ -3,28 +3,18 @@ x-legacy-doc-urls: - '#/reference/actors' - '#tag/Actors' - description: >- - The API endpoints described in this section enable you to manage, build and run - Apify actors. - - For more information, see the Actor - documentation. - - - Note that for all the API endpoints that accept the `actorId` parameter to specify - an actor, + description: | + The API endpoints described in this section enable you to manage, build and run Apify actors. + For more information, see the Actor documentation. + Note that for all the API endpoints that accept the `actorId` parameter to specify an actor, you can pass either the actor ID (e.g. `HG7ML7M8z78YcAPEB`) or a tilde-separated - username of the actor owner and the actor name (e.g. `janedoe~my-actor`). - Some of the API endpoints return runs objects. Note that if any such run object contains usage in dollars, your effective unit pricing at the time of query - has been used for computation of this dollar equivalent, and hence it should be used only for informative purposes. You can learn more - about platform usage in the documentation. - name: Actors/Actor collection x-displayName: Actor collection @@ -54,20 +44,16 @@ - '#/reference/actors/version-object' - '#tag/ActorsVersion-object' x-trait: 'true' - description: >- + description: | The **Version object** contains the source code of a specific version of an actor. - The `sourceType` property indicates where the source code is hosted, and based - on its value the Version object has the following additional property: -
"SOURCE_FILES" - Source code is comprised of multiple files specified in the sourceFiles - array. + Source code is comprised of multiple files specified in the sourceFiles array. Each item of the array is an object with the following fields:
  • name
  • - File path and name
    @@ -102,7 +88,6 @@
- For more information about source code and actor versions, see [Source code](https://docs.apify.com/platform/actors/development/actor-definition/source-code) in Actors documentation. - name: Actors/Environment variable collection @@ -211,138 +196,79 @@ - '#/reference/actors/last-run-object-and-its-storages' - '#tag/ActorsLast-run-object-and-its-storages' x-trait: 'true' - description: >- - This is not a single endpoint, but an entire group of endpoints that lets you - to - + description: | + This is not a single endpoint, but an entire group of endpoints that lets you to retrieve and manage the last run of given actor or any of its default storages. - All the endpoints require an authentication token. - The endpoints accept the same HTTP methods and query parameters as - the respective storage endpoints. - The base path represents the last actor run object is: - `/v2/acts/{actorId}/runs/last{?token,status}` - - Using the `status` query parameter you can ensure to only get a run with a certain - status - + Using the `status` query parameter you can ensure to only get a run with a certain status (e.g. `status=SUCCEEDED`). The output of this endpoint and other query parameters - are the same as in the [Run object](#/reference/actors/run-object) endpoint. - In order to access the default storages of the last actor run, i.e. log, key-value - store, dataset and request queue, - - use the following endpoints: - + store, dataset and request queue, use the following endpoints: * `/v2/acts/{actorId}/runs/last/log{?token,status}` - - * `/v2/acts/{actorId}/runs/last/key-value-store{?token,status}` - - * `/v2/acts/{actorId}/runs/last/dataset{?token,status}` - - * `/v2/acts/{actorId}/runs/last/request-queue{?token,status}` - These API endpoints have the same usage as the equivalent storage endpoints. - - For example, - - `/v2/acts/{actorId}/runs/last/key-value-store` has the same HTTP method and parameters - as the - - [Key-value store object](#/reference/key-value-stores/store-object) endpoint. - + For example, `/v2/acts/{actorId}/runs/last/key-value-store` has the same HTTP method and parameters + as the [Key-value store object](#/reference/key-value-stores/store-object) endpoint. Additionally, each of the above API endpoints supports all sub-endpoints - of the original one: - #### Key-value store - * `/v2/acts/{actorId}/runs/last/key-value-store/keys{?token,status}` [Key collection](#/reference/key-value-stores/key-collection) - - - * `/v2/acts/{actorId}/runs/last/key-value-store/records/{recordKey}{?token,status}` - [Record](#/reference/key-value-stores/record) - + * `/v2/acts/{actorId}/runs/last/key-value-store/records/{recordKey}{?token,status}` [Record](#/reference/key-value-stores/record) #### Dataset - * `/v2/acts/{actorId}/runs/last/dataset/items{?token,status}` [Item collection](#/reference/datasets/item-collection) - #### Request queue - * `/v2/acts/{actorId}/runs/last/request-queue/requests{?token,status}` [Request collection](#/reference/request-queues/request-collection) - - * `/v2/acts/{actorId}/runs/last/request-queue/requests/{requestId}{?token,status}` [Request collection](#/reference/request-queues/request) - - * `/v2/acts/{actorId}/runs/last/request-queue/head{?token,status}` [Queue head](#/reference/request-queues/queue-head) - - For example, to download data from a dataset of the last succeeded actor run in - XML format, - + For example, to download data from a dataset of the last succeeded actor run in XML format, send HTTP GET request to the following URL: - ``` - https://api.apify.com/v2/acts/{actorId}/runs/last/dataset/items?token={yourApiToken}&format=xml&status=SUCCEEDED - ``` - - In order to save new items to the dataset, send HTTP POST request with JSON payload - to the same URL. + In order to save new items to the dataset, send HTTP POST request with JSON payload to the same URL. - name: Actor tasks x-displayName: Actor tasks x-legacy-doc-urls: - '#/reference/actor-tasks' - '#tag/Actor-tasks' - description: >- - The API endpoints described in this section enable you to manage and run Apify - actor tasks. - + description: | + The API endpoints described in this section enable you to manage and run Apify actor tasks. For more information, see the Actor tasks documentation. - Note that for all the API endpoints that accept the `actorTaskId` parameter to - specify a task, - - you can pass either the task ID (e.g. `HG7ML7M8z78YcAPEB`) or a tilde-separated - + specify a task, you can pass either the task ID (e.g. `HG7ML7M8z78YcAPEB`) or a tilde-separated username of the task's owner and the task's name (e.g. `janedoe~my-task`). - Some of the API endpoints return runs objects. Note that if any such run object contains usage in dollars, your effective unit pricing at the time of query - has been used for computation of this dollar equivalent, and hence it should be used only for informative purposes. You can learn more - about platform usage in the documentation. - name: Actor tasks/Task collection x-displayName: Task collection @@ -400,129 +326,74 @@ - '#/reference/actor-tasks/last-run-object-and-its-storages' - '#tag/Actor-tasksLast-run-object-and-its-storages' x-trait: 'true' - description: >- - This is not a single endpoint, but an entire group of endpoints that lets you - to - + description: | + This is not a single endpoint, but an entire group of endpoints that lets you to retrieve and manage the last run of given actor task or any of its default storages. - All the endpoints require an authentication token. - The endpoints accept the same HTTP methods and query parameters as - the respective storage endpoints. - The base path represents the last actor task run object is: - `/v2/actor-tasks/{actorTaskId}/runs/last{?token,status}` - - Using the `status` query parameter you can ensure to only get a run with a certain - status - + Using the `status` query parameter you can ensure to only get a run with a certain status (e.g. `status=SUCCEEDED`). The output of this endpoint and other query parameters - are the same as in the [Run object](#/reference/actors/run-object) endpoint. - In order to access the default storages of the last actor task run, i.e. log, - key-value store, dataset and request queue, - - use the following endpoints: - + key-value store, dataset and request queue, use the following endpoints: * `/v2/actor-tasks/{actorTaskId}/runs/last/log{?token,status}` - - * `/v2/actor-tasks/{actorTaskId}/runs/last/key-value-store{?token,status}` - - * `/v2/actor-tasks/{actorTaskId}/runs/last/dataset{?token,status}` - - * `/v2/actor-tasks/{actorTaskId}/runs/last/request-queue{?token,status}` - These API endpoints have the same usage as the equivalent storage endpoints. + For example, `/v2/actor-tasks/{actorTaskId}/runs/last/key-value-store` has the same HTTP method + and parameters as the [Key-value store object](#/reference/key-value-stores/store-object) endpoint. - For example, - - `/v2/actor-tasks/{actorTaskId}/runs/last/key-value-store` has the same HTTP method - and parameters as the - - [Key-value store object](#/reference/key-value-stores/store-object) endpoint. - - - Additionally, each of the above API endpoints supports all sub-endpoints - - of the original one: - + Additionally, each of the above API endpoints supports all sub-endpoints of the original one: #### Key-value store - * `/v2/actor-tasks/{actorTaskId}/runs/last/key-value-store/keys{?token,status}` [Key collection](#/reference/key-value-stores/key-collection) - - * `/v2/actor-tasks/{actorTaskId}/runs/last/key-value-store/records/{recordKey}{?token,status}` [Record](#/reference/key-value-stores/record) - #### Dataset - * `/v2/actor-tasks/{actorTaskId}/runs/last/dataset/items{?token,status}` [Item collection](#/reference/datasets/item-collection) - #### Request queue - * `/v2/actor-tasks/{actorTaskId}/runs/last/request-queue/requests{?token,status}` [Request collection](#/reference/request-queues/request-collection) - - * `/v2/actor-tasks/{actorTaskId}/runs/last/request-queue/requests/{requestId}{?token,status}` [Request collection](#/reference/request-queues/request) - - * `/v2/actor-tasks/{actorTaskId}/runs/last/request-queue/head{?token,status}` [Queue head](#/reference/request-queues/queue-head) - - For example, to download data from a dataset of the last succeeded actor task - run in XML format, - + For example, to download data from a dataset of the last succeeded actor task run in XML format, send HTTP GET request to the following URL: - ``` - https://api.apify.com/v2/actor-tasks/{actorTaskId}/runs/last/dataset/items?token={yourApiToken}&format=xml&status=SUCCEEDED - ``` - - In order to save new items to the dataset, send HTTP POST request with JSON payload - to the same URL. + In order to save new items to the dataset, send HTTP POST request with JSON payload to the same URL. - name: Actor runs x-displayName: Actor runs x-legacy-doc-urls: - '#/reference/actor-runs' - '#tag/Actor-runs' - description: >- + description: | The API endpoints described in this section enable you to manage Apify actor runs. - - Note that if any returned run object contains usage in dollars, your effective - unit pricing at the time of query - - has been used for computation of this dollar equivalent, and hence it should be - used only for informative purposes. - + Note that if any returned run object contains usage in dollars, your effective unit pricing at the time of query + has been used for computation of this dollar equivalent, and hence it should be used only for informative purposes. You can learn more about platform usage in the documentation. - name: Actor runs/Run collection x-displayName: Run collection @@ -538,101 +409,55 @@ - '#/reference/actor-runs/run-object-and-its-storages' - '#tag/Actor-runsRun-object-and-its-storages' x-trait: 'true' - description: >- + description: | This is not a single endpoint, but an entire group of endpoints that lets you - retrieve the run or any of its default storages. - - The endpoints accept the same HTTP methods and query parameters as - - the respective storage endpoints. - + The endpoints accept the same HTTP methods and query parameters as the respective storage endpoints. The base path that represents the actor run object is: - `/v2/actor-runs/{runId}{?token}` - In order to access the default storages of the actor run, i.e. log, key-value - store, dataset and request queue, - - use the following endpoints: - + store, dataset and request queue, use the following endpoints: * `/v2/actor-runs/{runId}/log{?token}` - - * `/v2/actor-runs/{runId}/key-value-store{?token}` - - * `/v2/actor-runs/{runId}/dataset{?token}` - - * `/v2/actor-runs/{runId}/request-queue{?token}` - These API endpoints have the same usage as the equivalent storage endpoints. + For example, `/v2/actor-runs/{runId}/key-value-store` has the same HTTP method and parameters + as the [Key-value store object](#/reference/key-value-stores/store-object) endpoint. - For example, - - `/v2/actor-runs/{runId}/key-value-store` has the same HTTP method and parameters - as the - - [Key-value store object](#/reference/key-value-stores/store-object) endpoint. - - - Additionally, each of the above API endpoints supports all sub-endpoints - - of the original one: - + Additionally, each of the above API endpoints supports all sub-endpoints of the original one: #### Log - * `/v2/actor-runs/{runId}/log` [Log](#/reference/logs) - #### Key-value store - * `/v2/actor-runs/{runId}/key-value-store/keys{?token}` [Key collection](#/reference/key-value-stores/key-collection) - - * `/v2/actor-runs/{runId}/key-value-store/records/{recordKey}{?token}` [Record](#/reference/key-value-stores/record) - #### Dataset - * `/v2/actor-runs/{runId}/dataset/items{?token}` [Item collection](#/reference/datasets/item-collection) - #### Request queue - * `/v2/actor-runs/{runId}/request-queue/requests{?token}` [Request collection](#/reference/request-queues/request-collection) - - - * `/v2/actor-runs/{runId}/request-queue/requests/{requestId}{?token}` [Request - collection](#/reference/request-queues/request) - - + * `/v2/actor-runs/{runId}/request-queue/requests/{requestId}{?token}` [Request collection](#/reference/request-queues/request) * `/v2/actor-runs/{runId}/request-queue/head{?token}` [Queue head](#/reference/request-queues/queue-head) - For example, to download data from a dataset of the actor run in XML format, - send HTTP GET request to the following URL: - ``` - https://api.apify.com/v2/actor-runs/{runId}/dataset/items?format=xml - ``` - In order to save new items to the dataset, send HTTP POST request with JSON payload to the same URL. - name: Actor runs/Delete run @@ -682,16 +507,12 @@ x-legacy-doc-urls: - '#/reference/actor-builds' - '#tag/Actor-builds' - description: >- + description: | The API endpoints described in this section enable you to manage Apify actor builds. - Note that if any returned build object contains usage in dollars, your effective - unit pricing at the time of query - - has been used for computation of this dollar equivalent, and hence it should be + unit pricing at the time of query has been used for computation of this dollar equivalent, and hence it should be used only for informative purposes. - You can learn more about platform usage in the documentation. - name: Actor builds/Build collection x-displayName: Build collection @@ -732,25 +553,16 @@ x-legacy-doc-urls: - '#/reference/key-value-stores' - '#tag/Key-value-stores' - description: >- + description: | This section describes API endpoints to manage Key-value stores. - Key-value store is a simple storage for saving and reading data records or files. - - Each data record is represented by a unique key and associated with a MIME content - type. - - Key-value stores are ideal for saving screenshots, actor inputs and outputs, web - pages, - + Each data record is represented by a unique key and associated with a MIME content type. + Key-value stores are ideal for saving screenshots, actor inputs and outputs, web pages, PDFs or to persist the state of crawlers. - For more information, see the Key-value store documentation. - Note that some of the endpoints do not require the authentication token, the calls - are authenticated using a hard-to-guess ID of the key-value store. - name: Key-value stores/Store collection x-displayName: Store collection @@ -785,27 +597,18 @@ x-legacy-doc-urls: - '#/reference/datasets' - '#tag/Datasets' - description: >- + description: | This section describes API endpoints to manage Datasets. - - Dataset is a storage for structured data, where each record stored has the same - attributes, - + Dataset is a storage for structured data, where each record stored has the same attributes, such as online store products or real estate offers. You can imagine it as a table, - where each object is a row and its attributes are columns. Dataset is an append-only - storage - you can only add new records to it but you cannot modify or remove existing - records. Typically it is used to store crawling results. - For more information, see the Datasets documentation. - Note that some of the endpoints do not require the authentication token, the calls - are authenticated using the hard-to-guess ID of the dataset. - name: Datasets/Dataset collection x-displayName: Dataset collection @@ -837,22 +640,17 @@ x-legacy-doc-urls: - '#/reference/request-queues' - '#tag/Request-queues' - description: >- + description: | This section describes API endpoints to manage request queues. Request queue is a storage for a queue of HTTP URLs to crawl, which is typically used for deep crawling of websites where you - start with several URLs and then recursively follow links to other pages. - The storage supports both breadth-first and depth-first crawling orders. - For more information, see the Request queue documentation. - Note that some of the endpoints do not require the authentication token, the calls - are authenticated using the hard-to-guess ID of the queue. - name: Request queues/Queue collection x-displayName: Queue collection @@ -915,18 +713,14 @@ x-legacy-doc-urls: - '#/reference/webhooks' - '#tag/Webhooks' - description: >- + description: | This section describes API endpoints to manage webhooks. - Webhooks provide an easy and reliable way to configure the Apify platform - to carry out an action (e.g. a HTTP request to another service) when a certain system event occurs. - For example, you can use webhooks to start another actor when an actor run finishes or fails. - For more information see Webhooks documentation. - name: Webhooks/Webhook collection @@ -982,23 +776,18 @@ x-legacy-doc-urls: - '#/reference/schedules' - '#tag/Schedules' - description: >- + description: | This section describes API endpoints for managing schedules. - Schedules are used to automatically start your actors at certain times. Each schedule can be associated with a number of actors and actor tasks. It is also possible - to override the settings of each actor (task) similarly to when invoking the actor (task) using the API. - For more information, see Schedules documentation. - Each schedule is assigned actions for it to perform. Actions can be of two types - `RUN_ACTOR` and `RUN_ACTOR_TASK`. For details, see the documentation of the - [Get schedule](#/reference/schedules/schedule-object/get-schedule) endpoint. - name: Schedules/Schedules collection x-displayName: Schedules collection @@ -1026,13 +815,11 @@ x-legacy-doc-urls: - '#/reference/store' - '#tag/Store' - description: >- + description: | [Apify Store](https://apify.com/store) is home to hundreds of public Actors available to the Apify community. - The API endpoints described in this section are used to retrieve these Actors. - Note that the endpoints do not require the authentication token. - name: Store/Store Actors collection x-displayName: Store Actors collection @@ -1046,16 +833,12 @@ x-legacy-doc-urls: - '#/reference/logs' - '#tag/Logs' - description: >- + description: | The API endpoints described in this section are used the download the logs - generated by actor builds and runs. Note that only the trailing 5M characters - of the log are stored, the rest is discarded. - Note that the endpoints do not require the authentication token, the calls - are authenticated using a hard-to-guess ID of the actor build or run. - name: Logs/Log x-displayName: Log diff --git a/apify-api/openapi/openapi.yaml b/apify-api/openapi/openapi.yaml index 3a1279477..a0f3b23bf 100644 --- a/apify-api/openapi/openapi.yaml +++ b/apify-api/openapi/openapi.yaml @@ -3,8 +3,8 @@ info: title: Apify API description: | - > **UPDATE 2024-07-09:** - > We have rolled out this new Apify API Documentation. In case of any issues, please [report here](https://github.com/apify/openapi/issues). + > **UPDATE 2025-01-14:** + > We have rolled out this new Apify API Documentation. In case of any issues, please [report here](https://github.com/apify/apify-docs/issues). > The old API Documentation is still [available here](https://docs.apify.com/api/v2-old). The Apify API (version 2) provides programmatic access to the [Apify diff --git a/apify-api/openapi/paths/actor-builds/actor-builds@{buildId}.yaml b/apify-api/openapi/paths/actor-builds/actor-builds@{buildId}.yaml index 144c03993..b811dbdac 100644 --- a/apify-api/openapi/paths/actor-builds/actor-builds@{buildId}.yaml +++ b/apify-api/openapi/paths/actor-builds/actor-builds@{buildId}.yaml @@ -29,9 +29,7 @@ get: in: query description: | The maximum number of seconds the server waits for the build to finish. - By default it is `0`, the maximum value is `60`. - - + By default it is `0`, the maximum value is `60`. If the build finishes in time then the returned build object will have a terminal status (e.g. `SUCCEEDED`), otherwise it will have a transitional status (e.g. `RUNNING`). diff --git a/apify-api/openapi/paths/actor-builds/actor-builds@{buildId}@log.yaml b/apify-api/openapi/paths/actor-builds/actor-builds@{buildId}@log.yaml index 33956cb74..1243ee402 100644 --- a/apify-api/openapi/paths/actor-builds/actor-builds@{buildId}@log.yaml +++ b/apify-api/openapi/paths/actor-builds/actor-builds@{buildId}@log.yaml @@ -44,11 +44,11 @@ get: text/plain: schema: type: string - example: |- + example: | 2017-07-14T06:00:49.733Z Application started. 2017-07-14T06:00:49.741Z Input: { test: 123 } 2017-07-14T06:00:49.752Z Some useful debug information follows. - example: |- + example: | 2017-07-14T06:00:49.733Z Application started. 2017-07-14T06:00:49.741Z Input: { test: 123 } 2017-07-14T06:00:49.752Z Some useful debug information follows. diff --git a/apify-api/openapi/paths/actor-runs/actor-runs@{runId}.yaml b/apify-api/openapi/paths/actor-runs/actor-runs@{runId}.yaml index cf201ca95..4a75770a6 100644 --- a/apify-api/openapi/paths/actor-runs/actor-runs@{runId}.yaml +++ b/apify-api/openapi/paths/actor-runs/actor-runs@{runId}.yaml @@ -21,7 +21,6 @@ get: * `/v2/actor-runs/{runId}/dataset{?token}` * `/v2/actor-runs/{runId}/request-queue{?token}` - These API endpoints have the same usage as the equivalent storage endpoints. For example, `/v2/actor-runs/{runId}/key-value-store` has the same HTTP method and @@ -66,11 +65,8 @@ get: payload to the same URL.Gets an object that contains all the details about a specific run of an Actor. - By passing the optional `waitForFinish` parameter the API endpoint will - synchronously wait for the run to finish. - - This is useful to avoid periodic polling when waiting for Actor run to - complete. + By passing the optional `waitForFinish` parameter the API endpoint will synchronously wait + for the run to finish. This is useful to avoid periodic polling when waiting for Actor run to complete. This endpoint does not require the authentication token. Instead, calls are authenticated using a hard-to-guess ID of the run. However, if you access the endpoint without the token, certain attributes, such as `usageUsd` and `usageTotalUsd`, will be hidden. diff --git a/apify-api/openapi/paths/actor-runs/actor-runs@{runId}@abort.yaml b/apify-api/openapi/paths/actor-runs/actor-runs@{runId}@abort.yaml index d81203e17..4aea0d9b9 100644 --- a/apify-api/openapi/paths/actor-runs/actor-runs@{runId}@abort.yaml +++ b/apify-api/openapi/paths/actor-runs/actor-runs@{runId}@abort.yaml @@ -20,7 +20,7 @@ post: example: 3KH8gEpp4d8uQSe8T - name: gracefully in: query - description: |- + description: | If true passed, the Actor run will abort gracefully. It will send `aborting` and `persistState` event into run and force-stop the run after 30 seconds. It is helpful in cases where you plan to resurrect the run later. diff --git a/apify-api/openapi/paths/actor-tasks/actor-tasks@{actorTaskId}@input.yaml b/apify-api/openapi/paths/actor-tasks/actor-tasks@{actorTaskId}@input.yaml index 6297221d8..9ead70e9b 100644 --- a/apify-api/openapi/paths/actor-tasks/actor-tasks@{actorTaskId}@input.yaml +++ b/apify-api/openapi/paths/actor-tasks/actor-tasks@{actorTaskId}@input.yaml @@ -49,7 +49,6 @@ put: The response is the full task input as returned by the [Get task input](#/reference/tasks/task-input-object/get-task-input) endpoint. - The request needs to specify the `Content-Type: application/json` HTTP header! diff --git a/apify-api/openapi/paths/actor-tasks/actor-tasks@{actorTaskId}@run-sync-get-dataset-items.yaml b/apify-api/openapi/paths/actor-tasks/actor-tasks@{actorTaskId}@run-sync-get-dataset-items.yaml index 4d87b50d2..f46c96e8c 100644 --- a/apify-api/openapi/paths/actor-tasks/actor-tasks@{actorTaskId}@run-sync-get-dataset-items.yaml +++ b/apify-api/openapi/paths/actor-tasks/actor-tasks@{actorTaskId}@run-sync-get-dataset-items.yaml @@ -97,10 +97,8 @@ post: description: | Specifies optional webhooks associated with the Actor run, which can be used to receive a notification - e.g. when the Actor finished or failed. The value is a Base64-encoded JSON array of objects defining the webhooks. For more information, see - [Webhooks documentation](https://docs.apify.com/platform/integrations/webhooks). style: form @@ -123,12 +121,9 @@ post: description: | If `true` or `1` then the API endpoint returns only non-empty items and skips hidden fields - (i.e. fields starting with the # character). - The `clean` parameter is just a shortcut for `skipHidden=true` and `skipEmpty=true` parameters. - Note that since some objects might be skipped from the output, that the result might contain less items than the `limit` value. style: form @@ -160,12 +155,9 @@ post: in: query description: | A comma-separated list of fields which should be picked from the items, - only these fields will remain in the resulting record objects. - Note that the fields in the outputted items are sorted the same way as they are specified in the `fields` query parameter. - You can use this feature to effectively fix the output format. style: form explode: true @@ -185,18 +177,13 @@ post: description: | A comma-separated list of fields which should be unwound, in order which they should be processed. Each field should be either an array or an object. - If the field is an array then every element of - the array will become a separate record and merged with parent object. - If the unwound field is an object then it is merged with the parent object - If the unwound field is missing or its value is neither an array nor an object and therefore cannot be merged with a parent object then the item gets preserved as it is. - Note that the unwound items ignore the `desc` parameter. style: form explode: true @@ -208,10 +195,8 @@ post: description: | A comma-separated list of fields which should transform nested objects into flat structures. - For example, with `flatten="foo"` the object `{"foo":{"bar": "hello"}}` is turned into `{"foo.bar": "hello"}`. - The original object with properties is replaced with the flattened object. style: form @@ -256,10 +241,8 @@ post: description: | All text responses are encoded in UTF-8 encoding. By default, the `format=csv` files are prefixed with - the UTF-8 Byte Order Mark (BOM), while `json`, `jsonl`, `xml`, `html` and `rss` files are not. - If you want to override this default behavior, specify `bom=1` query parameter to include the BOM or `bom=0` to skip it. style: form @@ -297,7 +280,7 @@ post: example: true - name: skipHidden in: query - description: |- + description: | If `true` or `1` then hidden fields are skipped from the output, i.e. fields starting with the `#` character. style: form @@ -687,7 +670,7 @@ get: example: true - name: skipHidden in: query - description: |- + description: | If `true` or `1` then hidden fields are skipped from the output, i.e. fields starting with the `#` character. style: form @@ -712,10 +695,8 @@ get: description: | If `true` or `1` then, the endpoint applies the `fields=url,pageFunctionResult,errorInfo` - and `unwind=pageFunctionResult` query parameters. This feature is used to emulate simplified results provided by the - legacy Apify Crawler product and it's not recommended to use it in new integrations. style: form @@ -728,7 +709,6 @@ get: description: | If `true` or `1` then, the all the items with errorInfo property will be skipped from the output. - This feature is here to emulate functionality of API version 1 used for the legacy Apify Crawler product and it's not recommended to use it in new integrations. diff --git a/apify-api/openapi/paths/actor-tasks/actor-tasks@{actorTaskId}@run-sync.yaml b/apify-api/openapi/paths/actor-tasks/actor-tasks@{actorTaskId}@run-sync.yaml index 90ab55a50..42f26e091 100644 --- a/apify-api/openapi/paths/actor-tasks/actor-tasks@{actorTaskId}@run-sync.yaml +++ b/apify-api/openapi/paths/actor-tasks/actor-tasks@{actorTaskId}@run-sync.yaml @@ -91,7 +91,7 @@ post: example: 0.1.234 - name: outputRecordKey in: query - description: |- + description: | Key of the record from run's default key-value store to be returned in the response. By default, it is `OUTPUT`. style: form @@ -227,7 +227,7 @@ get: example: 0.1.234 - name: outputRecordKey in: query - description: |- + description: | Key of the record from run's default key-value store to be returned in the response. By default, it is `OUTPUT`. style: form @@ -240,12 +240,9 @@ get: description: | Specifies optional webhooks associated with the Actor run, which can be used to receive a notification - e.g. when the Actor finished or failed. The value is a Base64-encoded JSON array of objects defining the webhooks. For more information, see - - [Webhooks - documentation](https://docs.apify.com/platform/integrations/webhooks). + [Webhooks documentation](https://docs.apify.com/platform/integrations/webhooks). style: form explode: true schema: diff --git a/apify-api/openapi/paths/actor-tasks/actor-tasks@{actorTaskId}@runs.yaml b/apify-api/openapi/paths/actor-tasks/actor-tasks@{actorTaskId}@runs.yaml index d3a514edf..4de254c43 100644 --- a/apify-api/openapi/paths/actor-tasks/actor-tasks@{actorTaskId}@runs.yaml +++ b/apify-api/openapi/paths/actor-tasks/actor-tasks@{actorTaskId}@runs.yaml @@ -152,7 +152,7 @@ post: To fetch the Actor run results that are typically stored in the default dataset, you'll need to pass the ID received in the `defaultDatasetId` field - received in the response JSON to the + received in the response JSON to the [Get items](#/reference/datasets/item-collection/get-items) API endpoint. operationId: actorTask_runs_post parameters: @@ -216,12 +216,9 @@ post: in: query description: | The maximum number of seconds the server waits for the run to finish. By - default, it is `0`, the maximum value is `60`. - + default, it is `0`, the maximum value is `60`. If the build finishes in time then the returned run object will have a terminal status (e.g. `SUCCEEDED`), - otherwise it will have a transitional status (e.g. `RUNNING`). style: form explode: true @@ -234,7 +231,6 @@ post: description: | Specifies optional webhooks associated with the Actor run, which can be used to receive a notification - e.g. when the Actor finished or failed. The value is a Base64-encoded JSON array of objects defining the webhooks. diff --git a/apify-api/openapi/paths/actors/acts.yaml b/apify-api/openapi/paths/actors/acts.yaml index 7cbbbb08e..dc5983455 100644 --- a/apify-api/openapi/paths/actors/acts.yaml +++ b/apify-api/openapi/paths/actors/acts.yaml @@ -102,20 +102,14 @@ post: description: | Creates a new Actor with settings specified in an Actor object passed as JSON in the POST payload. - The response is the full Actor object as returned by the - [Get Actor](#/reference/actors/actor-object/get-actor) endpoint. - The HTTP request must have the `Content-Type: application/json` HTTP header! - The Actor needs to define at least one version of the source code. - For more information, see [Version object](#/reference/actors/version-object). - If you want to make your Actor [public](https://docs.apify.com/platform/actors/publishing) using `isPublic: true`, you will need to provide the Actor's `title` and the `categories` diff --git a/apify-api/openapi/paths/actors/acts@{actorId}.yaml b/apify-api/openapi/paths/actors/acts@{actorId}.yaml index 0d69a7162..0993fedfd 100644 --- a/apify-api/openapi/paths/actors/acts@{actorId}.yaml +++ b/apify-api/openapi/paths/actors/acts@{actorId}.yaml @@ -99,23 +99,18 @@ put: description: | Updates settings of an Actor using values specified by an Actor object passed as JSON in the POST payload. - If the object does not define a specific property, its value will not be updated. - The response is the full Actor object as returned by the [Get Actor](#/reference/actors/actor-object/get-actor) endpoint. - The request needs to specify the `Content-Type: application/json` HTTP header! - When providing your API authentication token, we recommend using the request's `Authorization` header, rather than the URL. ([More info](#/introduction/authentication)). - If you want to make your Actor [public](https://docs.apify.com/platform/actors/publishing) using `isPublic: true`, you will need to provide the Actor's `title` and the `categories` diff --git a/apify-api/openapi/paths/actors/acts@{actorId}@builds.yaml b/apify-api/openapi/paths/actors/acts@{actorId}@builds.yaml index cfa60194a..ccf602d0e 100644 --- a/apify-api/openapi/paths/actors/acts@{actorId}@builds.yaml +++ b/apify-api/openapi/paths/actors/acts@{actorId}@builds.yaml @@ -6,11 +6,9 @@ get: Gets the list of builds of a specific Actor. The response is a JSON with the list of objects, where each object contains basic information about a single build. - The endpoint supports pagination using the `limit` and `offset` parameters and it will not return more than 1000 records. - By default, the records are sorted by the `startedAt` field in ascending order, therefore you can use pagination to incrementally fetch all builds while new ones are still being started. To sort the records in descending order, use @@ -78,7 +76,7 @@ post: tags: - Actors/Build collection summary: Build Actor - description: |- + description: | Builds an Actor. The response is the build object as returned by the [Get build](#/reference/actors/build-object/get-build) endpoint. @@ -135,8 +133,7 @@ post: in: query description: | The maximum number of seconds the server waits for the build to finish. - By default it is `0`, the maximum value is `60`. + By default it is `0`, the maximum value is `60`. If the build finishes in time then the returned build object will have a terminal status (e.g. `SUCCEEDED`), otherwise it will have a transitional status (e.g. `RUNNING`). style: form diff --git a/apify-api/openapi/paths/actors/acts@{actorId}@builds@{buildId}.yaml b/apify-api/openapi/paths/actors/acts@{actorId}@builds@{buildId}.yaml index 894b4a3d5..5b1ea59e4 100644 --- a/apify-api/openapi/paths/actors/acts@{actorId}@builds@{buildId}.yaml +++ b/apify-api/openapi/paths/actors/acts@{actorId}@builds@{buildId}.yaml @@ -5,11 +5,9 @@ get: description: | By passing the optional `waitForFinish` parameter the API endpoint will synchronously wait for the build to finish. - This is useful to avoid periodic polling when waiting for an Actor build to finish. - This endpoint does not require the authentication token. Instead, calls are authenticated using a hard-to-guess ID of the build. However, if you access the endpoint without the token, certain attributes, such as `usageUsd` and `usageTotalUsd`, will be hidden. operationId: act_build_get @@ -37,10 +35,9 @@ get: in: query description: | The maximum number of seconds the server waits for the build to finish. - By default it is `0`, the maximum value is `60`. - If the build finishes in time then the returned build object will have a terminal status (e.g. `SUCCEEDED`), - otherwise it will have a transitional status (e.g. `RUNNING`). + By default it is `0`, the maximum value is `60`. + If the build finishes in time then the returned build object will have a terminal status (e.g. `SUCCEEDED`), + otherwise it will have a transitional status (e.g. `RUNNING`). style: form explode: true schema: diff --git a/apify-api/openapi/paths/actors/acts@{actorId}@run-sync-get-dataset-items.yaml b/apify-api/openapi/paths/actors/acts@{actorId}@run-sync-get-dataset-items.yaml index 321f41c43..c0b494a1d 100644 --- a/apify-api/openapi/paths/actors/acts@{actorId}@run-sync-get-dataset-items.yaml +++ b/apify-api/openapi/paths/actors/acts@{actorId}@run-sync-get-dataset-items.yaml @@ -5,36 +5,26 @@ post: description: | Runs a specific Actor and returns its dataset items. - The POST payload including its `Content-Type` header is passed as `INPUT` to the Actor (usually `application/json`). - The HTTP response contains the Actors dataset items, while the format of items depends on specifying dataset items' `format` parameter. - You can send all the same options in parameters as the [Get Dataset Items](#/reference/datasets/item-collection/get-items) API endpoint. - The Actor is started with the default options; you can override them using URL query parameters. - If the Actor run exceeds 300 seconds, - the HTTP response will return the 408 status code (Request Timeout). - Beware that it might be impossible to maintain an idle HTTP connection for a long period of time, - due to client timeout or network conditions. Make sure your HTTP client is configured to have a long enough connection timeout. - If the connection breaks, you will not receive any information about the run and its status. - To run the Actor asynchronously, use the [Run Actor](#/reference/actors/run-collection/run-actor) API endpoint instead. operationId: act_runSyncGetDatasetItems_post @@ -100,12 +90,9 @@ post: description: | Specifies optional webhooks associated with the Actor run, which can be used to receive a notification - e.g. when the Actor finished or failed. The value is a Base64-encoded JSON array of objects defining the webhooks. For more information, see - - [Webhooks - documentation](https://docs.apify.com/platform/integrations/webhooks). + [Webhooks documentation](https://docs.apify.com/platform/integrations/webhooks). style: form explode: true schema: @@ -125,13 +112,9 @@ post: in: query description: | If `true` or `1` then the API endpoint returns only non-empty items and - skips hidden fields - - (i.e. fields starting with the # character). - + skips hidden fields (i.e. fields starting with the # character). The `clean` parameter is just a shortcut for `skipHidden=true` and `skipEmpty=true` parameters. - Note that since some objects might be skipped from the output, that the result might contain less items than the `limit` value. style: form @@ -163,12 +146,9 @@ post: in: query description: | A comma-separated list of fields which should be picked from the items, - only these fields will remain in the resulting record objects. - Note that the fields in the outputted items are sorted the same way as they are specified in the `fields` query parameter. - You can use this feature to effectively fix the output format. style: form explode: true @@ -188,18 +168,12 @@ post: description: | A comma-separated list of fields which should be unwound, in order which they should be processed. Each field should be either an array or an object. - If the field is an array then every element of - the array will become a separate record and merged with parent object. - - If the unwound field is an object then it is merged with the parent - object - + If the unwound field is an object then it is merged with the parent object. If the unwound field is missing or its value is neither an array nor an object and therefore cannot be merged with a parent object then the item gets preserved as it is. - Note that the unwound items ignore the `desc` parameter. style: form explode: true @@ -211,10 +185,8 @@ post: description: | A comma-separated list of fields which should transform nested objects into flat structures. - For example, with `flatten="foo"` the object `{"foo":{"bar": "hello"}}` is turned into `{"foo.bar": "hello"}`. - The original object with properties is replaced with the flattened object. style: form @@ -259,10 +231,8 @@ post: description: | All text responses are encoded in UTF-8 encoding. By default, the `format=csv` files are prefixed with - the UTF-8 Byte Order Mark (BOM), while `json`, `jsonl`, `xml`, `html` and `rss` files are not. - If you want to override this default behavior, specify `bom=1` query parameter to include the BOM or `bom=0` to skip it. style: form @@ -300,7 +270,7 @@ post: example: true - name: skipHidden in: query - description: |- + description: | If `true` or `1` then hidden fields are skipped from the output, i.e. fields starting with the `#` character. style: form @@ -325,10 +295,8 @@ post: description: | If `true` or `1` then, the endpoint applies the `fields=url,pageFunctionResult,errorInfo` - and `unwind=pageFunctionResult` query parameters. This feature is used to emulate simplified results provided by the - legacy Apify Crawler product and it's not recommended to use it in new integrations. style: form @@ -341,7 +309,6 @@ post: description: | If `true` or `1` then, the all the items with errorInfo property will be skipped from the output. - This feature is here to emulate functionality of API version 1 used for the legacy Apify Crawler product and it's not recommended to use it in new integrations. @@ -432,27 +399,20 @@ get: summary: Run Actor synchronously without input and get dataset items description: | Runs a specific Actor and returns its dataset items. - The run must finish in 300 seconds otherwise the API endpoint returns a timeout error. - The Actor is not passed any input. - It allows to send all possible options in parameters from [Get Dataset Items](#/reference/datasets/item-collection/get-items) API endpoint. - Beware that it might be impossible to maintain an idle HTTP connection for a long period of time, - due to client timeout or network conditions. Make sure your HTTP client is configured to have a long enough connection timeout. - If the connection breaks, you will not receive any information about the run and its status. - To run the Actor asynchronously, use the [Run Actor](#/reference/actors/run-collection/run-actor) API endpoint instead. operationId: act_runSyncGetDatasetItems_get @@ -518,12 +478,9 @@ get: description: | Specifies optional webhooks associated with the Actor run, which can be used to receive a notification - e.g. when the Actor finished or failed. The value is a Base64-encoded JSON array of objects defining the webhooks. For more information, see - - [Webhooks - documentation](https://docs.apify.com/platform/integrations/webhooks). + [Webhooks documentation](https://docs.apify.com/platform/integrations/webhooks). style: form explode: true schema: @@ -543,13 +500,8 @@ get: in: query description: | If `true` or `1` then the API endpoint returns only non-empty items and - skips hidden fields - - (i.e. fields starting with the # character). - - The `clean` parameter is just a shortcut for `skipHidden=true` and - `skipEmpty=true` parameters. - + skips hidden fields (i.e. fields starting with the # character). + The `clean` parameter is just a shortcut for `skipHidden=true` and `skipEmpty=true` parameters. Note that since some objects might be skipped from the output, that the result might contain less items than the `limit` value. style: form @@ -560,8 +512,7 @@ get: - name: offset in: query description: | - Number of items that should be skipped at the start. The default value - is `0`. + Number of items that should be skipped at the start. The default value is `0`. style: form explode: true schema: @@ -581,12 +532,9 @@ get: in: query description: | A comma-separated list of fields which should be picked from the items, - only these fields will remain in the resulting record objects. - Note that the fields in the outputted items are sorted the same way as they are specified in the `fields` query parameter. - You can use this feature to effectively fix the output format. style: form explode: true @@ -606,18 +554,12 @@ get: description: | A comma-separated list of fields which should be unwound, in order which they should be processed. Each field should be either an array or an object. - If the field is an array then every element of - the array will become a separate record and merged with parent object. - - If the unwound field is an object then it is merged with the parent - object - + If the unwound field is an object then it is merged with the parent object If the unwound field is missing or its value is neither an array nor an object and therefore cannot be merged with a parent object then the item gets preserved as it is. - Note that the unwound items ignore the `desc` parameter. style: form explode: true @@ -627,14 +569,9 @@ get: - name: flatten in: query description: | - A comma-separated list of fields which should transform nested objects - into flat structures. - - For example, with `flatten="foo"` the object `{"foo":{"bar": "hello"}}` - is turned into `{"foo.bar": "hello"}`. - - The original object with properties is replaced with the flattened - object. + A comma-separated list of fields which should transform nested objects into flat structures. + For example, with `flatten="foo"` the object `{"foo":{"bar": "hello"}}` is turned into `{"foo.bar": "hello"}`. + The original object with properties is replaced with the flattened object. style: form explode: true schema: @@ -675,12 +612,8 @@ get: - name: bom in: query description: | - All text responses are encoded in UTF-8 encoding. By default, the - `format=csv` files are prefixed with - - the UTF-8 Byte Order Mark (BOM), while `json`, `jsonl`, `xml`, `html` - and `rss` files are not. - + All text responses are encoded in UTF-8 encoding. By default, the `format=csv` files are prefixed with + the UTF-8 Byte Order Mark (BOM), while `json`, `jsonl`, `xml`, `html` and `rss` files are not. If you want to override this default behavior, specify `bom=1` query parameter to include the BOM or `bom=0` to skip it. style: form @@ -718,7 +651,7 @@ get: example: true - name: skipHidden in: query - description: |- + description: | If `true` or `1` then hidden fields are skipped from the output, i.e. fields starting with the `#` character. style: form @@ -741,14 +674,10 @@ get: - name: simplified in: query description: | - If `true` or `1` then, the endpoint applies the - `fields=url,pageFunctionResult,errorInfo` - + If `true` or `1` then, the endpoint applies the `fields=url,pageFunctionResult,errorInfo` and `unwind=pageFunctionResult` query parameters. This feature is used to emulate simplified results provided by the - - legacy Apify Crawler product and it's not recommended to use it in new - integrations. + legacy Apify Crawler product and it's not recommended to use it in new integrations. style: form explode: true schema: @@ -759,7 +688,6 @@ get: description: | If `true` or `1` then, the all the items with errorInfo property will be skipped from the output. - This feature is here to emulate functionality of API version 1 used for the legacy Apify Crawler product and it's not recommended to use it in new integrations. diff --git a/apify-api/openapi/paths/actors/acts@{actorId}@runs.yaml b/apify-api/openapi/paths/actors/acts@{actorId}@runs.yaml index 7f25b54ee..a78b630de 100644 --- a/apify-api/openapi/paths/actors/acts@{actorId}@runs.yaml +++ b/apify-api/openapi/paths/actors/acts@{actorId}@runs.yaml @@ -6,11 +6,9 @@ get: Gets the list of runs of a specific Actor. The response is a list of objects, where each object contains basic information about a single Actor run. - The endpoint supports pagination using the `limit` and `offset` parameters and it will not return more than 1000 array elements. - By default, the records are sorted by the `startedAt` field in ascending order, therefore you can use pagination to incrementally fetch all records while new ones are still being created. To sort the records in descending order, use @@ -211,8 +209,7 @@ post: in: query description: | The maximum number of seconds the server waits for the run to finish. By - default, it is `0`, the maximum value is `60`. + default, it is `0`, the maximum value is `60`. If the build finishes in time then the returned run object will have a terminal status (e.g. `SUCCEEDED`), otherwise it will have a transitional status (e.g. `RUNNING`). style: form diff --git a/apify-api/openapi/paths/actors/acts@{actorId}@runs@{runId}.yaml b/apify-api/openapi/paths/actors/acts@{actorId}@runs@{runId}.yaml index 9649a777a..9e54df937 100644 --- a/apify-api/openapi/paths/actors/acts@{actorId}@runs@{runId}.yaml +++ b/apify-api/openapi/paths/actors/acts@{actorId}@runs@{runId}.yaml @@ -6,18 +6,13 @@ get: **[DEPRECATED]** API endpoints related to run of the Actor were moved under new namespace [`actor-runs`](#/reference/actor-runs). - - Gets an object that contains all the details about a specific run of an - Actor. - + Gets an object that contains all the details about a specific run of an Actor. By passing the optional `waitForFinish` parameter the API endpoint will synchronously wait for the run to finish. - This is useful to avoid periodic polling when waiting for Actor run to complete. - This endpoint does not require the authentication token. Instead, calls are authenticated using a hard-to-guess ID of the run. However, if you access the endpoint without the token, certain attributes, such as `usageUsd` and `usageTotalUsd`, will be hidden. operationId: act_run_get @@ -42,10 +37,9 @@ get: in: query description: | The maximum number of seconds the server waits for the run to finish. By - default it is `0`, the maximum value is `60`. - If the build finishes in time then the returned run object will have a terminal status (e.g. `SUCCEEDED`), - otherwise it will have a transitional status (e.g. `RUNNING`). + default it is `0`, the maximum value is `60`. + If the build finishes in time then the returned run object will have a terminal status (e.g. `SUCCEEDED`), + otherwise it will have a transitional status (e.g. `RUNNING`). style: form explode: true schema: diff --git a/apify-api/openapi/paths/actors/acts@{actorId}@runs@{runId}@abort.yaml b/apify-api/openapi/paths/actors/acts@{actorId}@runs@{runId}@abort.yaml index 2b64707d3..8286fce4c 100644 --- a/apify-api/openapi/paths/actors/acts@{actorId}@runs@{runId}@abort.yaml +++ b/apify-api/openapi/paths/actors/acts@{actorId}@runs@{runId}@abort.yaml @@ -29,10 +29,10 @@ post: example: 3KH8gEpp4d8uQSe8T - name: gracefully in: query - description: |- + description: | If true passed, the Actor run will abort gracefully. - It will send `aborting` and `persistState` event into run and force-stop the run after 30 seconds. - It is helpful in cases where you plan to resurrect the run later. + It will send `aborting` and `persistState` event into run and force-stop the run after 30 seconds. + It is helpful in cases where you plan to resurrect the run later. style: form explode: true schema: diff --git a/apify-api/openapi/paths/actors/acts@{actorId}@runs@{runId}@metamorph.yaml b/apify-api/openapi/paths/actors/acts@{actorId}@runs@{runId}@metamorph.yaml index c55d42263..8752c7172 100644 --- a/apify-api/openapi/paths/actors/acts@{actorId}@runs@{runId}@metamorph.yaml +++ b/apify-api/openapi/paths/actors/acts@{actorId}@runs@{runId}@metamorph.yaml @@ -8,28 +8,19 @@ post: into a run of another Actor with a new input. This is useful if you want to use another Actor to finish the work - of your current Actor run, without the need to create a completely new run and waiting for its finish. - For the users of your Actors, the metamorph operation is transparent, they will just see your Actor got the work done. - There is a limit on how many times you can metamorph a single run. You can - check the limit in [the Actor runtime - limits](https://docs.apify.com/platform/limits#actor-limits). - + check the limit in [the Actor runtime limits](https://docs.apify.com/platform/limits#actor-limits). Internally, the system stops the Docker container corresponding to the Actor - run - - and starts a new container using a different Docker image. - + run and starts a new container using a different Docker image. All the default storages are preserved and the new input is stored under the `INPUT-METAMORPH-1` key in the same default key-value store. - For more information, see the [Actor docs](https://docs.apify.com/platform/actors/development/programming-interface/metamorph). operationId: act_run_metamorph_post diff --git a/apify-api/openapi/paths/actors/acts@{actorId}@runs@{runId}@resurrect.yaml b/apify-api/openapi/paths/actors/acts@{actorId}@runs@{runId}@resurrect.yaml index d5d373333..5aede9c2e 100644 --- a/apify-api/openapi/paths/actors/acts@{actorId}@runs@{runId}@resurrect.yaml +++ b/apify-api/openapi/paths/actors/acts@{actorId}@runs@{runId}@resurrect.yaml @@ -10,13 +10,10 @@ post: Only finished runs, i.e. runs with status `FINISHED`, `FAILED`, `ABORTED` and `TIMED-OUT` can be resurrected. - Run status will be updated to RUNNING and its container will be restarted with the same storages - (the same behaviour as when the run gets migrated to the new server). - For more information, see the [Actor docs](https://docs.apify.com/platform/actors/running/runs-and-builds#resurrection-of-finished-run). operationId: act_run_resurrect_post diff --git a/apify-api/openapi/paths/actors/acts@{actorId}@versions@{versionNumber}.yaml b/apify-api/openapi/paths/actors/acts@{actorId}@versions@{versionNumber}.yaml index 820c8b1b9..0dad94777 100644 --- a/apify-api/openapi/paths/actors/acts@{actorId}@versions@{versionNumber}.yaml +++ b/apify-api/openapi/paths/actors/acts@{actorId}@versions@{versionNumber}.yaml @@ -46,7 +46,7 @@ get: For more information about source code and Actor versions, see [Source code](https://docs.apify.com/platform/actors/development/actor-definition/source-code) - in Actors documentation.Gets a [Version + in Actors documentation. Gets a [Version object](#/reference/actors/version-object) that contains all the details about a specific version of an Actor. operationId: act_version_get @@ -89,9 +89,7 @@ put: summary: Update version description: | The **Version object** contains the source code of a specific version of an - Actor. - - The `sourceType` property indicates where the source code is hosted, and + Actor. The `sourceType` property indicates where the source code is hosted, and based on its value the Version object has the following additional property: @@ -129,10 +127,9 @@ put:
- For more information about source code and Actor versions, see [Source code](https://docs.apify.com/platform/actors/development/actor-definition/source-code) - in Actors documentation.Updates Actor version using values specified by a + in Actors documentation. Updates Actor version using values specified by a [Version object](#/reference/actors/version-object) passed as JSON in the POST payload. If the object does not define a specific property, its value will not be @@ -206,15 +203,10 @@ delete: - Actors/Version object summary: Delete version description: | - The **Version object** contains the source code of a specific version of an - Actor. - - The `sourceType` property indicates where the source code is hosted, and - based - + The **Version object** contains the source code of a specific version of an Actor. + The `sourceType` property indicates where the source code is hosted, and based on its value the Version object has the following additional property: - @@ -250,10 +242,9 @@ delete:
"SOURCE_FILES"
- For more information about source code and Actor versions, see [Source code](https://docs.apify.com/platform/actors/development/actor-definition/source-code) - in Actors documentation.Deletes a specific version of Actor's source code. + in Actors documentation. Deletes a specific version of Actor's source code. operationId: act_version_delete parameters: - name: actorId diff --git a/apify-api/openapi/paths/actors/acts@{actorId}@versions@{versionNumber}@env-vars.yaml b/apify-api/openapi/paths/actors/acts@{actorId}@versions@{versionNumber}@env-vars.yaml index e5680f5c5..e8838e68e 100644 --- a/apify-api/openapi/paths/actors/acts@{actorId}@versions@{versionNumber}@env-vars.yaml +++ b/apify-api/openapi/paths/actors/acts@{actorId}@versions@{versionNumber}@env-vars.yaml @@ -53,12 +53,10 @@ post: JSON payload and a `Content-Type: application/json` HTTP header. ``` - { "name": "ENV_VAR_NAME", "value": "my-env-var" } - ``` The response is the [EnvVar diff --git a/apify-api/openapi/paths/actors/acts@{actorId}@versions@{versionNumber}@env-vars@{envVarName}.yaml b/apify-api/openapi/paths/actors/acts@{actorId}@versions@{versionNumber}@env-vars@{envVarName}.yaml index f53d1f480..48c327477 100644 --- a/apify-api/openapi/paths/actors/acts@{actorId}@versions@{versionNumber}@env-vars@{envVarName}.yaml +++ b/apify-api/openapi/paths/actors/acts@{actorId}@versions@{versionNumber}@env-vars@{envVarName}.yaml @@ -61,27 +61,19 @@ put: description: | Updates Actor environment variable using values specified by a [EnvVar object](#/reference/actors/environment-variable-object) - passed as JSON in the POST payload. - If the object does not define a specific property, its value will not be updated. - The request needs to specify the `Content-Type: application/json` HTTP header! - When providing your API authentication token, we recommend using the request's `Authorization` header, rather than the URL. ([More info](#/introduction/authentication)). - - The response is the [EnvVar - object](#/reference/actors/environment-variable-object) as returned by the - - [Get environment - variable](#/reference/actors/environment-variable-object/get-environment-variable) + The response is the [EnvVar object](#/reference/actors/environment-variable-object) as returned by the + [Get environment variable](#/reference/actors/environment-variable-object/get-environment-variable) endpoint. operationId: act_version_envVar_put parameters: diff --git a/apify-api/openapi/paths/datasets/datasets.yaml b/apify-api/openapi/paths/datasets/datasets.yaml index 7ef4a5c76..3ff0685ad 100644 --- a/apify-api/openapi/paths/datasets/datasets.yaml +++ b/apify-api/openapi/paths/datasets/datasets.yaml @@ -149,7 +149,6 @@ post: x-legacy-doc-urls: - https://docs.apify.com/api/v2#/reference/datasets/dataset-collection/create-dataset - https://docs.apify.com/api/v2#/reference/datasets/create-dataset - - https://docs.apify.com/api/v2#tag/DatasetsDataset-collection/operation/datasets_post x-js-parent: DatasetCollectionClient x-js-name: getOrCreate diff --git a/apify-api/openapi/paths/datasets/datasets@{datasetId}.yaml b/apify-api/openapi/paths/datasets/datasets@{datasetId}.yaml index 520455938..7d741f93e 100644 --- a/apify-api/openapi/paths/datasets/datasets@{datasetId}.yaml +++ b/apify-api/openapi/paths/datasets/datasets@{datasetId}.yaml @@ -5,7 +5,6 @@ get: description: | Returns dataset object for given dataset ID. - **NOTE:** Keep in mind that attributes `itemCount` and `cleanItemCount` are not propagated right away after data are pushed into a dataset. There is a short period (up to 5 seconds) during which these counters may not match with exact counts in dataset items. operationId: dataset_get diff --git a/apify-api/openapi/paths/datasets/datasets@{datasetId}@items.yaml b/apify-api/openapi/paths/datasets/datasets@{datasetId}@items.yaml index 3a058ec82..cc7dd9f7c 100644 --- a/apify-api/openapi/paths/datasets/datasets@{datasetId}@items.yaml +++ b/apify-api/openapi/paths/datasets/datasets@{datasetId}@items.yaml @@ -5,22 +5,16 @@ get: description: | Returns data stored in the dataset in a desired format. - ### Response format - The format of the response depends on format query parameter. - The format parameter can have one of the following values: - json, jsonl, xml, html, csv, xlsx and rss. - The following table describes how each format is treated. - @@ -57,17 +51,13 @@ get: Note that CSV, XLSX and HTML tables are limited to 2000 columns and the column names cannot be longer than 200 characters. JSON, XML and RSS formats do not have such restrictions. - ### Hidden fields - The top-level fields starting with the `#` character are considered hidden. These are useful to store debugging information and can be omitted from the output by providing the `skipHidden=1` or `clean=1` query parameters. For example, if you store the following object to the dataset: - ``` - { productName: "iPhone Xs", description: "Welcome to the big screens." @@ -76,26 +66,19 @@ get: crawledAt: "2019-01-21T16:06:03.683Z" } } - ``` - The `#debug` field will be considered as hidden and can be omitted from the results. This is useful to - provide nice cleaned data to end users, while keeping debugging info available if needed. The Dataset object - returned by the API contains the number of such clean items in the`dataset.cleanItemCount` property. - ### XML format extension - When exporting results to XML or RSS formats, the names of object properties become XML tags and the corresponding values become tag's children. For example, the following JavaScript object: ``` - { name: "Paul Newman", address: [ @@ -103,17 +86,12 @@ get: { type: "office", street: null, city: null } ] } - ``` - will be transformed to the following XML snippet: - ``` - Paul Newman -
home 21st @@ -124,7 +102,6 @@ get:
- ``` If the JavaScript object contains a property named `@` then its sub-properties are exported as attributes of the parent XML @@ -133,9 +110,7 @@ get: For example, the following JavaScript object: - ``` - { "address": [{ "@": { @@ -151,44 +126,30 @@ get: "#": 'unknown' }] } - ``` - will be transformed to the following XML snippet: - ``` -
21st Chicago
-
unknown
- ``` - This feature is also useful to customize your RSS feeds generated for various websites. - By default the whole result is wrapped in a `` element and each page object is wrapped in a `` element. - You can change this using xmlRoot and xmlRow url parameters. - ### Pagination - The generated response supports [pagination](#/introduction/pagination). The pagination is always performed with the granularity of a single item, regardless whether unwind parameter was provided. By default, the **Items** in the response are sorted by the time they were stored to the database, therefore you can use pagination to incrementally fetch the items as they are being added. - No limit exists to how many items can be returned in one response. - - If you specify `desc=1` query parameter, the results are returned in the reverse order than they were stored (i.e. from newest to oldest items). Note that only the order of **Items** is reversed, but not the order of the `unwind` array elements. operationId: dataset_items_get @@ -360,7 +321,7 @@ get: example: true - name: skipHidden in: query - description: |- + description: | If `true` or `1` then hidden fields are skipped from the output, i.e. fields starting with the `#` character. style: form explode: true @@ -475,14 +436,11 @@ post: summary: Put items description: | Appends an item or an array of items to the end of the dataset. - The POST payload is a JSON object or a JSON array of objects to save into the dataset. - If the data you attempt to store in the dataset is invalid (meaning any of the items received by the API fails the validation), the whole request is discarded and the API will return a response with status code 400. For more information about dataset schema validation, see [Dataset schema](https://docs.apify.com/platform/actors/development/actor-definition/dataset-schema/validation). - **IMPORTANT:** The limit of request payload size for the dataset is 5 MB. If the array exceeds the size, you'll need to split it into a number of smaller arrays. operationId: dataset_items_post parameters: diff --git a/apify-api/openapi/paths/logs/logs@{buildOrRunId}.yaml b/apify-api/openapi/paths/logs/logs@{buildOrRunId}.yaml index 7b2f2468e..0ee1eecb8 100644 --- a/apify-api/openapi/paths/logs/logs@{buildOrRunId}.yaml +++ b/apify-api/openapi/paths/logs/logs@{buildOrRunId}.yaml @@ -47,11 +47,11 @@ get: text/plain: schema: type: string - example: |- + example: | 2017-07-14T06:00:49.733Z Application started. 2017-07-14T06:00:49.741Z Input: { test: 123 } 2017-07-14T06:00:49.752Z Some useful debug information follows. - example: |- + example: | 2017-07-14T06:00:49.733Z Application started. 2017-07-14T06:00:49.741Z Input: { test: 123 } 2017-07-14T06:00:49.752Z Some useful debug information follows. diff --git a/apify-api/openapi/paths/request-queues/request-queues.yaml b/apify-api/openapi/paths/request-queues/request-queues.yaml index 39b274405..632d495b4 100644 --- a/apify-api/openapi/paths/request-queues/request-queues.yaml +++ b/apify-api/openapi/paths/request-queues/request-queues.yaml @@ -5,20 +5,13 @@ get: description: | Lists all of a user's request queues. The response is a JSON array of objects, where each object - contains basic information about one queue. - - By default, the objects are sorted by the `createdAt` field in ascending - order, - + By default, the objects are sorted by the `createdAt` field in ascending order, therefore you can use pagination to incrementally fetch all queues while new - ones are still being created. To sort them in descending order, use `desc=1` - parameter. The endpoint supports pagination using `limit` and `offset` parameters and it will not return more than 1000 - array elements. operationId: requestQueues_get parameters: @@ -89,14 +82,11 @@ post: summary: Create request queue description: | Creates a request queue and returns its object. - Keep in mind that requests stored under unnamed queue follows [data retention period](https://docs.apify.com/platform/storage#data-retention). - It creates a queue of given name if the parameter name is used. If a queue with the given name already exists then the endpoint returns - its object. operationId: requestQueues_post parameters: diff --git a/apify-api/openapi/paths/request-queues/request-queues@{queueId}.yaml b/apify-api/openapi/paths/request-queues/request-queues@{queueId}.yaml index b6228d2aa..5c8c84228 100644 --- a/apify-api/openapi/paths/request-queues/request-queues@{queueId}.yaml +++ b/apify-api/openapi/paths/request-queues/request-queues@{queueId}.yaml @@ -68,12 +68,8 @@ put: Updates a request queue's name using a value specified by a JSON object passed in the PUT payload. - The response is the updated request queue object, as returned by the - - [Get request - queue](#/reference/request-queues/queue-collection/get-request-queue) API - endpoint. + [Get request queue](#/reference/request-queues/queue-collection/get-request-queue) API endpoint. operationId: requestQueue_put parameters: - name: queueId diff --git a/apify-api/openapi/paths/request-queues/request-queues@{queueId}@head.yaml b/apify-api/openapi/paths/request-queues/request-queues@{queueId}@head.yaml index 0506a2300..b0916e6cd 100644 --- a/apify-api/openapi/paths/request-queues/request-queues@{queueId}@head.yaml +++ b/apify-api/openapi/paths/request-queues/request-queues@{queueId}@head.yaml @@ -5,11 +5,9 @@ get: description: | Returns given number of first requests from the queue. - The response contains the `hadMultipleClients` boolean field which indicates that the queue was accessed by more than one client (with unique or empty `clientKey`). - This field is used by [Apify SDK](https://sdk.apify.com) to determine whether the local cache is consistent with the request queue, and thus optimize performance of certain operations. @@ -39,7 +37,6 @@ get: be a string between 1 and 32 characters long. This identifier is used to determine whether the queue was accessed by multiple clients. If `clientKey` is not provided, - the system considers this API call to come from a new client. For details, see the `hadMultipleClients` field returned by the [Get head](#/reference/request-queues/queue-head) operation. diff --git a/apify-api/openapi/paths/request-queues/request-queues@{queueId}@requests.yaml b/apify-api/openapi/paths/request-queues/request-queues@{queueId}@requests.yaml index ec4fe9211..23b5f962a 100644 --- a/apify-api/openapi/paths/request-queues/request-queues@{queueId}@requests.yaml +++ b/apify-api/openapi/paths/request-queues/request-queues@{queueId}@requests.yaml @@ -22,7 +22,6 @@ get: be a string between 1 and 32 characters long. This identifier is used to determine whether the queue was accessed by multiple clients. If `clientKey` is not provided, - the system considers this API call to come from a new client. For details, see the `hadMultipleClients` field returned by the [Get head](#/reference/request-queues/queue-head) operation. @@ -144,7 +143,6 @@ post: Adds request to the queue. Response contains ID of the request and info if request was already present in the queue or handled. - If request with same `uniqueKey` was already present in the queue then returns an ID of existing request. operationId: requestQueue_requests_post @@ -164,7 +162,6 @@ post: be a string between 1 and 32 characters long. This identifier is used to determine whether the queue was accessed by multiple clients. If `clientKey` is not provided, - the system considers this API call to come from a new client. For details, see the `hadMultipleClients` field returned by the [Get head](#/reference/request-queues/queue-head) operation. diff --git a/apify-api/openapi/paths/request-queues/request-queues@{queueId}@requests@batch.yaml b/apify-api/openapi/paths/request-queues/request-queues@{queueId}@requests@batch.yaml index 3a62eb1f4..b08590180 100644 --- a/apify-api/openapi/paths/request-queues/request-queues@{queueId}@requests@batch.yaml +++ b/apify-api/openapi/paths/request-queues/request-queues@{queueId}@requests@batch.yaml @@ -5,16 +5,12 @@ post: description: | Adds requests to the queue in batch. The maximum requests in batch is limit to 25. The response contains an array of unprocessed and processed requests. - If any add operation fails because the request queue rate limit is exceeded or an internal failure occurs, - the failed request is returned in the unprocessedRequests response parameter. - You can resend these requests to add. It is recommended to use exponential backoff algorithm for these retries. - If a request with the same `uniqueKey` was already present in the queue, then it returns an ID of the existing request. operationId: requestQueue_requests_batch_post @@ -120,16 +116,12 @@ delete: Batch-deletes given requests from the queue. The number of requests in a batch is limited to 25. The response contains an array of unprocessed and processed requests. - If any delete operation fails because the request queue rate limit is exceeded or an internal failure occurs, - the failed request is returned in the `unprocessedRequests` response parameter. - You can re-send these delete requests. It is recommended to use an exponential backoff algorithm for these retries. - Each request is identified by its ID or uniqueKey parameter. You can use either of them to identify the request. operationId: requestQueue_requests_batch_delete diff --git a/apify-api/openapi/paths/request-queues/request-queues@{queueId}@requests@{requestId}.yaml b/apify-api/openapi/paths/request-queues/request-queues@{queueId}@requests@{requestId}.yaml index f6982fc34..d6392c5be 100644 --- a/apify-api/openapi/paths/request-queues/request-queues@{queueId}@requests@{requestId}.yaml +++ b/apify-api/openapi/paths/request-queues/request-queues@{queueId}@requests@{requestId}.yaml @@ -83,8 +83,6 @@ put: description: | Updates a request in a queue. Mark request as handled by setting `request.handledAt = new Date()`. - - If `handledAt` is set, the request will be removed from head of the queue. operationId: requestQueue_request_put parameters: @@ -121,7 +119,6 @@ put: be a string between 1 and 32 characters long. This identifier is used to determine whether the queue was accessed by multiple clients. If `clientKey` is not provided, - the system considers this API call to come from a new client. For details, see the `hadMultipleClients` field returned by the [Get head](#/reference/request-queues/queue-head) operation. @@ -228,7 +225,6 @@ delete: be a string between 1 and 32 characters long. This identifier is used to determine whether the queue was accessed by multiple clients. If `clientKey` is not provided, - the system considers this API call to come from a new client. For details, see the `hadMultipleClients` field returned by the [Get head](#/reference/request-queues/queue-head) operation. diff --git a/apify-api/openapi/paths/store/store.yaml b/apify-api/openapi/paths/store/store.yaml index 16b57aae8..839dd5edd 100644 --- a/apify-api/openapi/paths/store/store.yaml +++ b/apify-api/openapi/paths/store/store.yaml @@ -6,11 +6,9 @@ get: Gets the list of public Actors in Apify Store. You can use `search` parameter to search Actors by string in title, name, description, username and readme. - If you need detailed info about a specific Actor, use the [Get Actor](#/reference/actors/actor-object/get-actor) endpoint. - The endpoint supports pagination using the `limit` and `offset` parameters. It will not return more than 1,000 records. operationId: store_get diff --git a/apify-api/openapi/paths/webhook-dispatches/webhook-dispatches.yaml b/apify-api/openapi/paths/webhook-dispatches/webhook-dispatches.yaml index e851c7d3c..b04cd9ed9 100644 --- a/apify-api/openapi/paths/webhook-dispatches/webhook-dispatches.yaml +++ b/apify-api/openapi/paths/webhook-dispatches/webhook-dispatches.yaml @@ -5,13 +5,10 @@ get: description: | Gets the list of webhook dispatches that the user have. - The endpoint supports pagination using the `limit` and `offset` parameters and it will not return more than 1000 records. - By default, the records are sorted by the `createdAt` field in ascending order. To sort the records in descending order, use the `desc=1` - parameter. operationId: webhookDispatches_get parameters: diff --git a/apify-api/openapi/paths/webhooks/webhooks.yaml b/apify-api/openapi/paths/webhooks/webhooks.yaml index ffed50327..1af6827b6 100644 --- a/apify-api/openapi/paths/webhooks/webhooks.yaml +++ b/apify-api/openapi/paths/webhooks/webhooks.yaml @@ -5,13 +5,10 @@ get: description: | Gets the list of webhooks that the user created. - The endpoint supports pagination using the `limit` and `offset` parameters and it will not return more than 1000 records. - By default, the records are sorted by the `createdAt` field in ascending order. To sort the records in descending order, use the `desc=1` - parameter. operationId: webhooks_get parameters: @@ -73,54 +70,35 @@ post: description: | Creates a new webhook with settings provided by the webhook object passed as JSON in the payload. - The response is the created webhook object. - To avoid duplicating a webhook, use the `idempotencyKey` parameter in the request body. - Multiple calls to create a webhook with the same `idempotencyKey` will only create the webhook with the first call and return the existing webhook on subsequent calls. - Idempotency keys must be unique, so use a UUID or another random string with enough entropy. - To assign the new webhook to an Actor or task, the request body must contain `requestUrl`, `eventTypes`, and `condition` properties. - * `requestUrl` is the webhook's target URL, to which data is sent as a POST request with a JSON payload. - - * `eventTypes` is a list of events that will trigger the webhook, e.g. when the Actor run succeeds. - - * `condition` should be an object containing the ID of the Actor or task to which the webhook will be assigned. - - * `payloadTemplate` is a JSON-like string, whose syntax is extended with the use of variables. - - * `headersTemplate` is a JSON-like string, whose syntax is extended with the use of variables. Following values will be re-written to defaults: "host", "Content-Type", "X-Apify-Webhook", "X-Apify-Webhook-Dispatch-Id", "X-Apify-Request-Origin" - - * `description` is an optional string. - - * `shouldInterpolateStrings` is a boolean indicating whether to interpolate variables contained inside strings in the `payloadTemplate` - ``` "isAdHoc" : false, "requestUrl" : "https://example.com", @@ -138,7 +116,6 @@ post: "shouldInterpolateStrings": false, ``` - **Important**: The request must specify the `Content-Type: application/json` HTTP header. operationId: webhooks_post diff --git a/apify-api/openapi/paths/webhooks/webhooks@{webhookId}.yaml b/apify-api/openapi/paths/webhooks/webhooks@{webhookId}.yaml index 2208e7e9e..3a160e24d 100644 --- a/apify-api/openapi/paths/webhooks/webhooks@{webhookId}.yaml +++ b/apify-api/openapi/paths/webhooks/webhooks@{webhookId}.yaml @@ -39,20 +39,15 @@ put: description: | Updates a webhook using values specified by a webhook object passed as JSON in the POST payload. - If the object does not define a specific property, its value will not be updated. - The response is the full webhook object as returned by the - [Get webhook](#/reference/webhooks/webhook-object/get-webhook) endpoint. - The request needs to specify the `Content-Type: application/json` HTTP header! - When providing your API authentication token, we recommend using the request's `Authorization` header, rather than the URL. ([More info](#/introduction/authentication)). diff --git a/apify-docs-theme/src/theme/MDXComponents/A.js b/apify-docs-theme/src/theme/MDXComponents/A.js index 937352e2a..575d08f3a 100644 --- a/apify-docs-theme/src/theme/MDXComponents/A.js +++ b/apify-docs-theme/src/theme/MDXComponents/A.js @@ -7,6 +7,10 @@ import { isDifferentInstance } from '../../utils'; export default function MDXA(props) { const { siteConfig } = useDocusaurusContext(); + if (props.href?.startsWith(siteConfig.url)) { + props.target = '_self'; + } + // absolute links in README, e.g. in the SDK or API Client docs, need to be converted to local `to` links if (props.href?.startsWith(siteConfig.url) && isDifferentInstance(siteConfig.baseUrl)) { const { href, ...rest } = props; diff --git a/apify-docs-theme/src/theme/custom.css b/apify-docs-theme/src/theme/custom.css index 48ceaf652..5ec8a0403 100644 --- a/apify-docs-theme/src/theme/custom.css +++ b/apify-docs-theme/src/theme/custom.css @@ -1021,6 +1021,10 @@ aside li.section-header > .menu__list { background: inherit !important; } +.theme-doc-sidebar-menu > li.section-header > ul > li.theme-doc-sidebar-item-category-level-2 { + margin-bottom: 1rem; +} + .beta-chip { display: inline-block; border: 1px solid #ccc; diff --git a/apify-docs-theme/static/js/custom.js b/apify-docs-theme/static/js/custom.js index 8cc567067..9627b1acb 100644 --- a/apify-docs-theme/static/js/custom.js +++ b/apify-docs-theme/static/js/custom.js @@ -63,13 +63,13 @@ function scrollSidebarItemIntoView() { // handles automatic scrolling of the API reference sidebar (openapi-docs) function scrollOpenApiSidebarItemIntoView() { - const $li = document.querySelector(`ul.theme-doc-sidebar-menu a.menu__link--active[href]`); + const $li = document.querySelectorAll(`ul.theme-doc-sidebar-menu a.menu__link--active[href]`); - if (!$li) { + if ($li.length === 0) { return; } - $li.scrollIntoView({ + $li[$li.length - 1].scrollIntoView({ block: 'nearest', inline: 'center', }); diff --git a/docusaurus.config.js b/docusaurus.config.js index 64d6d77eb..2922ef0d6 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -232,12 +232,15 @@ module.exports = { : clsx({ 'menu__list-item--deprecated': item.schema.deprecated, }, 'schema'); + // const endpoint = item.api.servers[0].url + item.api.path; + const endpoint = item.api.path.replace('/v2', ''); + const { method } = item.api; return { type: 'doc', id: context.basePath === '' ? `${id}` : `${context.basePath}/${id}`, label: sidebarLabel ?? title ?? id, - customProps: { altids }, + customProps: { altids, endpoint, method }, className, }; }, diff --git a/src/theme/DocCard/index.js b/src/theme/DocCard/index.js index d09e42812..5e55596cb 100644 --- a/src/theme/DocCard/index.js +++ b/src/theme/DocCard/index.js @@ -35,17 +35,13 @@ function CardContainer({ href, children }) { ); } -function CardLayout({ href, icon, title, description, className }) { - if (href.startsWith('/api')) { - description = ''; - } - +function CardLayout({ href, icon, title, description }) { return ( {icon} {title} @@ -60,6 +56,23 @@ function CardLayout({ href, icon, title, description, className }) { ); } +function ApiCardLayout({ href, icon, title, className, endpoint }) { + return ( + + + {icon} {title} + + + {endpoint} + + + ); +} + function CardCategory({ item }) { const href = findFirstSidebarItemLink(item); const categoryItemsPlural = useCategoryItemsPlural(); @@ -82,11 +95,12 @@ function CardLink({ item }) { if (item.href.startsWith('/api/v2')) { return ( - ); }
Format