All Products
Search
Document Center

Resource Orchestration Service:GetDiagnostic

Last Updated:Sep 12, 2024

Obtains the diagnosis details based on a specified diagnostic report ID.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
ros:GetDiagnosticlist
  • All Resources
    *
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
ReportIdstringNo

The ID of the diagnostic report.

dr-d540def087714890****

Response parameters

ParameterTypeDescriptionExample
object
Codestring

The error code returned.

Forbidden
DiagnosticProductstring

The name of the diagnostic item.

ros
HttpStatusCodeinteger

The HTTP status code returned.

200
Messagestring

The error message returned.

The specified parameter ReportId is invalid, Can not find diagnostic report dr-5f6135782f104b0f****.
Recommendsobject

The suggestion for the diagnosis.

{'RosActionMessages': {'Reason': 'Fail to delete stack (fc966920-450a-456b-983c-deeaec8e****), as deletion protection is enabled.', 'Recommend': ''}}
ReportIdstring

The ID of the diagnostic report.

dr-cc80afc48c8741e9****
RequestIdstring

The request ID.

96A24844-9603-5E79-BDF4-EFD412FC5D4C
Statusstring

The diagnosis status. Valid values:

  • Running: The diagnosis is in progress.
  • Complete: The diagnosis is complete.
  • Failed: The diagnosis failed.
Running
StatusReasonstring

The reason for the diagnosis status.

Complete
Successstring

Indicates whether the request was successful. Valid values:

  • true
  • false
true
DiagnosticKeystring

The keyword in the diagnosis.

0938F60C-A2CA-5A2E-9983-03EB1E6D7AE2
DiagnosticTimestring

The time when the diagnosis was performed.

2023-03-27T03:32:03Z
HttpCodestring

The HTTP status code

200
DiagnosticResultobject

The diagnosis result.

StackMessagesobject

The stack information.

RosActionMessagesobject

The information about Resource Orchestration Service (ROS) calling.

FailedResourcesobject

The resources that failed to be diagnosed.

Examples

Sample success responses

JSONformat

{
  "Code": "Forbidden",
  "DiagnosticProduct": "ros",
  "HttpStatusCode": 200,
  "Message": "The specified parameter ReportId is invalid, Can not find diagnostic report dr-5f6135782f104b0f****.",
  "Recommends": {
    "test": "test",
    "test2": 1
  },
  "ReportId": "dr-cc80afc48c8741e9****",
  "RequestId": "96A24844-9603-5E79-BDF4-EFD412FC5D4C",
  "Status": "Running",
  "StatusReason": "Complete",
  "Success": "true",
  "DiagnosticKey": "0938F60C-A2CA-5A2E-9983-03EB1E6D7AE2",
  "DiagnosticTime": "2023-03-27T03:32:03Z",
  "HttpCode": "200",
  "DiagnosticResult": {
    "StackMessages": {
      "test": "test",
      "test2": 1
    },
    "RosActionMessages": {
      "test": "test",
      "test2": 1
    },
    "FailedResources": {
      "test": "test",
      "test2": 1
    }
  }
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
No change history