使用 Amazon Backup API 创建报告计划 - Amazon Backup
Amazon Web Services 文档中描述的 Amazon Web Services 服务或功能可能因区域而异。要查看适用于中国区域的差异,请参阅 中国的 Amazon Web Services 服务入门 (PDF)

本文属于机器翻译版本。若本译文内容与英语原文存在差异,则一律以英文原文为准。

使用 Amazon Backup API 创建报告计划

您也可以通过编程方式使用报告计划。

有两种类型的报告。一种是作业报告,它显示过去 24 小时内完成的作业以及所有活动作业。另一种报告是合规性报告。合规性报告可以监控资源级别或有效的不同控件。创建报告时,您可以选择要创建的报告类型。

对于单账户、单区域报告,请使用以下语法调用 CreateReportPlan

{ "ReportPlanName": "string", "ReportPlanDescription": "string", "ReportSetting": { "ReportTemplate": enum, // Can be RESOURCE_COMPLIANCE_REPORT, CONTROL_COMPLIANCE_REPORT, BACKUP_JOB_REPORT, COPY_JOB_REPORT, or RESTORE_JOB_REPORT. Only include "ReportCoverageList" if your report is a COMPLIANCE_REPORT. "ReportDeliveryChannel": { "S3BucketName": "string", "S3KeyPrefix": "string", "Formats": [ enum ] // Optional. Can be either CSV, JSON, or both. Default is CSV if left blank. }, "ReportPlanTags": { "string" : "string" // Optional. }, "IdempotencyToken": "string" }

当您使用报告计划的唯一名称调用 DescribeReportPlan 时,Amazon Backup API 会响应并返回以下信息。

{ "ReportPlanArn": "string", "ReportPlanName": "string", "ReportPlanDescription": "string", "ReportSetting": { "ReportTemplate": enum, }, "ReportDeliveryChannel": { "S3BucketName": "string", "S3KeyPrefix": "string", "Formats": [ enum ] }, "DeploymentStatus": enum "CreationTime": timestamp, "LastAttemptExecutionTime": timestamp, "LastSuccessfulExecutionTime": timestamp }

对于多账户、多区域报告,请使用以下语法调用 CreateReportPlan

{ "IdempotencyToken": "string", "ReportDeliveryChannel": { "Formats": [ "string" ], *//Organization report only support CSV file* "S3BucketName": "string", "S3KeyPrefix": "string" }, "ReportPlanDescription": "string", "ReportPlanName": "string", "ReportPlanTags": { "string" : "string" }, "ReportSetting": { "Accounts": [ "string" ] "OrganizationUnits": [ "string" ], "Regions": ["string"], "FrameworkArns": [ "string" ], "NumberOfFrameworks": number, "ReportTemplate": "string" } }

当您使用报告计划的唯一名称调用 DescribeReportPlan 时,对于多账户、多区域计划,Amazon Backup API 会响应并返回以下信息:

{ "ReportPlan": { "CreationTime": number, "DeploymentStatus": "string", "LastAttemptedExecutionTime": number, "LastSuccessfulExecutionTime": number, "ReportDeliveryChannel": { "Formats": [ "string" ], "S3BucketName": "string", "S3KeyPrefix": "string" }, "ReportPlanArn": "string", "ReportPlanDescription": "string", "ReportPlanName": "string", "ReportSetting": { "Accounts":[ "string" ], "OrganizationUnits":[ "string" ], "Regions": [ "string" ], "FrameworkArns": [ "string" ], "NumberOfFrameworks": number, "ReportTemplate": "string" } } }