get_metric
¶
get_metric(
app_id: AppId,
metric_id: MetricId,
scope: RequestScope,
*,
config_overrides: Optional[AppMonetizationClientConfig] = None,
stage: Optional[PlanStage] = None,
) -> GetMetricResponse
Returns the details of a metric.
Parameters:
-
app_id(AppId) –The ID of the app.
-
metric_id(MetricId) –The ID of the metric to retrieve.
-
stage(Optional[PlanStage], default:None) –The offering stage to read the metric from: DRAFT (the latest draft) or PUBLISHED (the offering customers see). Absent: PUBLISHED when scope=live, DRAFT when scope=sandbox.
-
scope(RequestScope) –Required. The environment: live or sandbox. live reads the published offering by default; sandbox reads the app's draft.
Raises:
-
AccessDeniedException–The caller does not have sufficient permission to perform this action.
-
InternalServerException–An unexpected error occurred while processing the request.
-
ResourceNotFoundException–The referenced resource does not exist.
-
ThrottlingException–The request was denied due to request throttling.
-
ValidationException–The request failed input validation.
-
UnknownServiceError–The service returned an error code this client does not model.