cloudhead / cloudhead/journey

How to get Post with form data?

Open
#15 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
322
Forks
26
PR merge metrics
No merged PRs in 30d

Description

In the documentation it says:

"How about a POST request, with form data, or JSON? Same thing, journey will parse the data, and pass it as the last argument to the bound function."

router.post('/').bind(function (req, res, params) {
console.log(params);
res.send(200, {"Content-Type":"application/json"}, params);
});

But I'm getting back empty for params or whatever else I call the last argument.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the documented router.post('/') example and the request-binding behavior it describes. Reproduce the POST with form data or JSON and inspect how the last bound-function argument is populated. Done means submitted data is available in params as documented, or the documentation clearly explains the supported request format and behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, node.js
Domain
api, backend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.