Skip to main content
System Management/System Settings/Custom Attribute
POSTCustom AttributeSince 4.7.0SynchronousAuth Required

Batch Update Resource Custom Attributes

Batch Update Resource Custom Attributes

Execution Availability

Try It Out

Submit a mock request using the current auth context and example-driven inputs.

Path Parameters

Request Inputs

Path Parameters

  • resourceUuidStringRequired

    Resource UUID of the configuration

Body Fields

  • resourceConfigsListRequired

    The list of resource custom attributes

  • systemTagsList

    System tags

  • userTagsList

    User tags

Responses

200 OK

On success, this API returns the following response structure.

  • successbooleanRequired

    操作是否成功。

  • inventoriesListRequired

    See inventories for details

    • valueStringRequired

      字段值。

    • nameStringRequired

      资源名称。

    • effectiveConfigsListRequired

      See effectiveConfigs for details

      • uuidStringRequired

        The UUID of the resource, uniquely identifying the resource

      • resourceUuidStringRequired

        The resource UUID associated with the configuration

      • resourceTypeStringRequired

        The resource type associated with the configuration

      • nameStringRequired

        Configuration name

      • descriptionStringRequired

        The detailed description of the configuration

      • categoryStringRequired

        Configuration category

      • valueStringRequired

        The configuration value

      • createDateTimestampRequired

        Creation time

      • lastOpDateTimestampRequired

        Last modification time

  • errorErrorCodeRequired

    The error code. If not null, the operation failed. This field is null when the operation succeeds. See error for details

    • codeStringRequired

      The error code number. A globally unique identifier for the error, for example, SYS.1000, HOST.1001

    • descriptionStringRequired

      A brief description of the error

    • detailsStringRequired

      The detailed error information

    • elaborationStringRequired

      Reserved field. Default is null

    • opaqueLinkedHashMapRequired

      Reserved field. Default is null

    • causeErrorCodeRequired

      The root error that caused the current error. If no root error exists, this field is null

Endpoint

POST/zstack/v1/resource-configurations/{resourceUuid}/resource-configs/actions

/zstack/v1/resource-configurations/{resourceUuid}/resource-configs/actions

Operation ID

UpdateResourceConfigs

Permalink

Request Example

curl -X POST 'http://{host}/zstack/v1/resource-configurations/{resourceUuid}/resource-configs/actions' -H 'Authorization: OAuth {sessionUuid}' -H 'Content-Type: application/json;charset=UTF-8' -d '{"resourceConfigs":["<resourceConfigs>"],"systemTags":["<systemTags>"],"userTags":["<userTags>"]}'

Response Example

200
{ "inventories": [ { "value": "10", "effectiveConfigs": [ { "uuid": "9d7aeba3ff604f46b419475c0ade1538", "resourceUuid": "378c6a50c9ee415baa4688fcd19f023a", "resourceType": "ClusterVO", "name": "cpu.overProvisioning.ratio", "category": "host", "value": "10", "createDate": "Nov 14, 2017 2:20:57 PM", "lastOpDate": "Nov 14, 2017 2:20:57 PM" } ], "name": "cpu.overProvisioning.ratio" } ] }

Change History

This API has no change history records yet.

View all change history