3.2.10 • Published 8 years ago

kronos-interceptor-http-request v3.2.10

Weekly downloads
3
License
BSD-2-Clause
Repository
github
Last release
8 years ago

npm Greenkeeper semantic-release Build Status bithound codecov.io Coverage Status Code Climate Known Vulnerabilities GitHub Issues Stories in Ready Dependency Status devDependency Status docs downloads Commitizen friendly

kronos-interceptor-http-request

Interceptor to convert messages into multipart form data and back

API Reference

transformMessageToRequestMessage(message) ⇒

Copies the fields 'info' and 'hops' into the new message. Then create a formdata object containing 'info', 'hops' and 'payload'. Stores the formdata object as the payload of the 'newMessage' object.

Kind: global function
Returns: newMessage The transformed message

ParamDescription
messageThe message to transform

unpackToMessage(request, forwardFunction) ⇒

Unpacks a message from a multipart http request

Kind: global function
Returns: Promise A promise with the result of the forwardFunction

ParamDescription
requestThe incomming http request
forwardFunctionThe function to call with the new generated message. The function must return a Promise. If no 'forwardFunction' is given It will return the message in the promise

install

With npm do:

npm install kronos-interceptor-http-request

license

BSD-2-Clause

3.2.10

8 years ago

3.2.9

8 years ago

3.2.8

9 years ago

3.2.7

9 years ago

3.2.6

9 years ago

3.2.5

9 years ago

3.2.4

9 years ago

3.2.3

9 years ago

3.2.2

9 years ago

3.2.1

9 years ago

3.2.0

9 years ago

3.1.1

9 years ago

3.1.0

9 years ago

3.0.3

9 years ago

3.0.2

9 years ago

3.0.1

9 years ago

3.0.0

9 years ago

2.3.1

10 years ago

2.3.0

10 years ago

2.2.0

10 years ago

2.1.0

10 years ago

2.0.0

10 years ago

1.1.1

10 years ago

1.1.0

10 years ago

1.0.0

10 years ago