This text provides instructions for performing Start and Stop operations using the Zomro service API. Each operation includes the necessary request parameters, methods, and example requests using curl. Each step is accompanied by a description of the expected result after the operation is performed.
To perform the Start operation using the API, we use the following function.
URL:
https://api.zomro.com/
Method: POST
Request Body (Form-data):
Parameter | Example Value | Required Parameter | Value Description |
func | service.stop | Yes | Function to initiate the delete operation on the instance |
auth | 21fc199...c43f71 | No | Session token. This is one of the authorization options. More details on other options are described here |
out | json | Yes | Response type to expect |
elid | 5116804 | Yes | ID of the service to perform the operation on |
Example of performing the Start operation
For example, we use the service:
URL:
https://api.zomro.com/
Method: POST
Request Body (Form-data):
Parameter | Value |
func | instances.stop |
auth | 21fc199...c43f71 |
out | json |
elid | 5116804 |
Here is an example of a request that can be executed from the console:
curl --location 'https://api.zomro.com/' \
--form 'func="service.stop"' \
--form 'auth="bf15875098100189d4e47484"' \
--form 'elid="5116804"' \
--form 'out="json"'
After executing the request, we can see that the server is in the process of stopping.
After the operation is completed, we see that the service is in the "Temporary suspended" status, which means that the service is stopped.
Example of performing the Stop operation using the API
For example, we use the service:
URL:
https://api.zomro.com/
Method: POST
Request Body (Form-data):
Parameter | Value |
func | instances.start |
auth | 21fc199...c43f71 |
out | json |
elid | 5116804 |
Here is an example of a request that can be executed from the console:
curl --location 'https://api.zomro.com/' \
--form 'func="service.start"' \
--form 'auth="bf15875098100189d4e47484"' \
--form 'elid="5116804"' \
--form 'out="json"'
After executing the request, we can see that the server is in the process of starting.
After the operation is completed, we see that the service is in the "Active" status, which means that the service is started and ready for use.
We also suggest studying articles that may be useful for interacting with Cloud VPS products using the API:
- API - Creation of a Service
- API - Obtaining Information About Available Tariffs and Their Parameters
- API - Operation Reboot
- API - Operation Rebuild
- API - Operation Delete