Create Order
This action creates a new order through the API.
Method / Endpoint
POST/ {{API_URL}} buy
Request Parameters
Name | Requirement | Description |
---|---|---|
key | Yes | API Key |
type | Yes | Type of Product. Possible values: hosting, server, software, special, sms |
id | Yes | Product ID Number |
period_type | Yes | Which period the order will have. Possible values: none, year, month, week, week, day, hour |
period_duration | Yes | Period Duration of the Order |
options[...array...] | Optional | If information such as domain, hostname, nameserver, password, IP is needed in the order, it is sent in this parameter. |
Sample cURL Request
curl --location 'https://example.com/api/reseller/buy' \
--data '{
"key":"UzZBSlBWeWk0UEcrVWxlU0RjS1B1dz09",
"type":"hosting",
"id":33,
"period_type":"month",
"period_duration":1,
"options":
{
"domain":"example123.com"
}
}'
Sample JSON Response
{
"status": "successful",
"invoice_id": 3,
"order_id": 3,
"fee": "14.0000",
"fee_formatted": "$14"
}