Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
en:dedicated-server:tutorials:api:order-dedibox-from-api [2019/07/02 16:44]
dedibox created
en:dedicated-server:tutorials:api:order-dedibox-from-api [2019/07/24 09:46] (current)
dedibox
Line 5: Line 5:
  
 <note tip>​**Requirements:​** <note tip>​**Requirements:​**
-  * You have an account and are logged into [console.online.net](https://console.online.net)\\+  * You have an account and are logged into [[http://console.online.net|console.online.net]]\\
   * You have already ordered a product from the management console\\   * You have already ordered a product from the management console\\
   * You have a valid payment method (SEPA, Credit Card or Paypal)\\   * You have a valid payment method (SEPA, Credit Card or Paypal)\\
   * You have retrieved [[https://​console.online.net/​en/​api/​access|your API token]]. \\   * You have retrieved [[https://​console.online.net/​en/​api/​access|your API token]]. \\
-  * You have [[https://​curl.haxx.se/​|curl]] on your local computer.+  * You have [[https://​curl.haxx.se/​|curl]] ​installed ​on your local computer.
 </​note>​ </​note>​
- 
- 
  
 ==== Getting the Product ID ==== ==== Getting the Product ID ====
Line 183: Line 181:
 |addons|912 = USB drive of 500 GB / 1031 = HDD of 8 TB| |addons|912 = USB drive of 500 GB / 1031 = HDD of 8 TB|
  
-**Useful Links**+==== Terminating a server from the API ====  
 + 
 +To terminate a server, send a `DELETE` request to the `/​api/​v1/​server/<​server id>` endpoint. Replace the `<server id>` prat with the ID of the server you want to terminate. 
 + 
 +<​code>​ 
 +$ curl -s -X DELETE -H "​Authorization:​ Bearer $OAUTH_ACCESS_TOKEN"​ https://​api.online.net/​api/​v1/​server/​123 
 +</​code>​ 
 + 
 +To get your server IDs you have multiple choices: 
 + 
 +  ​Get them directly from the server listing (ID column) 
 +  ​Send a `GET` request to the `/​api/​v1/​server` endpoint 
 + 
 + 
 +==== Useful Links ====
  
 Swagger: https://​console.online.net/​en/​api/​ Swagger: https://​console.online.net/​en/​api/​