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
I'm trying to start a workflow using HTTP API according to the Cadence HTTP API documentation. It's working as expected when I do not define input for the workflow. When I changed the workflow definition to have input like below:
func MyWorkflow(ctx cadence.Context, input MyInput) error {
...
}
type MyInput struct {
SomeString: string,
SomeInteger: int
}
and send a HTTP POST request to start the workflow with the data like below:
The workflow failed immediately and gave out this error:
{
"reason": "cadenceInternal:Generic",
"details": "unable to decode the workflow function input bytes with error: unable to decode argument: 0, *MyInput, with json error: EOF, function name: sample-workflow-type",
...
}
Can someone help me point out where I did wrong? Thanks a lot!
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I'm trying to start a workflow using HTTP API according to the Cadence HTTP API documentation. It's working as expected when I do not define input for the workflow. When I changed the workflow definition to have input like below:
and send a HTTP POST request to start the workflow with the data like below:
The workflow failed immediately and gave out this error:
Can someone help me point out where I did wrong? Thanks a lot!
Beta Was this translation helpful? Give feedback.
All reactions