Skip to main content

Dashboard tenant modification

Thread needs solution
Beginner
Posts: 5
Comments: 9

I would like to configure my tenant dahsboard with this command : 

$Dashboard = Invoke-RestMethod -Method "PUT" -Uri "${baseUrl}bc/api/monitoring/api/1/playbook/call/client_collections_storage?id=$DashboardID" -Headers $headers2 -ContentType "application/json" -Body "{`"value`":`"{\`"name\`":\`"Dashboard\`",\`"editMode\`":true,\`"widgets\`":[{\`"name\`":\`"protected_resources_table_widget\`",\`"template\`":\`"table\`",\`"redirect\`":{\`"alias\`":\`"to_devices\`"},\`"query\`":[{\`"params\`":{\`"playbook\`":\`"protected_resource_table\`",\`"from\`":\`"`$last_1_days\`"},\`"model\`":\`"Table\`",\`"}],\`"queryOptions\`":{\`"limit\`":10,\`"namespace\`":\`"protected_resource_table\`",\`"columns\`":[{\`"name\`":\`"resource_name\`",\`"visible\`":true,\`"disabled\`":true,\`"grouping\`":true,\`"redirect\`":{\`"alias\`":\`"to_devices_by_resource_redirect_id\`"}},{\`"name\`":\`"plan_name\`",\`"visible\`":true,\`"disabled\`":true,\`"grouping\`":true},{\`"name\`":\`"resource_type\`"},{\`"name\`":\`"target\`",\`"grouping\`":true},{\`"name\`":\`"resource_status\`",\`"visible\`":true,\`"grouping\`":true},{\`"name\`":\`"resource_state\`",\`"visible\`":false,\`"grouping\`":true},{\`"name\`":\`"last_finish_ts\`"},{\`"name\`":\`"last_successful_finish_ts\`",\`"visible\`":true},{\`"name\`":\`"total_runs\`",\`"visible\`":false,\`"unsortable\`":true},{\`"name\`":\`"successful_runs\`",\`"visible\`":false,\`"unsortable\`":true},{\`"name\`":\`"bc_redirect_id\`",\`"baseField\`":true,\`"disabled\`":true},{\`"name\`":\`"resource_redirect_id\`",\`"baseField\`":true,\`"disabled\`":true}],\`"sort\`":null,\`"filters\`":[{\`"entity\`":\`"report_available_periods\`",\`"name\`":\`"range\`",\`"template\`":\`"am-custom-range-filter\`",\`"multiselect\`":false,\`"itemKey\`":\`"range\`",\`"queryKey\`":\`"from\`",\`"remoteOnly\`":true},{\`"entity\`":\`"all_protected_resource_statuses\`",\`"name\`":\`"resource_status\`",\`"multiselect\`":true,\`"addAll\`":\`"all\`",\`"itemKey\`":\`"resource_status\`"},{\`"entity\`":\`"all_resource_states\`",\`"name\`":\`"resource_state\`",\`"multiselect\`":true,\`"addAll\`":\`"all\`",\`"itemKey\`":\`"resource_state\`"},{\`"entity\`":\`"all_resource_types\`",\`"name\`":\`"resource_type\`",\`"multiselect\`":true,\`"addAll\`":\`"all\`",\`"itemKey\`":\`"resource_type\`"}],\`"group\`":{\`"name\`":null}},\`"id\`":\`"c841a494-a4b9-4e4a-892b-4fd1675fac5b\`",\`"index\`":0}],\`"version\`":13,\`"collection\`":\`"dashboards\`",\`"timeRange\`":null,\`"units\`":null}`",`"collection`":`"dashboards`"}"

 

It worked few minutes ago but now I having this error when I'm trying to run it again : Invoke-RestMethod : {"error": "Internal server error", "server_datetime": 1617798161}.

 

Can you tell me which paramater is wrong on my request or what is wrong with my request ? 

 

0 Users found this helpful
Forum Member
Posts: 3
Comments: 82

Sorry, that API is not a public API, I don't have any available documentation to share with you.