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

Torch Object Storage

Copy page
Download PDF
Log Analysis
PutBucketRealTimeLog
Copy page
Download PDF
PutBucketRealTimeLog
Description​
This interface is used to enable the log analysis feature.​
Request syntax​
​
PUT /?realtimeLog HTTP/1.1​
Host: bucketname.tos-cn-beijing.volces.com​
Authorization: authorization string​
Date: Fri, 18 Apr 2025 09:11:23 GMT​
​
{​
"RealTimeLogConfiguration": {​
"Role": "TOSLogArchiveTLSRole",​
"AccessLogConfiguration": {​
"UseServiceTopic": true,​
"TTL": 7​
}​
}​
}​
​
Request parameters and headers​
For the public request message headers used by this request, see Public Parameters.​
​
Name​
Location​
Type​
Required​
Sample Value​
Description​
realtimeLog​
Query​
String​
Yes​
-​
A special identifier representing the PutBucketRealTimeLog request.​
​
Request body elements​
​
Name​
Type​
Required​
Sample Value​
Description​
RealTimeLogConfiguration​
Container​
Yes​
-​
Configure real-time logs.​
Role​
String​
Yes​
TOSLogArchiveTLSRole​
The role name is used to grant Object Storage TOS permission to create resources such as project and topic and to write logs in Log Service TLS. You can use the TOS default role TOSLogArchiveTLSRole.​
Parent Node: RealTimeLogConfiguration​
AccessLogConfiguration​
Container​
Yes​
-​
Configure log resources.​
Parent Node: RealTimeLogConfiguration​
UseServiceTopic​
Bool​
Yes​
true​
For topics created using the TOS service, only the value true is supported.​
Parent Node: AccessLogConfiguration​
TTL​
Integer​
No​
7​
TLS log retention period, measured in days. The valid range is [0, 3650], with a default value of 7 days.​
Parent Node: AccessLogConfiguration​
​
Response headers​
For the public response headers returned by this request, please refer to Common Parameters.​
Response body elements​
There are no message elements in this request response.​
Sample request​
​
PUT /?realtimeLog HTTP/1.1​
Host: bucket-name.tos-cn-beijing.volces.com​
Date: Fri, 18 Apr 2025 09:11:23 GMT​
Authorization: authorization string​
Content-Length: 280​
{​
"RealTimeLogConfiguration": {​
"Role": "TOSLogArchiveTLSRole",​
"AccessLogConfiguration": {​
"UseServiceTopic": true,​
"TTL": 7​
}​
}​
}​
​
Sample response​
​
HTTP/1.1 200 OK​
x-tos-id-2: f91b0c03a01300c1-a444cd0 ​
x-tos-request-id: f91b0c03a01300c1-a444cd0 ​
Date: Fri, 18 Apr 2025 09:11:23 GMT​
server: TosServer​
Content-Length: 0​
​
​
Last updated: 2025.11.10 17:46:55