/*
* FHT.Core.API 1.0
*
* ̨group.apiVersion:1.0
*
* OpenAPI spec version: v1
* Contact: fht@fht360.com
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Net.Http;
using IO.Swagger.Client;
using IO.Swagger.Model;
namespace IO.Swagger.Api
{
///
/// Represents a collection of functions to interact with the API endpoints
///
public interface INotificationApiApi : IApiAccessor
{
#region Synchronous Operations
///
///
///
///
///
///
/// Thrown when fails to make API call
///
///
void NotificationApiBatchMarkAsRead (MarkNotificationsAsReadInputModel model);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
/// ApiResponse of Object(void)
ApiResponse NotificationApiBatchMarkAsReadWithHttpInfo (MarkNotificationsAsReadInputModel model);
///
///
///
///
///
///
/// Thrown when fails to make API call
/// List<string>
List NotificationApiGetChannels ();
///
///
///
///
///
///
/// Thrown when fails to make API call
/// ApiResponse of List<string>
ApiResponse> NotificationApiGetChannelsWithHttpInfo ();
///
///
///
///
///
///
/// Thrown when fails to make API call
/// (optional, default to 10)
/// (optional, default to 0)
/// List<BroadcastNotificationViewModel>
List NotificationApiGetMarketBroadcastNoticesAsync (int? limit = null, int? offset = null);
///
///
///
///
///
///
/// Thrown when fails to make API call
/// (optional, default to 10)
/// (optional, default to 0)
/// ApiResponse of List<BroadcastNotificationViewModel>
ApiResponse> NotificationApiGetMarketBroadcastNoticesAsyncWithHttpInfo (int? limit = null, int? offset = null);
///
///
///
///
///
///
/// Thrown when fails to make API call
/// 从上次读取的NotificationId (optional)
/// 从上次读取广播的BroadcastId (optional)
/// NotificationUnreadCountViewModel
NotificationUnreadCountViewModel NotificationApiGetNotificationUnreadCountAsync (long? fromNotificationId = null, long? fromBroadcastId = null);
///
///
///
///
///
///
/// Thrown when fails to make API call
/// 从上次读取的NotificationId (optional)
/// 从上次读取广播的BroadcastId (optional)
/// ApiResponse of NotificationUnreadCountViewModel
ApiResponse NotificationApiGetNotificationUnreadCountAsyncWithHttpInfo (long? fromNotificationId = null, long? fromBroadcastId = null);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
///
/// CursorPaginationResultNotificationModelBase
CursorPaginationResultNotificationModelBase NotificationApiGetNotifications (long? cursorCursor, int? cursorLimit);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
///
/// ApiResponse of CursorPaginationResultNotificationModelBase
ApiResponse NotificationApiGetNotificationsWithHttpInfo (long? cursorCursor, int? cursorLimit);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
///
/// StatViewModel
StatViewModel NotificationApiGetUnReadNotificationNum (long? cursorCursor, int? cursorLimit);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
///
/// ApiResponse of StatViewModel
ApiResponse NotificationApiGetUnReadNotificationNumWithHttpInfo (long? cursorCursor, int? cursorLimit);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
///
/// CursorPaginationResultNotificationModelBase
CursorPaginationResultNotificationModelBase NotificationApiGetUnReadNotifications (long? cursorCursor, int? cursorLimit);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
///
/// ApiResponse of CursorPaginationResultNotificationModelBase
ApiResponse NotificationApiGetUnReadNotificationsWithHttpInfo (long? cursorCursor, int? cursorLimit);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
void NotificationApiIgnoreAllAsync ();
///
///
///
///
///
///
/// Thrown when fails to make API call
/// ApiResponse of Object(void)
ApiResponse NotificationApiIgnoreAllAsyncWithHttpInfo ();
///
///
///
///
///
///
/// Thrown when fails to make API call
///
///
void NotificationApiMarkAsRead (long? notificationId);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
/// ApiResponse of Object(void)
ApiResponse NotificationApiMarkAsReadWithHttpInfo (long? notificationId);
#endregion Synchronous Operations
#region Asynchronous Operations
///
///
///
///
///
///
/// Thrown when fails to make API call
///
/// Task of void
System.Threading.Tasks.Task NotificationApiBatchMarkAsReadAsync (MarkNotificationsAsReadInputModel model);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
/// Task of ApiResponse
System.Threading.Tasks.Task> NotificationApiBatchMarkAsReadAsyncWithHttpInfo (MarkNotificationsAsReadInputModel model);
///
///
///
///
///
///
/// Thrown when fails to make API call
/// Task of List<string>
System.Threading.Tasks.Task> NotificationApiGetChannelsAsync ();
///
///
///
///
///
///
/// Thrown when fails to make API call
/// Task of ApiResponse (List<string>)
System.Threading.Tasks.Task>> NotificationApiGetChannelsAsyncWithHttpInfo ();
///
///
///
///
///
///
/// Thrown when fails to make API call
/// (optional, default to 10)
/// (optional, default to 0)
/// Task of List<BroadcastNotificationViewModel>
System.Threading.Tasks.Task> NotificationApiGetMarketBroadcastNoticesAsyncAsync (int? limit = null, int? offset = null);
///
///
///
///
///
///
/// Thrown when fails to make API call
/// (optional, default to 10)
/// (optional, default to 0)
/// Task of ApiResponse (List<BroadcastNotificationViewModel>)
System.Threading.Tasks.Task>> NotificationApiGetMarketBroadcastNoticesAsyncAsyncWithHttpInfo (int? limit = null, int? offset = null);
///
///
///
///
///
///
/// Thrown when fails to make API call
/// 从上次读取的NotificationId (optional)
/// 从上次读取广播的BroadcastId (optional)
/// Task of NotificationUnreadCountViewModel
System.Threading.Tasks.Task NotificationApiGetNotificationUnreadCountAsyncAsync (long? fromNotificationId = null, long? fromBroadcastId = null);
///
///
///
///
///
///
/// Thrown when fails to make API call
/// 从上次读取的NotificationId (optional)
/// 从上次读取广播的BroadcastId (optional)
/// Task of ApiResponse (NotificationUnreadCountViewModel)
System.Threading.Tasks.Task> NotificationApiGetNotificationUnreadCountAsyncAsyncWithHttpInfo (long? fromNotificationId = null, long? fromBroadcastId = null);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
///
/// Task of CursorPaginationResultNotificationModelBase
System.Threading.Tasks.Task NotificationApiGetNotificationsAsync (long? cursorCursor, int? cursorLimit);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
///
/// Task of ApiResponse (CursorPaginationResultNotificationModelBase)
System.Threading.Tasks.Task> NotificationApiGetNotificationsAsyncWithHttpInfo (long? cursorCursor, int? cursorLimit);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
///
/// Task of StatViewModel
System.Threading.Tasks.Task NotificationApiGetUnReadNotificationNumAsync (long? cursorCursor, int? cursorLimit);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
///
/// Task of ApiResponse (StatViewModel)
System.Threading.Tasks.Task> NotificationApiGetUnReadNotificationNumAsyncWithHttpInfo (long? cursorCursor, int? cursorLimit);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
///
/// Task of CursorPaginationResultNotificationModelBase
System.Threading.Tasks.Task NotificationApiGetUnReadNotificationsAsync (long? cursorCursor, int? cursorLimit);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
///
/// Task of ApiResponse (CursorPaginationResultNotificationModelBase)
System.Threading.Tasks.Task> NotificationApiGetUnReadNotificationsAsyncWithHttpInfo (long? cursorCursor, int? cursorLimit);
///
///
///
///
///
///
/// Thrown when fails to make API call
/// Task of void
System.Threading.Tasks.Task NotificationApiIgnoreAllAsyncAsync ();
///
///
///
///
///
///
/// Thrown when fails to make API call
/// Task of ApiResponse
System.Threading.Tasks.Task> NotificationApiIgnoreAllAsyncAsyncWithHttpInfo ();
///
///
///
///
///
///
/// Thrown when fails to make API call
///
/// Task of void
System.Threading.Tasks.Task NotificationApiMarkAsReadAsync (long? notificationId);
///
///
///
///
///
///
/// Thrown when fails to make API call
///
/// Task of ApiResponse
System.Threading.Tasks.Task> NotificationApiMarkAsReadAsyncWithHttpInfo (long? notificationId);
#endregion Asynchronous Operations
}
///
/// Represents a collection of functions to interact with the API endpoints
///
public partial class NotificationApiApi : INotificationApiApi
{
private IO.Swagger.Client.ExceptionFactory _exceptionFactory = (name, response) => null;
///
/// Initializes a new instance of the class
/// using Configuration object
///
/// An instance of Configuration
///
public NotificationApiApi(Configuration configuration)
{
this.Configuration = configuration;
ExceptionFactory = IO.Swagger.Client.Configuration.DefaultExceptionFactory;
// ensure API client has configuration ready
if (Configuration.ApiClient.Configuration == null)
{
this.Configuration.ApiClient.Configuration = this.Configuration;
}
}
///
/// Gets or sets the configuration object
///
/// An instance of the Configuration
public Configuration Configuration {get; set;}
///
/// Provides a factory method hook for the creation of exceptions.
///
public IO.Swagger.Client.ExceptionFactory ExceptionFactory
{
get
{
if (_exceptionFactory != null && _exceptionFactory.GetInvocationList().Length > 1)
{
throw new InvalidOperationException("Multicast delegate for ExceptionFactory is unsupported.");
}
return _exceptionFactory;
}
set { _exceptionFactory = value; }
}
///
///
///
/// Thrown when fails to make API call
///
///
public void NotificationApiBatchMarkAsRead (MarkNotificationsAsReadInputModel model)
{
NotificationApiBatchMarkAsReadWithHttpInfo(model);
}
///
///
///
/// Thrown when fails to make API call
///
/// ApiResponse of Object(void)
public ApiResponse NotificationApiBatchMarkAsReadWithHttpInfo (MarkNotificationsAsReadInputModel model)
{
// verify the required parameter 'model' is set
if (model == null)
throw new ApiException(400, "Missing required parameter 'model' when calling NotificationApiApi->NotificationApiBatchMarkAsRead");
var localVarPath = "/v1/notifications";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
"application/vnd.fht360.enumAsString+json",
"application/vnd.fht360.preserveCircularReference+json",
"application/json",
"text/json",
"application/xml",
"text/xml",
"application/x-www-form-urlencoded"
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
localVarPostBody = Configuration.ApiClient.Serialize(model); // http body (model) parameter
// make the HTTP request
var localVarResponse = Configuration.ApiClient.CallApi(localVarPath,
"POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiBatchMarkAsRead", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
null);
}
///
///
///
/// Thrown when fails to make API call
///
/// Task of void
public async System.Threading.Tasks.Task NotificationApiBatchMarkAsReadAsync (MarkNotificationsAsReadInputModel model)
{
await NotificationApiBatchMarkAsReadAsyncWithHttpInfo(model);
}
///
///
///
/// Thrown when fails to make API call
///
/// Task of ApiResponse
public async System.Threading.Tasks.Task> NotificationApiBatchMarkAsReadAsyncWithHttpInfo (MarkNotificationsAsReadInputModel model)
{
// verify the required parameter 'model' is set
if (model == null)
throw new ApiException(400, "Missing required parameter 'model' when calling NotificationApiApi->NotificationApiBatchMarkAsRead");
var localVarPath = "/v1/notifications";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
"application/vnd.fht360.enumAsString+json",
"application/vnd.fht360.preserveCircularReference+json",
"application/json",
"text/json",
"application/xml",
"text/xml",
"application/x-www-form-urlencoded"
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
localVarPostBody = Configuration.ApiClient.Serialize(model); // http body (model) parameter
// make the HTTP request
var localVarResponse = await Configuration.ApiClient.CallApiAsync(localVarPath,
"POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiBatchMarkAsRead", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
null);
}
///
///
///
/// Thrown when fails to make API call
/// List<string>
public List NotificationApiGetChannels ()
{
ApiResponse> localVarResponse = NotificationApiGetChannelsWithHttpInfo();
return localVarResponse.Data;
}
///
///
///
/// Thrown when fails to make API call
/// ApiResponse of List<string>
public ApiResponse< List > NotificationApiGetChannelsWithHttpInfo ()
{
var localVarPath = "/v1/notifications/channels";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
"application/vnd.fht360.enumAsString+json",
"application/vnd.fht360.preserveCircularReference+json",
"application/json",
"text/json",
"application/xml",
"text/xml"
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
// make the HTTP request
var localVarResponse = Configuration.ApiClient.CallApi(localVarPath,
"GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiGetChannels", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse>(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
(List) Configuration.ApiClient.Deserialize(localVarResponse.Content.ReadAsStringAsync().Result, typeof(List)));
}
///
///
///
/// Thrown when fails to make API call
/// Task of List<string>
public async System.Threading.Tasks.Task> NotificationApiGetChannelsAsync ()
{
ApiResponse> localVarResponse = await NotificationApiGetChannelsAsyncWithHttpInfo();
return localVarResponse.Data;
}
///
///
///
/// Thrown when fails to make API call
/// Task of ApiResponse (List<string>)
public async System.Threading.Tasks.Task>> NotificationApiGetChannelsAsyncWithHttpInfo ()
{
var localVarPath = "/v1/notifications/channels";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
"application/vnd.fht360.enumAsString+json",
"application/vnd.fht360.preserveCircularReference+json",
"application/json",
"text/json",
"application/xml",
"text/xml"
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
// make the HTTP request
var localVarResponse = await Configuration.ApiClient.CallApiAsync(localVarPath,
"GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiGetChannels", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse>(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
(List) Configuration.ApiClient.Deserialize(await localVarResponse.Content.ReadAsStringAsync(), typeof(List)));
}
///
///
///
/// Thrown when fails to make API call
/// (optional, default to 10)
/// (optional, default to 0)
/// List<BroadcastNotificationViewModel>
public List NotificationApiGetMarketBroadcastNoticesAsync (int? limit = null, int? offset = null)
{
ApiResponse> localVarResponse = NotificationApiGetMarketBroadcastNoticesAsyncWithHttpInfo(limit, offset);
return localVarResponse.Data;
}
///
///
///
/// Thrown when fails to make API call
/// (optional, default to 10)
/// (optional, default to 0)
/// ApiResponse of List<BroadcastNotificationViewModel>
public ApiResponse< List > NotificationApiGetMarketBroadcastNoticesAsyncWithHttpInfo (int? limit = null, int? offset = null)
{
var localVarPath = "/v1/notifications/broadcast";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
"application/vnd.fht360.enumAsString+json",
"application/vnd.fht360.preserveCircularReference+json",
"application/json",
"text/json",
"application/xml",
"text/xml"
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
if (limit != null) localVarQueryParams.Add("limit", Configuration.ApiClient.ParameterToString(limit)); // query parameter
if (offset != null) localVarQueryParams.Add("offset", Configuration.ApiClient.ParameterToString(offset)); // query parameter
// make the HTTP request
var localVarResponse = Configuration.ApiClient.CallApi(localVarPath,
"GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiGetMarketBroadcastNoticesAsync", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse>(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
(List) Configuration.ApiClient.Deserialize(localVarResponse.Content.ReadAsStringAsync().Result, typeof(List)));
}
///
///
///
/// Thrown when fails to make API call
/// (optional, default to 10)
/// (optional, default to 0)
/// Task of List<BroadcastNotificationViewModel>
public async System.Threading.Tasks.Task> NotificationApiGetMarketBroadcastNoticesAsyncAsync (int? limit = null, int? offset = null)
{
ApiResponse> localVarResponse = await NotificationApiGetMarketBroadcastNoticesAsyncAsyncWithHttpInfo(limit, offset);
return localVarResponse.Data;
}
///
///
///
/// Thrown when fails to make API call
/// (optional, default to 10)
/// (optional, default to 0)
/// Task of ApiResponse (List<BroadcastNotificationViewModel>)
public async System.Threading.Tasks.Task>> NotificationApiGetMarketBroadcastNoticesAsyncAsyncWithHttpInfo (int? limit = null, int? offset = null)
{
var localVarPath = "/v1/notifications/broadcast";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
"application/vnd.fht360.enumAsString+json",
"application/vnd.fht360.preserveCircularReference+json",
"application/json",
"text/json",
"application/xml",
"text/xml"
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
if (limit != null) localVarQueryParams.Add("limit", Configuration.ApiClient.ParameterToString(limit)); // query parameter
if (offset != null) localVarQueryParams.Add("offset", Configuration.ApiClient.ParameterToString(offset)); // query parameter
// make the HTTP request
var localVarResponse = await Configuration.ApiClient.CallApiAsync(localVarPath,
"GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiGetMarketBroadcastNoticesAsync", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse>(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
(List) Configuration.ApiClient.Deserialize(await localVarResponse.Content.ReadAsStringAsync(), typeof(List)));
}
///
///
///
/// Thrown when fails to make API call
/// 从上次读取的NotificationId (optional)
/// 从上次读取广播的BroadcastId (optional)
/// NotificationUnreadCountViewModel
public NotificationUnreadCountViewModel NotificationApiGetNotificationUnreadCountAsync (long? fromNotificationId = null, long? fromBroadcastId = null)
{
ApiResponse localVarResponse = NotificationApiGetNotificationUnreadCountAsyncWithHttpInfo(fromNotificationId, fromBroadcastId);
return localVarResponse.Data;
}
///
///
///
/// Thrown when fails to make API call
/// 从上次读取的NotificationId (optional)
/// 从上次读取广播的BroadcastId (optional)
/// ApiResponse of NotificationUnreadCountViewModel
public ApiResponse< NotificationUnreadCountViewModel > NotificationApiGetNotificationUnreadCountAsyncWithHttpInfo (long? fromNotificationId = null, long? fromBroadcastId = null)
{
var localVarPath = "/v1/notifications/unreadcount";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
"application/vnd.fht360.enumAsString+json",
"application/vnd.fht360.preserveCircularReference+json",
"application/json",
"text/json",
"application/xml",
"text/xml"
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
if (fromNotificationId != null) localVarQueryParams.Add("fromNotificationId", Configuration.ApiClient.ParameterToString(fromNotificationId)); // query parameter
if (fromBroadcastId != null) localVarQueryParams.Add("fromBroadcastId", Configuration.ApiClient.ParameterToString(fromBroadcastId)); // query parameter
// make the HTTP request
var localVarResponse = Configuration.ApiClient.CallApi(localVarPath,
"GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiGetNotificationUnreadCountAsync", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
(NotificationUnreadCountViewModel) Configuration.ApiClient.Deserialize(localVarResponse.Content.ReadAsStringAsync().Result, typeof(NotificationUnreadCountViewModel)));
}
///
///
///
/// Thrown when fails to make API call
/// 从上次读取的NotificationId (optional)
/// 从上次读取广播的BroadcastId (optional)
/// Task of NotificationUnreadCountViewModel
public async System.Threading.Tasks.Task NotificationApiGetNotificationUnreadCountAsyncAsync (long? fromNotificationId = null, long? fromBroadcastId = null)
{
ApiResponse localVarResponse = await NotificationApiGetNotificationUnreadCountAsyncAsyncWithHttpInfo(fromNotificationId, fromBroadcastId);
return localVarResponse.Data;
}
///
///
///
/// Thrown when fails to make API call
/// 从上次读取的NotificationId (optional)
/// 从上次读取广播的BroadcastId (optional)
/// Task of ApiResponse (NotificationUnreadCountViewModel)
public async System.Threading.Tasks.Task> NotificationApiGetNotificationUnreadCountAsyncAsyncWithHttpInfo (long? fromNotificationId = null, long? fromBroadcastId = null)
{
var localVarPath = "/v1/notifications/unreadcount";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
"application/vnd.fht360.enumAsString+json",
"application/vnd.fht360.preserveCircularReference+json",
"application/json",
"text/json",
"application/xml",
"text/xml"
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
if (fromNotificationId != null) localVarQueryParams.Add("fromNotificationId", Configuration.ApiClient.ParameterToString(fromNotificationId)); // query parameter
if (fromBroadcastId != null) localVarQueryParams.Add("fromBroadcastId", Configuration.ApiClient.ParameterToString(fromBroadcastId)); // query parameter
// make the HTTP request
var localVarResponse = await Configuration.ApiClient.CallApiAsync(localVarPath,
"GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiGetNotificationUnreadCountAsync", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
(NotificationUnreadCountViewModel) Configuration.ApiClient.Deserialize(await localVarResponse.Content.ReadAsStringAsync(), typeof(NotificationUnreadCountViewModel)));
}
///
///
///
/// Thrown when fails to make API call
///
///
/// CursorPaginationResultNotificationModelBase
public CursorPaginationResultNotificationModelBase NotificationApiGetNotifications (long? cursorCursor, int? cursorLimit)
{
ApiResponse localVarResponse = NotificationApiGetNotificationsWithHttpInfo(cursorCursor, cursorLimit);
return localVarResponse.Data;
}
///
///
///
/// Thrown when fails to make API call
///
///
/// ApiResponse of CursorPaginationResultNotificationModelBase
public ApiResponse< CursorPaginationResultNotificationModelBase > NotificationApiGetNotificationsWithHttpInfo (long? cursorCursor, int? cursorLimit)
{
// verify the required parameter 'cursorCursor' is set
if (cursorCursor == null)
throw new ApiException(400, "Missing required parameter 'cursorCursor' when calling NotificationApiApi->NotificationApiGetNotifications");
// verify the required parameter 'cursorLimit' is set
if (cursorLimit == null)
throw new ApiException(400, "Missing required parameter 'cursorLimit' when calling NotificationApiApi->NotificationApiGetNotifications");
var localVarPath = "/v1/notifications";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
"application/vnd.fht360.enumAsString+json",
"application/vnd.fht360.preserveCircularReference+json",
"application/json",
"text/json",
"application/xml",
"text/xml"
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
if (cursorCursor != null) localVarQueryParams.Add("cursor.cursor", Configuration.ApiClient.ParameterToString(cursorCursor)); // query parameter
if (cursorLimit != null) localVarQueryParams.Add("cursor.limit", Configuration.ApiClient.ParameterToString(cursorLimit)); // query parameter
// make the HTTP request
var localVarResponse = Configuration.ApiClient.CallApi(localVarPath,
"GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiGetNotifications", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
(CursorPaginationResultNotificationModelBase) Configuration.ApiClient.Deserialize(localVarResponse.Content.ReadAsStringAsync().Result, typeof(CursorPaginationResultNotificationModelBase)));
}
///
///
///
/// Thrown when fails to make API call
///
///
/// Task of CursorPaginationResultNotificationModelBase
public async System.Threading.Tasks.Task NotificationApiGetNotificationsAsync (long? cursorCursor, int? cursorLimit)
{
ApiResponse localVarResponse = await NotificationApiGetNotificationsAsyncWithHttpInfo(cursorCursor, cursorLimit);
return localVarResponse.Data;
}
///
///
///
/// Thrown when fails to make API call
///
///
/// Task of ApiResponse (CursorPaginationResultNotificationModelBase)
public async System.Threading.Tasks.Task> NotificationApiGetNotificationsAsyncWithHttpInfo (long? cursorCursor, int? cursorLimit)
{
// verify the required parameter 'cursorCursor' is set
if (cursorCursor == null)
throw new ApiException(400, "Missing required parameter 'cursorCursor' when calling NotificationApiApi->NotificationApiGetNotifications");
// verify the required parameter 'cursorLimit' is set
if (cursorLimit == null)
throw new ApiException(400, "Missing required parameter 'cursorLimit' when calling NotificationApiApi->NotificationApiGetNotifications");
var localVarPath = "/v1/notifications";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
"application/vnd.fht360.enumAsString+json",
"application/vnd.fht360.preserveCircularReference+json",
"application/json",
"text/json",
"application/xml",
"text/xml"
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
if (cursorCursor != null) localVarQueryParams.Add("cursor.cursor", Configuration.ApiClient.ParameterToString(cursorCursor)); // query parameter
if (cursorLimit != null) localVarQueryParams.Add("cursor.limit", Configuration.ApiClient.ParameterToString(cursorLimit)); // query parameter
// make the HTTP request
var localVarResponse = await Configuration.ApiClient.CallApiAsync(localVarPath,
"GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiGetNotifications", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
(CursorPaginationResultNotificationModelBase) Configuration.ApiClient.Deserialize(await localVarResponse.Content.ReadAsStringAsync(), typeof(CursorPaginationResultNotificationModelBase)));
}
///
///
///
/// Thrown when fails to make API call
///
///
/// StatViewModel
public StatViewModel NotificationApiGetUnReadNotificationNum (long? cursorCursor, int? cursorLimit)
{
ApiResponse localVarResponse = NotificationApiGetUnReadNotificationNumWithHttpInfo(cursorCursor, cursorLimit);
return localVarResponse.Data;
}
///
///
///
/// Thrown when fails to make API call
///
///
/// ApiResponse of StatViewModel
public ApiResponse< StatViewModel > NotificationApiGetUnReadNotificationNumWithHttpInfo (long? cursorCursor, int? cursorLimit)
{
// verify the required parameter 'cursorCursor' is set
if (cursorCursor == null)
throw new ApiException(400, "Missing required parameter 'cursorCursor' when calling NotificationApiApi->NotificationApiGetUnReadNotificationNum");
// verify the required parameter 'cursorLimit' is set
if (cursorLimit == null)
throw new ApiException(400, "Missing required parameter 'cursorLimit' when calling NotificationApiApi->NotificationApiGetUnReadNotificationNum");
var localVarPath = "/v1/unreadnotificationnum";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
"application/vnd.fht360.enumAsString+json",
"application/vnd.fht360.preserveCircularReference+json",
"application/json",
"text/json",
"application/xml",
"text/xml"
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
if (cursorCursor != null) localVarQueryParams.Add("cursor.cursor", Configuration.ApiClient.ParameterToString(cursorCursor)); // query parameter
if (cursorLimit != null) localVarQueryParams.Add("cursor.limit", Configuration.ApiClient.ParameterToString(cursorLimit)); // query parameter
// make the HTTP request
var localVarResponse = Configuration.ApiClient.CallApi(localVarPath,
"GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiGetUnReadNotificationNum", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
(StatViewModel) Configuration.ApiClient.Deserialize(localVarResponse.Content.ReadAsStringAsync().Result, typeof(StatViewModel)));
}
///
///
///
/// Thrown when fails to make API call
///
///
/// Task of StatViewModel
public async System.Threading.Tasks.Task NotificationApiGetUnReadNotificationNumAsync (long? cursorCursor, int? cursorLimit)
{
ApiResponse localVarResponse = await NotificationApiGetUnReadNotificationNumAsyncWithHttpInfo(cursorCursor, cursorLimit);
return localVarResponse.Data;
}
///
///
///
/// Thrown when fails to make API call
///
///
/// Task of ApiResponse (StatViewModel)
public async System.Threading.Tasks.Task> NotificationApiGetUnReadNotificationNumAsyncWithHttpInfo (long? cursorCursor, int? cursorLimit)
{
// verify the required parameter 'cursorCursor' is set
if (cursorCursor == null)
throw new ApiException(400, "Missing required parameter 'cursorCursor' when calling NotificationApiApi->NotificationApiGetUnReadNotificationNum");
// verify the required parameter 'cursorLimit' is set
if (cursorLimit == null)
throw new ApiException(400, "Missing required parameter 'cursorLimit' when calling NotificationApiApi->NotificationApiGetUnReadNotificationNum");
var localVarPath = "/v1/unreadnotificationnum";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
"application/vnd.fht360.enumAsString+json",
"application/vnd.fht360.preserveCircularReference+json",
"application/json",
"text/json",
"application/xml",
"text/xml"
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
if (cursorCursor != null) localVarQueryParams.Add("cursor.cursor", Configuration.ApiClient.ParameterToString(cursorCursor)); // query parameter
if (cursorLimit != null) localVarQueryParams.Add("cursor.limit", Configuration.ApiClient.ParameterToString(cursorLimit)); // query parameter
// make the HTTP request
var localVarResponse = await Configuration.ApiClient.CallApiAsync(localVarPath,
"GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiGetUnReadNotificationNum", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
(StatViewModel) Configuration.ApiClient.Deserialize(await localVarResponse.Content.ReadAsStringAsync(), typeof(StatViewModel)));
}
///
///
///
/// Thrown when fails to make API call
///
///
/// CursorPaginationResultNotificationModelBase
public CursorPaginationResultNotificationModelBase NotificationApiGetUnReadNotifications (long? cursorCursor, int? cursorLimit)
{
ApiResponse localVarResponse = NotificationApiGetUnReadNotificationsWithHttpInfo(cursorCursor, cursorLimit);
return localVarResponse.Data;
}
///
///
///
/// Thrown when fails to make API call
///
///
/// ApiResponse of CursorPaginationResultNotificationModelBase
public ApiResponse< CursorPaginationResultNotificationModelBase > NotificationApiGetUnReadNotificationsWithHttpInfo (long? cursorCursor, int? cursorLimit)
{
// verify the required parameter 'cursorCursor' is set
if (cursorCursor == null)
throw new ApiException(400, "Missing required parameter 'cursorCursor' when calling NotificationApiApi->NotificationApiGetUnReadNotifications");
// verify the required parameter 'cursorLimit' is set
if (cursorLimit == null)
throw new ApiException(400, "Missing required parameter 'cursorLimit' when calling NotificationApiApi->NotificationApiGetUnReadNotifications");
var localVarPath = "/v1/unreadnotifications";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
"application/vnd.fht360.enumAsString+json",
"application/vnd.fht360.preserveCircularReference+json",
"application/json",
"text/json",
"application/xml",
"text/xml"
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
if (cursorCursor != null) localVarQueryParams.Add("cursor.cursor", Configuration.ApiClient.ParameterToString(cursorCursor)); // query parameter
if (cursorLimit != null) localVarQueryParams.Add("cursor.limit", Configuration.ApiClient.ParameterToString(cursorLimit)); // query parameter
// make the HTTP request
var localVarResponse = Configuration.ApiClient.CallApi(localVarPath,
"GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiGetUnReadNotifications", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
(CursorPaginationResultNotificationModelBase) Configuration.ApiClient.Deserialize(localVarResponse.Content.ReadAsStringAsync().Result, typeof(CursorPaginationResultNotificationModelBase)));
}
///
///
///
/// Thrown when fails to make API call
///
///
/// Task of CursorPaginationResultNotificationModelBase
public async System.Threading.Tasks.Task NotificationApiGetUnReadNotificationsAsync (long? cursorCursor, int? cursorLimit)
{
ApiResponse localVarResponse = await NotificationApiGetUnReadNotificationsAsyncWithHttpInfo(cursorCursor, cursorLimit);
return localVarResponse.Data;
}
///
///
///
/// Thrown when fails to make API call
///
///
/// Task of ApiResponse (CursorPaginationResultNotificationModelBase)
public async System.Threading.Tasks.Task> NotificationApiGetUnReadNotificationsAsyncWithHttpInfo (long? cursorCursor, int? cursorLimit)
{
// verify the required parameter 'cursorCursor' is set
if (cursorCursor == null)
throw new ApiException(400, "Missing required parameter 'cursorCursor' when calling NotificationApiApi->NotificationApiGetUnReadNotifications");
// verify the required parameter 'cursorLimit' is set
if (cursorLimit == null)
throw new ApiException(400, "Missing required parameter 'cursorLimit' when calling NotificationApiApi->NotificationApiGetUnReadNotifications");
var localVarPath = "/v1/unreadnotifications";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
"application/vnd.fht360.enumAsString+json",
"application/vnd.fht360.preserveCircularReference+json",
"application/json",
"text/json",
"application/xml",
"text/xml"
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
if (cursorCursor != null) localVarQueryParams.Add("cursor.cursor", Configuration.ApiClient.ParameterToString(cursorCursor)); // query parameter
if (cursorLimit != null) localVarQueryParams.Add("cursor.limit", Configuration.ApiClient.ParameterToString(cursorLimit)); // query parameter
// make the HTTP request
var localVarResponse = await Configuration.ApiClient.CallApiAsync(localVarPath,
"GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiGetUnReadNotifications", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
(CursorPaginationResultNotificationModelBase) Configuration.ApiClient.Deserialize(await localVarResponse.Content.ReadAsStringAsync(), typeof(CursorPaginationResultNotificationModelBase)));
}
///
///
///
/// Thrown when fails to make API call
///
public void NotificationApiIgnoreAllAsync ()
{
NotificationApiIgnoreAllAsyncWithHttpInfo();
}
///
///
///
/// Thrown when fails to make API call
/// ApiResponse of Object(void)
public ApiResponse NotificationApiIgnoreAllAsyncWithHttpInfo ()
{
var localVarPath = "/v1/notifications/_ignoreall";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
// make the HTTP request
var localVarResponse = Configuration.ApiClient.CallApi(localVarPath,
"POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiIgnoreAllAsync", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
null);
}
///
///
///
/// Thrown when fails to make API call
/// Task of void
public async System.Threading.Tasks.Task NotificationApiIgnoreAllAsyncAsync ()
{
await NotificationApiIgnoreAllAsyncAsyncWithHttpInfo();
}
///
///
///
/// Thrown when fails to make API call
/// Task of ApiResponse
public async System.Threading.Tasks.Task> NotificationApiIgnoreAllAsyncAsyncWithHttpInfo ()
{
var localVarPath = "/v1/notifications/_ignoreall";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
// make the HTTP request
var localVarResponse = await Configuration.ApiClient.CallApiAsync(localVarPath,
"POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiIgnoreAllAsync", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
null);
}
///
///
///
/// Thrown when fails to make API call
///
///
public void NotificationApiMarkAsRead (long? notificationId)
{
NotificationApiMarkAsReadWithHttpInfo(notificationId);
}
///
///
///
/// Thrown when fails to make API call
///
/// ApiResponse of Object(void)
public ApiResponse NotificationApiMarkAsReadWithHttpInfo (long? notificationId)
{
// verify the required parameter 'notificationId' is set
if (notificationId == null)
throw new ApiException(400, "Missing required parameter 'notificationId' when calling NotificationApiApi->NotificationApiMarkAsRead");
var localVarPath = "/v1/notifications/{notificationId}";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
// make the HTTP request
var localVarResponse = Configuration.ApiClient.CallApi(localVarPath,
"POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiMarkAsRead", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
null);
}
///
///
///
/// Thrown when fails to make API call
///
/// Task of void
public async System.Threading.Tasks.Task NotificationApiMarkAsReadAsync (long? notificationId)
{
await NotificationApiMarkAsReadAsyncWithHttpInfo(notificationId);
}
///
///
///
/// Thrown when fails to make API call
///
/// Task of ApiResponse
public async System.Threading.Tasks.Task> NotificationApiMarkAsReadAsyncWithHttpInfo (long? notificationId)
{
// verify the required parameter 'notificationId' is set
if (notificationId == null)
throw new ApiException(400, "Missing required parameter 'notificationId' when calling NotificationApiApi->NotificationApiMarkAsRead");
var localVarPath = "/v1/notifications/{notificationId}";
var localVarQueryParams = new Dictionary();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
string localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
// make the HTTP request
var localVarResponse = await Configuration.ApiClient.CallApiAsync(localVarPath,
"POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("NotificationApiMarkAsRead", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
null);
}
}
}