I want send json data to process by workflow. When I use event webhook/file/nats I can get content of event message through dependency. How to achieve this using Argo server API.
CodePudding user response:
The Argo Server API includes a few endpoints which can be used to submit workflows. The simplest one is /api/v1/workflows/{namespace}/submit
. To send JSON as a parameter, make sure the following is part of the payload:
{
"submitOptions": {
"parameters": [
"param-name={\"your-json\": \"encoded as a string\"}"
]
}
}