Create Resource Warning

Create Resource Warning

Create a new Resource Warning

Request
URI
POST
https://{api_host}/v1/resource-warnings
COPY
Request Body
ResourceWarningCreationSpec of type(s) application/json
Required

Show optional properties

{
    "resourceId": "string",
    "resourceName": "string",
    "resourceType": "HOST, CLUSTER, DOMAIN",
    "warningType": "SKIPPED_RESOURCE, VALIDATION, CONFIGURATION, OTHER",
    "severity": "MINOR, MAJOR",
    "occurredAtTimestamp": 0,
    "localizableWarningPack": {
        "warningCode": "string",
        "localBundle": "string",
        "vipComponent": "string",
        "defaultMessage": "string"
    }
}
{
    "resourceId": "string",
    "resourceName": "string",
    "resourceType": "HOST, CLUSTER, DOMAIN",
    "warningType": "SKIPPED_RESOURCE, VALIDATION, CONFIGURATION, OTHER",
    "severity": "MINOR, MAJOR",
    "occurredAtTimestamp": 0,
    "context": {
        "context": "string"
    },
    "localizableWarningPack": {
        "warningCode": "string",
        "localBundle": "string",
        "vipComponent": "string",
        "defaultMessage": "string",
        "arguments": [
            "string"
        ],
        "referenceToken": "string"
    },
    "associatedTask": {
        "taskId": "string",
        "subTaskId": "string"
    }
}
string
resourceId
Required

ID of the resource to which this warning will be associated

string
resourceName
Required

Name of the resource to which this warning will be associated

string
resourceType
Required

Type of the resource to which this warning will be associated

Possible values are : HOST, CLUSTER, DOMAIN,
string
warningType
Required

The type of the warning

Possible values are : CONFIGURATION, OTHER, SKIPPED_RESOURCE, VALIDATION,
string
severity
Required

The severity of the warning

Possible values are : MAJOR, MINOR,
integer As int64 As int64
occurredAtTimestamp
Required

The Unix epoch timestamp of when the warning occurred

object
context
Optional

Optional additional context information to be associated to the warning

object
localizableWarningPack
Required

Localization warning pack containing all required data to provide localized warning messages

object
associatedTask
Optional

Task association for a resource warning. Indicates in which task the resource warning occurred

Responses
201

Created

Returns ResourceWarning of type(s) application/json
"ResourceWarning Object"
string
id
Optional

ID of the resource warning

string
warningCode
Optional

The warning code

string
message
Optional

The localized warning message

string
remediationMessage
Optional

The localized remediation warning message

string
referenceToken
Optional

A reference token correlating the warning with the relevant detailed logs. Should be sent to the service provider when reporting issues

string
resourceId
Optional

ID of the associated resource

string
resourceType
Optional

Type of the associated resource

string
resourceName
Optional

Name of the associated resource

string
warningType
Optional

Type of the warning

string
severity
Optional

Severity of the warning

string
occurredAtTimestamp
Required

Timestamp when the warning occurred

object
context
Optional

Optional additional context information in a key value form

object
associatedTask
Optional

Task association for a resource warning. Indicates in which task the resource warning occurred


400

Bad Request

Returns Error of type(s) application/json
"Error Object"
string
errorCode
Optional

The minor error code

string
errorType
Optional

The error type

array of string
arguments
Optional

The arguments used to localize the message, Can be used by scripts to automate the error processing.

object
context
Optional

The error context (e.g. the component where it occurred).

string
message
Optional

The localized error message

string
remediationMessage
Optional

The localized remediation error message

array of object
causes
Optional

The underlying cause exceptions.

array of Error
nestedErrors
Optional

The nested errors when the error is a composite one

string
referenceToken
Optional

A reference token correlating the error with the relevant detailed error logs. Should be sent to the service provider when reporting issues.


500

Internal Server Error

Returns Error of type(s) application/json
"Error Object"
string
errorCode
Optional

The minor error code

string
errorType
Optional

The error type

array of string
arguments
Optional

The arguments used to localize the message, Can be used by scripts to automate the error processing.

object
context
Optional

The error context (e.g. the component where it occurred).

string
message
Optional

The localized error message

string
remediationMessage
Optional

The localized remediation error message

array of object
causes
Optional

The underlying cause exceptions.

array of Error
nestedErrors
Optional

The nested errors when the error is a composite one

string
referenceToken
Optional

A reference token correlating the error with the relevant detailed error logs. Should be sent to the service provider when reporting issues.


Code Samples
COPY
                    curl -X POST -H 'Authorization: <value>' -H 'Content-Type: application/json' -d '{"localizableWarningPack:"object","occurredAtTimestamp:"integer","resourceId:"string","resourceName:"string","resourceType:"string","severity:"string","warningType:"string"}' https://{api_host}/v1/resource-warnings