Skip to content

Latest commit

 

History

History
208 lines (145 loc) · 6.54 KB

File metadata and controls

208 lines (145 loc) · 6.54 KB

Dashboard Actions

Details on the various actions that can be performed on the Dashboard resource, including the expected parameters and the potential responses.

Contents

Delete

Deletes a dashboard

result = client.dashboard.delete(dashboardId=my_dashboard_id)

print(result)

Authentication

The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.Organization, all.User, dashboard.*, or dashboard.delete.

Available Parameters

Name Type Required Description Default Example
dashboardId string Y ID of the associated dashboard 575ece2b7ae143cd83dc4a9b
losantdomain string N Domain scope of request (rarely needed) example.com

Successful Responses

Code Type Description
200 Success If dashboard was successfully deleted

Error Responses

Code Type Description
400 Error Error if malformed request
404 Error Error if dashboard was not found

Get

Retrieves information on a dashboard

result = client.dashboard.get(dashboardId=my_dashboard_id)

print(result)

Authentication

No api access token is required to call this action.

Available Parameters

Name Type Required Description Default Example
dashboardId string Y ID of the associated dashboard 575ece2b7ae143cd83dc4a9b
password string N Password for password-protected dashboards myPassword
losantdomain string N Domain scope of request (rarely needed) example.com

Successful Responses

Code Type Description
200 Dashboard Dashboard information

Error Responses

Code Type Description
400 Error Error if malformed request
404 Error Error if dashboard was not found

Patch

Updates information about a dashboard

result = client.dashboard.patch(
    dashboardId=my_dashboard_id,
    dashboard=my_dashboard)

print(result)

Authentication

The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.Organization, all.User, dashboard.*, or dashboard.patch.

Available Parameters

Name Type Required Description Default Example
dashboardId string Y ID of the associated dashboard 575ece2b7ae143cd83dc4a9b
dashboard Dashboard Patch Y Object containing new dashboard properties Dashboard Patch Example
losantdomain string N Domain scope of request (rarely needed) example.com

Successful Responses

Code Type Description
200 Dashboard Update dashboard information

Error Responses

Code Type Description
400 Error Error if malformed request
404 Error Error if dashboard was not found

Send Report

Sends a snapshot of a dashboard

result = client.dashboard.send_report(
    dashboardId=my_dashboard_id,
    reportConfig=my_report_config)

print(result)

Authentication

The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.Organization, all.User, dashboard.*, or dashboard.sendReport.

Available Parameters

Name Type Required Description Default Example
dashboardId string Y ID of the associated dashboard 575ece2b7ae143cd83dc4a9b
reportConfig Dashboard Send Report Y Object containing report options Dashboard Send Report Example
losantdomain string N Domain scope of request (rarely needed) example.com

Successful Responses

Code Type Description
202 Job Enqueued API Result If dashboard report was enqueued to be sent

Error Responses

Code Type Description
400 Error Error if malformed request
404 Error Error if dashboard was not found

Validate Context

Validates a context object against the dashboard's context configuration

result = client.dashboard.validate_context(
    dashboardId=my_dashboard_id,
    ctx=my_ctx)

print(result)

Authentication

No api access token is required to call this action.

Available Parameters

Name Type Required Description Default Example
dashboardId string Y ID of the associated dashboard 575ece2b7ae143cd83dc4a9b
ctx Dashboard Context Instance Y The context object to validate Dashboard Context Instance Example
password string N Password for password-protected dashboards myPassword
duration string N Duration of data to fetch in milliseconds 3600000
resolution string N Resolution in milliseconds 60000
end string N End timestamp of the data, in ms since epoch 1465790400000
losantdomain string N Domain scope of request (rarely needed) example.com

Successful Responses

Code Type Description
200 Validate Context Success If context is valid

Error Responses

Code Type Description
400 Validate Context Error Error if context is invalid
404 Error Error if dashboard or application was not found