usamember usamember - 1 month ago 4x
PHP Question

Use PHP to deploy 20 minutes trial VPS powered by Scaleway

i just knew thats the api link is

and i want to provide free 20 minutes VPS to my site visitors to enjoy more , of course i will leave credits to the becoz they are the hosters

can someone tell me some php examples to start building?


EDIT: to correct you, was giving 20 minutes trial in the past but now it's only 15 minutes.

Seems really simple.

Anyway, the API link is and not .

And as a lot of APIs, the API return the data using JSON.

Currently, I get the following when I try to browse in the browser:

  "message": "No server available at the moment",
  "type": "unknown_resource"

And when I try to click "GET YOUR C2M SERVER" button in, I get


All cloud servers are busy, please retry in few minutes :)

So, really return the correct answer!

Start by making the PHP part like that:

$instantcloud['api'] = "";
$instantcloud['jsonfalse'] = json_decode($instantcloud['api']);
if( $instantcloud['jsonfalse']->message == "No server available at the moment" ) {
    echo 'Failed creating server. Reason: no stocks available.';

I really don't know how we can create the server AT THE MOMENT , because I get "No server available at the moment" and I don't know what the API will return if the server is created...

So wait until I'm able to create a server then I'll edit this answer!