SoftLayer API:订购许可证
SoftLayer API: order license
我正在使用方法 Product_Order.placeOrder 来订购许可证。问题是 complexType 和 packageId 的关系是什么。我可以同时指定 complexType 和 packageId 吗?我在哪里可以找到 API 文档?谢谢。
{'complexType': 'SoftLayer_Container_Product_Order_Software_License',
'quantity': xxx,
'packageId': xxx,
'prices': [{'id': xxx}]
}
complexType 让服务器知道您发送的数据类型结构是什么。 https://softlayer.github.io/article/soap/
Each WSDL defines that specific service’s available methods and
includes an XSD file that defines every complex type available to the
SoftLayer API.
Important API headers, such as authentication, initialization
parameters, and object masks are sent to the SoftLayer API as SOAP
headers. Each call header has an associated complex type.
当调用 placeOrder 时你需要发送一个 SoftLayer_Container_Product_Order 数据类型(一个基本的 orderData),一些 products/devices 需要设置额外的信息但是他们不在 SoftLayer_Container_Product_Order 中,因为它们属于从 SoftLayer_Container_Product_Order 继承的另一种数据类型。
SoftLayer_Container_Product_Order_Software_License 继承自 SoftLayer_Container_Product_Order 除非有不属于 SoftLayer_Container_Product_Order 的必需数据,否则您会遇到异常。
packageId 定义了您为订购所需产品而发送的价格。现在,某些产品可以使用相同的 complexType,但使用不同的 packageId,例如硬件服务器(请参阅 placeOrder 中的 table):
|Product | Order Container | Package type
------------------------------------------------------------------------------------------------
|Bare metal server by CPU | SoftLayer_Container_Product_Order_Hardware_Server | BARE_METAL_CPU |
|Bare metal server by core| SoftLayer_Container_Product_Order_Hardware_Server | BARE_METAL_CORE|
建议同时设置complexType和packageId,这有助于服务器更快地处理请求。
我正在使用方法 Product_Order.placeOrder 来订购许可证。问题是 complexType 和 packageId 的关系是什么。我可以同时指定 complexType 和 packageId 吗?我在哪里可以找到 API 文档?谢谢。
{'complexType': 'SoftLayer_Container_Product_Order_Software_License',
'quantity': xxx,
'packageId': xxx,
'prices': [{'id': xxx}]
}
complexType 让服务器知道您发送的数据类型结构是什么。 https://softlayer.github.io/article/soap/
Each WSDL defines that specific service’s available methods and includes an XSD file that defines every complex type available to the SoftLayer API.
Important API headers, such as authentication, initialization parameters, and object masks are sent to the SoftLayer API as SOAP headers. Each call header has an associated complex type.
当调用 placeOrder 时你需要发送一个 SoftLayer_Container_Product_Order 数据类型(一个基本的 orderData),一些 products/devices 需要设置额外的信息但是他们不在 SoftLayer_Container_Product_Order 中,因为它们属于从 SoftLayer_Container_Product_Order 继承的另一种数据类型。
SoftLayer_Container_Product_Order_Software_License 继承自 SoftLayer_Container_Product_Order 除非有不属于 SoftLayer_Container_Product_Order 的必需数据,否则您会遇到异常。
packageId 定义了您为订购所需产品而发送的价格。现在,某些产品可以使用相同的 complexType,但使用不同的 packageId,例如硬件服务器(请参阅 placeOrder 中的 table):
|Product | Order Container | Package type
------------------------------------------------------------------------------------------------
|Bare metal server by CPU | SoftLayer_Container_Product_Order_Hardware_Server | BARE_METAL_CPU |
|Bare metal server by core| SoftLayer_Container_Product_Order_Hardware_Server | BARE_METAL_CORE|
建议同时设置complexType和packageId,这有助于服务器更快地处理请求。