Updated on 2023-09-01 GMT+08:00

Upgrading an Instance

API Description

A customer upgrades a purchased resource. After the upgrade order is paid, KooGallery calls this API to ask you to upgrade the resource and record the upgraded product data.

The following figure shows the process of upgrading a product.

Request Message

The following table describes the request parameters.

Request method: POST

Parameter

Mandatory

Type

Maximum Length

Description

activity

Yes

String

32

Request ID, which is used to distinguish the scenario.

For upgrades, the value is upgradeInstance.

instanceId

Yes

String

64

Instance ID.

NOTE:

The upgrade does not change instanceId.

orderId

Yes

String

64

Upgrade order ID.

NOTE:

An order is generated for the upgrade.

orderLineId

Yes

String

64

KooGallery order line ID.

testFlag

No

String

2

Whether a request is submitted for debugging.

  • 1: debugging request.
  • 0: non-debugging request.

The default value is 0.

Example request:

curl -X POST 'https://www.isvwebsite.com/saasproduce?signature=9D49F9BF09D69F7A**********0E07AF95FEE9E5BEF5218DA407&timestamp=1680510876429&nonce=D8FE86FA6ABE90CA63A72B3256743D3D869648FE99A96354E635F032629F6C21' -H 'Accept:application/json' -H 'Content-Type:application/json;charset=utf8' -d'{"activity":"upgradeInstance","instanceId":"10e75*********b-81d03469a10e","orderId":"CS2*******4LVS","orderLineId":"CS221118*******-000001","testFlag":"0"}'

Response Message

The following table describes the response parameters.

Parameter

Mandatory

Type

Maximum Length

Description

resultCode

Yes

String

6

Invocation result code.

For details, see Result Codes.

resultMsg

No

String

255

Invocation result description.

Example response:

{ 
    "resultCode":"000000", 
    "resultMsg":"success." 
}