get_options(\%Opt);
# Auth
if ($_ = $Opt{activate}) {
+ system qq|curl -s -XPOST -H"X-Ovh-Application: $_" -H "Content-type: application/json" https://eu.api.ovh.com/1.0/auth/credential -d '{"accessRules": [ { "method": "GET", "path": "/*" },{ "method": "PUT", "path": "/*" },{ "method": "POST", "path": "/*" },{ "method": "DELETE", "path": "/*" } ] }'|.'|jq .';
+ exit;
exec qq|curl -s -XPOST -H"X-Ovh-Application: $_" -H "Content-type: application/json" https://eu.api.ovh.com/1.0/auth/credential -d '{"accessRules": [ { "method": "GET", "path": "/*" } ] }'|.'|jq .';
#print qq|curl -XPOST -H"X-Ovh-Application: $_" -H "Content-type: application/json" https://eu.api.ovh.com/1.0/auth/credential -d '{"accessRules": [ { "method": "GET", "path": "/*" } ], "redirection":"https://www.mywebsite.com/" }'\n|;
#exec("curl","-XPOST",'-H',"X-Ovh-Application: $_",'-H','Content-type: application/json','https://eu.api.ovh.com/1.0/auth/credential','-d',qq|'{"accessRules": [ { "method": "GET", "path": "/*" } ],"redirection":"https://www.mywebsite.com/" }'|);
=head1 OPTIONS
option[activate=s] [KEY] Activate a key (first bit before ":" or KEY[0])
- option[method|m=s] Method (default: GET)
+ option[method|m=s] Method (default: GET)
option[verbose|v+] Verbose mode: increase the verbosity level.
option[debug+] Debug mode: increase the verbosity level.
option[version|V] Print version (default: $VERSION)