Skip to content

Commit e43a091

Browse files
committed
Document 404 related errors on acts endpoints
1 parent a177987 commit e43a091

22 files changed

Lines changed: 369 additions & 47 deletions
Lines changed: 85 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
ActorNotFoundError:
2+
allOf:
3+
- type: object
4+
properties:
5+
error:
6+
type: object
7+
properties:
8+
type:
9+
type: string
10+
enum: [actor-not-found]
11+
message:
12+
type: string
13+
enum: [Actor was not found]
14+
15+
ActorBuildNotFoundError:
16+
allOf:
17+
- type: object
18+
properties:
19+
error:
20+
type: object
21+
properties:
22+
type:
23+
type: string
24+
enum: [record-not-found]
25+
message:
26+
type: string
27+
enum: [Actor build was not found]
28+
29+
ActorRunNotFoundError:
30+
allOf:
31+
- type: object
32+
properties:
33+
error:
34+
type: object
35+
properties:
36+
type:
37+
type: string
38+
enum: [record-not-found]
39+
message:
40+
type: string
41+
enum: [Actor run was not found]
42+
43+
ActorRunTimeoutExceededError:
44+
allOf:
45+
- type: object
46+
properties:
47+
error:
48+
type: object
49+
properties:
50+
type:
51+
type: string
52+
enum: [run-timeout-exceeded]
53+
message:
54+
type: string
55+
pattern: '^Actor run exceeded the timeout of \d+ seconds for this API endpoint'
56+
example: Actor run exceeded the timeout of 300 seconds for this API endpoint
57+
58+
ActorRunFailedError:
59+
allOf:
60+
- type: object
61+
properties:
62+
error:
63+
type: object
64+
properties:
65+
type:
66+
type: string
67+
enum: [run-failed]
68+
message:
69+
type: string
70+
pattern: '^Actor run did not succeed \(run ID: .+, status: .+\)'
71+
example: "Actor run did not succeed (run ID: 55uatRrZib4xbZs, status: FAILED)"
72+
73+
ActorVersionNotFoundError:
74+
allOf:
75+
- type: object
76+
properties:
77+
error:
78+
type: object
79+
properties:
80+
type:
81+
type: string
82+
enum: [record-not-found]
83+
message:
84+
type: string
85+
enum: [Actor version was not found]
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
UnknownBuildTagError:
2+
allOf:
3+
- type: object
4+
properties:
5+
error:
6+
type: object
7+
properties:
8+
type:
9+
type: string
10+
enum: [unknown-build-tag]
11+
message:
12+
type: string
13+
enum: [Build with tag \"latest\" was not found. Has the Actor been built already?]
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
EnvironmentVariableNotFoundError:
2+
allOf:
3+
- type: object
4+
properties:
5+
error:
6+
type: object
7+
properties:
8+
type:
9+
type: string
10+
enum: [record-not-found]
11+
message:
12+
type: string
13+
enum: [Environment variable was not found]

apify-api/openapi/paths/actors/acts@{actorId}.yaml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,13 @@ get:
8383
finishedAt: "2019-06-10T11:15:49.286Z"
8484
"400":
8585
$ref: ../../components/responses/BadRequest.yaml
86+
"404":
87+
description: Not found - the requested resource was not found.
88+
content:
89+
application/json:
90+
schema:
91+
oneOf:
92+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorNotFoundError"
8693
deprecated: false
8794
x-legacy-doc-urls:
8895
- https://docs.apify.com/api/v2#/reference/actors/actor-object/get-actor
@@ -264,6 +271,13 @@ put:
264271
finishedAt: "2019-06-10T11:15:49.286Z"
265272
"400":
266273
$ref: ../../components/responses/BadRequest.yaml
274+
"404":
275+
description: Not found - the requested resource was not found.
276+
content:
277+
application/json:
278+
schema:
279+
oneOf:
280+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorNotFoundError"
267281
deprecated: false
268282
x-legacy-doc-urls:
269283
- https://docs.apify.com/api/v2#/reference/actors/actor-object/update-actor
@@ -302,6 +316,13 @@ delete:
302316
example: {}
303317
"400":
304318
$ref: ../../components/responses/BadRequest.yaml
319+
"404":
320+
description: Not found - the requested resource was not found.
321+
content:
322+
application/json:
323+
schema:
324+
oneOf:
325+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorNotFoundError"
305326
deprecated: false
306327
x-legacy-doc-urls:
307328
- https://docs.apify.com/api/v2#/reference/actors/actor-object/delete-actor

apify-api/openapi/paths/actors/acts@{actorId}@builds.yaml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,13 @@ get:
6363
$ref: ../../components/schemas/actor-builds/ListOfBuildsResponse.yaml
6464
"400":
6565
$ref: ../../components/responses/BadRequest.yaml
66+
"404":
67+
description: Not found - the requested resource was not found.
68+
content:
69+
application/json:
70+
schema:
71+
oneOf:
72+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorNotFoundError"
6673
deprecated: false
6774
x-legacy-doc-urls:
6875
- https://docs.apify.com/api/v2#/reference/actors/build-collection/get-list-of-builds
@@ -190,6 +197,13 @@ post:
190197
buildNumber: 0.1.1
191198
"400":
192199
$ref: ../../components/responses/BadRequest.yaml
200+
"404":
201+
description: Not found - the requested resource was not found.
202+
content:
203+
application/json:
204+
schema:
205+
oneOf:
206+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorNotFoundError"
193207
deprecated: false
194208
x-legacy-doc-urls:
195209
- https://docs.apify.com/api/v2#/reference/actors/build-collection/build-actor

apify-api/openapi/paths/actors/acts@{actorId}@builds@default.yaml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,21 @@ get:
7474
buildNumber: 0.1.1
7575
"400":
7676
$ref: ../../components/responses/BadRequest.yaml
77+
"404":
78+
description: Not found - the requested resource was not found.
79+
content:
80+
application/json:
81+
schema:
82+
oneOf:
83+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorNotFoundError"
84+
"403":
85+
# It should be 404, but is 403 for backwards compatibility. https://github.com/apify/apify-core/pull/17414
86+
description: Not found - the requested resource was not found.
87+
content:
88+
application/json:
89+
schema:
90+
oneOf:
91+
- $ref: "../../components/schemas/common/errors/BuildErrors.yaml#/UnknownBuildTagError"
7792
x-js-parent: ActorClient
7893
x-js-name: defaultBuild
7994
x-js-doc-url: https://docs.apify.com/api/client/js/reference/class/ActorClient#defaultBuild

apify-api/openapi/paths/actors/acts@{actorId}@builds@{buildId}.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,14 @@ get:
8181
buildNumber: 0.1.1
8282
"400":
8383
$ref: ../../components/responses/BadRequest.yaml
84+
"404":
85+
description: Not found - the requested resource was not found.
86+
content:
87+
application/json:
88+
schema:
89+
oneOf:
90+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorNotFoundError"
91+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorBuildNotFoundError"
8492
deprecated: true
8593
x-deprecated-description: "API endpoints related to build of the Actor were moved under new namespace [`actor-builds`](#/reference/actor-builds). Gets an object that contains all the details about a specific build of an Actor."
8694
x-legacy-doc-urls:

apify-api/openapi/paths/actors/acts@{actorId}@builds@{buildId}@abort.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,14 @@ post:
6363
buildNumber: 0.1.1
6464
"400":
6565
$ref: ../../components/responses/BadRequest.yaml
66+
"404":
67+
description: Not found - the requested resource was not found.
68+
content:
69+
application/json:
70+
schema:
71+
oneOf:
72+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorNotFoundError"
73+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorBuildNotFoundError"
6674
deprecated: true
6775
x-legacy-doc-urls:
6876
- https://docs.apify.com/api/v2#/reference/actors/abort-build/abort-build

apify-api/openapi/paths/actors/acts@{actorId}@builds@{buildId}@openapi.json.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,3 +49,11 @@ get:
4949
description: A standard OpenAPI 3.x JSON document.
5050
"400":
5151
$ref: ../../components/responses/BadRequest.yaml
52+
"404":
53+
description: Not found - the requested resource was not found.
54+
content:
55+
application/json:
56+
schema:
57+
oneOf:
58+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorNotFoundError"
59+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorBuildNotFoundError"

apify-api/openapi/paths/actors/acts@{actorId}@run-sync-get-dataset-items.yaml

Lines changed: 22 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -366,24 +366,23 @@ post:
366366
content:
367367
application/json:
368368
schema:
369-
$ref: ../../components/schemas/common/ErrorResponse.yaml
370-
example:
371-
error:
372-
type: run-failed
373-
message: >-
374-
Actor run did not succeed (run ID: 55uatRrZib4xbZs, status:
375-
FAILED)
369+
oneOf:
370+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorRunFailedError"
371+
"404":
372+
description: Not found - the requested resource was not found.
373+
content:
374+
application/json:
375+
schema:
376+
oneOf:
377+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorNotFoundError"
376378
"408":
377379
description: ""
378380
headers: {}
379381
content:
380382
application/json:
381383
schema:
382-
$ref: ../../components/schemas/common/ErrorResponse.yaml
383-
example:
384-
error:
385-
type: run-timeout-exceeded
386-
message: Actor run exceeded timeout of 300 seconds for this API endpoint
384+
oneOf:
385+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorRunTimeoutExceededError"
387386
deprecated: false
388387
x-legacy-doc-urls:
389388
- https://docs.apify.com/api/v2#/reference/actors/run-actor-synchronously-and-get-dataset-items/run-actor-synchronously-with-input-and-get-dataset-items
@@ -732,24 +731,23 @@ get:
732731
content:
733732
application/json:
734733
schema:
735-
$ref: ../../components/schemas/common/ErrorResponse.yaml
736-
example:
737-
error:
738-
type: run-failed
739-
message: >-
740-
Actor run did not succeed (run ID: 55uatRrZib4xbZs, status:
741-
FAILED)
734+
oneOf:
735+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorRunFailedError"
736+
"404":
737+
description: Not found - the requested resource was not found.
738+
content:
739+
application/json:
740+
schema:
741+
oneOf:
742+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorNotFoundError"
742743
"408":
743744
description: ""
744745
headers: {}
745746
content:
746747
application/json:
747748
schema:
748-
$ref: ../../components/schemas/common/ErrorResponse.yaml
749-
example:
750-
error:
751-
type: run-timeout-exceeded
752-
message: Actor run exceeded timeout of 60 seconds for this API endpoint
749+
oneOf:
750+
- $ref: "../../components/schemas/common/errors/ActorErrors.yaml#/ActorRunTimeoutExceededError"
753751
deprecated: false
754752
x-legacy-doc-urls:
755753
- https://docs.apify.com/api/v2#/reference/actors/run-actor-synchronously-and-get-dataset-items/run-actor-synchronously-without-input-and-get-dataset-items

0 commit comments

Comments
 (0)