华为云用户手册

  • 请求参数 表1 请求Header参数 参数 是否必选 参数类型 描述 X-Auth-Token 否 String 用户Token。 通过调用 IAM 服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。 x-publisher-token和X-Auth-Token必传一个 x-publisher-token 否 String 发布商凭证,x-publisher-token和X-Auth-Token必传一个 表2 FormData参数 参数 是否必选 参数类型 描述 file 是 File 文件 publisher_id 否 String 传用户token时,此字段为必传项 chunk_index 是 Long 分片索引,第几个分片 取值范围:1-100 merge 是 Boolean 是否合并已上传的分片(包含本次分片内容),true total_chunk_num 是 Long 总分片数 0-100 parent_file_size 是 Long 父文件大小 parent_file_name 是 String 父文件名称 override 是 Boolean 是否覆盖原有文件 chunk_md5 是 String 文件分片的md5,用于校验文件分片是否完整 parent_file_sha256 否 String 父文件hash,用于校验合并后的文件 task_id 否 String 上传任务的唯一标识,第一次上传分片时可不传
  • 响应参数 状态码: 200 表3 响应Body参数 参数 参数类型 描述 stack StacksTag object 技术栈 status String 状态 表4 StacksTag 参数 参数类型 描述 stack_list Array of Stacks objects 技术栈列表 tags Array of strings 技术栈tag集合 表5 Stacks 参数 参数类型 描述 arm_config StacksConfig object arm配置 config StacksConfig object x86配置 creator String 创建人 description String 描述 disable Boolean 是否可用 id Long id label String 标签 logo String 图标 name String 技术栈名称 scope String 范围 stack_id String 技术栈ID,通过技术栈管理ListStacks接口获取。 tags Array of strings tags 表6 StacksConfig 参数 参数类型 描述 attributes StacksAttribute object 属性值 recipe Recipe object 镜像 表7 StacksAttribute 参数 参数类型 描述 specs Array of strings 规格列表 suggest String 提示id suggest_title String 提示信息 volumes Array of strings 卷容量列表 表8 Recipe 参数 参数类型 描述 content String 镜像内容 type String 镜像类型 状态码: 403 表9 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 404 表10 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 406 表11 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 500 表12 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码
  • 响应示例 状态码: 200 OK { "stack" : { "tags" : [ "Java", "Maven", "CPP", "Vue", "ServiceComb", "Blockchain", "GO", "Node.js", "Quantum", "JavaScript", "Ruby", "Python" ], "stack_list" : [ { "id" : 1, "stack_id" : "all", "creator" : "ide", "name" : "All in One", "description" : "支持Java、Python、JS/TS等多种语言", "scope" : "general", "config" : { "recipe" : { "content" : "hishell-all-in-one:alpha", "type" : "dockerimage" }, "attributes" : { "specs" : [ "2U4G" ], "volumes" : [ "5GB", "10GB", "20GB" ] } }, "tags" : [ "Java", "Maven", "CPP", "JavaScript", "Vue", "GO", "Node.js", "Ruby", "Python", "ServiceComb" ], "disable" : false, "arm_config" : { "recipe" : { "content" : "hishell-all-in-one:alpha", "type" : "dockerimage" }, "attributes" : { "specs" : [ "4U8G" ], "volumes" : [ "5GB", "10GB", "20GB" ] } } } ] }, "status" : "success"}
  • 创建IDE实例 创建指定技术栈及规格的IDE实例。 请求示例 POST https://{endpoint}/v2/instances?instance_label=classroom { "instance_name" : "testjava", "stack_id" : "java", "description" : "", "cpu_memory" : "2U4G", "pvc_quantity" : "5GB", "refresh_time" : 30, "is_temporary" : "false", "instance_user_name" : "test", "instance_user_domain_name" : "test"} 响应示例 { "result" : { "link" : "https://*****/cloudide/loading?instanceId=mpdrao", "arch" : "x86", "id" : "mpdrao" }, "status" : "success"}
  • 响应示例 状态码: 200 OK { "instance" : { "created_time" : "2020-01-07 11:25:56", "updated_time" : "2020-03-20 17:14:00", "private" : false, "owner_name" : "ide_owner_name", "refresh_interval" : 30, "owner_id" : "d78cbac186b744899480f25bd022f468...", "description" : "aaa", "cpu_memory" : "1U1G", "display_name" : "chen002", "domain_name" : "IAM_DOMAIN_NAME_A", "is_temporary" : false, "organization_id" : "6251b1ee539f4c02ad4b83daeda81633...", "stack_id" : "python", "name" : "ide-instance8bmjgqx6vfrb9e9n", "platform_id" : 1, "attributes" : { "cpu_limit" : "1", "pvc_quantity" : "5Gi", "memory_limit_bytes" : "1073741824" }, "pvc_quantity" : "5GB", "arch" : "x86", "id" : "instancewc0yk05c8y6jov0v", "region" : "cn-north-7", "status" : "STOPPED", "visitor_id" : "c78cbac186b744899480f25bd022f468...", "visitor_name" : "ide_visitor_name", "visitor_domain_name" : "IAM_DOMAIN_NAME_B" }, "status" : "success"}
  • 响应示例 状态码: 200 OK { "results" : [ { "extensions" : [ { "extension_id" : "d45648941sadsadsa_hdsa", "extension_name" : "plugin_for_CodeArtsIDEOnline", "display_name" : "backgroudcolor_setting", "flags" : 8, "last_updated" : "2022-08-31 00:00:00", "published_date" : "2022-08-29 00:00:00", "release_date" : "2022-09-06 00:00:00", "short_description" : "插件的简要描述", "tags" : [ "color", "extention" ], "tag_all_list" : [ "color", "extension", "enhancer" ], "publisher" : { "publisher_id" : 123456, "publisher_name" : "code-huawei", "display_name" : "color-modify", "publisher_status" : "VERIFIED", "email" : "xxx@huawei.com", "web_url" : "www.xxx.huawei.com", "open" : true }, "arch" : [ "x86", "arm" ], "target" : "CodeArts IDE Online", "categories" : [ "backgroud", "color" ], "category_all_list" : [ "backgroud", "color", "script" ], "publish_manager" : { "publisher_id" : 123456, "publisher_name" : "code-huawei", "display_name" : "color-modify", "publisher_status" : "VERIFIED", "email" : "xxx@huawei.com", "web_url" : "www.xxx.huawei.com", "open" : true }, "status" : "NORMAL", "validate_status" : "NONE", "install_count" : 5000, "average_star" : 4.6, "identifier" : "marketplace_plugin", "support_os" : [ "win", "mac os", "linux" ], "support_ide" : 3, "support_ide_info" : "CodeArts IDE Online", "versions" : [ { "id" : "d45648132313", "version" : "version_one", "version_ranking" : 10000, "status" : "PUBLISHED", "version_status" : "PUBLISHED", "asset_uri" : "www.example.com", "last_updated" : "2022-08-31 00:00:00" } ], "extension_statistics" : { "install" : 10000, "stars" : 5 }, "preview" : false, "ext_info" : { "extension_id" : "d45648941sadsadsa_hdsa", "repo_url" : "www.xxxcodehub.com", "help_page" : "www.help.page.com", "website" : "www.index.com", "issue_link" : "www.problem.com", "show_previews" : false }, "platform" : "/opt/**", "check_result" : { "status" : "success" }, "extension_owner" : "huaweistaff" } ], "result_metadata" : [ { "metadata_type" : ".ts", "metadata_items" : [ { "key" : "value" }, { "uuid" : "uuid" } ] } ] } ]}
  • 概述 面向云原生的轻量级WebIDE,通过浏览器访问即可实现云端开发环境获取、代码编写、编译调试、运行预览、访问代码仓库、命令行执行等能力,同时支持丰富的插件扩展。 您可以使用本文档提供的API对CodeArts IDE Online进行相关操作,如:IDE实例管理、技术栈管理、模板管理等。支持的全部操作请参见API概览。 在调用CodeArts IDE Online的API之前,请确保已经充分了解CodeArts IDE Online的相关概念,详细信息请参见产品介绍。 父主题: 使用前必读
  • 响应示例 状态码: 200 OK { "result" : { "security" : { "status" : "success" }, "file" : { "status" : "success" }, "basicInformation" : { "status" : "success", "extension_version_compare" : "NULL_VERSION", "extension_brief_info" : { "publisherSnake" : { "publisher_id" : "c45c552c14b94e0889e0346090688ad9", "publisher_name" : "lemontree", "display_name" : "lemontree" }, "identifier" : "lemontree.big-file-test", "logUrl" : "https://cnnorth6-dev-cloudide.obs.cn-north-6.myhuaweicloud.com:443/upload/d6cbb007-4071-4bce-921f-538e78ce4859/icon.png?AccessKeyId=7JLQBTJ2B3TEYUIF00FF&Expires=1676272349&Signature=lT9YyiqQddPYYmaVoJ9hgvdGed8%3D", "displayName" : "bigfile upload test", "platform" : "codearts ide online", "version" : "0.0.1", "description" : "Debug for AOC SSP" } } }, "status" : "success"}
  • 请求参数 表1 请求Header参数 参数 是否必选 参数类型 描述 x-auth-token 是 String iam x-auth-token Content-Type 否 String content enum - application/json 枚举值: application/json 表2 请求Body参数 参数 是否必选 参数类型 描述 case 否 String case chat_id 是 String chat id message 是 String message infer_end 否 Boolean infer end meta_prompt 否 Array of strings prompt need_preprocess 否 Boolean need or not user_id 否 String user id task_parameters 否 Object task parameters
  • 请求参数 表2 请求Header参数 参数 是否必选 参数类型 描述 X-Auth-Token 否 String 用户Token。 通过调用IAM服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。 x-publisher-token和X-Auth-Token必传一个 x-publisher-token 否 String 发布商凭证,x-publisher-token和X-Auth-Token必传一个
  • 响应参数 状态码: 200 表3 响应Body参数 参数 参数类型 描述 result Object 返回值 status String 状态 状态码: 401 表4 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 403 表5 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 404 表6 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码
  • 文档修订记录 文档修订记录累积了每次文档更新的说明。最新版本的文档包含以前所有文档版本的更新内容。 修订记录 发布日期 第十九次正式发布,本次变更说明如下: 新增接口:查询插件分类 新增接口:插件发布 新增接口:获取插件检测结果 新增接口:获取当前用户下的发布商列表 新增接口:文件上传归一化 新增接口:CreateLogin接口 新增接口:CreateJoinRequest接口 新增接口:CreateEvent接口 2023-04-11 第十八次正式发布,本次变更说明如下: CloudIDE服务更名为CodeArts IDE Online 2023-02-16 第十七次正式发布,本次变更说明如下: 新增接口:CreateAcceptance接口 新增接口:Create Request接口 新增接口:Show Result接口 2022-12-05 第十六次正式发布,本次变更说明如下: 新增接口:添加插件评论 新增接口:添加评论回复、回复评论回复 新增接口:添加新评星 新增接口:举报评论,举报回复 新增接口:删除评论 新增接口:删除回复 新增接口:查询插件列表 新增接口:查询插件详细信息 新增接口:查询插件评价 新增接口:查询插件评星 2022-11-23 第十五次正式发布,本次变更说明如下: 接口查询某个IDE实例更新:响应示例中删掉instance.is_private。 接口启动IDE实例更新:新增请求示例。 接口查询某个租户下的IDE实例列表更新:响应示例参数删除 instances.count、instances.items.is_private。 接口查询IDE实例列表更新:响应示例参数删除 instances.count、instances.items.is_private。 接口查询技术栈模板工程更新:响应参数中新增arch参数。 2022-08-24 第十四次正式发布,本次变更说明如下: 新增接口:查询某个IDE实例的状态。 接口创建IDE实例更新:删除参数instance_user_domain_name、instance_user_name。 接口外部第三方集成商创建IDE实例更新:删除参数instance_user_domain_name、instance_user_name。 2022-07-22 第十三次正式发布,本次变更说明如下: 新增接口:上传插件。 2022-07-01 第十二次正式发布,本次变更说明如下: 接口创建IDE实例更新:新增请求Body参数instance_domain_id和instance_user_id。 参数描述中“组织”修改改成“租户”。 2022-03-01 第十一次正式发布,本次变更说明如下: 刷新refresh_interval参数。 2022-01-26 第十次正式发布,本次变更说明如下: 新增接口:按region获取标签所有技术栈。 废弃接口:获取标签所有技术栈。 2022-01-11 第九次正式发布,本次变更说明如下: 修改接口查询某个IDE实例的响应参数。 修改接口查询某个租户下的IDE实例列表的响应参数。 修改接口查询IDE实例列表的响应参数。 更新部分接口的参数描述。 2021-12-20 第八次正式发布,本次变更说明如下: 新增接口:查询用户是否有权限访问某个IDE实例 新增接口:刷新IDE实例活跃状态 新增接口:查询ide实例对插件的授权情况 新增接口:设置ide实例对插件的授权 2021-12-13 第七次正式发布,本次变更说明如下: 新增权限策略和授权项相关内容。 2021-08-24 第六次正式发布,本次变更说明如下: 接口创建IDE实例更新:新增请求Body参数。 更新部分接口参数描述。 2021-01-27 第五次正式发布,本次变更说明如下: 错误码更新:错误响应Body体格式示例更新。 接口启动IDE实例更新:新增请求body参数。 接口创建IDE实例更新:请求Body参数新增port_id、private_ip、vpc_id三个参数。 新增接口:查询当前账号访问权限。 2020-12-29 第四次正式发布,本次变更说明如下: 接口创建IDE实例返回值更新。 接口外部第三方集成商创建IDE实例返回值更新。 2020-11-09 第三次正式发布,本次变更说明如下: 更新终端节点,新增北京一和大连。 2020-09-17 第二次正式发布,本次变更说明如下: 新增应用示例。 2020-07-31 第一次正式发布。 2020-07-07
  • AK/SK认证 AK/SK签名认证方式仅支持消息体大小12M以内,12M以上的请求请使用Token认证。 AK/SK认证就是使用AK/SK对请求进行签名,在请求时将签名信息添加到消息头,从而通过身份认证。 AK(Access Key ID):访问密钥ID。与私有访问密钥关联的唯一标识符;访问密钥ID和私有访问密钥一起使用,对请求进行加密签名。 SK(Secret Access Key):与访问密钥ID结合使用的密钥,对请求进行加密签名,可标识发送方,并防止请求被修改。 使用AK/SK认证时,您可以基于签名算法使用AK/SK对请求进行签名,也可以使用专门的签名SDK对请求进行签名。详细的签名方法和SDK使用方法请参见API签名指南。 签名SDK只提供签名功能,与服务提供的SDK不同,使用时请注意。
  • Token认证 Token的有效期为24小时,需要使用一个Token鉴权时,可以先缓存起来,避免频繁调用。 Token在计算机系统中代表令牌(临时)的意思,拥有Token就代表拥有某种权限。Token认证就是在调用API的时候将Token加到请求消息头,从而通过身份认证,获得操作API的权限。 在构造请求中以调用获取用户Token接口为例说明了如何调用API。 Token可通过调用获取用户Token接口获取,调用本服务API需要project级别的Token,即调用获取用户Token接口时,请求body中auth.scope的取值需要选择project,如下所示。 { "auth": { "identity": { "methods": [ "password" ], "password": { "user": { "name": "username", "password": "********", "domain": { "name": "domainname" } } } }, "scope": { "project": { "name": "xxxxxxxx" } } } } 获取Token 后,再调用其他接口时,您需要在请求消息头中添加“X-Auth-Token”,其值即为Token。例如Token值为“ABCDEFJ....”,则调用接口时将“X-Auth-Token: ABCDEFJ....”加到请求消息头即可,如下所示。 GET https://iam.cn-north-1.myhuaweicloud.com/v3/auth/projects Content-Type: application/json X-Auth-Token: ABCDEFJ....
  • 响应示例 状态码: 200 successful operation { "result" : { "size" : 30, "total_items_count" : 3, "items_before" : 0, "items" : [ { "id" : 74, "extension_id" : "17c341ee-797e-4824-aec5-6fafb3c0eced", "comment" : "1111111", "stars" : 5, "create_time" : "2022-02-17 09:35:31", "last_updated" : "2022-04-11 16:52:12", "status" : "VALIDATED", "commentator" : { "domainId" : "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", "domainName" : "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", "deletedTime" : 0 } }, { "id" : 75, "extension_id" : "17c341ee-797e-4824-aec5-6fafb3c0eced", "comment" : "4分", "stars" : 4, "create_time" : "2022-02-17 09:41:24", "last_updated" : "2022-02-17 09:41:24", "status" : "VALIDATED", "commentator" : { "domainId" : "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", "domainName" : "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", "deletedTime" : 0 } } ], "empty" : false }, "status" : "success"}
  • 响应参数 状态码: 200 表3 响应Body参数 参数 参数类型 描述 result Object 返回值 status String 状态 状态码: 401 表4 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 403 表5 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 404 表6 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码
  • 响应示例 状态码: 200 successful operation { "results" : [ { "extensions" : [ { "extension_id" : "d45648941sadsadsa_hdsa", "extension_name" : "plugin_for_CodeArtsIDEOnline", "display_name" : "backgroudcolor_setting", "flags" : 8, "last_updated" : "2022-08-31 00:00:00", "published_date" : "2022-08-29 00:00:00", "release_date" : "2022-09-06 00:00:00", "short_description" : "插件的简要描述", "tags" : [ "color", "extention" ], "tag_all_list" : [ "color", "extension", "enhancer" ], "publisher" : { "publisher_id" : 123456, "publisher_name" : "code-huawei", "display_name" : "color-modify", "publisher_status" : "VERIFIED", "email" : "xxx@huawei.com", "web_url" : "www.xxx.huawei.com", "open" : true }, "arch" : [ "x86", "arm" ], "target" : "CodeArts IDE Online", "categories" : [ "backgroud", "color" ], "category_all_list" : [ "backgroud", "color", "script" ], "publish_manager" : { "publisher_id" : 123456, "publisher_name" : "code-huawei", "display_name" : "color-modify", "publisher_status" : "VERIFIED", "email" : "xxx@huawei.com", "web_url" : "www.xxx.huawei.com", "open" : true }, "status" : "NORMAL", "validate_status" : "NONE", "install_count" : 5000, "average_star" : 4.6, "identifier" : "marketplace_plugin", "support_os" : [ "win", "mac os", "linux" ], "support_ide" : 3, "support_ide_info" : "CodeArts IDE Online", "versions" : [ { "id" : "d45648132313", "version" : "version_one", "version_ranking" : 10000, "status" : "PUBLISHED", "version_status" : "PUBLISHED", "asset_uri" : "www.example.com", "last_updated" : "2022-08-31 00:00:00" } ], "extension_statistics" : { "install" : 10000, "stars" : 5 }, "preview" : false, "ext_info" : { "extension_id" : "d45648941sadsadsa_hdsa", "repo_url" : "www.xxxcodehub.com", "help_page" : "www.help.page.com", "website" : "www.index.com", "issue_link" : "www.problem.com", "show_previews" : false }, "platform" : "/opt/**", "check_result" : { "status" : "success" }, "extension_owner" : "huaweistaff" } ], "result_metadata" : [ { "metadata_type" : ".ts", "metadata_items" : [ { "key" : "value" }, { "uuid" : "uuid" } ] } ] } ]}
  • 请求参数 表1 请求Header参数 参数 是否必选 参数类型 描述 X-Auth-Token 否 String 用户Token。 通过调用IAM服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。 表2 请求Body参数 参数 是否必选 参数类型 描述 filters 是 Array of FilterSnake objects 过滤字段 flags 是 Integer 插件flag;通过传递flag参数来进行过滤或其他操作。flag的基础数字是2\4\8\16;传递的参数只能是这四个数字加法组合而成数字 利用它们之间二进制的运算获取的值进行其他操作.比如6=0110=0010+0100也就是2和4的集合flags 表3 FilterSnake 参数 是否必选 参数类型 描述 criteria 否 Array of CriteriaSnake objects 过滤集合 page_number 是 Long 页码 page_size 是 Long 分页大小 sort_by 否 Long 排序字段. 1 修改日期 2 插件名称 3 插件作者名称 枚举值: 1 2 3 sort_order 否 Long 排序顺序. 1 升序 2 降序 枚举值: 1 2 表4 CriteriaSnake 参数 是否必选 参数类型 描述 filter_type 否 Integer 过滤类型 1 按插件Tag过滤 2 按diplayName过滤 3 按publisherId过滤 4 按插件Id过滤 5 按插件分类过滤 7 按照作者名.插件名过滤 8 按Target(客户端)过滤 10 按关键字(客户端输入的)过滤 12 根据flags传入的值来进行过滤,eg:flags=2name就排除flags=2的插件. 13 根据flags传入的值来进行过滤,eg:flags=2name就查询出flags=2的插件 18 按publisherName过滤 19 按publisherDisplayName过滤 102 按照插件状态排除插件 103 按照插件状态过滤出插件 107 supportIdeInfo 108 根据插件ids查询 枚举值: 1 2 3 4 5 7 8 10 12 13 18 19 102 103 107 108 value 否 String 过滤类型对应字段名称
  • 实例相关权限 表1 实例相关权限 权限 对应API接口 授权项(Action) 依赖的授权项 IAM项目 (Project) 企业项目(Enterprise Project) 创建IDE实例 POST /v2/{org_id}/instances cloudIDE:instance:create - √ × 删除IDE实例 DELETE /v2/instances/{instance_id} cloudIDE:instance:delete - √ × 启动IDE实例 PUT /v2/instances/{instance_id}/runtime cloudIDE:instance:start - √ × 停止IDE实例 DELETE /v2/instances/{instance_id}/runtime cloudIDE:instance:stop - √ × 访问IDE实例 仅支持CodeArts IDE Online内部调用,API方式不支持 cloudIDE:instance:access - √ × 修改IDE实例(仅修改描述和名称) PUT /v2/instances/{instance_id} cloudIDE:instance:update - √ × 分发实例给访问者 POST /v2/instances/{instance_id}/visitor cloudIDE:instance:assign - √ × 授权实例给用户 POST /v2/instance/{instance_id}/user cloudIDE:instance:auth - √ × 重置实例 POST /v2/instance/{instance_id}/reset cloudIDE:instance:reset - √ × 父主题: 权限策略和授权项
  • 响应参数 状态码: 200 表4 响应Body参数 参数 参数类型 描述 result String 返回值 status String 状态 状态码: 403 表5 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 404 表6 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 406 表7 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 500 表8 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码
  • 响应参数 状态码: 200 表2 响应Body参数 参数 参数类型 描述 request_status String the status of the request 枚举值: created dispatched completed timeout unknown tasks Array of TaskModel objects task list request_type String the type of the request 表3 TaskModel 参数 参数类型 描述 docker_id String the docker_id exception String exception generated_snippet String the generated_snippet language String code language model_id String model_id record_time String record_time request_id String the unique id of request snippet String the snippet of code start_time String start_time status String status task_id Integer task_id time_consuming Number the time_consuming
  • 响应示例 状态码: 200 Successful Response { "tasks" : [ { "request_id" : "d980c2b5242eb97aa07a1f6645a6793a", "task_id" : 0, "language" : "python", "snippet" : "def add(x, y):\n return x + y", "generated_snippet" : "", "docker_id" : "02:55:ac:10:00:36", "start_time" : "2022-11-21T19:48:30", "record_time" : "2022-11-21T19:48:30", "time_consuming" : 0.022447, "status" : "success", "exception" : null, "model_id" : "300M" } ], "request_status" : "completed", "request_type" : "function"}
  • 响应示例 状态码: 200 OK { "result" : [ { "id" : "cc809483-21b8-473b-bd65-ff87efb261fa", "name" : "Spring Boot Extension Pack", "identifier" : "huawei", "description" : "Spring Boot Extension Pack", "email" : "xuhui80@huawei.com", "status" : true, "publisher_review" : false, "system_review" : false, "official" : false, "is_open" : false, "created_time" : "2022-04-01 09:54:26", "updated_time" : "2023-02-15 15:29:12", "role" : "Owner" }, { "id" : "6251b1ee539f4c02ad4b83daeda81633", "name" : "fast-run-app", "identifier" : "devcloud_cloudide_name_g0", "description" : "fast-run-appc", "email" : "test@qq.com", "web_url" : "", "status" : true, "publisher_review" : false, "system_review" : false, "official" : false, "is_open" : false, "created_time" : "2022-04-01 09:54:26", "updated_time" : "2022-09-08 11:01:10", "role" : "Owner" } ], "status" : "success"}
  • 响应参数 状态码: 200 表3 响应Body参数 参数 参数类型 描述 result Array of PublisherVO objects 返回值 status String 状态 表4 PublisherVO 参数 参数类型 描述 code_repo String 代码地址 created_time String 创建时间 description String 发布商描述 eamap_info String EAMAP注册信息 email String 邮箱 espase_group String espase交流群号 extension_count Long 插件数量 id String 发布商ID identifier String 唯一标志 is_open Boolean 开源发布商,0:非开源; 1:开源; is_org Boolean 发布商或组织,0:发布商; 1:组织; logo_url String 发布商logo member_count Long 成员数量 name String 发布商名称 official Boolean 是否是官方发布商 owners Array of MemberRoleVo objects 成员角色 publisher_review Boolean 是否开启发布商审核,1:开启;0:关闭 role String 角色 status Boolean 状态,0:禁用; 1:正常; suite_count Long 匹配数量 support_url String 支持地址 system_review Boolean 是否忽略系统审核,1:忽略;0:不忽略 updated_time String 更新时间 web_url String 官网地址 表5 MemberRoleVo 参数 参数类型 描述 domain_id String 租户ID extension_count Integer 插件数量 role String 角色名称 role_id Long 角色ID role_value String 发布商或插件ID user_id String 用户ID user_name String 用户名 状态码: 401 表6 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 403 表7 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 404 表8 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码
  • 响应参数 状态码: 200 表3 响应Body参数 参数 参数类型 描述 result Object 返回值 status String 状态 状态码: 403 表4 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 404 表5 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 406 表6 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 500 表7 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码
  • 响应示例 状态码: 200 OK { "result" : { "identifier" : "redhat.java", "instance_id" : "***", "extension_version" : "1.0.1", "status" : "AGREE" }, "status" : "success"} 状态码: 403 Forbidden { "error_msg" : "Instance does not belong to the user or tenant", "error_code" : "IDE.00010129"}
  • 请求参数 表1 请求Header参数 参数 是否必选 参数类型 描述 x-auth-token 是 String iam x-auth-token 表2 请求Body参数 参数 是否必选 参数类型 描述 region 否 String the region of user name 否 String the name of user email 否 String the email of user organization 否 String the organization of user phone_number 否 String the phone_number of user invitation_code 否 String the invitation_code
  • 请求示例 创建一个地域在北京,用户名为“name”,邮箱为“email@codeartssnap.com”,组织为“huawei”的用户。 POST https://{endpoint}/v2/aims/codemodelserver/join-request{ "region" : "北京", "name" : "name", "email" : "email@codeartssnap.com", "organization" : "huawei", "phone_number" : "13666666666", "invitation_code" : "gouliguojiashengsiyi"}
  • 响应参数 状态码: 200 表3 响应Body参数 参数 参数类型 描述 result Object 返回值 status String 状态 状态码: 401 表4 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 403 表5 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码
  • 响应参数 状态码: 200 表3 响应Body参数 参数 参数类型 描述 result Boolean 返回值 status String 状态 状态码: 403 表4 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 404 表5 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 406 表6 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码 状态码: 500 表7 响应Body参数 参数 参数类型 描述 error_msg String 错误描述 error_code String 错误码
共100000条
提示

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