You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The payload field of deployments in the API schema is typed as {'oneOf': [{'type': 'object', 'additionalProperties': True}, {'type': 'string'}]} to allow a (JSON) object directly or encoded as string.
However, the webhook that include deployments (deployment-created and deployment-status-created) are only typed as {'oneOf': [{'type': 'object'}, {'type': 'string'}]}. The missing additionalProperties means that only empty objects are allowed.
However, the webhook delivered by GitHub return the payload the deployments was created with (with can be objects with additional keys).
inspect the webhook response. It does return the same value. The payload includes more fields (downtime) than documented, but additionalProperties is the default false.
The text was updated successfully, but these errors were encountered:
Schema Inaccuracy
The
payload
field of deployments in the API schema is typed as{'oneOf': [{'type': 'object', 'additionalProperties': True}, {'type': 'string'}]}
to allow a (JSON) object directly or encoded as string.However, the webhook that include deployments (deployment-created and deployment-status-created) are only typed as
{'oneOf': [{'type': 'object'}, {'type': 'string'}]}
. The missingadditionalProperties
means that only empty objects are allowed.However, the webhook delivered by GitHub return the payload the deployments was created with (with can be objects with additional keys).
Expected
The webhook schemas:
components.schemas.webhook-deployment-created.properties.deployment.properties.payload
components.schemas.webhook-deployment-status-created.properties.deployment.properties.payload
should declare
"additionalProperties": true
as the api definitions already do:paths./repos/{owner}/{repo}/deployments.post.requestBody.content.application/json.schema.properties.payload
components.schemas.deployment.properties.payload
Reproduction Steps
Create a deployment with object payload, e.g.
inspect the webhook response. It does return the same value. The payload includes more fields (
downtime
) than documented, butadditionalProperties
is the default false.The text was updated successfully, but these errors were encountered: