ダッシュボードリスト
Dash が新機能を発表!インシデントマネジメント、Continuous Profiler など多数の機能が追加されました! Dash イベントで発表された新機能!

Dashboard Lists

Interact with your dashboard lists through the API to make it easier to organize, find, and share all of your dashboards with your team and organization.

Add Items to a Dashboard List

POST https://api.datadoghq.comhttps://api.datadoghq.eu/api/v2/dashboard/lists/manual/{dashboard_list_id}/dashboards

概要

Add dashboards to an existing dashboard list.

引数

パスパラメーター

名前

種類

説明

dashboard_list_id [required]

integer

ID of the dashboard list to add items to.

リクエスト

Body Data (required)

Dashboards to add to the dashboard list.

Expand All

Field

種類

説明

dashboards

[object]

List of dashboards to add the dashboard list.

id [required]

string

ID of the dashboard.

type [required]

enum

The type of the dashboard. Allowed enum values: custom_timeboard,custom_screenboard,integration_screenboard,integration_timeboard,host_timeboard

{
  "dashboards": [
    {
      "id": "q5j-nti-fv6",
      "type": "string"
    }
  ]
}

応答

OK

Response containing a list of added dashboards.

Expand All

Field

種類

説明

added_dashboards_to_list

[object]

List of dashboards added to the dashboard list.

id [required]

string

ID of the dashboard.

type [required]

enum

The type of the dashboard. Allowed enum values: custom_timeboard,custom_screenboard,integration_screenboard,integration_timeboard,host_timeboard

{
  "added_dashboards_to_list": [
    {
      "id": "q5j-nti-fv6",
      "type": "string"
    }
  ]
}

Bad Request

API error response.

Expand All

Field

種類

説明

errors [required]

[string]

A list of errors.

{
  "errors": [
    "Bad Request"
  ]
}

Forbidden

API error response.

Expand All

Field

種類

説明

errors [required]

[string]

A list of errors.

{
  "errors": [
    "Bad Request"
  ]
}

Not Found

API error response.

Expand All

Field

種類

説明

errors [required]

[string]

A list of errors.

{
  "errors": [
    "Bad Request"
  ]
}

コード例


                                        # Path parameters
export dashboard_list_id="CHANGE_ME"
# Curl command curl -X POST "https://api.datadoghq.com"https://api.datadoghq.eu/api/v2/dashboard/lists/manual/${dashboard_list_id}/dashboards" \ -H "Content-Type: application/json" \ -H "DD-API-KEY: ${DD_CLIENT_API_KEY}" \ -H "DD-APPLICATION-KEY: ${DD_CLIENT_APP_KEY}" \ -d @- << EOF { "dashboards": [ { "id": "q5j-nti-fv6", "type": null } ] } EOF
package main

import (
    "context"
    "fmt"
    "os"
    datadog "github.com/DataDog/datadog-api-client-go/api/v2/datadog"
)

func main() {
    ctx := context.WithValue(
        context.Background(),
        datadog.ContextAPIKeys,
        map[string]datadog.APIKey{
            "apiKeyAuth": {
                Key: os.Getenv("DD_CLIENT_API_KEY"),
            },
            "appKeyAuth": {
                Key: os.Getenv("DD_CLIENT_APP_KEY"),
            },
        },
    )

    dashboardListId := 987 // int64 | ID of the dashboard list to add items to.
    body := datadog.DashboardListAddItemsRequest{Dashboards: []DashboardListItemRequest{datadog.DashboardListItemRequest{Id: "Id_example", Type: datadog.DashboardType{}})} // DashboardListAddItemsRequest | Dashboards to add to the dashboard list.

    configuration := datadog.NewConfiguration()
    api_client := datadog.NewAPIClient(configuration)
    resp, r, err := api_client.DashboardListsApi.CreateDashboardListItems(ctx, dashboardListId).Body(body).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `DashboardListsApi.CreateDashboardListItems``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `CreateDashboardListItems`: DashboardListAddItemsResponse
    fmt.Fprintf(os.Stdout, "Response from `DashboardListsApi.CreateDashboardListItems`: %v\n", resp)
}
// Import classes:
import com.datadog.api.v2.client.ApiClient;
import com.datadog.api.v2.client.ApiException;
import com.datadog.api.v2.client.Configuration;
import com.datadog.api.v2.client.auth.*;
import com.datadog.api.v2.client.model.*;
import com.datadog.api.v2.client.api.DashboardListsApi;

public class Example {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        // Configure the Datadog site to send API calls to
        HashMap<String, String> serverVariables = new HashMap<String, String>();
        String site = System.getenv("DD_SITE");
        if (site != null) {
            serverVariables.put("site", site);
            defaultClient.setServerVariables(serverVariables);
        }
        // Configure API key authorization: 
        HashMap<String, String> secrets = new HashMap<String, String>();
        secrets.put("apiKeyAuth", System.getenv("DD_CLIENT_API_KEY"));
        secrets.put("appKeyAuth", System.getenv("DD_CLIENT_APP_KEY"));
        defaultClient.configureApiKeys(secrets);

        DashboardListsApi apiInstance = new DashboardListsApi(defaultClient);
        Long dashboardListId = 56L; // Long | ID of the dashboard list to add items to.
        DashboardListAddItemsRequest body = new DashboardListAddItemsRequest(); // DashboardListAddItemsRequest | Dashboards to add to the dashboard list.
        try {
            DashboardListAddItemsResponse result = api.createDashboardListItems(dashboardListId)
                .body(body)
                .execute();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling DashboardListsApi#createDashboardListItems");
            System.err.println("Status code: " + e.getCode());
            System.err.println("Reason: " + e.getResponseBody());
            System.err.println("Response headers: " + e.getResponseHeaders());
            e.printStackTrace();
        }
    }
}
from datadog import initialize, api

options = {
    'api_key': '<DATADOG_API_KEY>',
    'app_key': '<DATADOG_APPLICATION_KEY>'
}

initialize(**options)

list_id = 4741
dashboards = [
    {
        'type': 'custom_screenboard',
        'id': 'rys-xwq-geh'
    },
    {
        'type': 'custom_timeboard',
        'id': 'qts-q2k-yq6'
    },
    {
        'type': 'integration_screenboard',
        'id': '87'
    },
    {
        'type': 'integration_timeboard',
        'id': '23'
    },
    {
        'type': 'host_timeboard',
        'id': '3245468'
    }
]

api.DashboardList.v2.add_items(list_id, dashboards=dashboards)
require 'rubygems'
require 'dogapi'

api_key = '<DATADOG_API_KEY>'
app_key = '<DATADOG_APPLICATION_KEY>'

dog = Dogapi::Client.new(api_key, app_key)

list_id = 4741
dashboards = [
    {
        "type" => "custom_screenboard",
        "id" => "rys-xwq-geh"
    },
    {
        "type" => "custom_timeboard",
        "id" => "qts-q2k-yq6"
    },
    {
        "type" => "integration_screenboard",
        "id" => "87"
    },
    {
        "type" => "integration_timeboard",
        "id" => "23"
    },
    {
        "type" => "host_timeboard",
        "id" => "3245468"
    }
]

result = dog.v2.add_items_to_dashboard_list(list_id, dashboards)

Delete items from a dashboard list

DELETE https://api.datadoghq.comhttps://api.datadoghq.eu/api/v2/dashboard/lists/manual/{dashboard_list_id}/dashboards

概要

Delete dashboards from an existing dashboard list.

引数

パスパラメーター

名前

種類

説明

dashboard_list_id [required]

integer

ID of the dashboard list to delete items from.

リクエスト

Body Data (required)

Dashboards to delete from the dashboard list.

Expand All

Field

種類

説明

dashboards

[object]

List of dashboards to delete from the dashboard list.

id [required]

string

ID of the dashboard.

type [required]

enum

The type of the dashboard. Allowed enum values: custom_timeboard,custom_screenboard,integration_screenboard,integration_timeboard,host_timeboard

{
  "dashboards": [
    {
      "id": "q5j-nti-fv6",
      "type": "string"
    }
  ]
}

応答

OK

Response containing a list of deleted dashboards.

Expand All

Field

種類

説明

deleted_dashboards_from_list

[object]

List of dashboards deleted from the dashboard list.

id [required]

string

ID of the dashboard.

type [required]

enum

The type of the dashboard. Allowed enum values: custom_timeboard,custom_screenboard,integration_screenboard,integration_timeboard,host_timeboard

{
  "deleted_dashboards_from_list": [
    {
      "id": "q5j-nti-fv6",
      "type": "string"
    }
  ]
}

Bad Request

API error response.

Expand All

Field

種類

説明

errors [required]

[string]

A list of errors.

{
  "errors": [
    "Bad Request"
  ]
}

Forbidden

API error response.

Expand All

Field

種類

説明

errors [required]

[string]

A list of errors.

{
  "errors": [
    "Bad Request"
  ]
}

Not Found

API error response.

Expand All

Field

種類

説明

errors [required]

[string]

A list of errors.

{
  "errors": [
    "Bad Request"
  ]
}

コード例


                                        # Path parameters
export dashboard_list_id="CHANGE_ME"
# Curl command curl -X DELETE "https://api.datadoghq.com"https://api.datadoghq.eu/api/v2/dashboard/lists/manual/${dashboard_list_id}/dashboards" \ -H "Content-Type: application/json" \ -H "DD-API-KEY: ${DD_CLIENT_API_KEY}" \ -H "DD-APPLICATION-KEY: ${DD_CLIENT_APP_KEY}" \ -d @- << EOF { "dashboards": [ { "id": "q5j-nti-fv6", "type": null } ] } EOF
package main

import (
    "context"
    "fmt"
    "os"
    datadog "github.com/DataDog/datadog-api-client-go/api/v2/datadog"
)

func main() {
    ctx := context.WithValue(
        context.Background(),
        datadog.ContextAPIKeys,
        map[string]datadog.APIKey{
            "apiKeyAuth": {
                Key: os.Getenv("DD_CLIENT_API_KEY"),
            },
            "appKeyAuth": {
                Key: os.Getenv("DD_CLIENT_APP_KEY"),
            },
        },
    )

    dashboardListId := 987 // int64 | ID of the dashboard list to delete items from.
    body := datadog.DashboardListDeleteItemsRequest{Dashboards: []DashboardListItemRequest{datadog.DashboardListItemRequest{Id: "Id_example", Type: datadog.DashboardType{}})} // DashboardListDeleteItemsRequest | Dashboards to delete from the dashboard list.

    configuration := datadog.NewConfiguration()
    api_client := datadog.NewAPIClient(configuration)
    resp, r, err := api_client.DashboardListsApi.DeleteDashboardListItems(ctx, dashboardListId).Body(body).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `DashboardListsApi.DeleteDashboardListItems``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `DeleteDashboardListItems`: DashboardListDeleteItemsResponse
    fmt.Fprintf(os.Stdout, "Response from `DashboardListsApi.DeleteDashboardListItems`: %v\n", resp)
}
// Import classes:
import com.datadog.api.v2.client.ApiClient;
import com.datadog.api.v2.client.ApiException;
import com.datadog.api.v2.client.Configuration;
import com.datadog.api.v2.client.auth.*;
import com.datadog.api.v2.client.model.*;
import com.datadog.api.v2.client.api.DashboardListsApi;

public class Example {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        // Configure the Datadog site to send API calls to
        HashMap<String, String> serverVariables = new HashMap<String, String>();
        String site = System.getenv("DD_SITE");
        if (site != null) {
            serverVariables.put("site", site);
            defaultClient.setServerVariables(serverVariables);
        }
        // Configure API key authorization: 
        HashMap<String, String> secrets = new HashMap<String, String>();
        secrets.put("apiKeyAuth", System.getenv("DD_CLIENT_API_KEY"));
        secrets.put("appKeyAuth", System.getenv("DD_CLIENT_APP_KEY"));
        defaultClient.configureApiKeys(secrets);

        DashboardListsApi apiInstance = new DashboardListsApi(defaultClient);
        Long dashboardListId = 56L; // Long | ID of the dashboard list to delete items from.
        DashboardListDeleteItemsRequest body = new DashboardListDeleteItemsRequest(); // DashboardListDeleteItemsRequest | Dashboards to delete from the dashboard list.
        try {
            DashboardListDeleteItemsResponse result = api.deleteDashboardListItems(dashboardListId)
                .body(body)
                .execute();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling DashboardListsApi#deleteDashboardListItems");
            System.err.println("Status code: " + e.getCode());
            System.err.println("Reason: " + e.getResponseBody());
            System.err.println("Response headers: " + e.getResponseHeaders());
            e.printStackTrace();
        }
    }
}
from datadog import initialize, api

options = {
    'api_key': '<DATADOG_API_KEY>',
    'app_key': '<DATADOG_APPLICATION_KEY>'
}

initialize(**options)

list_id = 4741
dashboards = [
    {
        'type': 'custom_screenboard',
        'id': 'rys-xwq-geh'
    },
    {
        'type': 'custom_timeboard',
        'id': 'qts-q2k-yq6'
    },
    {
        'type': 'integration_screenboard',
        'id': '87'
    },
    {
        'type': 'integration_timeboard',
        'id': '23'
    },
    {
        'type': 'host_timeboard',
        'id': '3245468'
    }
]

api.DashboardList.v2.delete_items(list_id, dashboards=dashboards)
require 'rubygems'
require 'dogapi'

api_key = '<DATADOG_API_KEY>'
app_key = '<DATADOG_APPLICATION_KEY>'

dog = Dogapi::Client.new(api_key, app_key)

list_id = 4741
dashboards = [
    {
        "type" => "custom_screenboard",
        "id" => "rys-xwq-geh"
    },
    {
        "type" => "custom_timeboard",
        "id" => "qts-q2k-yq6"
    },
    {
        "type" => "integration_screenboard",
        "id" => "87"
    },
    {
        "type" => "integration_timeboard",
        "id" => "23"
    },
    {
        "type" => "host_timeboard",
        "id" => "3245468"
    }
]

result = dog.v2.delete_items_from_dashboard_list(list_id, dashboards)

Get a Dashboard List

GET https://api.datadoghq.comhttps://api.datadoghq.eu/api/v2/dashboard/lists/manual/{dashboard_list_id}/dashboards

概要

Fetch the dashboard list’s dashboard definitions.

引数

パスパラメーター

名前

種類

説明

dashboard_list_id [required]

integer

ID of the dashboard list to get items from.

応答

OK

Dashboards within a list.

Expand All

Field

種類

説明

dashboards [required]

[object]

List of dashboards in the dashboard list.

author

object

Creator of the object.

email

string

Email of the creator.

handle

string

Handle of the creator.

name

string

Name of the creator.

created

date-time

Date of creation of the dashboard.

icon

string

URL to the icon of the dashboard.

id [required]

string

ID of the dashboard.

is_favorite

boolean

Whether or not the dashboard is in the favorites.

is_read_only

boolean

Whether or not the dashboard is read only.

is_shared

boolean

Whether the dashboard is publicly shared or not.

modified

date-time

Date of last edition of the dashboard.

popularity

int32

Popularity of the dashboard.

title

string

Title of the dashboard.

type [required]

enum

The type of the dashboard. Allowed enum values: custom_timeboard,custom_screenboard,integration_screenboard,integration_timeboard,host_timeboard

url

string

URL path to the dashboard.

total

int64

Number of dashboards in the dashboard list.

{
  "dashboards": [
    {
      "author": {
        "email": "string",
        "handle": "string",
        "name": "string"
      },
      "created": "2019-09-19T10:00:00.000Z",
      "icon": "string",
      "id": "q5j-nti-fv6",
      "is_favorite": false,
      "is_read_only": false,
      "is_shared": false,
      "modified": "2019-09-19T10:00:00.000Z",
      "popularity": "integer",
      "title": "string",
      "type": "string",
      "url": "string"
    }
  ],
  "total": "integer"
}

Forbidden

API error response.

Expand All

Field

種類

説明

errors [required]

[string]

A list of errors.

{
  "errors": [
    "Bad Request"
  ]
}

Not Found

API error response.

Expand All

Field

種類

説明

errors [required]

[string]

A list of errors.

{
  "errors": [
    "Bad Request"
  ]
}

コード例


                                        # Path parameters
export dashboard_list_id="CHANGE_ME"
# Curl command curl -X GET "https://api.datadoghq.com"https://api.datadoghq.eu/api/v2/dashboard/lists/manual/${dashboard_list_id}/dashboards" \ -H "Content-Type: application/json" \ -H "DD-API-KEY: ${DD_CLIENT_API_KEY}" \ -H "DD-APPLICATION-KEY: ${DD_CLIENT_APP_KEY}"
package main

import (
    "context"
    "fmt"
    "os"
    datadog "github.com/DataDog/datadog-api-client-go/api/v2/datadog"
)

func main() {
    ctx := context.WithValue(
        context.Background(),
        datadog.ContextAPIKeys,
        map[string]datadog.APIKey{
            "apiKeyAuth": {
                Key: os.Getenv("DD_CLIENT_API_KEY"),
            },
            "appKeyAuth": {
                Key: os.Getenv("DD_CLIENT_APP_KEY"),
            },
        },
    )

    dashboardListId := 987 // int64 | ID of the dashboard list to get items from.

    configuration := datadog.NewConfiguration()
    api_client := datadog.NewAPIClient(configuration)
    resp, r, err := api_client.DashboardListsApi.GetDashboardListItems(ctx, dashboardListId).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `DashboardListsApi.GetDashboardListItems``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `GetDashboardListItems`: DashboardListItems
    fmt.Fprintf(os.Stdout, "Response from `DashboardListsApi.GetDashboardListItems`: %v\n", resp)
}
// Import classes:
import com.datadog.api.v2.client.ApiClient;
import com.datadog.api.v2.client.ApiException;
import com.datadog.api.v2.client.Configuration;
import com.datadog.api.v2.client.auth.*;
import com.datadog.api.v2.client.model.*;
import com.datadog.api.v2.client.api.DashboardListsApi;

public class Example {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        // Configure the Datadog site to send API calls to
        HashMap<String, String> serverVariables = new HashMap<String, String>();
        String site = System.getenv("DD_SITE");
        if (site != null) {
            serverVariables.put("site", site);
            defaultClient.setServerVariables(serverVariables);
        }
        // Configure API key authorization: 
        HashMap<String, String> secrets = new HashMap<String, String>();
        secrets.put("apiKeyAuth", System.getenv("DD_CLIENT_API_KEY"));
        secrets.put("appKeyAuth", System.getenv("DD_CLIENT_APP_KEY"));
        defaultClient.configureApiKeys(secrets);

        DashboardListsApi apiInstance = new DashboardListsApi(defaultClient);
        Long dashboardListId = 56L; // Long | ID of the dashboard list to get items from.
        try {
            DashboardListItems result = api.getDashboardListItems(dashboardListId)
                .execute();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling DashboardListsApi#getDashboardListItems");
            System.err.println("Status code: " + e.getCode());
            System.err.println("Reason: " + e.getResponseBody());
            System.err.println("Response headers: " + e.getResponseHeaders());
            e.printStackTrace();
        }
    }
}
from datadog import initialize, api

options = {
    'api_key': '<DATADOG_API_KEY>',
    'app_key': '<DATADOG_APPLICATION_KEY>'
}

initialize(**options)

api.DashboardList.v2.get_items(4741)
require 'rubygems'
require 'dogapi'

api_key = '<DATADOG_API_KEY>'
app_key = '<DATADOG_APPLICATION_KEY>'

dog = Dogapi::Client.new(api_key, app_key)

result = dog.v2.get_items_of_dashboard_list(4741)

Update items of a dashboard list

PUT https://api.datadoghq.comhttps://api.datadoghq.eu/api/v2/dashboard/lists/manual/{dashboard_list_id}/dashboards

概要

Update dashboards of an existing dashboard list.

引数

パスパラメーター

名前

種類

説明

dashboard_list_id [required]

integer

ID of the dashboard list to update items from.

リクエスト

Body Data (required)

New dashboards of the dashboard list.

Expand All

Field

種類

説明

dashboards

[object]

List of dashboards to update the dashboard list to.

id [required]

string

ID of the dashboard.

type [required]

enum

The type of the dashboard. Allowed enum values: custom_timeboard,custom_screenboard,integration_screenboard,integration_timeboard,host_timeboard

{
  "dashboards": [
    {
      "id": "q5j-nti-fv6",
      "type": "string"
    }
  ]
}

応答

OK

Response containing a list of updated dashboards.

Expand All

Field

種類

説明

dashboards

[object]

List of dashboards in the dashboard list.

id [required]

string

ID of the dashboard.

type [required]

enum

The type of the dashboard. Allowed enum values: custom_timeboard,custom_screenboard,integration_screenboard,integration_timeboard,host_timeboard

{
  "dashboards": [
    {
      "id": "q5j-nti-fv6",
      "type": "string"
    }
  ]
}

Bad Request

API error response.

Expand All

Field

種類

説明

errors [required]

[string]

A list of errors.

{
  "errors": [
    "Bad Request"
  ]
}

Forbidden

API error response.

Expand All

Field

種類

説明

errors [required]

[string]

A list of errors.

{
  "errors": [
    "Bad Request"
  ]
}

Not Found

API error response.

Expand All

Field

種類

説明

errors [required]

[string]

A list of errors.

{
  "errors": [
    "Bad Request"
  ]
}

コード例


                                        # Path parameters
export dashboard_list_id="CHANGE_ME"
# Curl command curl -X PUT "https://api.datadoghq.com"https://api.datadoghq.eu/api/v2/dashboard/lists/manual/${dashboard_list_id}/dashboards" \ -H "Content-Type: application/json" \ -H "DD-API-KEY: ${DD_CLIENT_API_KEY}" \ -H "DD-APPLICATION-KEY: ${DD_CLIENT_APP_KEY}" \ -d @- << EOF { "dashboards": [ { "id": "q5j-nti-fv6", "type": null } ] } EOF
package main

import (
    "context"
    "fmt"
    "os"
    datadog "github.com/DataDog/datadog-api-client-go/api/v2/datadog"
)

func main() {
    ctx := context.WithValue(
        context.Background(),
        datadog.ContextAPIKeys,
        map[string]datadog.APIKey{
            "apiKeyAuth": {
                Key: os.Getenv("DD_CLIENT_API_KEY"),
            },
            "appKeyAuth": {
                Key: os.Getenv("DD_CLIENT_APP_KEY"),
            },
        },
    )

    dashboardListId := 987 // int64 | ID of the dashboard list to update items from.
    body := datadog.DashboardListUpdateItemsRequest{Dashboards: []DashboardListItemRequest{)} // DashboardListUpdateItemsRequest | New dashboards of the dashboard list.

    configuration := datadog.NewConfiguration()
    api_client := datadog.NewAPIClient(configuration)
    resp, r, err := api_client.DashboardListsApi.UpdateDashboardListItems(ctx, dashboardListId).Body(body).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `DashboardListsApi.UpdateDashboardListItems``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `UpdateDashboardListItems`: DashboardListUpdateItemsResponse
    fmt.Fprintf(os.Stdout, "Response from `DashboardListsApi.UpdateDashboardListItems`: %v\n", resp)
}
// Import classes:
import com.datadog.api.v2.client.ApiClient;
import com.datadog.api.v2.client.ApiException;
import com.datadog.api.v2.client.Configuration;
import com.datadog.api.v2.client.auth.*;
import com.datadog.api.v2.client.model.*;
import com.datadog.api.v2.client.api.DashboardListsApi;

public class Example {
    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        // Configure the Datadog site to send API calls to
        HashMap<String, String> serverVariables = new HashMap<String, String>();
        String site = System.getenv("DD_SITE");
        if (site != null) {
            serverVariables.put("site", site);
            defaultClient.setServerVariables(serverVariables);
        }
        // Configure API key authorization: 
        HashMap<String, String> secrets = new HashMap<String, String>();
        secrets.put("apiKeyAuth", System.getenv("DD_CLIENT_API_KEY"));
        secrets.put("appKeyAuth", System.getenv("DD_CLIENT_APP_KEY"));
        defaultClient.configureApiKeys(secrets);

        DashboardListsApi apiInstance = new DashboardListsApi(defaultClient);
        Long dashboardListId = 56L; // Long | ID of the dashboard list to update items from.
        DashboardListUpdateItemsRequest body = new DashboardListUpdateItemsRequest(); // DashboardListUpdateItemsRequest | New dashboards of the dashboard list.
        try {
            DashboardListUpdateItemsResponse result = api.updateDashboardListItems(dashboardListId)
                .body(body)
                .execute();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling DashboardListsApi#updateDashboardListItems");
            System.err.println("Status code: " + e.getCode());
            System.err.println("Reason: " + e.getResponseBody());
            System.err.println("Response headers: " + e.getResponseHeaders());
            e.printStackTrace();
        }
    }
}