GetReportTemplate
Retrieves the details of a compliance report template.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
config:GetReportTemplate |
get |
*ReportTemplate
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| ReportTemplateId |
string |
Yes |
The ID of the report template. |
crt-xxx |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| ReportTemplate |
object |
The report template. |
|
| ReportTemplateId |
string |
The ID of the report template. |
crt-xxx |
| ReportTemplateName |
string |
The name of the report template. |
test-name |
| SubscriptionFrequency |
string |
The subscription frequency of the report. If this field is not empty, it specifies a Quartz-format cron expression that triggers subscription notifications. Format: seconds minutes hours day-of-month month day-of-week. Common cron expression examples:
Where:
Note
The trigger time is in UTC+8. You can adjust the cron expression based on your time zone. Note
The system attempts to trigger notifications according to the cron expression, but delays may occur depending on the report generation status. The cron expression limits notifications to a maximum of once per day for the same template. Note
You can also use numbers instead of MON for Monday. Note that in the Quartz framework: 1 represents Sunday; 2 represents Monday; 3 represents Tuesday; 4 represents Wednesday; 5 represents Thursday; 6 represents Friday; 7 represents Saturday. |
0 0 0 * * ? |
| ReportTemplateDescription |
string |
The description of the report template. |
test-description |
| ReportGranularity |
string |
The aggregation granularity of the report. |
AllInOne |
| ReportFileFormats |
string |
The file formats of the report. |
excel |
| ReportLanguage |
string |
The language of the report. Valid values: zh-CN and en-US. Default value: en-US. |
en-US |
| ReportScope |
array<object> |
The report scope array, which is used to specify the scope of rules included in the audit report. An OR logic, which is an additive logic, is applied between each ReportScope in the array. Note
For example, if the array size is 2, the first ReportScope specifies the rule In cr-1, and the second ReportScope specifies the rule In cr-2, the rule scope for this report includes cr-1 and cr-2. |
|
|
object |
The report scope. |
||
| Key |
string |
The key of the report scope. Valid values:
|
RuleId |
| Value |
string |
The value of the report scope. Multiple items of the same type, such as multiple rule IDs, can be separated by commas (,). |
cr-1,cr-2 |
| MatchType |
string |
The matching logic. Valid value: In. |
In |
| RequestId |
string |
The ID of the request. |
A7A0FFF8-0B44-40C6-8BBF-3A185EFDF3F7 |
Examples
Success response
JSON format
{
"ReportTemplate": {
"ReportTemplateId": "crt-xxx",
"ReportTemplateName": "test-name",
"SubscriptionFrequency": "0 0 0 * * ?",
"ReportTemplateDescription": "test-description",
"ReportGranularity": "AllInOne",
"ReportFileFormats": "excel",
"ReportLanguage": "en-US",
"ReportScope": [
{
"Key": "RuleId",
"Value": "cr-1,cr-2",
"MatchType": "In"
}
]
},
"RequestId": "A7A0FFF8-0B44-40C6-8BBF-3A185EFDF3F7"
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | ReportTemplateNotExist | Report template does not exist or invalid. | Report template does not exist, please check the input ReportTemplateId |
| 503 | ServiceUnavailable | The request has failed due to a temporary failure of the server. | The request has failed due to a temporary failure of the server. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.