fachinformatiker-wiki

it's easy when it's here

User Tools

Site Tools


hosting:hetzner:cloud

This is an old revision of the document!


API

Rescale

PowerShell

$serverid = "12345678"
$servertype = "cx23"
$token = "<CLOUD-API-TOKEN>"
$body = @{
    upgrade_disk = $true
    server_type  = $servertype
} | ConvertTo-Json
 
Invoke-WebRequest `
  -Method Post `
  -Headers @{ "Authorization" = "Bearer $token" } `
  -Uri "https://api.hetzner.cloud/v1/servers/$serverid/actions/change_type" `
  -ContentType "application/json" `
  -Body $body `
  -UseBasicParsing
 
Clear-Variable server*
Clear-Variable token
Clear-Variable body
This website uses cookies. By using the website, you agree with storing cookies on your computer. Also you acknowledge that you have read and understand our Privacy Policy. If you do not agree leave the website.  More information about cookies 
hosting/hetzner/cloud.1771631267.txt.gz · Last modified: by gsys