update_dashboard
async
¶
update_dashboard(
arn: DashboardArn,
name: DashboardName,
*,
config_overrides: Optional[AsyncBCMDashboardsClientConfig] = None,
description: Optional[Description] = None,
widgets: Optional[WidgetList] = None,
) -> UpdateDashboardResponse
Updates an existing dashboard's properties, including its name, description, and widget configurations.
Parameters:
-
arn(DashboardArn) –The ARN of the dashboard to update.
-
name(DashboardName) –The new name for the dashboard.
-
description(Optional[Description], default:None) –The new description for the dashboard.
-
widgets(Optional[WidgetList], default:None) –The updated array of widget configurations for the dashboard. Replaces all existing widgets.
Raises:
-
AccessDeniedException–You do not have sufficient permissions to perform this action. Verify your IAM permissions and any resource policies.
-
InternalServerException–An internal error occurred while processing the request. Retry your request. If the problem persists, contact Amazon Web Services Support.
-
ResourceNotFoundException–The specified resource (dashboard, policy, or widget) was not found. Verify the ARN and try again.
-
ThrottlingException–The request was denied due to request throttling. Reduce the frequency of requests and use exponential backoff.
-
ValidationException–The input parameters do not satisfy the requirements. Check the error message for specific validation details.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
Updating a dashboard
>>> await client.update_dashboard(arn='arn:aws:bcm-dashboards::123456789012:dashboard/abcd1234-ab12-12ab-1ab2-abcd1234efgh', name='cost-dashboards-updated', description='Dashboard for tracking costs version 2', widgets=[{'title': 'Monthly Cost Trend', 'width': 4, 'height': 7, 'horizontalOffset': 2, 'configs': [{'displayConfig': {'graph': {'costTrend': {'visualType': 'LINE'}}}, 'queryParameters': {'costAndUsage': {'granularity': 'MONTHLY', 'groupBy': [{'key': 'SERVICE', 'type': 'DIMENSION'}], 'metrics': ['UnblendedCost'], 'timeRange': {'endTime': {'type': 'RELATIVE', 'value': 'now'}, 'startTime': {'type': 'RELATIVE', 'value': '-3M'}}}}}]}])
Source code in docs_src/capo_bcm_dashboards/_services/async_bcm_dashboards.py
985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 | |