diff options
Diffstat (limited to 'spec/fixtures/api/schemas/public_api/v4')
9 files changed, 374 insertions, 109 deletions
diff --git a/spec/fixtures/api/schemas/public_api/v4/basic_environment.json b/spec/fixtures/api/schemas/public_api/v4/basic_environment.json new file mode 100644 index 00000000000..f22f73f573b --- /dev/null +++ b/spec/fixtures/api/schemas/public_api/v4/basic_environment.json @@ -0,0 +1,34 @@ +{ + "type": "object", + "required": [ + "id", + "name", + "slug", + "external_url", + "created_at", + "updated_at" + ], + "properties": { + "id": { + "type": "integer" + }, + "name": { + "type": "string" + }, + "slug": { + "type": "string" + }, + "external_url": { + "$ref": "../../types/nullable_string.json" + }, + "created_at": { + "type": "string", + "format": "date-time" + }, + "updated_at": { + "type": "string", + "format": "date-time" + } + }, + "additionalProperties": false +}
\ No newline at end of file diff --git a/spec/fixtures/api/schemas/public_api/v4/basic_environments.json b/spec/fixtures/api/schemas/public_api/v4/basic_environments.json new file mode 100644 index 00000000000..6620e423c96 --- /dev/null +++ b/spec/fixtures/api/schemas/public_api/v4/basic_environments.json @@ -0,0 +1,6 @@ +{ + "type": "array", + "items": { + "$ref": "./basic_environment.json" + } +}
\ No newline at end of file diff --git a/spec/fixtures/api/schemas/public_api/v4/branch.json b/spec/fixtures/api/schemas/public_api/v4/branch.json index 0073a6d89fc..ed65f3c2e5c 100644 --- a/spec/fixtures/api/schemas/public_api/v4/branch.json +++ b/spec/fixtures/api/schemas/public_api/v4/branch.json @@ -1,6 +1,6 @@ { "type": "object", - "required" : [ + "required": [ "name", "commit", "merged", @@ -10,16 +10,35 @@ "developers_can_merge", "web_url" ], - "properties" : { - "name": { "type": "string" }, - "commit": { "$ref": "commit/basic.json" }, - "merged": { "type": "boolean" }, - "protected": { "type": "boolean" }, - "default": { "type": "boolean" }, - "developers_can_push": { "type": "boolean" }, - "developers_can_merge": { "type": "boolean" }, - "can_push": { "type": "boolean" }, - "web_url": { "type": "uri" } + "properties": { + "name": { + "type": "string" + }, + "commit": { + "$ref": "commit/basic.json" + }, + "merged": { + "type": "boolean" + }, + "protected": { + "type": "boolean" + }, + "default": { + "type": "boolean" + }, + "developers_can_push": { + "type": "boolean" + }, + "developers_can_merge": { + "type": "boolean" + }, + "can_push": { + "type": "boolean" + }, + "web_url": { + "type": "string", + "format": "uri" + } }, "additionalProperties": false -} +}
\ No newline at end of file diff --git a/spec/fixtures/api/schemas/public_api/v4/deploy_token.json b/spec/fixtures/api/schemas/public_api/v4/deploy_token.json index 102ab95a4ee..664740c2a3c 100644 --- a/spec/fixtures/api/schemas/public_api/v4/deploy_token.json +++ b/spec/fixtures/api/schemas/public_api/v4/deploy_token.json @@ -19,7 +19,9 @@ "username": { "type": "string" }, - "expires_at": { "type": "string" }, + "expires_at": { + "type": "string" + }, "scopes": { "type": "array", "items": { diff --git a/spec/fixtures/api/schemas/public_api/v4/environments.json b/spec/fixtures/api/schemas/public_api/v4/environments.json index f739c06f604..1697da0f231 100644 --- a/spec/fixtures/api/schemas/public_api/v4/environments.json +++ b/spec/fixtures/api/schemas/public_api/v4/environments.json @@ -1,9 +1,6 @@ { "type": "array", "items": { - "type": "object", - "properties": { - "$ref": "./environment.json" - } + "$ref": "./environment.json" } -} +}
\ No newline at end of file diff --git a/spec/fixtures/api/schemas/public_api/v4/feature_flag_scopes.json b/spec/fixtures/api/schemas/public_api/v4/feature_flag_scopes.json index b1a7021db8b..1df46780a03 100644 --- a/spec/fixtures/api/schemas/public_api/v4/feature_flag_scopes.json +++ b/spec/fixtures/api/schemas/public_api/v4/feature_flag_scopes.json @@ -1,9 +1,6 @@ { "type": "array", "items": { - "type": "object", - "properties": { - "$ref": "./feature_flag_scope.json" - } + "$ref": "./feature_flag_scope.json" } -} +}
\ No newline at end of file diff --git a/spec/fixtures/api/schemas/public_api/v4/feature_flags.json b/spec/fixtures/api/schemas/public_api/v4/feature_flags.json index c19df0443d9..f381adc3c8b 100644 --- a/spec/fixtures/api/schemas/public_api/v4/feature_flags.json +++ b/spec/fixtures/api/schemas/public_api/v4/feature_flags.json @@ -1,9 +1,6 @@ { "type": "array", "items": { - "type": "object", - "properties": { - "$ref": "./feature_flag.json" - } + "$ref": "./feature_flag.json" } -} +}
\ No newline at end of file diff --git a/spec/fixtures/api/schemas/public_api/v4/integration.json b/spec/fixtures/api/schemas/public_api/v4/integration.json index b6f13d1cfe7..d1538db7de4 100644 --- a/spec/fixtures/api/schemas/public_api/v4/integration.json +++ b/spec/fixtures/api/schemas/public_api/v4/integration.json @@ -1,24 +1,62 @@ { "type": "object", "properties": { - "id": { "type": "integer" }, - "title": { "type": "string" }, - "slug": { "type": "string" }, - "created_at": { "type": "date-time" }, - "updated_at": { "type": "date-time" }, - "active": { "type": "boolean" }, - "commit_events": { "type": "boolean" }, - "push_events": { "type": "boolean" }, - "issues_events": { "type": "boolean" }, - "confidential_issues_events": { "type": "boolean" }, - "merge_requests_events": { "type": "boolean" }, - "tag_push_events": { "type": "boolean" }, - "note_events": { "type": "boolean" }, - "confidential_note_events": { "type": "boolean" }, - "pipeline_events": { "type": "boolean" }, - "wiki_page_events": { "type": "boolean" }, - "job_events": { "type": "boolean" }, - "comment_on_event_enabled": { "type": "boolean" } + "id": { + "type": "integer" + }, + "title": { + "type": "string" + }, + "slug": { + "type": "string" + }, + "created_at": { + "type": "string", + "format": "date-time" + }, + "updated_at": { + "type": "string", + "format": "date-time" + }, + "active": { + "type": "boolean" + }, + "commit_events": { + "type": "boolean" + }, + "push_events": { + "type": "boolean" + }, + "issues_events": { + "type": "boolean" + }, + "confidential_issues_events": { + "type": "boolean" + }, + "merge_requests_events": { + "type": "boolean" + }, + "tag_push_events": { + "type": "boolean" + }, + "note_events": { + "type": "boolean" + }, + "confidential_note_events": { + "type": "boolean" + }, + "pipeline_events": { + "type": "boolean" + }, + "wiki_page_events": { + "type": "boolean" + }, + "job_events": { + "type": "boolean" + }, + "comment_on_event_enabled": { + "type": "boolean" + } }, "additionalProperties": false -} +}
\ No newline at end of file diff --git a/spec/fixtures/api/schemas/public_api/v4/issue.json b/spec/fixtures/api/schemas/public_api/v4/issue.json index 90b368b5226..0e8de3cd3d7 100644 --- a/spec/fixtures/api/schemas/public_api/v4/issue.json +++ b/spec/fixtures/api/schemas/public_api/v4/issue.json @@ -1,16 +1,47 @@ { "type": "object", - "properties" : { - "id": { "type": "integer" }, - "iid": { "type": "integer" }, - "project_id": { "type": "integer" }, - "title": { "type": "string" }, - "description": { "type": ["string", "null"] }, - "state": { "type": "string" }, - "discussion_locked": { "type": ["boolean", "null"] }, - "closed_at": { "type": ["string", "null"] }, - "created_at": { "type": "string", "format": "date-time" }, - "updated_at": { "type": "string", "format": "date-time" }, + "properties": { + "id": { + "type": "integer" + }, + "iid": { + "type": "integer" + }, + "project_id": { + "type": "integer" + }, + "title": { + "type": "string" + }, + "description": { + "type": [ + "string", + "null" + ] + }, + "state": { + "type": "string" + }, + "discussion_locked": { + "type": [ + "boolean", + "null" + ] + }, + "closed_at": { + "type": [ + "string", + "null" + ] + }, + "created_at": { + "type": "string", + "format": "date-time" + }, + "updated_at": { + "type": "string", + "format": "date-time" + }, "labels": { "type": "array", "items": { @@ -18,58 +49,144 @@ } }, "milestone": { - "type": ["object", "null"], + "type": [ + "object", + "null" + ], "properties": { - "id": { "type": "integer" }, - "iid": { "type": "integer" }, - "project_id": { "type": ["integer", "null"] }, - "group_id": { "type": ["integer", "null"] }, - "title": { "type": "string" }, - "description": { "type": ["string", "null"] }, - "state": { "type": "string" }, - "created_at": { "type": "string", "format": "date-time" }, - "updated_at": { "type": "string", "format": "date-time" }, - "due_date": { "type": "string" , "format": "date-time" }, - "start_date": { "type": "string", "format": "date-time" } + "id": { + "type": "integer" + }, + "iid": { + "type": "integer" + }, + "project_id": { + "type": [ + "integer", + "null" + ] + }, + "group_id": { + "type": [ + "integer", + "null" + ] + }, + "title": { + "type": "string" + }, + "description": { + "type": [ + "string", + "null" + ] + }, + "state": { + "type": "string" + }, + "created_at": { + "type": "string", + "format": "date-time" + }, + "updated_at": { + "type": "string", + "format": "date-time" + }, + "due_date": { + "type": "string", + "format": "date-time" + }, + "start_date": { + "type": "string", + "format": "date-time" + } }, "additionalProperties": false }, "assignees": { "type": "array", "items": { - "type": ["object", "null"], + "type": [ + "object", + "null" + ], "properties": { - "name": { "type": "string" }, - "username": { "type": "string" }, - "id": { "type": "integer" }, - "state": { "type": "string" }, - "avatar_url": { "type": "uri" }, - "web_url": { "type": "uri" } + "name": { + "type": "string" + }, + "username": { + "type": "string" + }, + "id": { + "type": "integer" + }, + "state": { + "type": "string" + }, + "avatar_url": { + "type": "string", + "format": "uri" + }, + "web_url": { + "type": "string", + "format": "uri" + } }, "additionalProperties": false } }, "assignee": { - "type": ["object", "null"], + "type": [ + "object", + "null" + ], "properties": { - "name": { "type": "string" }, - "username": { "type": "string" }, - "id": { "type": "integer" }, - "state": { "type": "string" }, - "avatar_url": { "type": "uri" }, - "web_url": { "type": "uri" } + "name": { + "type": "string" + }, + "username": { + "type": "string" + }, + "id": { + "type": "integer" + }, + "state": { + "type": "string" + }, + "avatar_url": { + "type": "string", + "format": "uri" + }, + "web_url": { + "type": "string", + "format": "uri" + } }, "additionalProperties": false }, "author": { "type": "object", "properties": { - "name": { "type": "string" }, - "username": { "type": "string" }, - "id": { "type": "integer" }, - "state": { "type": "string" }, - "avatar_url": { "type": "uri" }, - "web_url": { "type": "uri" } + "name": { + "type": "string" + }, + "username": { + "type": "string" + }, + "id": { + "type": "integer" + }, + "state": { + "type": "string" + }, + "avatar_url": { + "type": "string", + "format": "uri" + }, + "web_url": { + "type": "string", + "format": "uri" + } }, "required": [ "id", @@ -80,30 +197,88 @@ "web_url" ] }, - "user_notes_count": { "type": "integer" }, - "upvotes": { "type": "integer" }, - "downvotes": { "type": "integer" }, - "due_date": { "type": ["string", "null"] }, - "confidential": { "type": "boolean" }, - "web_url": { "type": "uri" }, - "severity": { "type": "string", "enum": ["UNKNOWN", "LOW", "MEDIUM", "HIGH", "CRITICAL"] }, + "user_notes_count": { + "type": "integer" + }, + "upvotes": { + "type": "integer" + }, + "downvotes": { + "type": "integer" + }, + "due_date": { + "type": [ + "string", + "null" + ] + }, + "confidential": { + "type": "boolean" + }, + "web_url": { + "type": "string", + "format": "uri" + }, + "severity": { + "type": "string", + "enum": [ + "UNKNOWN", + "LOW", + "MEDIUM", + "HIGH", + "CRITICAL" + ] + }, "time_stats": { - "time_estimate": { "type": "integer" }, - "total_time_spent": { "type": "integer" }, - "human_time_estimate": { "type": ["string", "null"] }, - "human_total_time_spent": { "type": ["string", "null"] } + "time_estimate": { + "type": "integer" + }, + "total_time_spent": { + "type": "integer" + }, + "human_time_estimate": { + "type": [ + "string", + "null" + ] + }, + "human_total_time_spent": { + "type": [ + "string", + "null" + ] + } }, "references": { - "short": {"type": "string"}, - "relative": {"type": "string"}, - "full": {"type": "string"} + "short": { + "type": "string" + }, + "relative": { + "type": "string" + }, + "full": { + "type": "string" + } } }, "required": [ - "id", "iid", "project_id", "title", "description", - "state", "created_at", "updated_at", "labels", - "milestone", "assignees", "author", "user_notes_count", - "upvotes", "downvotes", "due_date", "confidential", + "id", + "iid", + "project_id", + "title", + "description", + "state", + "created_at", + "updated_at", + "labels", + "milestone", + "assignees", + "author", + "user_notes_count", + "upvotes", + "downvotes", + "due_date", + "confidential", "web_url" ] -} +}
\ No newline at end of file |