NAV
فناوران شبکه سینداد
bash php python

Introduction

Our HTTP REST API allows you to manage vital details of your account and services in client portal. JSON is used for all API returns

Use left menu to browse trough available methods, use right menu to check required parameters, data to post and code samples in various languages.

Swagger Doc: You can download or display the JSON to generate documentation in Swagger.

Authentication

Basic Authentication

# pass the correct header with each request (-u option)
curl 'https://sindad.net/api/details' \
    -u "username:password"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$resp = $client->get('/details');
# python requests module handles basic authentication if provided with auth parameter
payload = username
req = requests.get('https://sindad.net/api/details', auth=('username', 'password'))
print(req.json())

Make sure to replace username and password with your client area details.

This authentication method requires that you send your client area username (email address) and password with each request.

API calls that require authentication expect a header in the form of Authorization: Basic <credentials>, where credentials is the Base64 encoding of username and password joined by a single colon :.

For example:
Authorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==

You can find more info on this authentication method here: Basic HTTP Authentication

Clientarea

Login

Generate new authorization token

POST_DATA="{
    \"username\": \"user@example.com\",
    \"password\": \"secret\"
}"

curl -X POST "https://sindad.net/api/login" \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
]);

$options = [
    'json' => [
        "username" => "user@example.com",
        "password" => "secret"
    ]
]
$resp = $client->post('/login', $options);
echo $resp->getBody();
payload = {
    'username': "user@example.com",
    'password': "secret"
}


req = requests.post('https://sindad.net/api/login', json=payload)
print(req.json())
Example Response:
{
    "token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJpc3MiOiJodHRw(...)5lZ9T79ft9uwOkqRRmIBbtR51_w",
    "refresh": "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJzdWIiOiIzMD(...)ChwIAb3zvxBu6kvULa2AwAt9U-I"
}

HTTP Request

POST /login

Query Parameters

Parameter Type Description
username string

Your acount email address

password string

Account password

Logout

Invalidate authorization token


curl -X POST "https://sindad.net/api/logout" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->post('/logout');
echo $resp->getBody();

auth=('username', 'password')

req = requests.post('https://sindad.net/api/logout', auth=auth)
print(req.json())
Example Response:
{
    "status": true
}

HTTP Request

POST /logout

Refresh Token

Generate new authorization token using refresh token

POST_DATA="{
    \"refresh_token\": \"refresh_tokenValue\"
}"

curl -X POST "https://sindad.net/api/token" \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
]);

$options = [
    'json' => [
        "refresh_token" => "refresh_tokenValue"
    ]
]
$resp = $client->post('/token', $options);
echo $resp->getBody();
payload = {
    'refresh_token': "refresh_tokenValue"
}


req = requests.post('https://sindad.net/api/token', json=payload)
print(req.json())
Example Response:
{
    "token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJpc3MiOiJodHR(...)vY2xlYiHGvauCWZD9B0VwXgHEzXDllqY",
    "refresh": "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJzdWIiOiJBQ(...)Rmivc_u3YA_kgDqOPtUuGNXOzueXYtZw"
}

HTTP Request

POST /token

Query Parameters

Parameter Type Description
refresh_token string

Refresh token previously obtained from POST /login

Revoke Token

Invalidate authorization and refresh token. Pass refresh token or call this method with valid access token

POST_DATA="{
    \"refresh_token\": \"refresh_tokenValue\"
}"

curl -X POST "https://sindad.net/api/revoke" \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
]);

$options = [
    'json' => [
        "refresh_token" => "refresh_tokenValue"
    ]
]
$resp = $client->post('/revoke', $options);
echo $resp->getBody();
payload = {
    'refresh_token': "refresh_tokenValue"
}


req = requests.post('https://sindad.net/api/revoke', json=payload)
print(req.json())
Example Response:
{
    "status": true
}

HTTP Request

POST /revoke

Query Parameters

Parameter Type Description
refresh_token string

User Details

Return registration details for my account


curl -X GET "https://sindad.net/api/details" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/details');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/details', auth=auth)
print(req.json())
Example Response:
{
    "client": {
        "id": "26",
        "email": "api@example.com",
        "lastlogin": "2016-12-30 12:24:28",
        "ip": "172.100.2.1",
        "host": "hostname",
        "firstname": "Joe",
        "lastname": "Doe",
        "companyname": "",
        "address1": "Pretty View Lane",
        "address2": "3294",
        "city": "Santa Rosa",
        "state": "California",
        "postcode": "95401",
        "country": "US",
        "phonenumber": "+1.24123123"
    }
}

HTTP Request

GET /details

Update User Details

Update registration details under my account

POST_DATA="{
    \"email\": \"emailValue\",
    \"firstname\": \"firstnameValue\",
    \"lastname\": \"lastnameValue\",
    \"socialsecuritynumberpersonalid\": \"socialsecuritynumberpersonalidValue\",
    \"companyname\": \"companynameValue\",
    \"address1\": \"address1Value\",
    \"city\": \"cityValue\",
    \"state\": \"stateValue\",
    \"postcode\": \"postcodeValue\",
    \"country\": \"countryValue\",
    \"phonenumber\": \"phonenumberValue\",
    \"type\": \"typeValue\",
    \"mellicardimage\": \"mellicardimageValue\",
    \"telegramnotifications\": \"telegramnotificationsValue\",
    \"langcustomline0180\": \"langcustomline0180Value\"
}"

curl -X PUT "https://sindad.net/api/details" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "email" => "emailValue",
        "firstname" => "firstnameValue",
        "lastname" => "lastnameValue",
        "socialsecuritynumberpersonalid" => "socialsecuritynumberpersonalidValue",
        "companyname" => "companynameValue",
        "address1" => "address1Value",
        "city" => "cityValue",
        "state" => "stateValue",
        "postcode" => "postcodeValue",
        "country" => "countryValue",
        "phonenumber" => "phonenumberValue",
        "type" => "typeValue",
        "mellicardimage" => "mellicardimageValue",
        "telegramnotifications" => "telegramnotificationsValue",
        "langcustomline0180" => "langcustomline0180Value"
    ]
]
$resp = $client->put('/details', $options);
echo $resp->getBody();
payload = {
    'email': "emailValue",
    'firstname': "firstnameValue",
    'lastname': "lastnameValue",
    'socialsecuritynumberpersonalid': "socialsecuritynumberpersonalidValue",
    'companyname': "companynameValue",
    'address1': "address1Value",
    'city': "cityValue",
    'state': "stateValue",
    'postcode': "postcodeValue",
    'country': "countryValue",
    'phonenumber': "phonenumberValue",
    'type': "typeValue",
    'mellicardimage': "mellicardimageValue",
    'telegramnotifications': "telegramnotificationsValue",
    'langcustomline0180': "langcustomline0180Value"
}

auth=('username', 'password')

req = requests.put('https://sindad.net/api/details', json=payload, auth=auth)
print(req.json())
Example Response:
{
    "client": {
        "id": "26",
        "email": "api@example.com",
        "lastlogin": "2016-12-30 12:34:20",
        "ip": "172.100.2.1",
        "host": "hostname",
        "firstname": "Joe",
        "lastname": "Doe",
        "companyname": "",
        "address1": "Pretty View Lane",
        "address2": "3194",
        "city": "Santa Rosa",
        "state": "California",
        "postcode": "95401",
        "country": "US",
        "phonenumber": "+1.24123123"
    },
    "info": [
        "client_info_updated"
    ]
}

HTTP Request

PUT /details

Query Parameters

Parameter Type Description
email string

Email Address

firstname string

First Name

lastname string

Last Name

socialsecuritynumberpersonalid string

کد ملی

Value pattern: ^([0-9]){10}$

companyname string

Organization

address1 string

Address 1

city string

City

state string

State

postcode string

Post code

country string

Country

phonenumber string

Phone

Value pattern: ^(\+98)?\s?0?9([0-9]){9}$

type string

Account Type

Available values: Private, Company.

mellicardimage string

تصویر کارت ملی

Value pattern: .jpg;.gif;.png;.pdf

telegramnotifications string[]

دریافت نوتیفیکیشن از تلگرام - می‌توانید نوتیفیکیشن‌های مربوط به تیکت‌ها، صورتحساب‌ها و ... را با فعال کردن این گزینه از طریق تلگرام دریافت کنید.

Available values: بله.

langcustomline0180 string

تلفن ثابت شرکت

Get Affiliate summary


curl -X GET "https://sindad.net/api/affiliates/summary" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/affiliates/summary');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/affiliates/summary', auth=auth)
print(req.json())

HTTP Request

GET /affiliates/summary

Get Affiliate campaigns


curl -X GET "https://sindad.net/api/affiliates/campaigns" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/affiliates/campaigns');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/affiliates/campaigns', auth=auth)
print(req.json())

HTTP Request

GET /affiliates/campaigns

Get Affiliate commissions


curl -X GET "https://sindad.net/api/affiliates/commissions" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/affiliates/commissions');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/affiliates/commissions', auth=auth)
print(req.json())

HTTP Request

GET /affiliates/commissions

Get Affiliate payouts


curl -X GET "https://sindad.net/api/affiliates/payouts" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/affiliates/payouts');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/affiliates/payouts', auth=auth)
print(req.json())

HTTP Request

GET /affiliates/payouts

Get Affiliate vouchers


curl -X GET "https://sindad.net/api/affiliates/vouchers" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/affiliates/vouchers');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/affiliates/vouchers', auth=auth)
print(req.json())

HTTP Request

GET /affiliates/vouchers

Get Affiliate commission plans


curl -X GET "https://sindad.net/api/affiliates/commissionplans" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/affiliates/commissionplans');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/affiliates/commissionplans', auth=auth)
print(req.json())

HTTP Request

GET /affiliates/commissionplans

List contacts

Return a list of contacts on this account


curl -X GET "https://sindad.net/api/contact" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/contact');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/contact', auth=auth)
print(req.json())
Example Response:
{
    "contacts": [
        {
            "email": "mary@example.com",
            "id": "49",
            "firstname": "Mary",
            "lastname": "Sue",
            "companyname": "",
            "company": "0",
            "lastlogin": "0000-00-00 00:00:00"
        }
    ]
}

HTTP Request

GET /contact

Add contact

Create new contact account, if password is provided you can use provided email addres to login as that contact.

POST_DATA="{
    \"password\": \"passwordValue\",
    \"privileges\": \"privilegesValue\",
    \"email\": \"emailValue\",
    \"firstname\": \"firstnameValue\",
    \"lastname\": \"lastnameValue\",
    \"socialsecuritynumberpersonalid\": \"socialsecuritynumberpersonalidValue\",
    \"companyname\": \"companynameValue\",
    \"address1\": \"address1Value\",
    \"city\": \"cityValue\",
    \"state\": \"stateValue\",
    \"postcode\": \"postcodeValue\",
    \"country\": \"countryValue\",
    \"phonenumber\": \"phonenumberValue\",
    \"type\": \"typeValue\",
    \"mellicardimage\": \"mellicardimageValue\",
    \"telegramnotifications\": \"telegramnotificationsValue\",
    \"langcustomline0180\": \"langcustomline0180Value\"
}"

curl -X POST "https://sindad.net/api/contact" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "password" => "passwordValue",
        "privileges" => "privilegesValue",
        "email" => "emailValue",
        "firstname" => "firstnameValue",
        "lastname" => "lastnameValue",
        "socialsecuritynumberpersonalid" => "socialsecuritynumberpersonalidValue",
        "companyname" => "companynameValue",
        "address1" => "address1Value",
        "city" => "cityValue",
        "state" => "stateValue",
        "postcode" => "postcodeValue",
        "country" => "countryValue",
        "phonenumber" => "phonenumberValue",
        "type" => "typeValue",
        "mellicardimage" => "mellicardimageValue",
        "telegramnotifications" => "telegramnotificationsValue",
        "langcustomline0180" => "langcustomline0180Value"
    ]
]
$resp = $client->post('/contact', $options);
echo $resp->getBody();
payload = {
    'password': "passwordValue",
    'privileges': "privilegesValue",
    'email': "emailValue",
    'firstname': "firstnameValue",
    'lastname': "lastnameValue",
    'socialsecuritynumberpersonalid': "socialsecuritynumberpersonalidValue",
    'companyname': "companynameValue",
    'address1': "address1Value",
    'city': "cityValue",
    'state': "stateValue",
    'postcode': "postcodeValue",
    'country': "countryValue",
    'phonenumber': "phonenumberValue",
    'type': "typeValue",
    'mellicardimage': "mellicardimageValue",
    'telegramnotifications': "telegramnotificationsValue",
    'langcustomline0180': "langcustomline0180Value"
}

auth=('username', 'password')

req = requests.post('https://sindad.net/api/contact', json=payload, auth=auth)
print(req.json())
Example Response:
{
    "contact_id": "1",        
    "info": [
        "profile_added"
    ]
}

HTTP Request

POST /contact

Query Parameters

Parameter Type Description
password string

Optional, allows you to login as contact

privileges array

Array with privileges that you want to enable. Formatted the same way as output from GET /contact/privileges

email string

Email Address

firstname string

First Name

lastname string

Last Name

socialsecuritynumberpersonalid string

کد ملی

Value pattern: ^([0-9]){10}$

companyname string

Organization

address1 string

Address 1

city string

City

state string

State

postcode string

Post code

country string

Country

phonenumber string

Phone

Value pattern: ^(\+98)?\s?0?9([0-9]){9}$

type string

Account Type

Available values: Private, Company.

mellicardimage string

تصویر کارت ملی

Value pattern: .jpg;.gif;.png;.pdf

telegramnotifications string[]

دریافت نوتیفیکیشن از تلگرام - می‌توانید نوتیفیکیشن‌های مربوط به تیکت‌ها، صورتحساب‌ها و ... را با فعال کردن این گزینه از طریق تلگرام دریافت کنید.

Available values: بله.

langcustomline0180 string

تلفن ثابت شرکت

Contact privileges

List possible contact privileges. Each domain and service may list additional privileges, depending on available features.


curl -X GET "https://sindad.net/api/contact/privileges" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/contact/privileges');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/contact/privileges', auth=auth)
print(req.json())
Example Response:
{
    "privileges": {
        "billing": [
            "emails", // Receive billing notifications
            "payinvoice", // Allow to view/pay invoices
            "orders", // Allow to place new orders
            "balance", // View account balance
            "addfunds", // Add account funds
            "creditcard" // Edit Credit Card details
        ],
        "support": [
            "newticket", // Open new tickets
            "tickets", // View all tickets
            "closeticket", // Close tickets
            "emails" // Receive email notifications from support
        ],
        "misc": [
            "editmain", // Modify main profile details
            "emails", // View emails history
            "editipaccess", // Edit allowed IP access
            "manageprofiles", // Add / Edit contacts
            "affiliates" // Access affiliates section
        ],
        "services": {
            "full": 1, // Full control over services
            "332": [
                "basic", // View basic details
                "billing", // View billing info
                "cancelation", // Request cancellation
                "upgrade", // Upgrade / Downgrade
                "notify", // Receive related email notifications  
                (...)
                "logindetails"
            ]
        },
        "domains": {
            "full": 1, // Full control over domains
            "523": [
                "basic", // View basic details
                "renew", // Renew domain
                "notify", // Receive related email notifications  
                "contactinfo", // Contact Information
                (...)
                "nameservers" // Manage Nameservers
            ]
        }
    }
}

HTTP Request

GET /contact/privileges

Get contacts details

Return array with contact details


curl -X GET "https://sindad.net/api/contact/@id" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/contact/@id');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/contact/@id', auth=auth)
print(req.json())
Example Response:
{
    "contact": {
        "id": "49",
        "email": "mary@example.com",
        "firstname": "Mary",
        "lastname": "Sue",
        "companyname": "",
        "address1": "Pretty View Lane",
        "address2": "3194",
        "city": "Santa Rosa",
        "state": "California",
        "postcode": "95401",
        "country": "US",
        "phonenumber": "+1.24123123",
        "type": "Private",
        "privileges" : {
            "support" : ["tickets", "newticket"]
        }
    }
}

HTTP Request

GET /contact/@id

Query Parameters

Parameter Type Description
id int

Contact ID

Edit contact

Change contact details`

POST_DATA="{
    \"privileges\": \"privilegesValue\",
    \"email\": \"emailValue\",
    \"firstname\": \"firstnameValue\",
    \"lastname\": \"lastnameValue\",
    \"socialsecuritynumberpersonalid\": \"socialsecuritynumberpersonalidValue\",
    \"companyname\": \"companynameValue\",
    \"address1\": \"address1Value\",
    \"city\": \"cityValue\",
    \"state\": \"stateValue\",
    \"postcode\": \"postcodeValue\",
    \"country\": \"countryValue\",
    \"phonenumber\": \"phonenumberValue\",
    \"type\": \"typeValue\",
    \"mellicardimage\": \"mellicardimageValue\",
    \"telegramnotifications\": \"telegramnotificationsValue\",
    \"langcustomline0180\": \"langcustomline0180Value\"
}"

curl -X PUT "https://sindad.net/api/contact/@id" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "privileges" => "privilegesValue",
        "email" => "emailValue",
        "firstname" => "firstnameValue",
        "lastname" => "lastnameValue",
        "socialsecuritynumberpersonalid" => "socialsecuritynumberpersonalidValue",
        "companyname" => "companynameValue",
        "address1" => "address1Value",
        "city" => "cityValue",
        "state" => "stateValue",
        "postcode" => "postcodeValue",
        "country" => "countryValue",
        "phonenumber" => "phonenumberValue",
        "type" => "typeValue",
        "mellicardimage" => "mellicardimageValue",
        "telegramnotifications" => "telegramnotificationsValue",
        "langcustomline0180" => "langcustomline0180Value"
    ]
]
$resp = $client->put('/contact/@id', $options);
echo $resp->getBody();
payload = {
    'privileges': "privilegesValue",
    'email': "emailValue",
    'firstname': "firstnameValue",
    'lastname': "lastnameValue",
    'socialsecuritynumberpersonalid': "socialsecuritynumberpersonalidValue",
    'companyname': "companynameValue",
    'address1': "address1Value",
    'city': "cityValue",
    'state': "stateValue",
    'postcode': "postcodeValue",
    'country': "countryValue",
    'phonenumber': "phonenumberValue",
    'type': "typeValue",
    'mellicardimage': "mellicardimageValue",
    'telegramnotifications': "telegramnotificationsValue",
    'langcustomline0180': "langcustomline0180Value"
}

auth=('username', 'password')

req = requests.put('https://sindad.net/api/contact/@id', json=payload, auth=auth)
print(req.json())
Example Response:
{
    "info": [
        "profile_updated"
    ]
}

HTTP Request

PUT /contact/@id

Query Parameters

Parameter Type Description
id int
privileges array

Array with privileges that you want to enable. Formatted the same way as output from GET /contact/privileges

email string

Email Address

firstname string

First Name

lastname string

Last Name

socialsecuritynumberpersonalid string

کد ملی

Value pattern: ^([0-9]){10}$

companyname string

Organization

address1 string

Address 1

city string

City

state string

State

postcode string

Post code

country string

Country

phonenumber string

Phone

Value pattern: ^(\+98)?\s?0?9([0-9]){9}$

type string

Account Type

Available values: Private, Company.

mellicardimage string

تصویر کارت ملی

Value pattern: .jpg;.gif;.png;.pdf

telegramnotifications string[]

دریافت نوتیفیکیشن از تلگرام - می‌توانید نوتیفیکیشن‌های مربوط به تیکت‌ها، صورتحساب‌ها و ... را با فعال کردن این گزینه از طریق تلگرام دریافت کنید.

Available values: بله.

langcustomline0180 string

تلفن ثابت شرکت

List all portal notifications

Return a list of all portal notifications.


curl -X GET "https://sindad.net/api/notifications" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/notifications');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/notifications', auth=auth)
print(req.json())

HTTP Request

GET /notifications

Query Parameters

Parameter Type Description
rel_type string

Optional, return only by relation type

rel_id string

Optional, return only by relation id

List new portal notifications

Return only new portal notifications.


curl -X GET "https://sindad.net/api/notifications/new" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/notifications/new');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/notifications/new', auth=auth)
print(req.json())

HTTP Request

GET /notifications/new

Query Parameters

Parameter Type Description
rel_type string

Optional, return only by relation type

rel_id string

Optional, return only by relation id

Acknowledge notification

Marks the notification as read


curl -X PUT "https://sindad.net/api/notifications/@id/ack" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->put('/notifications/@id/ack');
echo $resp->getBody();

auth=('username', 'password')

req = requests.put('https://sindad.net/api/notifications/@id/ack', auth=auth)
print(req.json())

HTTP Request

PUT /notifications/@id/ack

Query Parameters

Parameter Type Description
id int

Billing

Account balance

Get current account balance(unpaid invoices total), account credit


curl -X GET "https://sindad.net/api/balance" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/balance');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/balance', auth=auth)
print(req.json())
Example Response:
{
    {
        "success": true,
        "details": {
            "currency": "USD",
            "acc_balance": "123456.55",
            "acc_credit": "0.00"
        }
    }
}

HTTP Request

GET /balance

List Invoices

List all invoices under my account


curl -X GET "https://sindad.net/api/invoice" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/invoice');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/invoice', auth=auth)
print(req.json())
Example Response:
{
    "invoices": [
        {
            "id": "308976",
            "date": "2016-12-30",
            "dateorig": "2016-12-30",
            "duedate": "2017-01-06",
            "paybefore": "2017-01-06",
            "total": "19.65",
            "datepaid": "2016-12-30 12:40:47",
            "status": "Paid",
            "merge_id": null,
            "number": "2016\/12\/1",
            "currency": "USD"
        }
    ]
}

HTTP Request

GET /invoice

Invoice Details

Get invoice details


curl -X GET "https://sindad.net/api/invoice/@id" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/invoice/@id');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/invoice/@id', auth=auth)
print(req.json())
Example Response:
{
    "invoice": {
        "id": "308976",
        "status": "Paid",
        "date": "2016-12-30",
        "duedate": "2017-01-06",
        "paybefore": "2017-01-06",
        "datepaid": "2016-12-30 12:40:47",
        "subtotal": 16.24,
        "credit": 0,
        "tax": 3.41,
        "taxrate": 21,
        "tax2": 0,
        "taxrate2": 0,
        "taxexempt": "0",
        "total": 19.65,
        "rate": 1,
        "rate2": 0,
        "rate3": 1,
        "notes": "",
        "items": [
            {
                "id": "12305",
                "invoice_id": "308976",
                "type": "Other",
                "item_id": "0",
                "description": "Example Service",
                "amount": "15.00",
                "taxed": "1",
                "qty": "1.00",
                "linetotal": "15.00"
            },
            {
                "id": "12309",
                "invoice_id": "308976",
                "type": "Other",
                "item_id": "-2",
                "description": "PayPal Payment Fee",
                "amount": "1.24",
                "taxed": "1",
                "qty": "1.00",
                "linetotal": "1.24"
            }
        ],
        "client": {
            "id": "26",
            "email": "api@example.com",
            "firstname": "Joe",
            "lastname": "Doe",
            "companyname": "",
            "address1": "Pretty View Lane",
            "address2": "3194",
            "city": "Santa Rosa",
            "state": "California",
            "postcode": "95401",
            "country": "US",
            "phonenumber": "+1.24123123"
        },
        "number": "2016\/12\/1",
        "currency": "USD"
    }
}

HTTP Request

GET /invoice/@id

Query Parameters

Parameter Type Description
id int

Apply credit

Apply account credit to invoice

POST_DATA="{
    \"amount\": \"amountValue\"
}"

curl -X POST "https://sindad.net/api/invoice/@id/credit" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "amount" => "amountValue"
    ]
]
$resp = $client->post('/invoice/@id/credit', $options);
echo $resp->getBody();
payload = {
    'amount': "amountValue"
}

auth=('username', 'password')

req = requests.post('https://sindad.net/api/invoice/@id/credit', json=payload, auth=auth)
print(req.json())
Example Response:
{
    "success": true,
    "invoice_status": "Paid",
    "applied": 2.1
}

HTTP Request

POST /invoice/@id/credit

Query Parameters

Parameter Type Description
id int
amount decimal

Optional credit amount, when no value is specified maximum amount to fully pay the invoice will be used

Payment Methods

List available payment methods


curl -X GET "https://sindad.net/api/payment" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/payment');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/payment', auth=auth)
print(req.json())
Example Response:
{
    "payments": {
        "10": "BankTransfer",
        "9": "PayPal"
    }
}

HTTP Request

GET /payment

Payment Methods Fees

List available payment methods with fees


curl -X GET "https://sindad.net/api/payment/fees" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/payment/fees');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/payment/fees', auth=auth)
print(req.json())
Example Response:
{
    "payments": [
        {
            "id": 1,
            "name": "Bank Transfer",
            "fixed_fee": "0.0",
            "percent_fee": "0.0",
        },
        {
            "id": 2,
            "name": "Stripe",
            "fixed_fee": "0.5",
            "percent_fee": "2.9",
        },
        {
            "id": 4,
            "name": "Credit Card",
            "fixed_fee": "0.1",
            "percent_fee": "2.4"
        },
        {
            "id": 5,
            "name": "PayPal",
            "fixed_fee": "0.3",
            "percent_fee": "2.9"
        }
    ]
}

HTTP Request

GET /payment/fees

Support

List Tickets

List support tickets under my account


curl -X GET "https://sindad.net/api/tickets" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/tickets');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/tickets', auth=auth)
print(req.json())
Example Response:
{
    "tickets": [
        {
            "client_read": "1",
            "ticket_number": "736633",
            "date": "2016-12-30 12:48:13",
            "deptname": "Billing",
            "subject": "Lore Ipsum",
            "status": "Open"
        }
    ]
}

HTTP Request

GET /tickets

Ticket details

Get ticket details, including all replies


curl -X GET "https://sindad.net/api/tickets/@number" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/tickets/@number');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/tickets/@number', auth=auth)
print(req.json())
Example Response:
{
    "ticket": {
        "date": "2016-12-30 12:48:13",
        "ticket_number": "736633",
        "name": "Joe Doe",
        "email": "api@example.com",
        "subject": "Lore Ipsum",
        "body": "Donec sollicitudin molestie malesuada. \r\nSed porttitor lectus nibh. Vivamus magna justo, \r\nlacinia eget consectetur sed, convallis at tellus.",
        "status": "Answered",
        "client_read": "1",
        "deptname": "Billing"
    },
    "replies": [
        {
            "id": "929",
            "name": "Suppport Staff",
            "date": "2016-12-30 12:51:04",
            "body": "Vestibulum ac diam sit amet quam \r\nvehicula elementum sed sit amet dui. \r\nPraesent sapien massa\r\n\r\n-- Maecenas efficitur elit est --",
            "status": "Sent",
            "type": "Admin"
        }
    ]
}

HTTP Request

GET /tickets/@number

Query Parameters

Parameter Type Description
number int

Ticket number

Ticket attachment

Get ticket attachment


curl -X GET "https://sindad.net/api/ticket/attachment/@file" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/ticket/attachment/@file');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/ticket/attachment/@file', auth=auth)
print(req.json())

HTTP Request

GET /ticket/attachment/@file

Query Parameters

Parameter Type Description
number int

Ticket number

file string

Attachment id

Create Ticket

Submit new ticket

POST_DATA="{
    \"dept_id\": 1,
    \"subject\": \"Subject\",
    \"body\": \"Message ...\"
}"

curl -X POST "https://sindad.net/api/tickets" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "dept_id" => 1,
        "subject" => "Subject",
        "body" => "Message ..."
    ]
]
$resp = $client->post('/tickets', $options);
echo $resp->getBody();
payload = {
    'dept_id': 1,
    'subject': "Subject",
    'body': "Message ..."
}

auth=('username', 'password')

req = requests.post('https://sindad.net/api/tickets', json=payload, auth=auth)
print(req.json())
Example Response:
{
    "ticket": 865650
}

HTTP Request

POST /tickets

Query Parameters

Parameter Type Description
dept_id int

Department id

subject string

Ticket subject

body string

Ticket message

Create Reply

Reply to ticket

POST_DATA="{
    \"body\": \"reply text ..\"
}"

curl -X POST "https://sindad.net/api/tickets/@number" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "body" => "reply text .."
    ]
]
$resp = $client->post('/tickets/@number', $options);
echo $resp->getBody();
payload = {
    'body': "reply text .."
}

auth=('username', 'password')

req = requests.post('https://sindad.net/api/tickets/@number', json=payload, auth=auth)
print(req.json())
Example Response:
{
    "info": [
        "reply_added"
    ]
}

HTTP Request

POST /tickets/@number

Query Parameters

Parameter Type Description
number int

Ticket number

body string

Reply message

Re-open ticket

Try to re-open closed ticket


curl -X PUT "https://sindad.net/api/tickets/@number/open" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->put('/tickets/@number/open');
echo $resp->getBody();

auth=('username', 'password')

req = requests.put('https://sindad.net/api/tickets/@number/open', auth=auth)
print(req.json())
Example Response:
{
    "status": true
}

HTTP Request

PUT /tickets/@number/open

Query Parameters

Parameter Type Description
number int

Ticket number

Close ticket

Send request to close a ticket


curl -X PUT "https://sindad.net/api/tickets/@number/close" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->put('/tickets/@number/close');
echo $resp->getBody();

auth=('username', 'password')

req = requests.put('https://sindad.net/api/tickets/@number/close', auth=auth)
print(req.json())
Example Response:
{
    "status": true
}

HTTP Request

PUT /tickets/@number/close

Query Parameters

Parameter Type Description
number int

Ticket number

List ticket departments

Get the list of ticket departments


curl -X GET "https://sindad.net/api/ticket/departments" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/ticket/departments');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/ticket/departments', auth=auth)
print(req.json())

HTTP Request

GET /ticket/departments

Services

List services

List all services under your account


curl -X GET "https://sindad.net/api/service" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service', auth=auth)
print(req.json())
Example Response:
{
    "services": [
        {
            "id": "301",
            "domain": "examplename.com",
            "total": "9.99",
            "status": "Pending",
            "billingcycle": "Monthly",
            "next_due": "2017-12-30",
            "category": "Hosting",
            "category_url": "hosting",
            "name": "Starter Hosting"
        }
    ]
}

HTTP Request

GET /service

Service details

Return details for service @id


curl -X GET "https://sindad.net/api/service/@id" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id', auth=auth)
print(req.json())
Example Response:
{
    "service": {
        "id": "301",
        "date_created": "2016-12-30",
        "domain": "examplename.com",
        "firstpayment": "9.99",
        "total": "9.99",
        "billingcycle": "Monthly",
        "next_due": "2017-12-30",
        "next_invoice": "2017-01-27",
        "status": "Active",
        "label": "",
        "username": "examplen",
        "password": "pdtzc",
        "name": "Starter Hosting"
    }
}

HTTP Request

GET /service/@id

Query Parameters

Parameter Type Description
id int

Service id

List service methods

List methods available for service


curl -X GET "https://sindad.net/api/service/@id/methods" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/methods');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/methods', auth=auth)
print(req.json())
Example Response:
{
    "methods": [
        {
            "name": "Upgrade Request",
            "method": "POST",
            "route": "\/service\/@id\/upgrade"
        },
        {
            "name": "Upgrade Options",
            "method": "GET",
            "route": "\/service\/@id\/upgrade"
        },
        {
            "name": "Change service label",
            "method": "POST",
            "route": "\/service\/@id\/label"
        },
        {
            "name": "Service label",
            "method": "GET",
            "route": "\/service\/@id\/label"
        },
        {
            "name": "Cancel Service",
            "method": "POST",
            "route": "\/service\/@id\/cancel"
        }
    ]
}

HTTP Request

GET /service/@id/methods

Query Parameters

Parameter Type Description
id int

Upgrade Options

List upgrade options


curl -X GET "https://sindad.net/api/service/@id/upgrade" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/upgrade');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/upgrade', auth=auth)
print(req.json())
Example Response:
{
    "resources": [
        {
            "id": 1557,
            "name": "Bandwidth",
            "type": "select",
            "items": [
                {
                    "id": "9953",
                    "name": "100 GB",
                    "price": 1,
                    "setup_price": 0,
                    "selected": true
                },
                {
                    "id": "10103",
                    "name": "500 GB",
                    "price": 5,
                    "setup_price": 0,
                    "selected": false
                },
                {
                    "id": "10104",
                    "name": "1 TB",
                    "price": 10,
                    "setup_price": 0,
                    "selected": false
                }
            ]
        }
    ],
    "package": []
}

HTTP Request

GET /service/@id/upgrade

Query Parameters

Parameter Type Description
id int

Upgrade Request

Estimate or request upgrade

// Format of ''resources'' paremeter
{
    "resource_id" : "qty_value", // sliders & qty fields
    "resource_id" : "item_id", // dropdown & radio fields
    "resource_id" : {
        "item_id": "qty_value" // dropdown with qty field
    }
}
POST_DATA="{
    \"resources\": \"resourcesValue\",
    \"package\": \"packageValue\",
    \"cycle\": \"cycleValue\",
    \"send\": \"sendValue\"
}"

curl -X POST "https://sindad.net/api/service/@id/upgrade" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "resources" => "resourcesValue",
        "package" => "packageValue",
        "cycle" => "cycleValue",
        "send" => "sendValue"
    ]
]
$resp = $client->post('/service/@id/upgrade', $options);
echo $resp->getBody();
payload = {
    'resources': "resourcesValue",
    'package': "packageValue",
    'cycle': "cycleValue",
    'send': "sendValue"
}

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/upgrade', json=payload, auth=auth)
print(req.json())

HTTP Request

POST /service/@id/upgrade

Query Parameters

Parameter Type Description
id int

Service id

resources array

array with resource values

package int

New package id, optonal when upgrading resources

cycle string

New billing cycle, optonal when upgrading resources

send boolean

Set to true when you want to send your upgrade request

Cancel Service

Request service cancellation

POST_DATA="{
    \"immediate\": \"immediateValue\",
    \"reason\": \"reasonValue\"
}"

curl -X POST "https://sindad.net/api/service/@id/cancel" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "immediate" => "immediateValue",
        "reason" => "reasonValue"
    ]
]
$resp = $client->post('/service/@id/cancel', $options);
echo $resp->getBody();
payload = {
    'immediate': "immediateValue",
    'reason': "reasonValue"
}

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/cancel', json=payload, auth=auth)
print(req.json())
Example Response:
{
  "info": [
    "cancell_sent"
  ]
}

HTTP Request

POST /service/@id/cancel

Query Parameters

Parameter Type Description
id int

Service id

immediate string

set to false to terminate service at the end of billing date, true - terminate immediately

reason string

Reason for this request

Service label

Show current service label


curl -X GET "https://sindad.net/api/service/@id/label" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/label');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/label', auth=auth)
print(req.json())
Example Response:
{
    "label": "example"
}

HTTP Request

GET /service/@id/label

Query Parameters

Parameter Type Description
id int

Service id

Change service label

Set new custom label to identify this service

POST_DATA="{
    \"label\": \"labelValue\"
}"

curl -X POST "https://sindad.net/api/service/@id/label" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "label" => "labelValue"
    ]
]
$resp = $client->post('/service/@id/label', $options);
echo $resp->getBody();
payload = {
    'label': "labelValue"
}

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/label', json=payload, auth=auth)
print(req.json())
Example Response:
{
    "success": true,
    "info": [
        "label_updated"
    ]
}

HTTP Request

POST /service/@id/label

Query Parameters

Parameter Type Description
id int

Service id

label string

New label

Get list statuses

Get a list of all statuses.


curl -X GET "https://sindad.net/api/statuses" 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
]);


$resp = $client->get('/statuses');
echo $resp->getBody();


req = requests.get('https://sindad.net/api/statuses')
print(req.json())

HTTP Request

GET /statuses

Get specific statuses

Get a list of all statuses with specific status.


curl -X GET "https://sindad.net/api/statuses/specific/@status" 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
]);


$resp = $client->get('/statuses/specific/@status');
echo $resp->getBody();


req = requests.get('https://sindad.net/api/statuses/specific/@status')
print(req.json())

HTTP Request

GET /statuses/specific/@status

Query Parameters

Parameter Type Description
status string

Status. Possible values: Scheduled, InProgress, Cancelled, ResolvedFaultIssue, CompletedMaintenance, Finished

Get status

Get status details.


curl -X GET "https://sindad.net/api/statuses/@id" 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
]);


$resp = $client->get('/statuses/@id');
echo $resp->getBody();


req = requests.get('https://sindad.net/api/statuses/@id')
print(req.json())

HTTP Request

GET /statuses/@id

Query Parameters

Parameter Type Description
id int

Status id

List VMs

List virtual servers


curl -X GET "https://sindad.net/api/service/@id/vms" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/vms');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/vms', auth=auth)
print(req.json())

HTTP Request

GET /service/@id/vms

Query Parameters

Parameter Type Description
id int

Get VM Details

Get the details of a particular virtual server


curl -X GET "https://sindad.net/api/service/@id/vms/@vmid" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/vms/@vmid');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/vms/@vmid', auth=auth)
print(req.json())

HTTP Request

GET /service/@id/vms/@vmid

Query Parameters

Parameter Type Description
id int
vmid string

Virtual server id

Create VM

Add new virtual server

POST_DATA="{
    \"label\": \"labelValue\",
    \"template\": \"templateValue\",
    \"flavor\": \"flavorValue\",
    \"disk\": \"diskValue\",
    \"security_group\": \"security_groupValue\",
    \"keypair\": \"keypairValue\",
    \"password\": \"passwordValue\"
}"

curl -X POST "https://sindad.net/api/service/@id/vms" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "label" => "labelValue",
        "template" => "templateValue",
        "flavor" => "flavorValue",
        "disk" => "diskValue",
        "security_group" => "security_groupValue",
        "keypair" => "keypairValue",
        "password" => "passwordValue"
    ]
]
$resp = $client->post('/service/@id/vms', $options);
echo $resp->getBody();
payload = {
    'label': "labelValue",
    'template': "templateValue",
    'flavor': "flavorValue",
    'disk': "diskValue",
    'security_group': "security_groupValue",
    'keypair': "keypairValue",
    'password': "passwordValue"
}

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/vms', json=payload, auth=auth)
print(req.json())

HTTP Request

POST /service/@id/vms

Query Parameters

Parameter Type Description
id int
label string

VM label

template string

Template ID

flavor string

Flavor describing VM cpu and memory size

disk string

Disk Space in GB

security_group string

Network security group

keypair string

SSH Key name

password string

Password for root user

Stop VM

Stop virtual server


curl -X POST "https://sindad.net/api/service/@id/vms/@vmid/stop" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->post('/service/@id/vms/@vmid/stop');
echo $resp->getBody();

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/vms/@vmid/stop', auth=auth)
print(req.json())

HTTP Request

POST /service/@id/vms/@vmid/stop

Query Parameters

Parameter Type Description
id int
vmid string

Virtual server id

Start VM

Start virtual servers


curl -X POST "https://sindad.net/api/service/@id/vms/@vmid/start" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->post('/service/@id/vms/@vmid/start');
echo $resp->getBody();

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/vms/@vmid/start', auth=auth)
print(req.json())

HTTP Request

POST /service/@id/vms/@vmid/start

Query Parameters

Parameter Type Description
id int
vmid string

Virtual server id

Reboot VM

Reboot virtual servers


curl -X POST "https://sindad.net/api/service/@id/vms/@vmid/reboot" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->post('/service/@id/vms/@vmid/reboot');
echo $resp->getBody();

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/vms/@vmid/reboot', auth=auth)
print(req.json())

HTTP Request

POST /service/@id/vms/@vmid/reboot

Query Parameters

Parameter Type Description
id int
vmid string

Virtual server id

Rescue VM

Reboot virtual servers into rescue mode.


curl -X POST "https://sindad.net/api/service/@id/vms/@vmid/rescue" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->post('/service/@id/vms/@vmid/rescue');
echo $resp->getBody();

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/vms/@vmid/rescue', auth=auth)
print(req.json())

HTTP Request

POST /service/@id/vms/@vmid/rescue

Query Parameters

Parameter Type Description
id int
vmid string

Virtual server id

Unrescue VM

Disable rescue mode for server.


curl -X POST "https://sindad.net/api/service/@id/vms/@vmid/unrescue" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->post('/service/@id/vms/@vmid/unrescue');
echo $resp->getBody();

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/vms/@vmid/unrescue', auth=auth)
print(req.json())

HTTP Request

POST /service/@id/vms/@vmid/unrescue

Query Parameters

Parameter Type Description
id int
vmid string

Virtual server id

Rebuild VM

Rebuild server, you can get list of templates supported by this server using '''/service/$id/vms/$vmid/rebuild'''

POST_DATA="{
    \"template\": \"templateValue\"
}"

curl -X POST "https://sindad.net/api/service/@id/vms/@vmid/rebuild" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "template" => "templateValue"
    ]
]
$resp = $client->post('/service/@id/vms/@vmid/rebuild', $options);
echo $resp->getBody();
payload = {
    'template': "templateValue"
}

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/vms/@vmid/rebuild', json=payload, auth=auth)
print(req.json())

HTTP Request

POST /service/@id/vms/@vmid/rebuild

Query Parameters

Parameter Type Description
id int
vmid int
template string

Template ID

List OS templates

List templates that can be used to create virtual server


curl -X GET "https://sindad.net/api/service/@id/templates" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/templates');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/templates', auth=auth)
print(req.json())

HTTP Request

GET /service/@id/templates

Query Parameters

Parameter Type Description
id int

Resources

Show available and used resources


curl -X GET "https://sindad.net/api/service/@id/resources" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/resources');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/resources', auth=auth)
print(req.json())

HTTP Request

GET /service/@id/resources

Query Parameters

Parameter Type Description
id int

List OS templates and recipes

Lists templates that can be installed on server. Lists recipes that can be used for additional configuration, check usablefor key to find which templates are supported by recipe.


curl -X GET "https://sindad.net/api/service/@id/reinstall/templates" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/reinstall/templates');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/reinstall/templates', auth=auth)
print(req.json())

HTTP Request

GET /service/@id/reinstall/templates

Query Parameters

Parameter Type Description
id int

Reinstall Status

Get reinstall operation status


curl -X GET "https://sindad.net/api/service/@id/reinstall" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/reinstall');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/reinstall', auth=auth)
print(req.json())

HTTP Request

GET /service/@id/reinstall

Query Parameters

Parameter Type Description
id int

Reinstall

Start reinstall operation on a server

POST_DATA="{
    \"hostname\": \"hostnameValue\",
    \"template\": \"templateValue\",
    \"recipe\": \"recipeValue\",
    \"password\": \"passwordValue\"
}"

curl -X POST "https://sindad.net/api/service/@id/reinstall" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "hostname" => "hostnameValue",
        "template" => "templateValue",
        "recipe" => "recipeValue",
        "password" => "passwordValue"
    ]
]
$resp = $client->post('/service/@id/reinstall', $options);
echo $resp->getBody();
payload = {
    'hostname': "hostnameValue",
    'template': "templateValue",
    'recipe': "recipeValue",
    'password': "passwordValue"
}

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/reinstall', json=payload, auth=auth)
print(req.json())

HTTP Request

POST /service/@id/reinstall

Query Parameters

Parameter Type Description
id int
hostname string

New hostname for server

template string

Template ID

recipe string

Recipe ID [Optional]

password string

New password for server [Optional, will be generated automatically if left empty]

Cancel Diagnostics

Cancel this operation


curl -X POST "https://sindad.net/api/service/@id/diag/cancel" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->post('/service/@id/diag/cancel');
echo $resp->getBody();

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/diag/cancel', auth=auth)
print(req.json())

HTTP Request

POST /service/@id/diag/cancel

Query Parameters

Parameter Type Description
id int

List Diagnostics templates

List templates that can be used fr diagnostics operation


curl -X GET "https://sindad.net/api/service/@id/diag/templates" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/diag/templates');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/diag/templates', auth=auth)
print(req.json())

HTTP Request

GET /service/@id/diag/templates

Query Parameters

Parameter Type Description
id int

Diagnostics Status

Show diagnostic operation status


curl -X GET "https://sindad.net/api/service/@id/diag" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/diag');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/diag', auth=auth)
print(req.json())

HTTP Request

GET /service/@id/diag

Query Parameters

Parameter Type Description
id int

Run Diagnostics

Start new diagnostic operation

POST_DATA="{
    \"template\": \"templateValue\",
    \"clearhdd\": \"clearhddValue\",
    \"fullhddclear\": \"fullhddclearValue\"
}"

curl -X POST "https://sindad.net/api/service/@id/diag" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "template" => "templateValue",
        "clearhdd" => "clearhddValue",
        "fullhddclear" => "fullhddclearValue"
    ]
]
$resp = $client->post('/service/@id/diag', $options);
echo $resp->getBody();
payload = {
    'template': "templateValue",
    'clearhdd': "clearhddValue",
    'fullhddclear': "fullhddclearValue"
}

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/diag', json=payload, auth=auth)
print(req.json())

HTTP Request

POST /service/@id/diag

Query Parameters

Parameter Type Description
id int
template string

Diagnostic Template ID

clearhdd bool

Clear disks

fullhddclear bool

Full hard drive erase ($clearhdd also has to be set to True)

List Rescue templates

List templates that can be used start rescue operation


curl -X GET "https://sindad.net/api/service/@id/rescue/templates" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/rescue/templates');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/rescue/templates', auth=auth)
print(req.json())

HTTP Request

GET /service/@id/rescue/templates

Query Parameters

Parameter Type Description
id int

Rescue Status

Show rescue operation status


curl -X GET "https://sindad.net/api/service/@id/rescue" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/rescue');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/rescue', auth=auth)
print(req.json())

HTTP Request

GET /service/@id/rescue

Query Parameters

Parameter Type Description
id int

Rescue

Start rescue operation on a server

POST_DATA="{
    \"template\": \"templateValue\",
    \"password\": \"passwordValue\"
}"

curl -X POST "https://sindad.net/api/service/@id/rescue" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "template" => "templateValue",
        "password" => "passwordValue"
    ]
]
$resp = $client->post('/service/@id/rescue', $options);
echo $resp->getBody();
payload = {
    'template': "templateValue",
    'password': "passwordValue"
}

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/rescue', json=payload, auth=auth)
print(req.json())

HTTP Request

POST /service/@id/rescue

Query Parameters

Parameter Type Description
id int
template string

Rescue Template ID

password string

Password for rescue operation

Cancel Rescue

Cancel rescue operation


curl -X POST "https://sindad.net/api/service/@id/rescue/cancel" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->post('/service/@id/rescue/cancel');
echo $resp->getBody();

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/rescue/cancel', auth=auth)
print(req.json())

HTTP Request

POST /service/@id/rescue/cancel

Query Parameters

Parameter Type Description
id int

Server Info

Get server hardware and os details


curl -X GET "https://sindad.net/api/service/@id/info" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/info');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/info', auth=auth)
print(req.json())

HTTP Request

GET /service/@id/info

Query Parameters

Parameter Type Description
id int

Update Hostname

Update server hostname

POST_DATA="{
    \"hostname\": \"hostnameValue\"
}"

curl -X POST "https://sindad.net/api/service/@id/hostname" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "hostname" => "hostnameValue"
    ]
]
$resp = $client->post('/service/@id/hostname', $options);
echo $resp->getBody();
payload = {
    'hostname': "hostnameValue"
}

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/hostname', json=payload, auth=auth)
print(req.json())

HTTP Request

POST /service/@id/hostname

Query Parameters

Parameter Type Description
id int
hostname string

New Hostname

List IPs

List server ips


curl -X GET "https://sindad.net/api/service/@id/ips" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/ips');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/ips', auth=auth)
print(req.json())

HTTP Request

GET /service/@id/ips

Query Parameters

Parameter Type Description
id int

List VLANs

List available VLANs


curl -X GET "https://sindad.net/api/service/@id/vlans" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/vlans');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/vlans', auth=auth)
print(req.json())

HTTP Request

GET /service/@id/vlans

Query Parameters

Parameter Type Description
id int

Add IP

Add new ip to server

POST_DATA="{
    \"vlan\": \"vlanValue\",
    \"domain\": \"domainValue\",
    \"num\": \"numValue\"
}"

curl -X POST "https://sindad.net/api/service/@id/ips" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "vlan" => "vlanValue",
        "domain" => "domainValue",
        "num" => "numValue"
    ]
]
$resp = $client->post('/service/@id/ips', $options);
echo $resp->getBody();
payload = {
    'vlan': "vlanValue",
    'domain': "domainValue",
    'num': "numValue"
}

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/ips', json=payload, auth=auth)
print(req.json())

HTTP Request

POST /service/@id/ips

Query Parameters

Parameter Type Description
id int
vlan string

VLAN ID

domain string

IP Domain

num string

Number of IPs to add [Optional]

IP Details

Get details about IP


curl -X GET "https://sindad.net/api/service/@id/ips/@ip" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/ips/@ip');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/ips/@ip', auth=auth)
print(req.json())

HTTP Request

GET /service/@id/ips/@ip

Query Parameters

Parameter Type Description
id int
ip string

IP Address ID

Edit IP

Update IP domain

POST_DATA="{
    \"domain\": \"domainValue\"
}"

curl -X POST "https://sindad.net/api/service/@id/ips/@ip" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "domain" => "domainValue"
    ]
]
$resp = $client->post('/service/@id/ips/@ip', $options);
echo $resp->getBody();
payload = {
    'domain': "domainValue"
}

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/ips/@ip', json=payload, auth=auth)
print(req.json())

HTTP Request

POST /service/@id/ips/@ip

Query Parameters

Parameter Type Description
id int
ip string

IP Address ID

domain string

Domain name

Delete IP

Remove IP from server


curl -X DELETE "https://sindad.net/api/service/@id/ips/@ip" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->delete('/service/@id/ips/@ip');
echo $resp->getBody();

auth=('username', 'password')

req = requests.delete('https://sindad.net/api/service/@id/ips/@ip', auth=auth)
print(req.json())

HTTP Request

DELETE /service/@id/ips/@ip

Query Parameters

Parameter Type Description
id int
ip string

IP Address ID

Reboot

Request server reboot


curl -X POST "https://sindad.net/api/service/@id/reboot" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->post('/service/@id/reboot');
echo $resp->getBody();

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/reboot', auth=auth)
print(req.json())

HTTP Request

POST /service/@id/reboot

Query Parameters

Parameter Type Description
id int

Power OFF

Power off server


curl -X POST "https://sindad.net/api/service/@id/poweroff" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->post('/service/@id/poweroff');
echo $resp->getBody();

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/poweroff', auth=auth)
print(req.json())

HTTP Request

POST /service/@id/poweroff

Query Parameters

Parameter Type Description
id int

Power ON

Power on server


curl -X POST "https://sindad.net/api/service/@id/poweron" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->post('/service/@id/poweron');
echo $resp->getBody();

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/poweron', auth=auth)
print(req.json())

HTTP Request

POST /service/@id/poweron

Query Parameters

Parameter Type Description
id int

Destroy VM

Remove virtual server


curl -X DELETE "https://sindad.net/api/service/@id/vms/@vmid" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->delete('/service/@id/vms/@vmid');
echo $resp->getBody();

auth=('username', 'password')

req = requests.delete('https://sindad.net/api/service/@id/vms/@vmid', auth=auth)
print(req.json())

HTTP Request

DELETE /service/@id/vms/@vmid

Query Parameters

Parameter Type Description
id int
vmid string

Virtual server id

Resize VM

Edit a virtual server

POST_DATA="{
    \"memory\": \"memoryValue\",
    \"cpu\": \"cpuValue\"
}"

curl -X PUT "https://sindad.net/api/service/@id/vms/@vmid" \
   -u user:pass \
   -H "Content-Type: application/json" \
   -d "${POST_DATA}"
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);

$options = [
    'json' => [
        "memory" => "memoryValue",
        "cpu" => "cpuValue"
    ]
]
$resp = $client->put('/service/@id/vms/@vmid', $options);
echo $resp->getBody();
payload = {
    'memory': "memoryValue",
    'cpu': "cpuValue"
}

auth=('username', 'password')

req = requests.put('https://sindad.net/api/service/@id/vms/@vmid', json=payload, auth=auth)
print(req.json())

HTTP Request

PUT /service/@id/vms/@vmid

Query Parameters

Parameter Type Description
id int
vmid string

Virtual server id

memory string

Amount of RAM in MB

cpu string

Amount of CPU cores

Shutdown VM

Perform graceful shutdown


curl -X POST "https://sindad.net/api/service/@id/vms/@vmid/shutdown" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->post('/service/@id/vms/@vmid/shutdown');
echo $resp->getBody();

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/vms/@vmid/shutdown', auth=auth)
print(req.json())

HTTP Request

POST /service/@id/vms/@vmid/shutdown

Query Parameters

Parameter Type Description
id int
vmid string

Virtual server id

Reset VM

Reset virtual servers power


curl -X POST "https://sindad.net/api/service/@id/vms/@vmid/reset" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->post('/service/@id/vms/@vmid/reset');
echo $resp->getBody();

auth=('username', 'password')

req = requests.post('https://sindad.net/api/service/@id/vms/@vmid/reset', auth=auth)
print(req.json())

HTTP Request

POST /service/@id/vms/@vmid/reset

Query Parameters

Parameter Type Description
id int
vmid string

Virtual server id

DNS

List DNS for service

Returns a list of DNS zones under the service


curl -X GET "https://sindad.net/api/service/@service_id/dns" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@service_id/dns');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@service_id/dns', auth=auth)
print(req.json())
Example Response:
{
    "error": [
        "invalid method"
    ]
}

HTTP Request

GET /service/@service_id/dns

Query Parameters

Parameter Type Description
service_id int

Service ID

Cart

Most of API methods found here will require service @id, you can lookup your service ids with /service method

Get server state

Return details about server power state


curl -X GET "https://sindad.net/api/service/@id/status" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/service/@id/status');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/service/@id/status', auth=auth)
print(req.json())

HTTP Request

GET /service/@id/status

Query Parameters

Parameter Type Description
id int

List Servers In-stock

Rebuild the network for a particular virtual server


curl -X GET "https://sindad.net/api/serverstock" \
   -u user:pass 
use GuzzleHttp\Client;

$client = new Client([
    'base_uri' => 'https://sindad.net/api',
    'auth' => ['username', 'password']
]);


$resp = $client->get('/serverstock');
echo $resp->getBody();

auth=('username', 'password')

req = requests.get('https://sindad.net/api/serverstock', auth=auth)
print(req.json())

HTTP Request

GET /serverstock