华为云用户手册

  • 请求示例 { "scheduled_type" : "FIXED_TIME", "day_interval" : 1, "week_list" : "1,2,7", "month_list" : "1,3,12", "date_list" : "1,2,28,L", "time_zone" : "Asia/Shanghai", "scheduled_date" : "2022-12-23", "scheduled_time" : "09:00:00", "expire_time" : "2022-03-07T10:40:43.858Z" }
  • 请求参数 表2 请求Header参数 参数 是否必选 参数类型 描述 X-Auth-Token 否 String 用户Token。 通过调用 IAM 服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。 表3 请求Body参数 参数 是否必选 参数类型 描述 scheduled_type 否 String 执行周期类型,可选值为: FIXED_TIME:指定时间。 DAY:按天。 WEEK:按周。 MONTH:按月。 day_interval 否 Integer 周期按天时:按x天间隔执行。 week_list 否 String 周期按周时:取值1~7,英文逗号分隔,如1,2,7。 month_list 否 String 周期按月时:取值1~12,英文逗号分隔,如1,3,12。 date_list 否 String 周期按月时:取值1~31及L(代表当月最后一天),英文逗号分隔,如1,2,28,L。 time_zone 否 String 时区。 scheduled_date 否 String 周期指定时间时:表示指定的日期,格式为yyyy-MM-dd。 scheduled_time 否 String 指定的执行时间点,格式为HH:mm:ss。 expire_time 否 String 到期时间。
  • 响应参数 状态码:200 表4 响应Body参数 参数 参数类型 描述 future_executions Array of strings 未来执行的具体时间列表。 time_zone String 时区。 状态码:400 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:401 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:403 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:404 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:405 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:500 表10 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:503 表11 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。
  • 响应示例 状态码:200 成功响应。 { "id" : "sawafaw12414214awfa", "script_id" : "string", "script_name" : "string", "script_task_id" : "string", "resource_id" : "string", "resource_name" : "string", "resource_type" : "string", "start_time" : "2024-12-25T07:10:36.054Z", "end_time" : "2024-12-25T07:10:36.054Z", "status" : "string", "execute_order" : 0, "command_content" : "string", "command_type" : "string", "result_code" : "string", "reason" : "string", "output" : "string" }
  • 响应参数 状态码:200 表3 响应Body参数 参数 参数类型 描述 id String 脚本执行记录ID。 script_id String 脚本ID。 script_name String 脚本名称。 script_task_id String 脚本执行的任务ID。 resource_id String 执行脚本的资源ID,如桌面ID。 resource_name String 执行脚本的资源名称,如桌面名称。 resource_type String 资源类型,如桌面(DESKTOP)。 start_time String 脚本执行开始时间。 end_time String 脚本执行结束时间。 status String 脚本执行状态。 execute_order Integer 执行批次(默认:0,灰度:1,非灰度:2)。 result_code String 错误码。 reason String 原因。 output String 脚本执行的输出。 状态码:400 表4 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:401 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:403 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:404 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:405 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:500 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:503 表10 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。
  • 请求示例 POST /v2/29dfe82ada564ac2b927e1ff036d9a9b/policy-groups { "policy_group" : { "policy_group_id" : "string", "policy_group_name" : "string", "priority" : 55, "description" : "string。", "scope_flag" : 1, "update_time" : "string", "targets" : [ { "target_id" : "string", "target_name" : "string", "target_type" : "string" } ], "policies" : { "peripherals" : { "usb_custom_policy_debug" : "string", "usb_port_redirection" : { "usb_enable" : true, "options" : { "usb_image_enable" : true, "usb_video_enable" : true, "usb_printer_enable" : true, "usb_storage_enable" : false, "wireless_devices_enable" : false, "network_devices_enable" : false, "usb_smart_card_enable" : true, "other_usb_devices_enable" : false, "usb_redirection_customization_policy" : "string", "usb_redirection_mode" : "Common mode" } }, "device_redirection" : { "printer_redirection" : { "printer_enable" : true, "options" : { "mobile_printer_enable" : false, "print_data_compression_mode" : false, "sync_client_default_printer_enable" : true, "universal_printer_driver" : "Default" } }, "session_printer" : { "session_printer_enable" : false, "options" : { "session_printer_customization_policy" : "string" } }, "camera_redirection" : { "video_compress_enable" : true, "options" : { "camera_frame_rate" : 15, "camera_max_width" : 3000, "camera_max_heigth" : 3000, "camera_compression_method" : "H.264" } }, "twain_redirection_enable" : true, "image_compression_level" : "medium", "hid_redirection" : { "hid_redirection_enable" : false, "options" : { "hid_redirection_customization_policy" : "string" } } }, "usb_device_common" : { "pcsc_smart_card_enable" : "Disable", "common_options" : { "remove_smart_card_disconnect_enable" : false } }, "serial_port_redirection" : { "serial_port_enable" : false, "options" : { "auto_connect_enable" : false } }, "parallel_port_redirection" : { "parallel_port_enable" : false }, "driver_interface_redirection" : { "api_redir_driver_list" : "string" } }, "audio" : { "audio_redirection_enable" : true, "play_volume" : "Do Not Set Volume", "play_volume_ratio" : "Do Not Set Volume Ratio", "record_volume" : "100", "record_volume_ratio" : "Do Not Set Volume Ratio", "audio_transmission_mode" : "Reliable Transmission", "play_redirection_enable" : true, "play_classification" : "Music Play", "play_quality" : "Middle", "play_denoising" : "Disable Denoising", "play_agc" : "Disable AGC", "play_crc" : "Disable CRC", "play_device_mode" : "Play Device In Shared Mode", "play_delay_threshold" : "240", "play_amplitude_threshold" : "4096", "play_prefill_data" : "Do Not Prefill Data", "record_redirection_enable" : true, "record_classification" : "Speech Call", "record_quality" : "Middle", "record_denoising" : "-25", "record_agc" : "Disable AGC", "record_crc" : "Disable CRC", "record_device_mode" : "Record Device In Shared Mode", "record_delay_threshold" : "200", "record_amplitude_threshold" : "4096" }, "client" : { "automatic_reconnection_interval" : 5, "session_persistence_time" : 180, "autoclose_monitor_after_locked" : false, "autoclose_monitor_options" : { "autoclose_monitor_wait_time" : 300 }, "forbid_screen_capture" : false, "client_machine_join_domain" : true, "client_type" : { "client_type_limit" : true, "options" : { "sc_type_window" : true, "sc_type_mac" : true, "sc_type_android" : true, "sc_type_linux" : true, "sc_type_h5" : true, "sc_type_ios" : true, "sc_type_harmony_os" : true, "tc_type_all" : true } } }, "display" : { "display_level" : "LEVEL4", "options" : { "display_bandwidth" : 20000, "frame_rate" : 25, "video_frame_rate" : 30, "min_image_cache" : 200, "smoothing_factor" : 60, "lossless_compression_mode" : "Basic Compression", "deep_compression_options" : { "deep_compression_level" : "Compression grade 0" }, "lossy_compression_quality" : 85, "color_enhancement_enable" : false, "quality_bandwidth_first" : "Quality First", "video_bit_rate_options" : { "average_video_bit_rate" : 18000 }, "peak_video_bit_rate" : 18000, "video_quality_options" : { "average_video_quality" : 15, "lowest_video_quality" : 25, "highest_video_quality" : 7 }, "gop_size" : 100, "encoding_preset" : "Preset 1" }, "rendering_acceleration_enable" : false, "rendering_acceleration_options" : { "video_acceleration_enhancement_enable" : true, "video_optimization_enable" : false, "gpu_color_optimization_enable" : false, "video_recognition_threshold" : 10, "frame_rate_statistical_length" : 4, "image_quality_threshold" : 0, "refresh_frequency_threshold" : 3, "exiting_video_area_threshold" : 8, "min_video_width" : 191, "min_video_length" : 191, "single_frame_natural_percentage" : "0.3", "cyclical_natural_images_number" : 2, "non_natural_image_percentage" : "0.85", "non_natural_images_number" : 25 }, "adaptive_bitrate_control_enable" : false, "adaptive_bitrate_control_options" : { "peak_bandwidth_suppression_enable" : false, "expected_average_network_latency" : 160, "network_latency_threshold1" : 160, "network_latency_threshold2" : 300, "min_dynamic_frame_rate" : 17, "min_dynamic_frame_rate_lv1" : 17, "min_dynamic_frame_rate_lv2" : 10, "rtt_threshold" : 20, "min_add_framerate" : 8, "max_add_framerate" : 20, "sub_framerate" : 25, "adaptive_bandwidth_lower_limit" : 500, "adaptive_compression_quality_lower_limit" : 60, "adaptive_compression_quality_upper_limit" : 85, "adaptive_compression_quality_increase_limit" : 5, "adaptive_compression_quality_decrease_limit" : 10, "adaptive_average_quality_lower_limit" : 15, "adaptive_average_quality_upper_limit" : 25, "adaptive_average_quality_increase_limit" : 3, "adaptive_average_quality_decrease_limit" : 1, "adaptive_min_quality_lower_limit" : 25, "adaptive_min_quality_upper_limit" : 30, "adaptive_min_quality_increase_limit" : 3, "adaptive_min_quality_decrease_limit" : 1 }, "video_card_memory_size" : 64, "configuration1_enable" : false, "driver_delegation_mode_enable" : false, "driver_delegation_latency" : 80, "video_latency" : 80, "change_resolution_vm" : false, "application_recognition" : "string", "duplicate_display_enable" : false, "default_mapping_order" : "1,2,3,4", "duplicate_display_mode" : "One-to-One" }, "file_and_clipboard" : { "file_redirection" : { "redirection_mode" : "DISABLED", "options" : { "fluid_control_switch_enable" : false, "fluid_control_options" : { "good_network_latency" : 30, "normal_network_latency" : 70, "poor_network_latency" : 100, "reducing_step" : 20, "slow_increasing_step" : 10, "quick_increasing_step" : 20, "start_speed" : 1024, "test_block_size" : 64, "test_time_gap" : 10000 }, "compression_switch_enable" : false, "compression_switch_options" : { "compression_threshold" : 512, "minimum_compression_rate" : 900 }, "linux_file_size_supported_enable" : true, "linux_file_size_supported_options" : { "linux_file_size_supported_threshold" : 100 }, "linux_root_mount_switch_enable" : true, "linux_root_dir_list" : "\\\\var\\\\log", "linux_file_mount_path" : "\\\\media|\\\\Volumes|\\\\swdb\\\\mnt|\\\\home|\\\\storage|\\\\tmp|\\\\run\\\\media", "linux_fixed_drive_file_system_format" : "string", "linux_removable_drive_file_system_format" : "vfat|ntfs|msdos|fuseblk|sdcardfs|exfat|fuse.fdredir|lifs", "linux_cdrom_drive_file_system_format" : "cd9660|iso9660|udf", "linux_network_drive_file_system_format" : "smbfs|afpfs|cifs", "path_separator" : "|", "fixed_drive_enable" : true, "removable_drive_enable" : true, "cd_rom_drive_enable" : true, "network_drive_enable" : true }, "vm_send_file_client" : true, "redirection_send_file_options" : { "read_write_speed" : 0 } }, "clip_length_limit_flag_c2s" : true, "clip_length_limit_c2s" : 180, "clip_length_limit_flag_s2c" : true, "clip_length_limit_s2c" : 180, "fd_mobile_client_redir_enable" : true, "clipboard_redirection" : "DISABLED", "clipboard_redirection_options" : { "rich_text_redirection_enable" : true, "clipboard_file_redirection_enable" : true } }, "access_control" : { "ip_access_control" : "string" }, "session" : { "vdi" : { "auto_lock_enable" : true, "auto_lock_options" : { "auto_lock_minutes" : 10, "auto_disconnect" : "DISABLED", "options" : { "auto_disconnect_minutes" : 1440 } }, "disconnect_logout_enable" : 0, "disconnect_logout_options" : { "disconnect_logout_minutes" : 10 }, "disconnect_hibernate_enable" : false, "disconnect_hibernate_options" : { "disconnect_hibernate_minutes" : 0 }, "no_operation_hibernate_enable" : false, "no_operation_hibernate_options" : { "no_operation_hibernate_minutes" : 0 } }, "self_help_console" : true, "disconnect_on_lock_flag" : false }, "bandwidth" : { "intelligent_data_transport_flag" : "DISABLE", "total_bandwidth_control_enable" : false, "options" : { "total_bandwidth_control_value" : 30000, "display_bandwidth_percentage_enable" : false, "display_bandwidth_percentage_options" : { "display_bandwidth_percentage_value" : 65 }, "multimedia_bandwidth_percentage_enable" : false, "multimedia_bandwidth_percentage_options" : { "multimedia_bandwidth_percentage_value" : 50 }, "usb_bandwidth_percentage_enable" : false, "usb_bandwidth_percentage_options" : { "usb_bandwidth_percentage_value" : 100 }, "pcsc_bandwidth_percentage_enable" : false, "pcsc_bandwidth_percentage_options" : { "pcsc_bandwidth_percentage_value" : 5 }, "twain_bandwidth_percentage_enable" : false, "twain_bandwidth_percentage_options" : { "twain_bandwidth_percentage_value" : 15 }, "printer_bandwidth_percentage_enable" : false, "printer_bandwidth_percentage_options" : { "printer_bandwidth_percentage_value" : 5 }, "com_bandwidth_percentage_enable" : false, "com_bandwidth_percentage_options" : { "com_bandwidth_percentage_value" : 3 }, "file_redirection_bandwidth_percentage_enable" : false, "file_redirection_bandwidth_percentage_options" : { "file_redirection_bandwidth_percentage_value" : 30 }, "clipboard_bandwidth_percentage_enable" : false, "clipboard_bandwidth_percentage_options" : { "clipboard_bandwidth_percentage_value" : 3 }, "secure_channel_bandwidth_percentage_enable" : false, "secure_channel_bandwidth_percentage_options" : { "secure_channel_bandwidth_percentage_value" : 30 }, "camera_bandwidth_percentage_enable" : false, "camera_bandwidth_percentage_options" : { "camera_bandwidth_percentage_value" : 30 }, "virtual_channel_bandwidth_percentage_enable" : false, "virtual_channel_bandwidth_percentage_options" : { "virtual_channel_bandwidth_percentage_value" : 65 } }, "display_bandwidth_control_enable" : false, "display_bandwidth_control_options" : { "display_bandwidth_control_value" : 20000 }, "multimedia_bandwidth_control_enable" : false, "multimedia_bandwidth_control_options" : { "multimedia_bandwidth_control_value" : 15000 }, "usb_bandwidth_control_enable" : false, "usb_bandwidth_control_options" : { "usb_bandwidth_control_value" : 30000 }, "pcsc_bandwidth_control_enable" : false, "pcsc_bandwidth_control_options" : { "pcsc_bandwidth_control_value" : 2000 }, "twain_bandwidth_control_enable" : false, "twain_bandwidth_control_options" : { "twain_bandwidth_control_value" : 5000 }, "printer_bandwidth_control_enable" : false, "printer_bandwidth_control_options" : { "printer_bandwidth_control_value" : 2000 }, "com_bandwidth_control_enable" : false, "com_bandwidth_control_options" : { "com_bandwidth_control_value" : 1000 }, "file_redirection_bandwidth_control_enable" : false, "file_redirection_bandwidth_control_options" : { "file_redirection_bandwidth_control_value" : 10000 }, "clipboard_bandwidth_control_enable" : false, "clipboard_bandwidth_control_options" : { "clipboard_bandwidth_control_value" : 1000 }, "secure_channel_bandwidth_control_enable" : false, "secure_channel_bandwidth_control_options" : { "secure_channel_bandwidth_control_value" : 10000 }, "camera_bandwidth_control_enable" : false, "camera_bandwidth_control_options" : { "camera_bandwidth_control_value" : 10000 }, "virtual_channel_bandwidth_control_enable" : false, "virtual_channel_bandwidth_control_options" : { "virtual_channel_bandwidth_control_value" : 20000 } }, "virtual_channel" : { "virtual_channel_control_enable" : false, "options" : { "custom_virtual_channel_name" : "string", "virtual_channel_plugin_details" : "string", "third_party_plugin_name" : "string" } }, "watermark" : { "watermark_enable" : false, "options" : { "show_style" : "RANDOM", "color" : "2a2a2a", "font_size" : 30, "opacity_setting" : "12.5", "content_item_count" : 1, "display_format" : "{\"AlignMode\":\"left\",\"DateTimeFormat\":\"DT\",\"DateFormat\":\"yyyy-mm-dd\",\"TimeFormat\":\"hh:mm:ss\",\"RepeatCount\":2,\"RepeatInterval\":10,\"DisplayFormat\":{\"Content1\":\"CustomContent\",\"Interval1\":\"n\",\"Content2\":\"UserName\",\"Interval2\":\"4\",\"Content3\":\"DateTime\"}}", "lean" : -45, "content_customized" : "string", "content_color" : 522857002, "watermark_security_access" : false, "user_extend_info_switch" : false, "user_extend_info" : "string" } }, "keyboard_mouse" : { "mouse_feedback" : "SELFADAPTION", "mouse_simulation_mode" : "ABSOLUTE_POSITION", "external_cursor_feedback" : false, "selfhelp_console_enable" : true, "client_mouse_send_interval" : 30, "windows_client_keyboard_mode" : "GLOBAL", "windows_client_mouse_mode" : "WINDOW", "linux_client_keyboard_mode" : "EVENT", "linux_client_mouse_mode" : "EVENT", "special_keyboard" : false, "joy_stick_flag" : false }, "seamless" : { "seamless_enable" : false, "options" : { "seamless_apply_path" : "string" } }, "personalizedDataMgmt" : { "personalized_data_mgmt_path" : "string", "user_data_roaming_enable" : false, "user_data_roaming_options" : { "profile_streaming_enable" : false, "roamed_files_local_path" : "string", "exclude_folders_path" : "string", "roaming_registry_method" : "string", "roaming_registry_path" : "string" }, "user_folder_redirection_enable" : false, "user_folder_redirection_options" : { "restore_local_directories_enable" : false, "appData_roaming_enale" : false, "redirec_desktop" : false, "redirec_start_menu" : false, "redirec_documents" : false, "redirec_pictures" : false, "redirec_music" : false, "redirec_videos" : false, "redirec_favorites" : false, "redirec_contacts" : false, "redirec_downloads" : false, "redirec_links" : false, "redirec_searches" : false, "redirec_saved_games" : false }, "logoff_delete_user_configuration" : false, "network_drive_mapping_enable" : false, "network_drive_mapping_options" : { "network_drive_mapping_path" : "string", "drive_letter" : "string" } }, "custom" : { "custom_configuration1_enable" : false, "options" : { "custom_configuration1_rule" : "string" } }, "record_audit" : { "enable" : true, "rules" : { "rule" : { "record_type" : "string", "interval_record_start_time" : "string", "interval_record_end_time" : "string", "op_type" : "string", "audio_record" : true, "fps" : 0, "duration" : 0, "resolution" : "string", "retention_duration" : 0 } } } } } }
  • 响应参数 状态码:201 表68 响应Body参数 参数 参数类型 描述 id String 策略组ID。 状态码:400 表69 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:401 表70 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:403 表71 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:404 表72 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:405 表73 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:500 表74 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:503 表75 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。
  • 响应参数 状态码:202 表4 响应Body参数 参数 参数类型 描述 job_id String 任务ID。 状态码:400 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:412 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:default 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。
  • 响应参数 状态码:400 表4 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:401 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:403 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:404 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:405 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:500 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:503 表10 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。
  • 请求参数 表2 请求Header参数 参数 是否必选 参数类型 描述 X-Auth-Token 否 String 用户Token。 通过调用IAM服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。 Content-Type 是 String 发送的实体的MIME类型。 表3 请求Body参数 参数 是否必选 参数类型 描述 enterprise_id 是 String 企业ID。
  • 响应参数 状态码:200 表4 响应Body参数 参数 参数类型 描述 enterprise_id String 企业ID。 状态码:400 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:401 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:403 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:404 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:500 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。
  • 响应示例 状态码:200 成功响应。 { "id" : "x-xx-xxx", "tenant_id" : "xxx-xx-x-xx", "name" : "xxx.exe", "version" : "v1.1.1", "description" : "测试应用。", "authorization_type" : "ALL_USER", "app_file_store" : { "store_type" : "OBS", "bucket_store" : { "bucket_name" : "wks-appcenter-xxxx", "bucket_file_path" : "app-file/xxxx.exe" }, "file_link" : "https://host-addresss/xxxxx.jpg" }, "app_icon_url" : "https://host-addresss/xxxxx", "install_type" : "QUIET_INSTALL", "install_command" : "${FILE_PATH} /S", "uninstall_command" : "msiexec /uninstall ${FILE_PATH} /quiet", "support_os" : "Windows", "status" : "NORMAL", "application_source" : "CUSTOM", "create_time" : "2024-12-25T06:56:58.622Z", "catalog_id" : 1, "catalog" : "其他", "install_info" : "安装信息" }
  • 请求示例 { "name" : "notepad++.exe", "version" : "v1.1.1", "description" : "xxx。", "authorization_type" : "ALL_USER", "app_file_store" : { "store_type" : "OBS", "bucket_store" : { "bucket_name" : "wks-appcenter-xxxx", "bucket_file_path" : "app-file/xxxx.exe" }, "file_link" : "https://host-addresss/xxxxx.jpg" }, "app_icon_url" : "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHElEQVQI12P4//8 /w38GIAXDIBKE0DHxgljNBAAO9TXL0Y4OHwAAAABJRU5ErkJggg==", "install_type" : "UNZIP_INSTALL", "install_command" : "${FILE_PATH} /S", "uninstall_command" : "msiexec /uninstall ${FILE_PATH} /quiet", "support_os" : "Windows", "catalog_id" : "xxxx-xxx-xxxx", "install_info" : "xxxx-xxx-xxxx" }
  • 响应参数 状态码:200 表6 响应Body参数 参数 参数类型 描述 id String 唯一标识。 tenant_id String 租户id。 name String 应用名称。 version String 版本号。 description String 描述。 authorization_type String ALL_USER - 全部用户 ASSIGN_USER - 授权指定用户 app_file_store FileStoreLink object 应用存储信息。 app_icon_url String 应用图标路径。 install_type String 安装方式: QUIET_INSTALL - 静默安装。 安装命令(静默安装命令),例: ${FILE_PATH} /S。 UNZIP_INSTALL - 解压安装。 例: unzip ${FILE_PATH}。 GUI_INSTALL - 用户通过GUI界面安装。 install_type为QUIET_INSTALL、UNZIP_INSTALL时install_command非空。 预定义变量将采用以下值: ${FILE_PATH}: 应用安装包在桌面本地的存储路径。 install_command String 安装命令(静默安装命令)。 例: ${FILE_PATH} /S。 预定义变量将采用以下值: ${FILE_PATH}: 应用安装包在桌面本地的存储路径。 uninstall_command String 卸载命令(静默卸载命令)。 例: msiexec /uninstall ${FILE_PATH} /quiet。 预定义变量将采用以下值: ${FILE_PATH}: 应用安装包在桌面本地的存储路径。 support_os String 系统类型: Linux - Windows - Other - status String 应用状态(正常、禁用) 'NORMAL' - 正常 'FORBIDDEN' - 禁用状态 application_source String 应用来源: CUSTOM - 用户上传 SYSTEM - 内置应用 MARKET - 市场应用 create_time String 应用创建时间。 catalog_id String 分类ID。 catalog String 分类名称。 install_info String 安装信息。 表7 FileStoreLink 参数 参数类型 描述 store_type String 存储方式: OBS - OBS桶存储。 LINK - 外部存储,使用的可访问下载链接。 bucket_store BucketStore object OBS桶存储。 file_link String 文件下载完整路径。 表8 BucketStore 参数 参数类型 描述 bucket_name String 桶名称固定格式:wks-appcenter-{project_id}; 需先调用桶授权接口进行授权。 bucket_file_path String OBS对象路径。 注: bucket_file_path是对象在obs中的完整路径,不能以/开头。 例如桶存在如下目录结构的数据。 Bucket: ├─dir1 | ├─object1.txt | └─object2.txt └─object3.txt Object1的路径: dir1/object1.txt Object2的路径: dir1/object2.txt Object3的路径: object3.txt 状态码:400 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:401 表10 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:403 表11 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:404 表12 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:405 表13 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:500 表14 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:503 表15 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。
  • 响应示例 状态码:200 响应成功。 { "count" : 0, "items" : [ { "resource_id" : "xxx-xxx-xxx", "resource_pool_id" : "xxx-xxx-xxx", "resource_name" : "xxxx", "metric" : [ { "metric_name" : "desktop_state", "metric_value" : 10 } ] } ] }
  • URI GET /v2/{project_id}/statistics/metrics/desktops 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 项目ID。 表2 Query参数 参数 是否必选 参数类型 描述 start_time 是 String 查询起始时间(0时区) 云服务每天凌晨02:00进行聚合运算前一天00:00:00~23:59:59的使用时长,并将周期范围内的数据聚合到周期边界上 跨天的记录会按照统计周期进行计算 假设一天内桌面登录多次,09:00~12:00,13:00~21:00,22:00~01:00(次日): 则当天的累计使用时长数据会被汇聚到23:59:59这个点;总使用时长为 3hours(09:00~12:00)+8hours(13:00~21:00)+2hours(22:00~00:00) 如果查询的from-to不足一个周期内,可能造成查询到数据为空; end_time 是 String 查询截至时间(0时区)。 resource_name 否 String 资源名称(模糊匹配)。 min_idle_days 否 Integer 最小空闲天数。 max_idle_days 否 Integer 最大空闲天数 min_idle_days、max_idle_days都非空时,max_idle_days必须大于等于min_idle_days否则可能查询不到数据 usage_min_hours 否 Integer 使用时长(hour)最小值。 usage_max_hours 否 Integer 使用时长(hour)最大值(必须大于等于usage_min_hours)。 sort_field 否 String 按照指标进行排序 desktop_usage - 按照桌面使用时长排序 desktop_idle_duration - 按照桌面空闲周期排序 sort_type 否 String 按照指标进行排序的方向;需配合sort_field一起使用 DESC - 降序返回数据 ASC - 升序返回数据 offset 否 Integer 查询的偏移量,默认值0。 limit 否 Integer limit范围[1-100],默认值0。
  • 响应参数 状态码:200 表4 响应Body参数 参数 参数类型 描述 count Integer 总数。 items Array of DesktopMetric objects 桌面统计指标。 表5 DesktopMetric 参数 参数类型 描述 resource_id String 桌面ID。 resource_pool_id String 桌面池ID(仅桌面池中的桌面存在该字段)。 resource_name String 桌面名称。 metric Array of Metric objects 统计信息 desktop_usage - 桌面使用时长(单位:秒) desktop_idle_duration - 桌面空闲时长(单位:秒) 表6 Metric 参数 参数类型 描述 metric_name String 指标名称。 metric_value Double 指标值。 状态码:400 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 状态码:401 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 状态码:500 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。
  • 功能介绍 查询桌面使用统计信息; 云服务每天凌晨02:00进行聚合运算前一天00:00:00~23:59:59的使用时长,并将周期范围内的数据聚合到周期边界上 跨天的记录会按照统计周期进行计算 假设一天内桌面登录多次,09:00~12:00,13:00~21:00,22:00~01:00(次日): 则当天的累计使用时长数据会被汇聚到23:59:59这个点;总使用时长为 3hours(09:00~12:00)+8hours(13:00~21:00)+2hours(22:00~00:00) 仅能查询最近180天已进行汇聚计算的数据
  • 响应示例 状态码:200 包周期桌面池批量询价响应体。 { "currency" : "string", "cloud_service_rating_results" : [ { "order_request_id" : "string", "official_website_rating_result" : { "amount" : 0, "official_website_amount" : 0, "original_amount" : 0, "official_website_discount_amount" : 0, "optional_discount_amount" : 0, "discount_amount" : 0, "per_amount" : 0, "per_discount_amount" : 0, "per_original_amount" : 0, "per_period_type" : 0, "measure_id" : 0, "product_rating_results" : [ { "id" : "string", "product_id" : "string", "amount" : 0, "discount_amount" : 0, "original_amount" : 0, "official_website_amount" : 0, "official_website_discount_amount" : 0, "optional_discount_amount" : 0, "per_amount" : 0, "per_discount_amount" : 0, "per_original_amount" : 0, "per_official_website_amount" : 0, "per_official_website_discount_amount" : 0, "per_optional_discount_amount" : 0, "per_period_type" : 0, "measure_id" : 0, "extend_params" : "string" } ] }, "optional_discount_rating_results" : [ { "discount_id" : "string", "amount" : 0, "official_website_amount" : 0, "original_amount" : 0, "official_website_discount_amount" : 0, "optional_discount_amount" : 0, "discount_amount" : 0, "per_amount" : 0, "per_discount_amount" : 0, "per_original_amount" : 0, "per_official_website_amount" : 0, "per_official_website_discount_amount" : 0, "per_optional_discount_amount" : 0, "per_period_type" : 0, "measure_id" : 0, "discount_type" : 0, "discount_name" : "string", "best_offer" : 0, "same_ratio_flag" : 0, "discount_ratio" : 0, "promotion_info" : "string", "product_rating_results" : [ { "id" : "string", "product_id" : "string", "amount" : 0, "discount_amount" : 0, "original_amount" : 0, "official_website_amount" : 0, "official_website_discount_amount" : 0, "optional_discount_amount" : 0, "per_amount" : 0, "per_discount_amount" : 0, "per_original_amount" : 0, "per_official_website_amount" : 0, "per_official_website_discount_amount" : 0, "per_optional_discount_amount" : 0, "per_period_type" : 0, "measure_id" : 0, "extend_params" : "string" } ] } ] } ] }
  • 响应参数 状态码:200 表4 响应Body参数 参数 参数类型 描述 currency String 币种,比如CNY。 cloud_service_rating_results Array of CloudServiceRatingResult objects 询价结果。 表5 CloudServiceRatingResult 参数 参数类型 描述 order_request_id String 下单请求体中的orderRequestId。 official_website_rating_result OfficialWebsiteRatingResult object 结果。 optional_discount_rating_results Array of OptionalDiscountRatingResult objects 优惠询价结果。 表6 OfficialWebsiteRatingResult 参数 参数类型 描述 amount Number 订单总额,即最终优惠后的订单金额(预留实例只包含预付部分)。 official_website_amount Number 官网价(预留实例只包含预付部分)。 original_amount Number 订单原总额,即优惠前订单总额(预留实例只包含预付部分)。 official_website_discount_amount Number 官网价优惠额(预留实例只包含预付部分)。 optional_discount_amount Number 可选折扣优惠额(预留实例只包含预付部分)。 discount_amount Number 总优惠额(预留实例只包含预付部分)。 per_amount Number 总分期金额(批量询价的商品分期周期类型一致,才会有总分期金额,分期周期类型不一致,该信息没有)。 per_discount_amount Number 总分期金额的优惠额(perDiscountAmount = perOriginalAmount - perAmount)。 per_original_amount Number 总分期金额原价。 per_period_type Integer 分期周期类型 2:月 4:小时。 measure_id Integer 度量单位。 product_rating_results Array of ProductResult objects 产品询价结果。 表7 OptionalDiscountRatingResult 参数 参数类型 描述 discount_id String 折扣优惠Id。 amount Number 订单总额,即最终优惠后的订单金额(预留实例只包含预付部分)。 official_website_amount Number 官网价(预留实例只包含预付部分)。 original_amount Number 订单原总额,即优惠前订单总额(预留实例只包含预付部分)。 official_website_discount_amount Number 官网价优惠额(预留实例只包含预付部分)。 optional_discount_amount Number 可选折扣优惠额(预留实例只包含预付部分)。 discount_amount Number 总优惠额(预留实例只包含预付部分)。 per_amount Number 总分期金额(批量询价的商品分期周期类型一致,才会有总分期金额,分期周期类型不一致,该信息没有)。 per_discount_amount Number 总分期金额的优惠额(perDiscountAmount = perOriginalAmount - perAmount)。 per_original_amount Number 总分期金额原价。 per_official_website_amount Number 总分期金额的官网价(批量询价的商品分期周期类型一致,才会有总分期金额的官网价,分期周期类型不一致,该信息没有)。 per_official_website_discount_amount Number 总分期金额的官网价官网价优惠额,即: perOfficialWebsiteDiscountAmount =perOriginalAmount-perOfficialWebsiteAmount (批量询价的商品分期周期类型一致,才会有总分期金额的官网价,分期周期类型不一致,该信息没有)。 per_optional_discount_amount Number 总分期金额的可选折扣优惠额,如商务折扣、伙伴折扣、促销折扣和折扣券选用时的优惠额 perOptionalDiscountAmount= perOfficialWebsiteAmount- perAmount (批量询价的商品分期周期类型一致,才会有总分期金额的官网价,分期周期类型不一致,该信息没有)。 per_period_type Integer 分期周期类型 2:月 4:小时。 measure_id Integer 度量单位。 discount_type Integer 折扣优惠类型。 discount_name String 折扣名称。 best_offer Integer 是否为最优折扣0:不是最优折扣;为缺省值。1:是最优折扣;最优折扣:在商务折扣、伙伴折扣和促销折扣中选择(优惠金额相等则按此顺序排优先级),折扣券不参与最优折扣的计算。 same_ratio_flag Integer sameRatioFlag。 discount_ratio Number sameRatioFlag为1时有值,表示该折扣的折扣率。 promotion_info String 折扣优惠基本信息;调用者在确定好折扣优惠后、下单时,使用此字段值,填入到订购/变更接口中的promotionInfo字段。 product_rating_results Array of ProductResult objects 产品询价结果。 表8 ProductResult 参数 参数类型 描述 id String 对应请求体中的ID。 product_id String 产品ID。 amount Number 总额,即最终优惠后的金额(预留实例只包含预付部分)。 discount_amount Number 优惠额(预留实例只包含预付部分)。 original_amount Number 原总额,即优惠前总额(预留实例只包含预付部分)。 official_website_amount Number 官网价(非所有接口有该字段)(预留实例只包含预付部分)。 official_website_discount_amount Number 官网价优惠额(非所有接口有该字段)(预留实例只包含预付部分)。 optional_discount_amount Number 可选折扣优惠额(预留实例只包含预付部分),如商务折扣、伙伴折扣、促销折扣和折扣券选用时的优惠额(非所有接口有该字段)。 per_amount Number 总分期金额(批量询价的商品分期周期类型一致,才会有总分期金额,分期周期类型不一致,该信息没有)。 per_discount_amount Number 总分期金额的优惠额(perDiscountAmount = perOriginalAmount - perAmount)。 per_original_amount Number 总分期金额原价。 per_official_website_amount Number 分期金额的官网价。 per_official_website_discount_amount Number 分期金额的官网价官网价优惠额,即:perOfficialWebsiteDiscountAmount =perOriginalAmount-perOfficialWebsiteAmount。 per_optional_discount_amount Number 分期金额的可选折扣优惠额,如商务折扣、伙伴折扣、促销折扣和折扣券选用时的优惠额 perOptionalDiscountAmount= perOfficialWebsiteAmount- perAmount。 per_period_type Integer 分期周期类型 2:月 4:小时。 measure_id Integer 度量单位。 extend_params String 扩展参数。 状态码:400 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:409 表10 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:500 表11 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。
  • 请求参数 表2 请求Header参数 参数 是否必选 参数类型 描述 X-Auth-Token 否 String 用户Token。 通过调用IAM服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。 Content-Type 否 String 发送的实体的MIME类型。 表3 请求Body参数 参数 是否必选 参数类型 描述 desktop_pool_id 否 String 桌面池ID。当desktop_pool_id与desktop_ids同时存在时,取desktop_ids的值,两者不可同时为空。 desktop_ids 否 Array of strings 包周期桌面ID列表。 不可同时存在普通桌面和池桌面ID。 promotion_plan_id 否 String 促销计划ID。 sub_resource_sku 是 String 新增附属资源SKU码。
  • 响应参数 状态码:400 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:401 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:403 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:404 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:405 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:500 表10 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:503 表11 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。
  • 请求参数 表2 请求Header参数 参数 是否必选 参数类型 描述 X-Auth-Token 否 String 用户Token。 通过调用IAM服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。 Content-Type 是 String 发送的实体的MIME类型,如:application/json。 表3 请求Body参数 参数 是否必选 参数类型 描述 users 是 Array of CreateUserRequest objects 创建单个用户请求。 表4 CreateUserRequest 参数 是否必选 参数类型 描述 user_name 是 String 用户名称。 user_email 否 String 用户邮箱。 account_expires 否 String 账户过期时间,0表示永远不过期。时间格式:yyyy-MM-ddTHH:mm:ssZ或yyyy-MM-ddTHH:mm:ss.SSSZ。 active_type 否 String 激活类型,默认为用户激活。 USER_ACTIVATE: 用户激活 ADMIN_ACTIVATE: 管理员激活 user_phone 否 String 用户手机号。 password 否 String 用户初始密码。管理员激活模式需要输入。 enable_change_password 否 Boolean 是否允许用户更改密码,缺省值为true,后续此字段无效,创建时都为true。 next_login_change_password 否 Boolean 下次登录是否必须更改密码,缺省值为true。后续此字段无效,创建时都为true。 group_ids 否 Array of strings 用户组的专有ID列表。 description 否 String 用户描述,字符串长度区间[0, 255]。 alias_name 否 String 别名。
  • 响应参数 状态码:400 表4 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:401 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:403 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:404 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:405 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:500 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 状态码:503 表10 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。
  • 响应示例 状态码:200 任务明细响应。 { "total_count" : 2, "jobs" : [ { "status" : "RUNNING", "entities" : { "user_name" : "user-test-01", "product_id" : "workspace.c2.large.windows", "desktop_id" : "9d30c8ac-77b5-4453-80da-8f027223ee99" }, "job_id" : "0e2dae94-23ff-449a-bb9c-1b808cf2106d", "job_type" : "createDesktops", "begin_time" : "2020-04-10 06:45:14", "end_time" : "2020-04-10 07:06:10", "id" : "e43caef5-e478-4624-9e8c-b0b636331cbc" }, { "status" : "RUNNING", "entities" : { "user_name" : "user-test-01", "product_id" : "workspace.c2.large.windows", "desktop_id" : "14cccba0-12a6-4b66-9fd9-57290328f8da" }, "job_id" : "0e2dae94-23ff-449a-bb9c-1b808cf2106d", "job_type" : "createDesktops", "begin_time" : "2020-04-10 06:45:14", "end_time" : "2020-04-10 07:05:49", "id" : "cf5043e9-dd94-43be-9c07-6dba5d43c4d2" } ] }
  • 响应参数 状态码:200 表4 响应Body参数 参数 参数类型 描述 total_count Integer 任务列表总数。 jobs Array of JobDetailInfo objects 任务列表。 表5 JobDetailInfo 参数 参数类型 描述 id String 子任务ID。 job_type String 任务类型。 entities JobEntities object 任务。 begin_time String 任务创建时间。 end_time String 任务结束时间。 status String 任务状态。 error_code String 任务执行失败时的错误码。 fail_reason String 任务失败原因。 host String 任务执行的服务器IP。 project_id String 项目ID。 job_id String 任务ID。 process Integer 任务进度。 attach_user String 关联用户。 entity String 操作对象。 ip_address String ip地址。 表6 JobEntities 参数 参数类型 描述 desktop_id String 桌面ID。 product_id String 套餐ID。 user_name String 用户名。 desktop_name String 桌面名称。 ip_address String ip地址。 状态码:400 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:401 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:403 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:404 表10 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:405 表11 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:500 表12 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:503 表13 响应Body参数 参数 参数类型 描述 error_code String 错误码。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。
  • URI GET /v2/{project_id}/workspace-sub-jobs 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 项目id。 表2 Query参数 参数 是否必选 参数类型 描述 status 否 String 任务状态 SUC CES S:成功。 RUNNING:运行中。 FAILED:失败。 WAITING:等待。 job_id 否 String 任务ID。 job_type 否 String 任务类型 createDesktops:创建桌面任务。 applyWorkspace:开通 云桌面 服务。 cancelWorkspace:注销云桌面服务。 expandVolumes: 扩容磁盘。 addVolumes: 添加磁盘。 desktop_pool_id 否 String 桌面池ID。 limit 否 Integer 用于分页查询,取值范围0~1000,默认1000。 offset 否 Integer 用于分页查询,查询的起始记录序号,从0开始。
  • 请求参数 表2 请求Header参数 参数 是否必选 参数类型 描述 X-Auth-Token 否 String 用户Token。 通过调用IAM服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。 Content-Type 否 String 发送的实体的MIME类型。 表3 请求Body参数 参数 是否必选 参数类型 描述 desktop_ids 是 Array of strings 待删除的桌面ID列表。 delete_users 否 Boolean 删除桌面后,如果当前用户没有其它桌面,可以删除桌面用户。true:删除用户,false:不删除用户,默认为false。 email_notification 否 Boolean 是否邮件通知,true:邮件通知,false:不通知,默认值true。 is_force_delete 否 Boolean 是否强制删除,true:强制删除,false:不强制删除。
  • 响应参数 状态码:202 表4 响应Body参数 参数 参数类型 描述 job_id String 任务ID。 状态码:400 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:401 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:403 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:404 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:409 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 状态码:500 表10 响应Body参数 参数 参数类型 描述 error_code String 错误码,失败时返回。 error_msg String 错误描述。 encoded_authorization_message String 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。
  • 响应示例 状态码:200 成功响应。 { "availability_zones" : [ { "availability_zone" : "cn-north-7a", "display_name" : "cn-north-7a", "i18n" : { "en_us" : "AZ1", "zh_cn" : "可用区1" }, "sold_out" : { "products" : [ ] }, "product_ids" : [ ], "visible" : true, "default_availability_zone" : false }, { "availability_zone" : "cn-north-7b", "display_name" : "cn-north-7b", "i18n" : { "en_us" : "AZ2", "zh_cn" : "可用区2" }, "sold_out" : { "products" : [ ] }, "product_ids" : [ ], "visible" : true, "default_availability_zone" : false }, { "availability_zone" : "cn-north-7c", "display_name" : "cn-north-7c", "i18n" : { "en_us" : "AZ3", "zh_cn" : "可用区3" }, "sold_out" : { "products" : [ ] }, "product_ids" : [ ], "visible" : true, "default_availability_zone" : false } ], "total_count" : 3 }
共100000条
提示

您即将访问非华为云网站,请注意账号财产安全