Open danieltalmor369 opened 1 year ago
- uses: convictional/trigger-workflow-and-wait@v1.6.5
with:
owner: BAC
repo: xyz
github_token: ${{ secrets.TOKEN }}
github_user: user10
workflow_file_name: metrics.yml
ref: master
wait_interval: 2
client_payload: '{"repository": "ABC", "application": "12", "deploy_tag": "ABC", "previous_deploy_tag": "ABC", "deploy_status": "true", "build_duration": "12.5"}'
trigger_workflow: true
wait_workflow: true
Thanks @loki1978 I still getting the same error
curl: (22) The requested URL returned error: 422
api failed:
path: workflows/qa_deployment.yml/dispatches
response: {
"message": "Invalid request.\n\nFor 'additionalProperties', {\"repository\"=>\"klinse\", \"ref\"=>\"feature/johnnyT/Aicore-20/combine-deploy-workflows\", \"environment\"=>\"qa-1\", \"env_start\"=>\"disabled\", \"service_to_deploy\"=>\"data_ingestor\"} is not a string.",
"documentation_url": "https://docs.github.com/rest/reference/actions#create-a-workflow-dispatch-event"
}
I try to wait for external workflow (which locate in other repository. Do I need to set something on the triggered workflow?
Same for me.
using client_payload: '{"data":"I am a custom client_payload"}'
results in
Triggering workflow: workflows/testing-workflow.yml/dispatches {"ref":"master","inputs":{"data":"I am a custom client_payload"}} curl: (22) The requested URL returned error: 422 api failed: path: workflows/testing-workflow.yml/dispatches response: { "message": "Unexpected inputs provided: [\"data\"]", "documentation_url": "https://docs.github.com/rest/reference/actions#create-a-workflow-dispatch-event" }
Thanks @loki1978 I still getting the same error
curl: (22) The requested URL returned error: 422 api failed: path: workflows/qa_deployment.yml/dispatches response: { "message": "Invalid request.\n\nFor 'additionalProperties', {\"repository\"=>\"klinse\", \"ref\"=>\"feature/johnnyT/Aicore-20/combine-deploy-workflows\", \"environment\"=>\"qa-1\", \"env_start\"=>\"disabled\", \"service_to_deploy\"=>\"data_ingestor\"} is not a string.", "documentation_url": "https://docs.github.com/rest/reference/actions#create-a-workflow-dispatch-event" }
I try to wait for external workflow (which locate in other repository. Do I need to set something on the triggered workflow?
Triggered workflow need workflow dispatch and inputs ( optional )
workflow_dispatch:
inputs:
Thanks @loki1978 I still getting the same error
curl: (22) The requested URL returned error: 422 api failed: path: workflows/qa_deployment.yml/dispatches response: { "message": "Invalid request.\n\nFor 'additionalProperties', {\"repository\"=>\"klinse\", \"ref\"=>\"feature/johnnyT/Aicore-20/combine-deploy-workflows\", \"environment\"=>\"qa-1\", \"env_start\"=>\"disabled\", \"service_to_deploy\"=>\"data_ingestor\"} is not a string.", "documentation_url": "https://docs.github.com/rest/reference/actions#create-a-workflow-dispatch-event" }
I try to wait for external workflow (which locate in other repository. Do I need to set something on the triggered workflow?
Triggered workflow need workflow dispatch and inputs ( optional )
workflow_dispatch: inputs:
Yes the workflow which you are triggering should have:
on:
workflow_dispatch:
I provided a json string
But I get an error on the payload: