/*
* InfluxDB OSS API Service
*
* The InfluxDB v2 API provides a programmatic interface for all interactions with InfluxDB. Access the InfluxDB API using the `/api/v2/` endpoint.
*
* OpenAPI spec version: 2.0.0
*
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Threading;
using RestSharp;
using InfluxDB.Client.Api.Client;
using InfluxDB.Client.Api.Domain;
namespace InfluxDB.Client.Api.Service
{
///
/// Represents a collection of functions to interact with the API endpoints
///
public interface IDashboardsService : IApiAccessor
{
#region Synchronous Operations
///
/// Delete a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
///
void DeleteDashboardsID(string dashboardID, string zapTraceSpan = null);
///
/// Delete a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
ApiResponse DeleteDashboardsIDWithHttpInfo(string dashboardID, string zapTraceSpan = null);
///
/// Delete a dashboard cell
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to delete.
/// The ID of the cell to delete.
/// OpenTracing span context (optional)
///
void DeleteDashboardsIDCellsID(string dashboardID, string cellID, string zapTraceSpan = null);
///
/// Delete a dashboard cell
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to delete.
/// The ID of the cell to delete.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
ApiResponse DeleteDashboardsIDCellsIDWithHttpInfo(string dashboardID, string cellID,
string zapTraceSpan = null);
///
/// Delete a label from a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// The ID of the label to delete.
/// OpenTracing span context (optional)
///
void DeleteDashboardsIDLabelsID(string dashboardID, string labelID, string zapTraceSpan = null);
///
/// Delete a label from a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// The ID of the label to delete.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
ApiResponse DeleteDashboardsIDLabelsIDWithHttpInfo(string dashboardID, string labelID,
string zapTraceSpan = null);
///
/// Remove a member from a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the member to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
///
void DeleteDashboardsIDMembersID(string userID, string dashboardID, string zapTraceSpan = null);
///
/// Remove a member from a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the member to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
ApiResponse DeleteDashboardsIDMembersIDWithHttpInfo(string userID, string dashboardID,
string zapTraceSpan = null);
///
/// Remove an owner from a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the owner to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
///
void DeleteDashboardsIDOwnersID(string userID, string dashboardID, string zapTraceSpan = null);
///
/// Remove an owner from a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the owner to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
ApiResponse DeleteDashboardsIDOwnersIDWithHttpInfo(string userID, string dashboardID,
string zapTraceSpan = null);
///
/// List all dashboards
///
///
///
///
/// Thrown when fails to make API call
/// OpenTracing span context (optional)
/// (optional)
/// (optional, default to 20)
/// (optional, default to false)
/// A user identifier. Returns only dashboards where this user has the `owner` role. (optional)
/// The column to sort by. (optional)
/// A list of dashboard identifiers. Returns only the listed dashboards. If both `id` and `owner` are specified, only `id` is used. (optional)
/// The identifier of the organization. (optional)
/// The name of the organization. (optional)
/// Dashboards
Dashboards GetDashboards(string zapTraceSpan = null, int? offset = null, int? limit = null,
bool? descending = null, string owner = null, string sortBy = null, List id = null,
string orgID = null, string org = null);
///
/// List all dashboards
///
///
///
///
/// Thrown when fails to make API call
/// OpenTracing span context (optional)
/// (optional)
/// (optional, default to 20)
/// (optional, default to false)
/// A user identifier. Returns only dashboards where this user has the `owner` role. (optional)
/// The column to sort by. (optional)
/// A list of dashboard identifiers. Returns only the listed dashboards. If both `id` and `owner` are specified, only `id` is used. (optional)
/// The identifier of the organization. (optional)
/// The name of the organization. (optional)
/// ApiResponse of Dashboards
ApiResponse GetDashboardsWithHttpInfo(string zapTraceSpan = null, int? offset = null,
int? limit = null, bool? descending = null, string owner = null, string sortBy = null,
List id = null, string orgID = null, string org = null);
///
/// Retrieve a Dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// Includes the cell view properties in the response if set to `properties` (optional)
/// Dashboard
Dashboard GetDashboardsID(string dashboardID, string zapTraceSpan = null, string include = null);
///
/// Retrieve a Dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// Includes the cell view properties in the response if set to `properties` (optional)
/// ApiResponse of Dashboard
ApiResponse GetDashboardsIDWithHttpInfo(string dashboardID, string zapTraceSpan = null,
string include = null);
///
/// Retrieve the view for a cell
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// The cell ID.
/// OpenTracing span context (optional)
/// View
View GetDashboardsIDCellsIDView(string dashboardID, string cellID, string zapTraceSpan = null);
///
/// Retrieve the view for a cell
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// The cell ID.
/// OpenTracing span context (optional)
/// ApiResponse of View
ApiResponse GetDashboardsIDCellsIDViewWithHttpInfo(string dashboardID, string cellID,
string zapTraceSpan = null);
///
/// List all labels for a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// OpenTracing span context (optional)
/// LabelsResponse
LabelsResponse GetDashboardsIDLabels(string dashboardID, string zapTraceSpan = null);
///
/// List all labels for a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// OpenTracing span context (optional)
/// ApiResponse of LabelsResponse
ApiResponse GetDashboardsIDLabelsWithHttpInfo(string dashboardID, string zapTraceSpan = null);
///
/// List all dashboard members
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// OpenTracing span context (optional)
/// ResourceMembers
ResourceMembers GetDashboardsIDMembers(string dashboardID, string zapTraceSpan = null);
///
/// List all dashboard members
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// OpenTracing span context (optional)
/// ApiResponse of ResourceMembers
ApiResponse GetDashboardsIDMembersWithHttpInfo(string dashboardID, string zapTraceSpan = null);
///
/// List all dashboard owners
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// OpenTracing span context (optional)
/// ResourceOwners
ResourceOwners GetDashboardsIDOwners(string dashboardID, string zapTraceSpan = null);
///
/// List all dashboard owners
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// OpenTracing span context (optional)
/// ApiResponse of ResourceOwners
ApiResponse GetDashboardsIDOwnersWithHttpInfo(string dashboardID, string zapTraceSpan = null);
///
/// Update a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// (optional)
/// Dashboard
Dashboard PatchDashboardsID(string dashboardID, string zapTraceSpan = null,
PatchDashboardRequest patchDashboardRequest = null);
///
/// Update a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// (optional)
/// ApiResponse of Dashboard
ApiResponse PatchDashboardsIDWithHttpInfo(string dashboardID, string zapTraceSpan = null,
PatchDashboardRequest patchDashboardRequest = null);
///
/// Update the non-positional information related to a cell
///
///
/// Updates the non positional information related to a cell. Updates to a single cell's positional data could cause grid conflicts.
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// The ID of the cell to update.
///
/// OpenTracing span context (optional)
/// Cell
Cell PatchDashboardsIDCellsID(string dashboardID, string cellID, CellUpdate cellUpdate,
string zapTraceSpan = null);
///
/// Update the non-positional information related to a cell
///
///
/// Updates the non positional information related to a cell. Updates to a single cell's positional data could cause grid conflicts.
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// The ID of the cell to update.
///
/// OpenTracing span context (optional)
/// ApiResponse of Cell
ApiResponse PatchDashboardsIDCellsIDWithHttpInfo(string dashboardID, string cellID, CellUpdate cellUpdate,
string zapTraceSpan = null);
///
/// Update the view for a cell
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// The ID of the cell to update.
///
/// OpenTracing span context (optional)
/// View
View PatchDashboardsIDCellsIDView(string dashboardID, string cellID, View view, string zapTraceSpan = null);
///
/// Update the view for a cell
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// The ID of the cell to update.
///
/// OpenTracing span context (optional)
/// ApiResponse of View
ApiResponse PatchDashboardsIDCellsIDViewWithHttpInfo(string dashboardID, string cellID, View view,
string zapTraceSpan = null);
///
/// Create a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// Dashboard to create
/// OpenTracing span context (optional)
/// Dashboard
Dashboard PostDashboards(CreateDashboardRequest createDashboardRequest, string zapTraceSpan = null);
///
/// Create a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// Dashboard to create
/// OpenTracing span context (optional)
/// ApiResponse of Dashboard
ApiResponse PostDashboardsWithHttpInfo(CreateDashboardRequest createDashboardRequest,
string zapTraceSpan = null);
///
/// Create a dashboard cell
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// Cell that will be added
/// OpenTracing span context (optional)
/// Cell
Cell PostDashboardsIDCells(string dashboardID, CreateCell createCell, string zapTraceSpan = null);
///
/// Create a dashboard cell
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// Cell that will be added
/// OpenTracing span context (optional)
/// ApiResponse of Cell
ApiResponse PostDashboardsIDCellsWithHttpInfo(string dashboardID, CreateCell createCell,
string zapTraceSpan = null);
///
/// Add a label to a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// Label to add
/// OpenTracing span context (optional)
/// LabelResponse
LabelResponse PostDashboardsIDLabels(string dashboardID, LabelMapping labelMapping, string zapTraceSpan = null);
///
/// Add a label to a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// Label to add
/// OpenTracing span context (optional)
/// ApiResponse of LabelResponse
ApiResponse PostDashboardsIDLabelsWithHttpInfo(string dashboardID, LabelMapping labelMapping,
string zapTraceSpan = null);
///
/// Add a member to a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// User to add as member
/// OpenTracing span context (optional)
/// ResourceMember
ResourceMember PostDashboardsIDMembers(string dashboardID,
AddResourceMemberRequestBody addResourceMemberRequestBody, string zapTraceSpan = null);
///
/// Add a member to a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// User to add as member
/// OpenTracing span context (optional)
/// ApiResponse of ResourceMember
ApiResponse PostDashboardsIDMembersWithHttpInfo(string dashboardID,
AddResourceMemberRequestBody addResourceMemberRequestBody, string zapTraceSpan = null);
///
/// Add an owner to a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// User to add as owner
/// OpenTracing span context (optional)
/// ResourceOwner
ResourceOwner PostDashboardsIDOwners(string dashboardID,
AddResourceMemberRequestBody addResourceMemberRequestBody, string zapTraceSpan = null);
///
/// Add an owner to a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// User to add as owner
/// OpenTracing span context (optional)
/// ApiResponse of ResourceOwner
ApiResponse PostDashboardsIDOwnersWithHttpInfo(string dashboardID,
AddResourceMemberRequestBody addResourceMemberRequestBody, string zapTraceSpan = null);
///
/// Replace cells in a dashboard
///
///
/// Replaces all cells in a dashboard. This is used primarily to update the positional information of all cells.
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
///
/// OpenTracing span context (optional)
/// Dashboard
Dashboard PutDashboardsIDCells(string dashboardID, List cell, string zapTraceSpan = null);
///
/// Replace cells in a dashboard
///
///
/// Replaces all cells in a dashboard. This is used primarily to update the positional information of all cells.
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
///
/// OpenTracing span context (optional)
/// ApiResponse of Dashboard
ApiResponse PutDashboardsIDCellsWithHttpInfo(string dashboardID, List cell,
string zapTraceSpan = null);
#endregion Synchronous Operations
#region Asynchronous Operations
///
/// Delete a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of void
System.Threading.Tasks.Task DeleteDashboardsIDAsync(string dashboardID, string zapTraceSpan = null,
CancellationToken cancellationToken = default);
///
/// Delete a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse
System.Threading.Tasks.Task> DeleteDashboardsIDAsyncWithHttpInfo(string dashboardID,
string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Delete a dashboard cell
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to delete.
/// The ID of the cell to delete.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of void
System.Threading.Tasks.Task DeleteDashboardsIDCellsIDAsync(string dashboardID, string cellID,
string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Delete a dashboard cell
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to delete.
/// The ID of the cell to delete.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse
System.Threading.Tasks.Task> DeleteDashboardsIDCellsIDAsyncWithHttpInfo(string dashboardID,
string cellID, string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Delete a label from a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// The ID of the label to delete.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of void
System.Threading.Tasks.Task DeleteDashboardsIDLabelsIDAsync(string dashboardID, string labelID,
string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Delete a label from a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// The ID of the label to delete.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse
System.Threading.Tasks.Task> DeleteDashboardsIDLabelsIDAsyncWithHttpInfo(string dashboardID,
string labelID, string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Remove a member from a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the member to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of void
System.Threading.Tasks.Task DeleteDashboardsIDMembersIDAsync(string userID, string dashboardID,
string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Remove a member from a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the member to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse
System.Threading.Tasks.Task> DeleteDashboardsIDMembersIDAsyncWithHttpInfo(string userID,
string dashboardID, string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Remove an owner from a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the owner to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of void
System.Threading.Tasks.Task DeleteDashboardsIDOwnersIDAsync(string userID, string dashboardID,
string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Remove an owner from a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the owner to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse
System.Threading.Tasks.Task> DeleteDashboardsIDOwnersIDAsyncWithHttpInfo(string userID,
string dashboardID, string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// List all dashboards
///
///
///
///
/// Thrown when fails to make API call
/// OpenTracing span context (optional)
/// (optional)
/// (optional, default to 20)
/// (optional, default to false)
/// A user identifier. Returns only dashboards where this user has the `owner` role. (optional)
/// The column to sort by. (optional)
/// A list of dashboard identifiers. Returns only the listed dashboards. If both `id` and `owner` are specified, only `id` is used. (optional)
/// The identifier of the organization. (optional)
/// The name of the organization. (optional)
/// Cancellation token
/// Task of Dashboards
System.Threading.Tasks.Task GetDashboardsAsync(string zapTraceSpan = null, int? offset = null,
int? limit = null, bool? descending = null, string owner = null, string sortBy = null,
List id = null, string orgID = null, string org = null,
CancellationToken cancellationToken = default);
///
/// List all dashboards
///
///
///
///
/// Thrown when fails to make API call
/// OpenTracing span context (optional)
/// (optional)
/// (optional, default to 20)
/// (optional, default to false)
/// A user identifier. Returns only dashboards where this user has the `owner` role. (optional)
/// The column to sort by. (optional)
/// A list of dashboard identifiers. Returns only the listed dashboards. If both `id` and `owner` are specified, only `id` is used. (optional)
/// The identifier of the organization. (optional)
/// The name of the organization. (optional)
/// Cancellation token
/// Task of ApiResponse (Dashboards)
System.Threading.Tasks.Task> GetDashboardsAsyncWithHttpInfo(string zapTraceSpan = null,
int? offset = null, int? limit = null, bool? descending = null, string owner = null, string sortBy = null,
List id = null, string orgID = null, string org = null,
CancellationToken cancellationToken = default);
///
/// Retrieve a Dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// Includes the cell view properties in the response if set to `properties` (optional)
/// Cancellation token
/// Task of Dashboard
System.Threading.Tasks.Task GetDashboardsIDAsync(string dashboardID, string zapTraceSpan = null,
string include = null, CancellationToken cancellationToken = default);
///
/// Retrieve a Dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// Includes the cell view properties in the response if set to `properties` (optional)
/// Cancellation token
/// Task of ApiResponse (Dashboard)
System.Threading.Tasks.Task> GetDashboardsIDAsyncWithHttpInfo(string dashboardID,
string zapTraceSpan = null, string include = null, CancellationToken cancellationToken = default);
///
/// Retrieve the view for a cell
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// The cell ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of View
System.Threading.Tasks.Task GetDashboardsIDCellsIDViewAsync(string dashboardID, string cellID,
string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Retrieve the view for a cell
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// The cell ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse (View)
System.Threading.Tasks.Task> GetDashboardsIDCellsIDViewAsyncWithHttpInfo(string dashboardID,
string cellID, string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// List all labels for a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of LabelsResponse
System.Threading.Tasks.Task GetDashboardsIDLabelsAsync(string dashboardID,
string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// List all labels for a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse (LabelsResponse)
System.Threading.Tasks.Task> GetDashboardsIDLabelsAsyncWithHttpInfo(
string dashboardID, string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// List all dashboard members
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ResourceMembers
System.Threading.Tasks.Task GetDashboardsIDMembersAsync(string dashboardID,
string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// List all dashboard members
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse (ResourceMembers)
System.Threading.Tasks.Task> GetDashboardsIDMembersAsyncWithHttpInfo(
string dashboardID, string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// List all dashboard owners
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ResourceOwners
System.Threading.Tasks.Task GetDashboardsIDOwnersAsync(string dashboardID,
string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// List all dashboard owners
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse (ResourceOwners)
System.Threading.Tasks.Task> GetDashboardsIDOwnersAsyncWithHttpInfo(
string dashboardID, string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Update a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// (optional)
/// Cancellation token
/// Task of Dashboard
System.Threading.Tasks.Task PatchDashboardsIDAsync(string dashboardID, string zapTraceSpan = null,
PatchDashboardRequest patchDashboardRequest = null, CancellationToken cancellationToken = default);
///
/// Update a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// (optional)
/// Cancellation token
/// Task of ApiResponse (Dashboard)
System.Threading.Tasks.Task> PatchDashboardsIDAsyncWithHttpInfo(string dashboardID,
string zapTraceSpan = null, PatchDashboardRequest patchDashboardRequest = null,
CancellationToken cancellationToken = default);
///
/// Update the non-positional information related to a cell
///
///
/// Updates the non positional information related to a cell. Updates to a single cell's positional data could cause grid conflicts.
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// The ID of the cell to update.
///
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of Cell
System.Threading.Tasks.Task PatchDashboardsIDCellsIDAsync(string dashboardID, string cellID,
CellUpdate cellUpdate, string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Update the non-positional information related to a cell
///
///
/// Updates the non positional information related to a cell. Updates to a single cell's positional data could cause grid conflicts.
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// The ID of the cell to update.
///
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse (Cell)
System.Threading.Tasks.Task> PatchDashboardsIDCellsIDAsyncWithHttpInfo(string dashboardID,
string cellID, CellUpdate cellUpdate, string zapTraceSpan = null,
CancellationToken cancellationToken = default);
///
/// Update the view for a cell
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// The ID of the cell to update.
///
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of View
System.Threading.Tasks.Task PatchDashboardsIDCellsIDViewAsync(string dashboardID, string cellID,
View view, string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Update the view for a cell
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// The ID of the cell to update.
///
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse (View)
System.Threading.Tasks.Task> PatchDashboardsIDCellsIDViewAsyncWithHttpInfo(string dashboardID,
string cellID, View view, string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Create a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// Dashboard to create
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of Dashboard
System.Threading.Tasks.Task PostDashboardsAsync(CreateDashboardRequest createDashboardRequest,
string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Create a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// Dashboard to create
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse (Dashboard)
System.Threading.Tasks.Task> PostDashboardsAsyncWithHttpInfo(
CreateDashboardRequest createDashboardRequest, string zapTraceSpan = null,
CancellationToken cancellationToken = default);
///
/// Create a dashboard cell
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// Cell that will be added
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of Cell
System.Threading.Tasks.Task PostDashboardsIDCellsAsync(string dashboardID, CreateCell createCell,
string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Create a dashboard cell
///
///
///
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// Cell that will be added
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse (Cell)
System.Threading.Tasks.Task> PostDashboardsIDCellsAsyncWithHttpInfo(string dashboardID,
CreateCell createCell, string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Add a label to a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// Label to add
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of LabelResponse
System.Threading.Tasks.Task PostDashboardsIDLabelsAsync(string dashboardID,
LabelMapping labelMapping, string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Add a label to a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// Label to add
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse (LabelResponse)
System.Threading.Tasks.Task> PostDashboardsIDLabelsAsyncWithHttpInfo(
string dashboardID, LabelMapping labelMapping, string zapTraceSpan = null,
CancellationToken cancellationToken = default);
///
/// Add a member to a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// User to add as member
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ResourceMember
System.Threading.Tasks.Task PostDashboardsIDMembersAsync(string dashboardID,
AddResourceMemberRequestBody addResourceMemberRequestBody, string zapTraceSpan = null,
CancellationToken cancellationToken = default);
///
/// Add a member to a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// User to add as member
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse (ResourceMember)
System.Threading.Tasks.Task> PostDashboardsIDMembersAsyncWithHttpInfo(
string dashboardID, AddResourceMemberRequestBody addResourceMemberRequestBody, string zapTraceSpan = null,
CancellationToken cancellationToken = default);
///
/// Add an owner to a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// User to add as owner
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ResourceOwner
System.Threading.Tasks.Task PostDashboardsIDOwnersAsync(string dashboardID,
AddResourceMemberRequestBody addResourceMemberRequestBody, string zapTraceSpan = null,
CancellationToken cancellationToken = default);
///
/// Add an owner to a dashboard
///
///
///
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// User to add as owner
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse (ResourceOwner)
System.Threading.Tasks.Task> PostDashboardsIDOwnersAsyncWithHttpInfo(
string dashboardID, AddResourceMemberRequestBody addResourceMemberRequestBody, string zapTraceSpan = null,
CancellationToken cancellationToken = default);
///
/// Replace cells in a dashboard
///
///
/// Replaces all cells in a dashboard. This is used primarily to update the positional information of all cells.
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
///
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of Dashboard
System.Threading.Tasks.Task PutDashboardsIDCellsAsync(string dashboardID, List cell,
string zapTraceSpan = null, CancellationToken cancellationToken = default);
///
/// Replace cells in a dashboard
///
///
/// Replaces all cells in a dashboard. This is used primarily to update the positional information of all cells.
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
///
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse (Dashboard)
System.Threading.Tasks.Task> PutDashboardsIDCellsAsyncWithHttpInfo(string dashboardID,
List cell, string zapTraceSpan = null, CancellationToken cancellationToken = default);
#endregion Asynchronous Operations
}
///
/// Represents a collection of functions to interact with the API endpoints
///
public partial class DashboardsService : IDashboardsService
{
private ExceptionFactory _exceptionFactory = (name, response) => null;
///
/// Initializes a new instance of the class.
///
///
public DashboardsService(string basePath)
{
Configuration = new Configuration { BasePath = basePath };
ExceptionFactory = Configuration.DefaultExceptionFactory;
}
///
/// Initializes a new instance of the class
/// using Configuration object
///
/// An instance of Configuration
///
public DashboardsService(Configuration configuration = null)
{
if (configuration == null) // use the default one in Configuration
{
Configuration = Configuration.Default;
}
else
{
Configuration = configuration;
}
ExceptionFactory = Configuration.DefaultExceptionFactory;
}
///
/// Gets the base path of the API client.
///
/// The base path
public string GetBasePath()
{
return Configuration.ApiClient.RestClientOptions.BaseUrl.ToString();
}
///
/// Sets the base path of the API client.
///
/// The base path
[Obsolete(
"SetBasePath is deprecated, please do 'Configuration.ApiClient = new ApiClient(\"http://new-path\")' instead.")]
public void SetBasePath(string basePath)
{
// do nothing
}
///
/// 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 ExceptionFactory ExceptionFactory
{
get
{
if (_exceptionFactory != null && _exceptionFactory.GetInvocationList().Length > 1)
{
throw new InvalidOperationException("Multicast delegate for ExceptionFactory is unsupported.");
}
return _exceptionFactory;
}
set => _exceptionFactory = value;
}
///
/// Gets the default header.
///
/// Dictionary of HTTP header
[Obsolete("DefaultHeader is deprecated, please use Configuration.DefaultHeader instead.")]
public IDictionary DefaultHeader()
{
return new ReadOnlyDictionary(Configuration.DefaultHeader);
}
///
/// Add default header.
///
/// Header field name.
/// Header field value.
///
[Obsolete("AddDefaultHeader is deprecated, please use Configuration.AddDefaultHeader instead.")]
public void AddDefaultHeader(string key, string value)
{
Configuration.AddDefaultHeader(key, value);
}
///
/// Delete a dashboard
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
///
public void DeleteDashboardsID(string dashboardID, string zapTraceSpan = null)
{
DeleteDashboardsIDWithHttpInfo(dashboardID, zapTraceSpan);
}
///
/// Delete a dashboard
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
public ApiResponse DeleteDashboardsIDWithHttpInfo(string dashboardID, string zapTraceSpan = null)
{
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)Configuration.ApiClient.CallApi(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.Select(h => (h.Name, h.Value)),
null);
}
///
/// Delete a dashboard
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// Cancellation token
/// ApiResponse of Object(void)
public async System.Threading.Tasks.Task DeleteDashboardsIDWithIRestResponseAsync(
string dashboardID, string zapTraceSpan = null, CancellationToken cancellationToken = default)
{
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)await Configuration.ApiClient.CallApiAsync(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType, cancellationToken).ConfigureAwait(false);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// Delete a dashboard
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
public RestResponse DeleteDashboardsIDWithIRestResponse(string dashboardID, string zapTraceSpan = null)
{
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)Configuration.ApiClient.CallApi(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// Delete a dashboard
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
public RestRequest DeleteDashboardsIDWithRestRequest(string dashboardID, string zapTraceSpan = null)
{
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
return Configuration.ApiClient.PrepareRequest(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
}
///
/// Delete a dashboard
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of void
public System.Threading.Tasks.Task DeleteDashboardsIDAsync(string dashboardID, string zapTraceSpan = null,
CancellationToken cancellationToken = default)
{
return DeleteDashboardsIDAsyncWithHttpInfo(dashboardID, zapTraceSpan, cancellationToken);
}
///
/// Delete a dashboard
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse
public async System.Threading.Tasks.Task> DeleteDashboardsIDAsyncWithHttpInfo(
string dashboardID, string zapTraceSpan = null, CancellationToken cancellationToken = default)
{
// make the HTTP request
var localVarResponse =
await DeleteDashboardsIDAsyncWithIRestResponse(dashboardID, zapTraceSpan, cancellationToken)
.ConfigureAwait(false);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.Select(h => (h.Name, h.Value)),
null);
}
///
/// Delete a dashboard
///
/// Thrown when fails to make API call
/// The ID of the dashboard to update.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of RestResponse
public async System.Threading.Tasks.Task DeleteDashboardsIDAsyncWithIRestResponse(
string dashboardID, string zapTraceSpan = null, CancellationToken cancellationToken = default)
{
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)await Configuration.ApiClient.CallApiAsync(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType, cancellationToken).ConfigureAwait(false);
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// Delete a dashboard cell
///
/// Thrown when fails to make API call
/// The ID of the dashboard to delete.
/// The ID of the cell to delete.
/// OpenTracing span context (optional)
///
public void DeleteDashboardsIDCellsID(string dashboardID, string cellID, string zapTraceSpan = null)
{
DeleteDashboardsIDCellsIDWithHttpInfo(dashboardID, cellID, zapTraceSpan);
}
///
/// Delete a dashboard cell
///
/// Thrown when fails to make API call
/// The ID of the dashboard to delete.
/// The ID of the cell to delete.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
public ApiResponse DeleteDashboardsIDCellsIDWithHttpInfo(string dashboardID, string cellID,
string zapTraceSpan = null)
{
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDCellsID");
}
// verify the required parameter 'cellID' is set
if (cellID == null)
{
throw new ApiException(400,
"Missing required parameter 'cellID' when calling DashboardsService->DeleteDashboardsIDCellsID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/cells/{cellID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (cellID != null)
{
localVarPathParams.Add("cellID", Configuration.ApiClient.ParameterToString(cellID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)Configuration.ApiClient.CallApi(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDCellsID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.Select(h => (h.Name, h.Value)),
null);
}
///
/// Delete a dashboard cell
///
/// Thrown when fails to make API call
/// The ID of the dashboard to delete.
/// The ID of the cell to delete.
/// OpenTracing span context (optional)
/// Cancellation token
/// ApiResponse of Object(void)
public async System.Threading.Tasks.Task DeleteDashboardsIDCellsIDWithIRestResponseAsync(
string dashboardID, string cellID, string zapTraceSpan = null,
CancellationToken cancellationToken = default)
{
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDCellsID");
}
// verify the required parameter 'cellID' is set
if (cellID == null)
{
throw new ApiException(400,
"Missing required parameter 'cellID' when calling DashboardsService->DeleteDashboardsIDCellsID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/cells/{cellID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (cellID != null)
{
localVarPathParams.Add("cellID", Configuration.ApiClient.ParameterToString(cellID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)await Configuration.ApiClient.CallApiAsync(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType, cancellationToken).ConfigureAwait(false);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDCellsID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// Delete a dashboard cell
///
/// Thrown when fails to make API call
/// The ID of the dashboard to delete.
/// The ID of the cell to delete.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
public RestResponse DeleteDashboardsIDCellsIDWithIRestResponse(string dashboardID, string cellID,
string zapTraceSpan = null)
{
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDCellsID");
}
// verify the required parameter 'cellID' is set
if (cellID == null)
{
throw new ApiException(400,
"Missing required parameter 'cellID' when calling DashboardsService->DeleteDashboardsIDCellsID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/cells/{cellID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (cellID != null)
{
localVarPathParams.Add("cellID", Configuration.ApiClient.ParameterToString(cellID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)Configuration.ApiClient.CallApi(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDCellsID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// Delete a dashboard cell
///
/// Thrown when fails to make API call
/// The ID of the dashboard to delete.
/// The ID of the cell to delete.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
public RestRequest DeleteDashboardsIDCellsIDWithRestRequest(string dashboardID, string cellID,
string zapTraceSpan = null)
{
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDCellsID");
}
// verify the required parameter 'cellID' is set
if (cellID == null)
{
throw new ApiException(400,
"Missing required parameter 'cellID' when calling DashboardsService->DeleteDashboardsIDCellsID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/cells/{cellID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (cellID != null)
{
localVarPathParams.Add("cellID", Configuration.ApiClient.ParameterToString(cellID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
return Configuration.ApiClient.PrepareRequest(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
}
///
/// Delete a dashboard cell
///
/// Thrown when fails to make API call
/// The ID of the dashboard to delete.
/// The ID of the cell to delete.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of void
public System.Threading.Tasks.Task DeleteDashboardsIDCellsIDAsync(string dashboardID, string cellID,
string zapTraceSpan = null, CancellationToken cancellationToken = default)
{
return DeleteDashboardsIDCellsIDAsyncWithHttpInfo(dashboardID, cellID, zapTraceSpan, cancellationToken);
}
///
/// Delete a dashboard cell
///
/// Thrown when fails to make API call
/// The ID of the dashboard to delete.
/// The ID of the cell to delete.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse
public async System.Threading.Tasks.Task> DeleteDashboardsIDCellsIDAsyncWithHttpInfo(
string dashboardID, string cellID, string zapTraceSpan = null,
CancellationToken cancellationToken = default)
{
// make the HTTP request
var localVarResponse =
await DeleteDashboardsIDCellsIDAsyncWithIRestResponse(dashboardID, cellID, zapTraceSpan,
cancellationToken).ConfigureAwait(false);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDCellsID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.Select(h => (h.Name, h.Value)),
null);
}
///
/// Delete a dashboard cell
///
/// Thrown when fails to make API call
/// The ID of the dashboard to delete.
/// The ID of the cell to delete.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of RestResponse
public async System.Threading.Tasks.Task DeleteDashboardsIDCellsIDAsyncWithIRestResponse(
string dashboardID, string cellID, string zapTraceSpan = null,
CancellationToken cancellationToken = default)
{
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDCellsID");
}
// verify the required parameter 'cellID' is set
if (cellID == null)
{
throw new ApiException(400,
"Missing required parameter 'cellID' when calling DashboardsService->DeleteDashboardsIDCellsID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/cells/{cellID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (cellID != null)
{
localVarPathParams.Add("cellID", Configuration.ApiClient.ParameterToString(cellID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)await Configuration.ApiClient.CallApiAsync(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType, cancellationToken).ConfigureAwait(false);
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDCellsID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// Delete a label from a dashboard
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// The ID of the label to delete.
/// OpenTracing span context (optional)
///
public void DeleteDashboardsIDLabelsID(string dashboardID, string labelID, string zapTraceSpan = null)
{
DeleteDashboardsIDLabelsIDWithHttpInfo(dashboardID, labelID, zapTraceSpan);
}
///
/// Delete a label from a dashboard
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// The ID of the label to delete.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
public ApiResponse DeleteDashboardsIDLabelsIDWithHttpInfo(string dashboardID, string labelID,
string zapTraceSpan = null)
{
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDLabelsID");
}
// verify the required parameter 'labelID' is set
if (labelID == null)
{
throw new ApiException(400,
"Missing required parameter 'labelID' when calling DashboardsService->DeleteDashboardsIDLabelsID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/labels/{labelID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (labelID != null)
{
localVarPathParams.Add("labelID", Configuration.ApiClient.ParameterToString(labelID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)Configuration.ApiClient.CallApi(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDLabelsID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.Select(h => (h.Name, h.Value)),
null);
}
///
/// Delete a label from a dashboard
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// The ID of the label to delete.
/// OpenTracing span context (optional)
/// Cancellation token
/// ApiResponse of Object(void)
public async System.Threading.Tasks.Task DeleteDashboardsIDLabelsIDWithIRestResponseAsync(
string dashboardID, string labelID, string zapTraceSpan = null,
CancellationToken cancellationToken = default)
{
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDLabelsID");
}
// verify the required parameter 'labelID' is set
if (labelID == null)
{
throw new ApiException(400,
"Missing required parameter 'labelID' when calling DashboardsService->DeleteDashboardsIDLabelsID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/labels/{labelID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (labelID != null)
{
localVarPathParams.Add("labelID", Configuration.ApiClient.ParameterToString(labelID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)await Configuration.ApiClient.CallApiAsync(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType, cancellationToken).ConfigureAwait(false);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDLabelsID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// Delete a label from a dashboard
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// The ID of the label to delete.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
public RestResponse DeleteDashboardsIDLabelsIDWithIRestResponse(string dashboardID, string labelID,
string zapTraceSpan = null)
{
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDLabelsID");
}
// verify the required parameter 'labelID' is set
if (labelID == null)
{
throw new ApiException(400,
"Missing required parameter 'labelID' when calling DashboardsService->DeleteDashboardsIDLabelsID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/labels/{labelID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (labelID != null)
{
localVarPathParams.Add("labelID", Configuration.ApiClient.ParameterToString(labelID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)Configuration.ApiClient.CallApi(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDLabelsID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// Delete a label from a dashboard
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// The ID of the label to delete.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
public RestRequest DeleteDashboardsIDLabelsIDWithRestRequest(string dashboardID, string labelID,
string zapTraceSpan = null)
{
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDLabelsID");
}
// verify the required parameter 'labelID' is set
if (labelID == null)
{
throw new ApiException(400,
"Missing required parameter 'labelID' when calling DashboardsService->DeleteDashboardsIDLabelsID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/labels/{labelID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (labelID != null)
{
localVarPathParams.Add("labelID", Configuration.ApiClient.ParameterToString(labelID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
return Configuration.ApiClient.PrepareRequest(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
}
///
/// Delete a label from a dashboard
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// The ID of the label to delete.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of void
public System.Threading.Tasks.Task DeleteDashboardsIDLabelsIDAsync(string dashboardID, string labelID,
string zapTraceSpan = null, CancellationToken cancellationToken = default)
{
return DeleteDashboardsIDLabelsIDAsyncWithHttpInfo(dashboardID, labelID, zapTraceSpan, cancellationToken);
}
///
/// Delete a label from a dashboard
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// The ID of the label to delete.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse
public async System.Threading.Tasks.Task> DeleteDashboardsIDLabelsIDAsyncWithHttpInfo(
string dashboardID, string labelID, string zapTraceSpan = null,
CancellationToken cancellationToken = default)
{
// make the HTTP request
var localVarResponse =
await DeleteDashboardsIDLabelsIDAsyncWithIRestResponse(dashboardID, labelID, zapTraceSpan,
cancellationToken).ConfigureAwait(false);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDLabelsID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.Select(h => (h.Name, h.Value)),
null);
}
///
/// Delete a label from a dashboard
///
/// Thrown when fails to make API call
/// The dashboard ID.
/// The ID of the label to delete.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of RestResponse
public async System.Threading.Tasks.Task DeleteDashboardsIDLabelsIDAsyncWithIRestResponse(
string dashboardID, string labelID, string zapTraceSpan = null,
CancellationToken cancellationToken = default)
{
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDLabelsID");
}
// verify the required parameter 'labelID' is set
if (labelID == null)
{
throw new ApiException(400,
"Missing required parameter 'labelID' when calling DashboardsService->DeleteDashboardsIDLabelsID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/labels/{labelID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (labelID != null)
{
localVarPathParams.Add("labelID", Configuration.ApiClient.ParameterToString(labelID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)await Configuration.ApiClient.CallApiAsync(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType, cancellationToken).ConfigureAwait(false);
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDLabelsID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// Remove a member from a dashboard
///
/// Thrown when fails to make API call
/// The ID of the member to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
///
public void DeleteDashboardsIDMembersID(string userID, string dashboardID, string zapTraceSpan = null)
{
DeleteDashboardsIDMembersIDWithHttpInfo(userID, dashboardID, zapTraceSpan);
}
///
/// Remove a member from a dashboard
///
/// Thrown when fails to make API call
/// The ID of the member to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
public ApiResponse DeleteDashboardsIDMembersIDWithHttpInfo(string userID, string dashboardID,
string zapTraceSpan = null)
{
// verify the required parameter 'userID' is set
if (userID == null)
{
throw new ApiException(400,
"Missing required parameter 'userID' when calling DashboardsService->DeleteDashboardsIDMembersID");
}
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDMembersID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/members/{userID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (userID != null)
{
localVarPathParams.Add("userID", Configuration.ApiClient.ParameterToString(userID)); // path parameter
}
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)Configuration.ApiClient.CallApi(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDMembersID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.Select(h => (h.Name, h.Value)),
null);
}
///
/// Remove a member from a dashboard
///
/// Thrown when fails to make API call
/// The ID of the member to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// ApiResponse of Object(void)
public async System.Threading.Tasks.Task DeleteDashboardsIDMembersIDWithIRestResponseAsync(
string userID, string dashboardID, string zapTraceSpan = null,
CancellationToken cancellationToken = default)
{
// verify the required parameter 'userID' is set
if (userID == null)
{
throw new ApiException(400,
"Missing required parameter 'userID' when calling DashboardsService->DeleteDashboardsIDMembersID");
}
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDMembersID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/members/{userID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (userID != null)
{
localVarPathParams.Add("userID", Configuration.ApiClient.ParameterToString(userID)); // path parameter
}
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)await Configuration.ApiClient.CallApiAsync(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType, cancellationToken).ConfigureAwait(false);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDMembersID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// Remove a member from a dashboard
///
/// Thrown when fails to make API call
/// The ID of the member to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
public RestResponse DeleteDashboardsIDMembersIDWithIRestResponse(string userID, string dashboardID,
string zapTraceSpan = null)
{
// verify the required parameter 'userID' is set
if (userID == null)
{
throw new ApiException(400,
"Missing required parameter 'userID' when calling DashboardsService->DeleteDashboardsIDMembersID");
}
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDMembersID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/members/{userID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (userID != null)
{
localVarPathParams.Add("userID", Configuration.ApiClient.ParameterToString(userID)); // path parameter
}
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)Configuration.ApiClient.CallApi(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDMembersID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// Remove a member from a dashboard
///
/// Thrown when fails to make API call
/// The ID of the member to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
public RestRequest DeleteDashboardsIDMembersIDWithRestRequest(string userID, string dashboardID,
string zapTraceSpan = null)
{
// verify the required parameter 'userID' is set
if (userID == null)
{
throw new ApiException(400,
"Missing required parameter 'userID' when calling DashboardsService->DeleteDashboardsIDMembersID");
}
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDMembersID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/members/{userID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (userID != null)
{
localVarPathParams.Add("userID", Configuration.ApiClient.ParameterToString(userID)); // path parameter
}
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
return Configuration.ApiClient.PrepareRequest(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
}
///
/// Remove a member from a dashboard
///
/// Thrown when fails to make API call
/// The ID of the member to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of void
public System.Threading.Tasks.Task DeleteDashboardsIDMembersIDAsync(string userID, string dashboardID,
string zapTraceSpan = null, CancellationToken cancellationToken = default)
{
return DeleteDashboardsIDMembersIDAsyncWithHttpInfo(userID, dashboardID, zapTraceSpan, cancellationToken);
}
///
/// Remove a member from a dashboard
///
/// Thrown when fails to make API call
/// The ID of the member to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse
public async System.Threading.Tasks.Task> DeleteDashboardsIDMembersIDAsyncWithHttpInfo(
string userID, string dashboardID, string zapTraceSpan = null,
CancellationToken cancellationToken = default)
{
// make the HTTP request
var localVarResponse =
await DeleteDashboardsIDMembersIDAsyncWithIRestResponse(userID, dashboardID, zapTraceSpan,
cancellationToken).ConfigureAwait(false);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDMembersID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.Select(h => (h.Name, h.Value)),
null);
}
///
/// Remove a member from a dashboard
///
/// Thrown when fails to make API call
/// The ID of the member to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of RestResponse
public async System.Threading.Tasks.Task DeleteDashboardsIDMembersIDAsyncWithIRestResponse(
string userID, string dashboardID, string zapTraceSpan = null,
CancellationToken cancellationToken = default)
{
// verify the required parameter 'userID' is set
if (userID == null)
{
throw new ApiException(400,
"Missing required parameter 'userID' when calling DashboardsService->DeleteDashboardsIDMembersID");
}
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDMembersID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/members/{userID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (userID != null)
{
localVarPathParams.Add("userID", Configuration.ApiClient.ParameterToString(userID)); // path parameter
}
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)await Configuration.ApiClient.CallApiAsync(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType, cancellationToken).ConfigureAwait(false);
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDMembersID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// Remove an owner from a dashboard
///
/// Thrown when fails to make API call
/// The ID of the owner to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
///
public void DeleteDashboardsIDOwnersID(string userID, string dashboardID, string zapTraceSpan = null)
{
DeleteDashboardsIDOwnersIDWithHttpInfo(userID, dashboardID, zapTraceSpan);
}
///
/// Remove an owner from a dashboard
///
/// Thrown when fails to make API call
/// The ID of the owner to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
public ApiResponse DeleteDashboardsIDOwnersIDWithHttpInfo(string userID, string dashboardID,
string zapTraceSpan = null)
{
// verify the required parameter 'userID' is set
if (userID == null)
{
throw new ApiException(400,
"Missing required parameter 'userID' when calling DashboardsService->DeleteDashboardsIDOwnersID");
}
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDOwnersID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/owners/{userID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (userID != null)
{
localVarPathParams.Add("userID", Configuration.ApiClient.ParameterToString(userID)); // path parameter
}
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)Configuration.ApiClient.CallApi(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDOwnersID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.Select(h => (h.Name, h.Value)),
null);
}
///
/// Remove an owner from a dashboard
///
/// Thrown when fails to make API call
/// The ID of the owner to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// ApiResponse of Object(void)
public async System.Threading.Tasks.Task DeleteDashboardsIDOwnersIDWithIRestResponseAsync(
string userID, string dashboardID, string zapTraceSpan = null,
CancellationToken cancellationToken = default)
{
// verify the required parameter 'userID' is set
if (userID == null)
{
throw new ApiException(400,
"Missing required parameter 'userID' when calling DashboardsService->DeleteDashboardsIDOwnersID");
}
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDOwnersID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/owners/{userID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (userID != null)
{
localVarPathParams.Add("userID", Configuration.ApiClient.ParameterToString(userID)); // path parameter
}
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)await Configuration.ApiClient.CallApiAsync(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType, cancellationToken).ConfigureAwait(false);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDOwnersID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// Remove an owner from a dashboard
///
/// Thrown when fails to make API call
/// The ID of the owner to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
public RestResponse DeleteDashboardsIDOwnersIDWithIRestResponse(string userID, string dashboardID,
string zapTraceSpan = null)
{
// verify the required parameter 'userID' is set
if (userID == null)
{
throw new ApiException(400,
"Missing required parameter 'userID' when calling DashboardsService->DeleteDashboardsIDOwnersID");
}
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDOwnersID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/owners/{userID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (userID != null)
{
localVarPathParams.Add("userID", Configuration.ApiClient.ParameterToString(userID)); // path parameter
}
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)Configuration.ApiClient.CallApi(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDOwnersID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// Remove an owner from a dashboard
///
/// Thrown when fails to make API call
/// The ID of the owner to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// ApiResponse of Object(void)
public RestRequest DeleteDashboardsIDOwnersIDWithRestRequest(string userID, string dashboardID,
string zapTraceSpan = null)
{
// verify the required parameter 'userID' is set
if (userID == null)
{
throw new ApiException(400,
"Missing required parameter 'userID' when calling DashboardsService->DeleteDashboardsIDOwnersID");
}
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDOwnersID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/owners/{userID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (userID != null)
{
localVarPathParams.Add("userID", Configuration.ApiClient.ParameterToString(userID)); // path parameter
}
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
return Configuration.ApiClient.PrepareRequest(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
}
///
/// Remove an owner from a dashboard
///
/// Thrown when fails to make API call
/// The ID of the owner to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of void
public System.Threading.Tasks.Task DeleteDashboardsIDOwnersIDAsync(string userID, string dashboardID,
string zapTraceSpan = null, CancellationToken cancellationToken = default)
{
return DeleteDashboardsIDOwnersIDAsyncWithHttpInfo(userID, dashboardID, zapTraceSpan, cancellationToken);
}
///
/// Remove an owner from a dashboard
///
/// Thrown when fails to make API call
/// The ID of the owner to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of ApiResponse
public async System.Threading.Tasks.Task> DeleteDashboardsIDOwnersIDAsyncWithHttpInfo(
string userID, string dashboardID, string zapTraceSpan = null,
CancellationToken cancellationToken = default)
{
// make the HTTP request
var localVarResponse =
await DeleteDashboardsIDOwnersIDAsyncWithIRestResponse(userID, dashboardID, zapTraceSpan,
cancellationToken).ConfigureAwait(false);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDOwnersID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.Select(h => (h.Name, h.Value)),
null);
}
///
/// Remove an owner from a dashboard
///
/// Thrown when fails to make API call
/// The ID of the owner to remove.
/// The dashboard ID.
/// OpenTracing span context (optional)
/// Cancellation token
/// Task of RestResponse
public async System.Threading.Tasks.Task DeleteDashboardsIDOwnersIDAsyncWithIRestResponse(
string userID, string dashboardID, string zapTraceSpan = null,
CancellationToken cancellationToken = default)
{
// verify the required parameter 'userID' is set
if (userID == null)
{
throw new ApiException(400,
"Missing required parameter 'userID' when calling DashboardsService->DeleteDashboardsIDOwnersID");
}
// verify the required parameter 'dashboardID' is set
if (dashboardID == null)
{
throw new ApiException(400,
"Missing required parameter 'dashboardID' when calling DashboardsService->DeleteDashboardsIDOwnersID");
}
var localVarPath = "/api/v2/dashboards/{dashboardID}/owners/{userID}";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (userID != null)
{
localVarPathParams.Add("userID", Configuration.ApiClient.ParameterToString(userID)); // path parameter
}
if (dashboardID != null)
{
localVarPathParams.Add("dashboardID",
Configuration.ApiClient.ParameterToString(dashboardID)); // path parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)await Configuration.ApiClient.CallApiAsync(localVarPath,
Method.Delete, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType, cancellationToken).ConfigureAwait(false);
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("DeleteDashboardsIDOwnersID", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// List all dashboards
///
/// Thrown when fails to make API call
/// OpenTracing span context (optional)
/// (optional)
/// (optional, default to 20)
/// (optional, default to false)
/// A user identifier. Returns only dashboards where this user has the `owner` role. (optional)
/// The column to sort by. (optional)
/// A list of dashboard identifiers. Returns only the listed dashboards. If both `id` and `owner` are specified, only `id` is used. (optional)
/// The identifier of the organization. (optional)
/// The name of the organization. (optional)
/// Dashboards
public Dashboards GetDashboards(string zapTraceSpan = null, int? offset = null, int? limit = null,
bool? descending = null, string owner = null, string sortBy = null, List id = null,
string orgID = null, string org = null)
{
var localVarResponse =
GetDashboardsWithHttpInfo(zapTraceSpan, offset, limit, descending, owner, sortBy, id, orgID, org);
return localVarResponse.Data;
}
///
/// List all dashboards
///
/// Thrown when fails to make API call
/// OpenTracing span context (optional)
/// (optional)
/// (optional, default to 20)
/// (optional, default to false)
/// A user identifier. Returns only dashboards where this user has the `owner` role. (optional)
/// The column to sort by. (optional)
/// A list of dashboard identifiers. Returns only the listed dashboards. If both `id` and `owner` are specified, only `id` is used. (optional)
/// The identifier of the organization. (optional)
/// The name of the organization. (optional)
/// ApiResponse of Dashboards
public ApiResponse GetDashboardsWithHttpInfo(string zapTraceSpan = null, int? offset = null,
int? limit = null, bool? descending = null, string owner = null, string sortBy = null,
List id = null, string orgID = null, string org = null)
{
var localVarPath = "/api/v2/dashboards";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (offset != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "offset", offset)); // query parameter
}
if (limit != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "limit", limit)); // query parameter
}
if (descending != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "descending", @descending)); // query parameter
}
if (owner != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "owner", owner)); // query parameter
}
if (sortBy != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "sortBy", sortBy)); // query parameter
}
if (id != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("multi", "id", id)); // query parameter
}
if (orgID != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "orgID", orgID)); // query parameter
}
if (org != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "org", org)); // query parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)Configuration.ApiClient.CallApi(localVarPath,
Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("GetDashboards", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.Select(h => (h.Name, h.Value)),
(Dashboards)Configuration.ApiClient.Deserialize(localVarResponse, typeof(Dashboards)));
}
///
/// List all dashboards
///
/// Thrown when fails to make API call
/// OpenTracing span context (optional)
/// (optional)
/// (optional, default to 20)
/// (optional, default to false)
/// A user identifier. Returns only dashboards where this user has the `owner` role. (optional)
/// The column to sort by. (optional)
/// A list of dashboard identifiers. Returns only the listed dashboards. If both `id` and `owner` are specified, only `id` is used. (optional)
/// The identifier of the organization. (optional)
/// The name of the organization. (optional)
/// Cancellation token
/// ApiResponse of Dashboards
public async System.Threading.Tasks.Task GetDashboardsWithIRestResponseAsync(
string zapTraceSpan = null, int? offset = null, int? limit = null, bool? descending = null,
string owner = null, string sortBy = null, List id = null, string orgID = null, string org = null,
CancellationToken cancellationToken = default)
{
var localVarPath = "/api/v2/dashboards";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (offset != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "offset", offset)); // query parameter
}
if (limit != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "limit", limit)); // query parameter
}
if (descending != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "descending", @descending)); // query parameter
}
if (owner != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "owner", owner)); // query parameter
}
if (sortBy != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "sortBy", sortBy)); // query parameter
}
if (id != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("multi", "id", id)); // query parameter
}
if (orgID != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "orgID", orgID)); // query parameter
}
if (org != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "org", org)); // query parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)await Configuration.ApiClient.CallApiAsync(localVarPath,
Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType, cancellationToken).ConfigureAwait(false);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("GetDashboards", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// List all dashboards
///
/// Thrown when fails to make API call
/// OpenTracing span context (optional)
/// (optional)
/// (optional, default to 20)
/// (optional, default to false)
/// A user identifier. Returns only dashboards where this user has the `owner` role. (optional)
/// The column to sort by. (optional)
/// A list of dashboard identifiers. Returns only the listed dashboards. If both `id` and `owner` are specified, only `id` is used. (optional)
/// The identifier of the organization. (optional)
/// The name of the organization. (optional)
/// ApiResponse of Dashboards
public RestResponse GetDashboardsWithIRestResponse(string zapTraceSpan = null, int? offset = null,
int? limit = null, bool? descending = null, string owner = null, string sortBy = null,
List id = null, string orgID = null, string org = null)
{
var localVarPath = "/api/v2/dashboards";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (offset != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "offset", offset)); // query parameter
}
if (limit != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "limit", limit)); // query parameter
}
if (descending != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "descending", @descending)); // query parameter
}
if (owner != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "owner", owner)); // query parameter
}
if (sortBy != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "sortBy", sortBy)); // query parameter
}
if (id != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("multi", "id", id)); // query parameter
}
if (orgID != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "orgID", orgID)); // query parameter
}
if (org != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "org", org)); // query parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
// make the HTTP request
var localVarResponse = (RestResponse)Configuration.ApiClient.CallApi(localVarPath,
Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("GetDashboards", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return localVarResponse;
}
///
/// List all dashboards
///
/// Thrown when fails to make API call
/// OpenTracing span context (optional)
/// (optional)
/// (optional, default to 20)
/// (optional, default to false)
/// A user identifier. Returns only dashboards where this user has the `owner` role. (optional)
/// The column to sort by. (optional)
/// A list of dashboard identifiers. Returns only the listed dashboards. If both `id` and `owner` are specified, only `id` is used. (optional)
/// The identifier of the organization. (optional)
/// The name of the organization. (optional)
/// ApiResponse of Dashboards
public RestRequest GetDashboardsWithRestRequest(string zapTraceSpan = null, int? offset = null,
int? limit = null, bool? descending = null, string owner = null, string sortBy = null,
List id = null, string orgID = null, string org = null)
{
var localVarPath = "/api/v2/dashboards";
var localVarPathParams = new Dictionary();
var localVarQueryParams = new List>();
var localVarHeaderParams = new Dictionary(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary();
var localVarFileParams = new Dictionary();
object localVarPostBody = null;
// to determine the Content-Type header
var localVarHttpContentTypes = new string[]
{
};
var localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
if (offset != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "offset", offset)); // query parameter
}
if (limit != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "limit", limit)); // query parameter
}
if (descending != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "descending", @descending)); // query parameter
}
if (owner != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "owner", owner)); // query parameter
}
if (sortBy != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "sortBy", sortBy)); // query parameter
}
if (id != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("multi", "id", id)); // query parameter
}
if (orgID != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "orgID", orgID)); // query parameter
}
if (org != null)
{
localVarQueryParams.AddRange(
Configuration.ApiClient.ParameterToKeyValuePairs("", "org", org)); // query parameter
}
if (zapTraceSpan != null)
{
localVarHeaderParams.Add("Zap-Trace-Span",
Configuration.ApiClient.ParameterToString(zapTraceSpan)); // header parameter
}
// to determine the Accept header
var localVarHttpHeaderAccepts = new string[]
{
"application/json"
};
var localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null && !localVarHeaderParams.ContainsKey("Accept"))
{
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
}
return Configuration.ApiClient.PrepareRequest(localVarPath,
Method.Get, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams,
localVarFileParams,
localVarPathParams, localVarHttpContentType);
}
///
/// List all dashboards
///
/// Thrown when fails to make API call
/// OpenTracing span context (optional)
/// (optional)
/// (optional, default to 20)
/// (optional, default to false)
/// A user identifier. Returns only dashboards where this user has the `owner` role. (optional)
/// The column to sort by. (optional)
/// A list of dashboard identifiers. Returns only the listed dashboards. If both `id` and `owner` are specified, only `id` is used. (optional)
/// The identifier of the organization. (optional)
/// The name of the organization. (optional)
/// Cancellation token
/// Task of Dashboards
public async System.Threading.Tasks.Task GetDashboardsAsync(string zapTraceSpan = null,
int? offset = null, int? limit = null, bool? descending = null, string owner = null, string sortBy = null,
List id = null, string orgID = null, string org = null,
CancellationToken cancellationToken = default)
{
var localVarResponse = await GetDashboardsAsyncWithHttpInfo(zapTraceSpan, offset, limit, descending, owner,
sortBy, id, orgID, org, cancellationToken).ConfigureAwait(false);
return localVarResponse.Data;
}
///
/// List all dashboards
///
/// Thrown when fails to make API call
/// OpenTracing span context (optional)
/// (optional)
/// (optional, default to 20)
/// (optional, default to false)
/// A user identifier. Returns only dashboards where this user has the `owner` role. (optional)
/// The column to sort by. (optional)
/// A list of dashboard identifiers. Returns only the listed dashboards. If both `id` and `owner` are specified, only `id` is used. (optional)
/// The identifier of the organization. (optional)
/// The name of the organization. (optional)
/// Cancellation token
/// Task of ApiResponse (Dashboards)
public async System.Threading.Tasks.Task> GetDashboardsAsyncWithHttpInfo(
string zapTraceSpan = null, int? offset = null, int? limit = null, bool? descending = null,
string owner = null, string sortBy = null, List id = null, string orgID = null, string org = null,
CancellationToken cancellationToken = default)
{
// make the HTTP request
var localVarResponse = await GetDashboardsAsyncWithIRestResponse(zapTraceSpan, offset, limit, descending,
owner, sortBy, id, orgID, org, cancellationToken).ConfigureAwait(false);
var localVarStatusCode = (int)localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
var exception = ExceptionFactory("GetDashboards", localVarResponse);
if (exception != null)
{
throw exception;
}
}
return new ApiResponse(localVarStatusCode,
localVarResponse.Headers.Select(h => (h.Name, h.Value)),
(Dashboards)Configuration.ApiClient.Deserialize(localVarResponse, typeof(Dashboards)));
}
///
/// List all dashboards
///
/// Thrown when fails to make API call
/// OpenTracing span context (optional)
/// (optional)
/// (optional, default to 20)
/// (optional, default to false)
/// A user identifier. Returns only dashboards where this user has the `owner` role. (optional)
/// The column to sort by. (optional)
/// A list of dashboard identifiers. Returns only the listed dashboards. If both `id` and `owner` are specified, only `id` is used. (optional)
/// The identifier of the organization. (optional)
/// The name of the organization. (optional)
/// Cancellation token
/// Task of RestResponse (Dashboards)
public async System.Threading.Tasks.Task GetDashboardsAsyncWithIRestResponse(
string zapTraceSpan = null, int? offset = null, int? limit = null, bool? descending = null,
string owner = null, string sortBy = null, List | | | | | | | |