From de709ce6e8be471aad14909a3a5bd0c0a75cd0d8 Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 22 Jun 2026 12:41:11 +0000 Subject: [PATCH 1/3] fix(openapi): add service-worker-registration-not-allowed to ErrorType enum Error: Response OpenAPI validation error {"url":"/v2/key-value-stores/{storeId}/records/sw.js","method":"GET","statusCode":403,"errors":[{"message":"must be equal to one of the allowed values: 3d-secure-auth-failed, access-right-already-exists, ... [truncated]","errorCode":"enum.openapi.validation","path":"/response/error/type"}]} Files: apify-api/openapi/components/schemas/common/ErrorType.yaml:311 Root cause: Fetching a key-value store record with a service-worker header is rejected with HTTP 403 and error type "service-worker-registration-not-allowed", but that value was missing from the ErrorType enum, so the validator failed the response body. Reference: https://github.com/apify/apify-core/tree/6f157da99ca076e5f3f1da67f507e885d6aeafe8/src/packages/errors/src/errors/api.ts#L158 --- apify-api/openapi/components/schemas/common/ErrorType.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/apify-api/openapi/components/schemas/common/ErrorType.yaml b/apify-api/openapi/components/schemas/common/ErrorType.yaml index 90259633db..2b3dc6681d 100644 --- a/apify-api/openapi/components/schemas/common/ErrorType.yaml +++ b/apify-api/openapi/components/schemas/common/ErrorType.yaml @@ -308,6 +308,7 @@ enum: - schema-validation - schema-validation-error - schema-validation-failed + - service-worker-registration-not-allowed - sign-up-method-not-allowed - slack-integration-not-custom - socket-closed From 61a41d11844b5eda32a17c9c1bfb0a33883cdf74 Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 22 Jun 2026 12:41:12 +0000 Subject: [PATCH 2/3] fix(openapi): document status query parameter on last run log endpoints Error: Request OpenAPI validation error {"url":"/v2/actor-tasks/{actorTaskId}/runs/last/log?status=SUCCEEDED","method":"GET","errors":[{"path":"/query/status","message":"Unknown query parameter 'status'"}]} Files: apify-api/openapi/components/objects/logs/log.yaml:103, apify-api/openapi/components/objects/logs/log.yaml:120 Root cause: The runs/last/log endpoints (for both actors and actor tasks) resolve the last run filtered by the status query parameter and then return its log, but the getLastRun and getTaskLastRun operations did not declare the status parameter, so valid requests using it were rejected by the validator. Reference: https://github.com/apify/apify-core/tree/6f157da99ca076e5f3f1da67f507e885d6aeafe8/src/api/src/routes/actors/last_run.ts#L21 --- apify-api/openapi/components/objects/logs/log.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/apify-api/openapi/components/objects/logs/log.yaml b/apify-api/openapi/components/objects/logs/log.yaml index e374123e23..43beafd78f 100644 --- a/apify-api/openapi/components/objects/logs/log.yaml +++ b/apify-api/openapi/components/objects/logs/log.yaml @@ -100,6 +100,7 @@ getLastRun: operationId: act_runs_last_log_get parameters: - $ref: "../../parameters/runAndBuildParameters.yaml#/actorId" + - $ref: "../../parameters/runAndBuildParameters.yaml#/statusLastRun" - $ref: "../../parameters/logParameters.yaml#/stream" - $ref: "../../parameters/logParameters.yaml#/download" - $ref: "../../parameters/logParameters.yaml#/raw" @@ -116,6 +117,7 @@ getTaskLastRun: operationId: actorTask_last_log_get parameters: - $ref: "../../parameters/runAndBuildParameters.yaml#/actorTaskId" + - $ref: "../../parameters/runAndBuildParameters.yaml#/statusLastRun" - $ref: "../../parameters/logParameters.yaml#/stream" - $ref: "../../parameters/logParameters.yaml#/download" - $ref: "../../parameters/logParameters.yaml#/raw" From f83c75382091f0d085a075620fa9891f74dea058 Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 22 Jun 2026 12:41:12 +0000 Subject: [PATCH 3/3] fix(openapi): use RequestWithoutId for request queue update request body Error: Request OpenAPI validation error {"url":"/v2/actor-runs/{runId}/request-queue/requests/{requestId}?token=[REDACTED]","method":"PUT","errors":[{"message":"must have required property 'id'","errorCode":"required.openapi.validation","path":"/body/id"}]} Files: apify-api/openapi/components/objects/request-queues/request-queue-request.yaml:109 Root cause: The update-request handler deletes id from the request body ("it's computed from uniqueKey always") and then validates the body against RequestSchema, which requires only uniqueKey and url; requestId is read from the URL path, not the body. The PUT body therefore must not require id. The shared Request schema requires id and is also used by the single-request and list responses (where id is always present), so instead of relaxing it the PUT body now reuses the existing RequestWithoutId schema, exactly as the add-request POST already does, leaving the response contracts unchanged. Reference: https://github.com/apify/apify-core/tree/6f157da99ca076e5f3f1da67f507e885d6aeafe8/src/api/src/routes/request_queues/request.ts#L189 --- .../objects/request-queues/request-queue-request.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apify-api/openapi/components/objects/request-queues/request-queue-request.yaml b/apify-api/openapi/components/objects/request-queues/request-queue-request.yaml index 0c3b1b283b..dd64ac7a42 100644 --- a/apify-api/openapi/components/objects/request-queues/request-queue-request.yaml +++ b/apify-api/openapi/components/objects/request-queues/request-queue-request.yaml @@ -106,7 +106,7 @@ sharedPut: &sharedPut content: application/json: schema: - $ref: ../../schemas/request-queues/Request.yaml + $ref: ../../schemas/request-queues/RequestWithoutId.yaml required: true responses: "200":