HTTPServiceClient
public protocol HTTPServiceClient
The HTTP service client, which can be used to perform HTTP requests via MongoDB Stitch.
-
Executes the given
HTTPRequest
.Declaration
Swift
func execute(request: HTTPRequest, _ completionHandler: @escaping (StitchResult<HTTPResponse>) -> Void)
Parameters
request
The request to execute
completionHandler
The completion handler to call when the request is complete or the operation fails. This handler is executed on a non-main global
DispatchQueue
. If the operation is successful, the result will contain the response to the request as anHTTPResponse
.