-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: updates to
deployment
and deployment_status
events, new `de…
…ployment` property for `check_run` event (#601) * feat: new `deployment` property on `check_run` event * feat: extract `deployment` into common schema * feat: `deployment.created#workflow` can also be a `workflow` common schema * fix: `environment_url` can be an empty string * feat: new `check_run` property on `deployment_status#created` event * feat: new `workflow_run` property on `deployment_status` event * fix: `workflow_run` property can also be a `workflow_run` object on the `deployment#created` event * build: generate types
- Loading branch information
Showing
9 changed files
with
299 additions
and
148 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
67 changes: 67 additions & 0 deletions
67
payload-schemas/api.github.com/common/deployment-workflow-run.schema.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-07/schema", | ||
"$id": "common/deployment-workflow-run.schema.json", | ||
"type": "object", | ||
"required": [ | ||
"id", | ||
"name", | ||
"node_id", | ||
"head_branch", | ||
"head_sha", | ||
"run_number", | ||
"event", | ||
"status", | ||
"conclusion", | ||
"workflow_id", | ||
"check_suite_id", | ||
"check_suite_node_id", | ||
"url", | ||
"html_url", | ||
"pull_requests", | ||
"created_at", | ||
"updated_at", | ||
"run_attempt", | ||
"run_started_at" | ||
], | ||
"properties": { | ||
"id": { "type": "integer" }, | ||
"name": { "type": "string" }, | ||
"node_id": { "type": "string" }, | ||
"head_branch": { "type": "string" }, | ||
"head_sha": { "type": "string" }, | ||
"run_number": { "type": "integer" }, | ||
"event": { "type": "string" }, | ||
"status": { | ||
"type": "string", | ||
"enum": ["requested", "in_progress", "completed", "queued"] | ||
}, | ||
"conclusion": { | ||
"type": ["string", "null"], | ||
"enum": [ | ||
"success", | ||
"failure", | ||
"neutral", | ||
"cancelled", | ||
"timed_out", | ||
"action_required", | ||
"stale", | ||
null | ||
] | ||
}, | ||
"workflow_id": { "type": "integer" }, | ||
"check_suite_id": { "type": "integer" }, | ||
"check_suite_node_id": { "type": "string" }, | ||
"url": { "type": "string", "format": "uri" }, | ||
"html_url": { "type": "string", "format": "uri" }, | ||
"pull_requests": { | ||
"type": "array", | ||
"items": { "$ref": "check-run-pull-request.schema.json" } | ||
}, | ||
"created_at": { "type": "string", "format": "date-time" }, | ||
"updated_at": { "type": "string", "format": "date-time" }, | ||
"run_attempt": { "type": "integer" }, | ||
"run_started_at": { "type": "string", "format": "date-time" } | ||
}, | ||
"additionalProperties": false, | ||
"title": "Deployment Workflow Run" | ||
} |
51 changes: 51 additions & 0 deletions
51
payload-schemas/api.github.com/common/deployment.schema.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-07/schema", | ||
"$id": "common/deployment.schema.json", | ||
"required": [ | ||
"url", | ||
"id", | ||
"node_id", | ||
"sha", | ||
"ref", | ||
"task", | ||
"payload", | ||
"original_environment", | ||
"environment", | ||
"description", | ||
"creator", | ||
"created_at", | ||
"updated_at", | ||
"statuses_url", | ||
"repository_url" | ||
], | ||
"type": "object", | ||
"properties": { | ||
"url": { "type": "string", "format": "uri" }, | ||
"id": { "type": "integer" }, | ||
"node_id": { "type": "string" }, | ||
"sha": { "type": "string" }, | ||
"ref": { "type": "string" }, | ||
"task": { "type": "string" }, | ||
"payload": { | ||
"type": "object", | ||
"required": [], | ||
"additionalProperties": true | ||
}, | ||
"original_environment": { "type": "string" }, | ||
"environment": { "type": "string" }, | ||
"transient_environment": { "type": "boolean" }, | ||
"production_environment": { "type": "boolean" }, | ||
"description": { "type": ["string", "null"] }, | ||
"creator": { "$ref": "user.schema.json" }, | ||
"created_at": { "type": "string" }, | ||
"updated_at": { "type": "string" }, | ||
"statuses_url": { "type": "string", "format": "uri" }, | ||
"repository_url": { "type": "string", "format": "uri" }, | ||
"performed_via_github_app": { | ||
"oneOf": [{ "$ref": "app.schema.json" }, { "type": "null" }] | ||
} | ||
}, | ||
"additionalProperties": false, | ||
"description": "The [deployment](https://docs.github.com/en/rest/reference/deployments#list-deployments).", | ||
"title": "Deployment" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.