Vermonster / fhir-kit-client

Node.js FHIR client library
MIT License
173 stars 37 forks source link

add an option to the client to sign the request. This is useful for F… #152

Closed ericfuxealth closed 3 years ago

ericfuxealth commented 3 years ago

…HIR store such as AWS healthlake.

bkaney commented 3 years ago

@ericfuxealth - Does each individual request need to be signed each time with a new signature, or can you create one signature once up front and use for any subsequent request?

If if is the latter, I think creating the signature and passing into the constructor (as additionHeaders) would do the trick.

bkaney commented 3 years ago

I think reading through this - https://docs.aws.amazon.com/general/latest/gr/sigv4-signed-request-examples.html - it seems each request would have to be signed each request.

ericfuxealth commented 3 years ago

I think reading through this - https://docs.aws.amazon.com/general/latest/gr/sigv4-signed-request-examples.html - it seems each request would have to be signed each request.

Each request has to be signed separately because the current timestamp is included in the signature.

ericfuxealth commented 3 years ago

@bkaney any update on this PR review?

shravan097 commented 3 years ago

@bkaney Any update on this? I am also waiting for this PR to get merge

bkaney commented 3 years ago

@shravan097 @ericfuxealth I will work on this today. I would like to add an @example to the JSDoc for the constructor though. Do you think you could do that?

sdhakal-xealth commented 3 years ago

@bkaney Let us know if any further changes are necessary

bkaney commented 3 years ago

Replaced by https://github.com/Vermonster/fhir-kit-client/pull/166