IDownstreamApi Interface
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Interface used to call a downstream API, for instance from controllers.
public interface IDownstreamApi
type IDownstreamApi = interface
Public Interface IDownstreamApi
Methods
CallApiAsync(DownstreamApiOptions, ClaimsPrincipal, HttpContent, CancellationToken) |
Calls the downstream API based on a programmatic description of the downstream API. The choice of calling the API on behalf of the user or the app, is made using RequestAppToken. |
CallApiAsync(String, Action<DownstreamApiOptions>, ClaimsPrincipal, HttpContent, CancellationToken) |
Calls the downstream API based on a description of the downstream API in the configuration (service name), overridatable programmatically. The choice of calling the API on behalf of the user or the app, is made by the configuration or programmatically. This is the lowest level API. There are other APIs for specific Http methods. |
CallApiForAppAsync(String, Action<DownstreamApiOptions>, HttpContent, CancellationToken) |
Calls the downstream API on behalf of the app itself, with the required scopes. |
CallApiForAppAsync<TInput,TOutput>(String, TInput, Action<DownstreamApiOptions>, CancellationToken) |
Calls a downstream API consuming JSON with some data and returns data. |
CallApiForAppAsync<TOutput>(String, Action<DownstreamApiOptions>, CancellationToken) |
Call a web API endpoint with an HttpGet, and return strongly typed data. |
CallApiForUserAsync(String, Action<DownstreamApiOptions>, ClaimsPrincipal, HttpContent, CancellationToken) |
Calls the downstream API on behalf of the user, based on a description of the downstream API in the configuration (service name), overridatable programmatically. This is a lower level API. There are other APIs for specific Http methods. |
CallApiForUserAsync<TInput,TOutput>(String, TInput, Action<DownstreamApiOptions>, ClaimsPrincipal, CancellationToken) |
Calls a downstream API consuming JSON with some data and returns data. |
CallApiForUserAsync<TOutput>(String, Action<DownstreamApiOptions>, ClaimsPrincipal, CancellationToken) |
Call a web API endpoint with an HttpGet, and return strongly typed data. |
DeleteForAppAsync<TInput,TOutput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, CancellationToken) |
Calls, using Delete, a downstream API with some input data and returning data.
By default the input data is serialized in JSON and the returned data is deserialized from JSON but you can provide your own serializer and your own deserializer in the action
you pass-in through the |
DeleteForAppAsync<TInput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, CancellationToken) |
Calls, using Delete, a downstream API with some input data .
By default the input data is serialized in JSON but you can provide your own serializer in the action
you pass-in through the |
DeleteForUserAsync<TInput,TOutput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, ClaimsPrincipal, CancellationToken) |
Calls, using Delete, a downstream API with some input data and returning data.
By default the input data is serialized in JSON and the returned data is deserialized from JSON but you can provide your own serializer and your own deserializer in the action
you pass-in through the |
DeleteForUserAsync<TInput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, ClaimsPrincipal, CancellationToken) |
Calls, using Delete, a downstream API with some input data .
By default the input data is serialized in JSON but you can provide your own serializer in the action
you pass-in through the |
GetForAppAsync<TInput,TOutput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, CancellationToken) |
Calls, using Get, a downstream API with some input data and returning data.
By default the input data is serialized in JSON and the returned data is deserialized from JSON but you can provide your own serializer and your own deserializer in the action
you pass-in through the |
GetForAppAsync<TOutput>(String, Action<DownstreamApiOptionsReadOnlyHttpMethod>, CancellationToken) |
Calls, using Get, a downstream API returning data.
By default the returned data is deserialized from JSON but you can provide your own deserializer in the action
you pass-in through the |
GetForUserAsync<TInput,TOutput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, ClaimsPrincipal, CancellationToken) |
Calls, using Get, a downstream API with some input data and returning data.
By default the input data is serialized in JSON and the returned data is deserialized from JSON but you can provide your own serializer and your own deserializer in the action
you pass-in through the |
GetForUserAsync<TOutput>(String, Action<DownstreamApiOptionsReadOnlyHttpMethod>, ClaimsPrincipal, CancellationToken) |
Calls, using Get, a downstream API returning data.
By default the returned data is deserialized from JSON but you can provide your own deserializer in the action
you pass-in through the |
PatchForAppAsync<TInput,TOutput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, CancellationToken) |
Calls, using Patch, a downstream API with some input data and returning data.
By default the input data is serialized in JSON and the returned data is deserialized from JSON but you can provide your own serializer and your own deserializer in the action
you pass-in through the |
PatchForAppAsync<TInput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, CancellationToken) |
Calls, using Patch, a downstream API with some input data .
By default the input data is serialized in JSON but you can provide your own serializer in the action
you pass-in through the |
PatchForUserAsync<TInput,TOutput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, ClaimsPrincipal, CancellationToken) |
Calls, using Patch, a downstream API with some input data and returning data.
By default the input data is serialized in JSON and the returned data is deserialized from JSON but you can provide your own serializer and your own deserializer in the action
you pass-in through the |
PatchForUserAsync<TInput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, ClaimsPrincipal, CancellationToken) |
Calls, using Patch, a downstream API with some input data .
By default the input data is serialized in JSON but you can provide your own serializer in the action
you pass-in through the |
PostForAppAsync<TInput,TOutput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, CancellationToken) |
Calls, using Post, a downstream API with some input data and returning data.
By default the input data is serialized in JSON and the returned data is deserialized from JSON but you can provide your own serializer and your own deserializer in the action
you pass-in through the |
PostForAppAsync<TInput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, CancellationToken) |
Calls, using Post, a downstream API with some input data .
By default the input data is serialized in JSON but you can provide your own serializer in the action
you pass-in through the |
PostForUserAsync<TInput,TOutput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, ClaimsPrincipal, CancellationToken) |
Calls, using Post, a downstream API with some input data and returning data.
By default the input data is serialized in JSON and the returned data is deserialized from JSON but you can provide your own serializer and your own deserializer in the action
you pass-in through the |
PostForUserAsync<TInput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, ClaimsPrincipal, CancellationToken) |
Calls, using Post, a downstream API with some input data .
By default the input data is serialized in JSON but you can provide your own serializer in the action
you pass-in through the |
PutForAppAsync<TInput,TOutput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, CancellationToken) |
Calls, using Put, a downstream API with some input data and returning data.
By default the input data is serialized in JSON and the returned data is deserialized from JSON but you can provide your own serializer and your own deserializer in the action
you pass-in through the |
PutForAppAsync<TInput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, CancellationToken) |
Calls, using Put, a downstream API with some input data .
By default the input data is serialized in JSON but you can provide your own serializer in the action
you pass-in through the |
PutForUserAsync<TInput,TOutput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, ClaimsPrincipal, CancellationToken) |
Calls, using Put, a downstream API with some input data and returning data.
By default the input data is serialized in JSON and the returned data is deserialized from JSON but you can provide your own serializer and your own deserializer in the action
you pass-in through the |
PutForUserAsync<TInput>(String, TInput, Action<DownstreamApiOptionsReadOnlyHttpMethod>, ClaimsPrincipal, CancellationToken) |
Calls, using Put, a downstream API with some input data .
By default the input data is serialized in JSON but you can provide your own serializer in the action
you pass-in through the |