Updated on 2025-11-07 GMT+08:00

Converting a Product Type to a Theme

Function

Convert a product type to a theme.

URI

GET /v2/irobot/themes/convert

Table 1 Query parameters

Parameter

Mandatory

Type

Description

product_type_id

No

String

Specifies the product type ID.

Minimum length: 1

Maximum length: 64

product_type_name

No

String

Specifies the product type name.

Minimum length: 0

Maximum length: 200

product_type_short_name

No

String

Specifies the product type abbreviation.

Minimum length: 0

Maximum length: 200

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

Specifies the user token.

It can be obtained by calling the IAM API (value of X-Subject-Token in the response header).

Minimum length: 1

Maximum length: 5000

x-service-key

Yes

String

Specifies the flag for invoking the intelligent customer service.

Minimum length: 1

Maximum length: 32

x-site

No

String

Specifies the site flag. The options are 0 (Chinese mainland) and 1 (international).

Minimum length: 0

Maximum length: 1

x-language

No

String

Specifies the region language with a language abbreviation. The options are en-us and zh-cn.

Minimum length: 0

Maximum length: 32

Response Parameters

Status code: 200

Table 3 Response body parameters

Parameter

Type

Description

themes

Array of RelationTheme objects

Specifies the list of associated themes.

Array length: 0 - 65535

error_code

String

Specifies the error code.

Minimum length: 0

Maximum length: 32

error_msg

String

Describes the error.

Minimum length: 0

Maximum length: 32

product_type_id

String

Specifies the product type ID.

Minimum length: 0

Maximum length: 64

theme_name

String

Specifies the theme name.

Minimum length: 0

Maximum length: 200

Table 4 RelationTheme

Parameter

Type

Description

theme_name

String

Specifies the name of the theme.

Minimum length: 0

Maximum length: 65535

relation_type

String

Specifies the type of the theme.

Options:

  • NON_PRIMARY

  • PRIMARY

Request Example

GET https://{endpoint}/v2/irobot/themes/convert?product_type_id=product-id&product_type_name=Product name&product_type_short_name=ECS

null

Response Example

Status code: 200

Code 200 is returned if the operation is successful.

{
  "themes" : [ {
    "theme_name" : "Theme name",
    "relation_type" : "PRIMARY"
  } ],
  "product_type_id" : "Product type ID",
  "theme_name" : "Theme name"
}

Status Codes

Status Code

Description

200

Code 200 is returned if the operation is successful.

Error Codes

See Error Codes.