Azure / azure-functions-durable-js

JavaScript library for using the Durable Functions bindings
https://www.npmjs.com/package/durable-functions
MIT License
131 stars 47 forks source link

Leverage the HttpRequest and HttpResponse classes from `@azure/functions` #454

Closed hossam-nasr closed 1 year ago

hossam-nasr commented 1 year ago

Let's get rid of the IHttpRequest and IHttpRespones classes in this SDK, and instead rely on the HttpRequest and HttpResponse classes provided by @azure/functions.

This means that client.createCheckStatusResponse() and client.waitForCompletionOrCreateCheckStatusResponse() should both accept an HttpRequest object, and return an HttpResponse object.

While technically a breaking change, this is actually helpful in most cases, because HttpRequest is the type of trigger input received by HTTP-triggered functions anyway, and most functions just pass the result of those API back to the Functions library, which also now expects an HttpResponse object

hossam-nasr commented 1 year ago

Closed by #462