incubator-devlake
incubator-devlake copied to clipboard
[Bug][Module Name] WebhookDeployTaskRequest.StartedDate is not optional
Search before asking
- [X] I had searched in the issues and found no similar issues.
What happened
{"code":0,"success":false,"message":"input json error (400)
Wraps: (2) Key: 'WebhookDeployTaskRequest.StartedDate' Error:Field validation for 'StartedDate' failed on the 'required' tag
Error types: (1) *hintdetail.withDetail (2) validator.ValidationErrors","causes":null,"data":null}
What do you expect to happen
Update curl command in Webhook deployment example command, to state the field is required, not optional.
How to reproduce
curl https://devlake.localhost.com/api/rest/plugins/webhook/connections/2/deployments -X 'POST' \
-H 'Authorization: Bearer XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX' \
-d '{ "deploymentCommits":[ { "commit_sha":"the sha of deployment commit1", "repo_url":"the repo URL of the deployment commit" } ] }'
Note start_time
is not indicated in JSON query.
Anything else
No response
Version
1.0.0-beta5
Are you willing to submit PR?
- [ ] Yes I am willing to submit a PR!
Code of Conduct
- [X] I agree to follow this project's Code of Conduct