Interface IBowireRequestPreview
- Namespace
- Kuestenlogik.Bowire
- Assembly
- Kuestenlogik.Bowire.dll
Optional capability of a protocol plugin that builds the HTTP request it
sends itself, from things only it knows (#1064): the SOAP plugin wraps the
body in an envelope whose namespace and SOAPAction come from the
WSDL. The workbench asks for the request without sending it
(POST /api/invoke/prepare), so a code snippet sends what an invoke
would send.
public interface IBowireRequestPreview
Methods
PrepareRequestAsync(string, string, string, IReadOnlyList<string>, IReadOnlyDictionary<string, string>?, CancellationToken)
The request InvokeAsync(string, string, string, List<string>, bool, Dictionary<string, string>?, CancellationToken) would send for the same arguments, without sending it; null when the plugin cannot say (no endpoint, an operation it does not know).
Task<BowirePreparedRequest?> PrepareRequestAsync(string serverUrl, string service, string method, IReadOnlyList<string> jsonMessages, IReadOnlyDictionary<string, string>? metadata, CancellationToken ct = default)
Parameters
serverUrlstringservicestringmethodstringjsonMessagesIReadOnlyList<string>metadataIReadOnlyDictionary<string, string>ctCancellationToken
Returns
Remarks
The headers are the ones the plugin itself decides (content type,
protocol headers). Headers from metadata that a
caller adds as they are are not repeated.