Compute
Elastic Cloud Server
Huawei Cloud Flexus
Bare Metal Server
Auto Scaling
Image Management Service
Dedicated Host
FunctionGraph
Cloud Phone Host
Huawei Cloud EulerOS
Networking
Virtual Private Cloud
Elastic IP
Elastic Load Balance
NAT Gateway
Direct Connect
Virtual Private Network
VPC Endpoint
Cloud Connect
Enterprise Router
Enterprise Switch
Global Accelerator
Management & Governance
Cloud Eye
Identity and Access Management
Cloud Trace Service
Resource Formation Service
Tag Management Service
Log Tank Service
Config
OneAccess
Resource Access Manager
Simple Message Notification
Application Performance Management
Application Operations Management
Organizations
Optimization Advisor
IAM Identity Center
Cloud Operations Center
Resource Governance Center
Migration
Server Migration Service
Object Storage Migration Service
Cloud Data Migration
Migration Center
Cloud Ecosystem
KooGallery
Partner Center
User Support
My Account
Billing Center
Cost Center
Resource Center
Enterprise Management
Service Tickets
HUAWEI CLOUD (International) FAQs
ICP Filing
Support Plans
My Credentials
Customer Operation Capabilities
Partner Support Plans
Professional Services
Analytics
MapReduce Service
Data Lake Insight
CloudTable Service
Cloud Search Service
Data Lake Visualization
Data Ingestion Service
GaussDB(DWS)
DataArts Studio
Data Lake Factory
DataArts Lake Formation
IoT
IoT Device Access
Others
Product Pricing Details
System Permissions
Console Quick Start
Common FAQs
Instructions for Associating with a HUAWEI CLOUD Partner
Message Center
Security & Compliance
Security Technologies and Applications
Web Application Firewall
Host Security Service
Cloud Firewall
SecMaster
Anti-DDoS Service
Data Encryption Workshop
Database Security Service
Cloud Bastion Host
Data Security Center
Cloud Certificate Manager
Edge Security
Managed Threat Detection
Blockchain
Blockchain Service
Web3 Node Engine Service
Media Services
Media Processing Center
Video On Demand
Live
SparkRTC
MetaStudio
Storage
Object Storage Service
Elastic Volume Service
Cloud Backup and Recovery
Storage Disaster Recovery Service
Scalable File Service Turbo
Scalable File Service
Volume Backup Service
Cloud Server Backup Service
Data Express Service
Dedicated Distributed Storage Service
Containers
Cloud Container Engine
SoftWare Repository for Container
Application Service Mesh
Ubiquitous Cloud Native Service
Cloud Container Instance
Databases
Relational Database Service
Document Database Service
Data Admin Service
Data Replication Service
GeminiDB
GaussDB
Distributed Database Middleware
Database and Application Migration UGO
TaurusDB
Middleware
Distributed Cache Service
API Gateway
Distributed Message Service for Kafka
Distributed Message Service for RabbitMQ
Distributed Message Service for RocketMQ
Cloud Service Engine
Multi-Site High Availability Service
EventGrid
Dedicated Cloud
Dedicated Computing Cluster
Business Applications
Workspace
ROMA Connect
Message & SMS
Domain Name Service
Edge Data Center Management
Meeting
AI
Face Recognition Service
Graph Engine Service
Content Moderation
Image Recognition
Optical Character Recognition
ModelArts
ImageSearch
Conversational Bot Service
Speech Interaction Service
Huawei HiLens
Video Intelligent Analysis Service
Developer Tools
SDK Developer Guide
API Request Signing Guide
Terraform
Koo Command Line Interface
Content Delivery & Edge Computing
Content Delivery Network
Intelligent EdgeFabric
CloudPond
Intelligent EdgeCloud
Solutions
SAP Cloud
High Performance Computing
Developer Services
ServiceStage
CodeArts
CodeArts PerfTest
CodeArts Req
CodeArts Pipeline
CodeArts Build
CodeArts Deploy
CodeArts Artifact
CodeArts TestPlan
CodeArts Check
CodeArts Repo
Cloud Application Engine
MacroVerse aPaaS
KooMessage
KooPhone
KooDrive
Help Center/ Cloud Eye/ API Reference/ API V3/ Agent maintenance tasks/ Creating Agent maintenance Tasks in Batches

Creating Agent maintenance Tasks in Batches

Updated on 2024-12-26 GMT+08:00

Function

This API is used to create Agent maintenance tasks in batches.

Constraints

This API is not supported at the following regions: LA-Buenos Aires1, and LA-Lima1.

Debugging

You can debug this API through automatic authentication in API Explorer or use the SDK sample code generated by API Explorer.

URI

POST /v3/{project_id}/agent-invocations/batch-create

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Specifies the project ID.

Minimum: 1

Maximum: 64

Regex Pattern: ^[a-z0-9]+$

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

Content-Type

Yes

String

Specifies the MIME type of a request body. The default type is application/json; charset=UTF-8.

Default: application/json; charset=UTF-8

Minimum: 1

Maximum: 64

X-Auth-Token

Yes

String

Specifies the user token. It is a response to the API for obtaining a user token. This API is the only one that does not require authentication. The value of X-Subject-Token in the response header is the token.

Minimum: 1

Maximum: 16384

Table 3 Request body parameters

Parameter

Mandatory

Type

Description

instance_ids

No

Array of strings

Specifies the server ID list. (This parameter is mandatory when the task type is INSTALL or UPDATE.)

Array Length: 1 - 100

invocation_type

Yes

String

Specifies the task type, which can be INSTALL, UPDATE, ROLLBACK, or RETRY.

Enumeration values:

  • INSTALL

  • UPDATE

  • ROLLBACK

  • RETRY

invocation_target

No

String

Specifies the task object. Only telescope is supported.

Default: telescope

Enumeration values:

  • telescope

invocation_ids

No

Array of strings

Specifies the task ID list. This parameter is mandatory when the task type is ROLLBACK or RETRY.

Array Length: 1 - 100

version_type

No

String

Specifies the version the Agent will be upgraded to. The value can be BASIC_VERSION or ADVANCE_VERSION.

Enumeration values:

  • BASIC_VERSION

  • ADVANCE_VERSION

origin

No

String

Specifies the source that calls the Agent maintenance task APIs. CES indicates the Cloud Eye console, APICOM_BMS indicates Bare Metal Server (BMS), and ADMIN_SERVER indicates the O&M platform.

Enumeration values:

  • CES

  • APICOM_BMS

  • ADMIN_SERVER

version

No

String

Version Number

Minimum: 0

Maximum: 64

Regex Pattern: ^([0-9A-Za-z]|_|-|\.)+$

Response Parameters

Status code: 201

Table 4 Response body parameters

Parameter

Type

Description

invocations

Array of BatchCreateInvocationInfo objects

Specifies the information list of the created task.

Array Length: 0 - 100

Table 5 BatchCreateInvocationInfo

Parameter

Type

Description

instance_id

String

Specifies the server ID.

Regex Pattern: ^[a-zA-Z0-9-]{1,64}$

ret_status

String

Specifies the task result. The value can be successful or error.

Enumeration values:

  • successful

  • error

error_msg

String

Specifies the error message.

Minimum: 1

Maximum: 128

invocation_id

String

Specifies the task ID.

Regex Pattern: ^[a-zA-Z0-9-]{1,64}$

error_code

String

Specifies the error code.

Regex Pattern: ^(invocationmgr\.[0-9]{4})$

Status code: 400

Table 6 Response body parameters

Parameter

Type

Description

error_code

String

Specifies the error code.

Regex Pattern: ^(taskmgr\.[0-9]{4})$

error_msg

String

Specifies the error message.

Minimum: 1

Maximum: 256

Status code: 401

Table 7 Response body parameters

Parameter

Type

Description

error_code

String

Specifies the error code.

Regex Pattern: ^(taskmgr\.[0-9]{4})$

error_msg

String

Specifies the error message.

Minimum: 1

Maximum: 256

Status code: 403

Table 8 Response body parameters

Parameter

Type

Description

error_code

String

Specifies the error code.

Regex Pattern: ^(taskmgr\.[0-9]{4})$

error_msg

String

Specifies the error message.

Minimum: 1

Maximum: 256

Status code: 500

Table 9 Response body parameters

Parameter

Type

Description

error_code

String

Specifies the error code.

Regex Pattern: ^(taskmgr\.[0-9]{4})$

error_msg

String

Specifies the error message.

Minimum: 1

Maximum: 256

Example Requests

{
  "instance_ids" : [ "instancexxx001", "instancexxx002" ],
  "invocation_type" : "INSTALL",
  "invocation_target" : "telescope"
}

Example Responses

Status code: 201

Created

[ {
  "instance_id" : "instancexxx001",
  "ret_status" : "successful"
}, {
  "instance_id" : "instancexxx002",
  "ret_status" : "error",
  "error_msg" : "do not meet the installation conditions"
} ]

Status Codes

Status Code

Description

201

Created

400

Bad Request

401

Unauthorized

403

Forbidden

500

Internal Server Error

Error Codes

See Error Codes.

We use cookies to improve our site and your experience. By continuing to browse our site you accept our cookie policy. Find out more

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback