You need to enable JavaScript to run this app.
Torch Object Storage

Torch Object Storage

Copy page
Download PDF
Auxiliary commands
Send HTTP requests (curl)
Copy page
Download PDF
Send HTTP requests (curl)
You can use the curl command to send HTTP requests and fetch responses.​
​
Command syntax​
​
Linux/macOS
Windows
​
​
​
./tosutil curl http(s)_url [-m=xxx] [-v] [-rb=xxx] [-fb=xxx] [-h=aaa:bbb#ccc:ddd] [-at=xxx] [-i=xxx] [-k=xxx] [-t=xxx]​
​
​
​
​
Parameters​
​
Parameter​
Type​
Description​
http(s)_url​
String​
The URL to which the HTTP request will be sent.​
-m​
String​
The request method for the curl command. The options are as follows:​
  • GET​
  • PUT​
  • POST​
  • DELETE​
  • HEAD​
The default is GET.​
-v​
String​
Print detailed information about the request and response when executing the curl command.​
-rb​
String​
The request body for the curl command. This parameter only applies when the request method is PUT, POST, or DELETE.​
-fb​
String​
Use a local file as the request body for the curl command and specify the path to that local file. This parameter only applies when the request method is PUT, POST, or DELETE.​
-h=aaa:bbb#ccc:ddd​
String​
The request headers for the curl command.​
-at​
String​
Generate a signature using the specified algorithm when executing the curl command. The options are as follows:​
  • tos​
-i​
String​
The access key ID that the signature algorithm will use.​
-k​
String​
The secret access key that the signature algorithm will use.​
-t​
String​
The STS token that the signature algorithm will use. For more information, see Accessing TOS with temporary credentials of Security Token Service.​
​
Example​
  • Command​
​
./tosutil curl https://console.volcengine.com/home​
​
  • Output​
​
* Status code: 302, Response Body: ​
​
* The response is truncated, total length: 93, consumed length: 93​
Redirecting to <a href="/auth/login?redirectURI=%2Fhome">/auth/login?redirectURI=%2Fhome</a>.​
​
​
Last updated: 2025.12.17 18:33:43