Get the Modify or Upgrade Price for a Single Domain Windows Hosting Order Using the API
Summary
When you want to check the price for modifying or upgrading a Single Domain Windows Hosting order using the API. This article explains the required order and plan inputs and how the applicable price is returned.
Description
Gets the applicable modify or upgrade price for a particular Single Domain Windows Hosting order.
Parameters
| Name | Data Type | Required / Optional | Description |
|---|---|---|---|
auth-userid | Integer | Required | Your Live Account Reseller ID used to authenticate the API request. |
api-key | String | Required | Your API key used to authenticate the API request. |
order-id | Integer | Required | Order ID for which the modify or upgrade price is to be fetched. |
new-plan-id | Integer | Required | Plan ID of the new plan to which the order is to be upgraded or downgraded. |
months | Integer | Required | Number of months for the new plan. |
Get the New Plan ID
To retrieve the available plan IDs, use the Plan Details API.
HTTP Method
GET
Example Test URL Request
https://test.httpapi.com/api/products/plan-details.json?auth-userid=0&api-key=key
The Single Domain Windows Hosting plan details are returned under the following product keys:
US, Texas Server
singledomainhostingwindowsus
India Server
singledomainhostingwindowsin
Use the required plan ID returned in the response as the new-plan-id.
Get the Modify or Upgrade Price
HTTP Method
GET
Example Test URL Request
US, Texas Server
https://test.httpapi.com/api/singledomainhosting/windows/us/modify-pricing.json?auth-userid=0&api-key=key&order-id=0&new-plan-id=0&months=0
India Server
https://test.httpapi.com/api/singledomainhosting/windows/in/modify-pricing.json?auth-userid=0&api-key=key&order-id=0&new-plan-id=0&months=0
Response
Returns the applicable modify or upgrade price for the specified Single Domain Windows Hosting order.
Example:
{
"upgradecost": 0.0,
"modifiedOrderPrice": 0.0,
"endtime": "0000000000",
"remainingmonths": 0,
"currentOrderPrice": 0.0
}
Where:
-
currentOrderPrice— Current price of the order for the remaining months. -
modifiedOrderPrice— New applicable price of the order based on the new plan. -
upgradecost— Actual price applicable, calculated asmodifiedOrderPrice - currentOrderPrice.