Nucleus .Net Core CMS

IRestApiClient Interface

Namespace: Nucleus.Abstractions
Assembly: Nucleus.Abstractions.dll
General-purpose Api client.
GetResponse (String baseUrl, String relativePath, HttpMethod httpMethod, String apiMethod, Object content, CancellationToken cancellationToken)
Send a Http request and return the raw http response message.
Parameters
Name Type
baseUrl String
relativePath String
httpMethod System.Net.Http.HttpMethod
apiMethod String
content Object
cancellationToken System.Threading.CancellationToken
GetResponse (String baseUrl, String relativePath, HttpMethod httpMethod, String apiMethod, HttpContent content, CancellationToken cancellationToken)
Send a Http request and return the raw http response message.
Parameters
Name Type
baseUrl String
relativePath String
httpMethod System.Net.Http.HttpMethod
apiMethod String
content System.Net.Http.HttpContent
cancellationToken System.Threading.CancellationToken
GetResponse (String baseUrl, String relativePath, HttpMethod httpMethod, String apiMethod, HttpRequestMessage callback, HttpRequestMessage> content, Object cancellationToken)
Send a Http request and return the raw http response message.
Parameters
Name Type
baseUrl String
relativePath String
httpMethod System.Net.Http.HttpMethod
apiMethod String
callback System.Func<System.Net.Http.HttpRequestMessage
content System.Net.Http.HttpRequestMessage>
cancellationToken Object
GetResponse (String baseUrl, String relativePath, HttpMethod httpMethod, String apiMethod, HttpRequestMessage callback, HttpRequestMessage> content, HttpContent cancellationToken)
Send a Http request and return the raw http response message.
Parameters
Name Type
baseUrl String
relativePath String
httpMethod System.Net.Http.HttpMethod
apiMethod String
callback System.Func<System.Net.Http.HttpRequestMessage
content System.Net.Http.HttpRequestMessage>
cancellationToken System.Net.Http.HttpContent
GetResponse<T> (String baseUrl, String relativePath, HttpMethod httpMethod, String apiMethod, HttpRequestMessage callback, HttpRequestMessage> content, HttpContent cancellationToken)
Send a Http request and return the response as the specified type T
Type Parameters
T
Parameters
Name Type
baseUrl String
relativePath String
httpMethod System.Net.Http.HttpMethod
apiMethod String
callback System.Func<System.Net.Http.HttpRequestMessage
content System.Net.Http.HttpRequestMessage>
cancellationToken System.Net.Http.HttpContent
GetResponse<T> (String baseUrl, String relativePath, HttpMethod httpMethod, String apiMethod, HttpContent content, CancellationToken cancellationToken)
Send a Http request and return the response as the specified type T
Type Parameters
T
Parameters
Name Type
baseUrl String
relativePath String
httpMethod System.Net.Http.HttpMethod
apiMethod String
content System.Net.Http.HttpContent
cancellationToken System.Threading.CancellationToken
GetResponse<T> (String baseUrl, String relativePath, HttpMethod httpMethod, String apiMethod, HttpRequestMessage callback, HttpRequestMessage> content, Object cancellationToken)
Send a Http request and return the response as the specified type T
Type Parameters
T
Parameters
Name Type
baseUrl String
relativePath String
httpMethod System.Net.Http.HttpMethod
apiMethod String
callback System.Func<System.Net.Http.HttpRequestMessage
content System.Net.Http.HttpRequestMessage>
cancellationToken Object
GetResponse<T> (String baseUrl, String relativePath, HttpMethod httpMethod, String apiMethod, Object content, CancellationToken cancellationToken)
Send a Http request and return the response as the specified type T
Type Parameters
T
Parameters
Name Type
baseUrl String
relativePath String
httpMethod System.Net.Http.HttpMethod
apiMethod String
content Object
cancellationToken System.Threading.CancellationToken
GetResponseAsStream (String baseUrl, String relativePath, HttpMethod httpMethod, String apiMethod, HttpRequestMessage callback, HttpRequestMessage> content, HttpContent cancellationToken)
Send a Http request and return the response as a stream,
Parameters
Name Type
baseUrl String
relativePath String
httpMethod System.Net.Http.HttpMethod
apiMethod String
callback System.Func<System.Net.Http.HttpRequestMessage
content System.Net.Http.HttpRequestMessage>
cancellationToken System.Net.Http.HttpContent
GetResponseAsStream (String baseUrl, String relativePath, HttpMethod httpMethod, String apiMethod, HttpContent content, CancellationToken cancellationToken)
Send a Http request and return the response as a stream,
Parameters
Name Type
baseUrl String
relativePath String
httpMethod System.Net.Http.HttpMethod
apiMethod String
content System.Net.Http.HttpContent
cancellationToken System.Threading.CancellationToken
GetResponseAsStream (String baseUrl, String relativePath, HttpMethod httpMethod, String apiMethod, HttpRequestMessage callback, HttpRequestMessage> content, Object cancellationToken)
Send a Http request and return the response as a stream,
Parameters
Name Type
baseUrl String
relativePath String
httpMethod System.Net.Http.HttpMethod
apiMethod String
callback System.Func<System.Net.Http.HttpRequestMessage
content System.Net.Http.HttpRequestMessage>
cancellationToken Object
GetResponseAsStream (String baseUrl, String relativePath, HttpMethod httpMethod, String apiMethod, Object content, CancellationToken cancellationToken)
Send a Http request and return the response as a stream,
Parameters
Name Type
baseUrl String
relativePath String
httpMethod System.Net.Http.HttpMethod
apiMethod String
content Object
cancellationToken System.Threading.CancellationToken
GetResponseAsString (String baseUrl, String relativePath, HttpMethod httpMethod, String apiMethod, HttpRequestMessage callback, HttpRequestMessage> content, HttpContent cancellationToken)
Send a Http request and return the response as a string.
Parameters
Name Type
baseUrl String
relativePath String
httpMethod System.Net.Http.HttpMethod
apiMethod String
callback System.Func<System.Net.Http.HttpRequestMessage
content System.Net.Http.HttpRequestMessage>
cancellationToken System.Net.Http.HttpContent
GetResponseAsString (String baseUrl, String relativePath, HttpMethod httpMethod, String apiMethod, HttpContent content, CancellationToken cancellationToken)
Send a Http request and return the response as a string.
Parameters
Name Type
baseUrl String
relativePath String
httpMethod System.Net.Http.HttpMethod
apiMethod String
content System.Net.Http.HttpContent
cancellationToken System.Threading.CancellationToken
GetResponseAsString (String baseUrl, String relativePath, HttpMethod httpMethod, String apiMethod, HttpRequestMessage callback, HttpRequestMessage> content, Object cancellationToken)
Send a Http request and return the response as a string.
Parameters
Name Type
baseUrl String
relativePath String
httpMethod System.Net.Http.HttpMethod
apiMethod String
callback System.Func<System.Net.Http.HttpRequestMessage
content System.Net.Http.HttpRequestMessage>
cancellationToken Object
GetResponseAsString (String baseUrl, String relativePath, HttpMethod httpMethod, String apiMethod, Object content, CancellationToken cancellationToken)
Send a Http request and return the response as a string.
Parameters
Name Type
baseUrl String
relativePath String
httpMethod System.Net.Http.HttpMethod
apiMethod String
content Object
cancellationToken System.Threading.CancellationToken