Retrieves the configuration of a Logstore.
Operation description
The
Hostin the request syntax consists of the Project name and the Log Service endpoint.You have an AccessKey. For more information, see AccessKey.
The AccessKey of an Alibaba Cloud account has full permissions on all APIs, which poses a high security risk. We recommend using a RAM user to make API calls or perform routine operations. You must grant the RAM user the required permissions to access Log Service resources. For more information, see Create a RAM user and grant permissions.
You have the Project name, region, and Logstore name. For more information, see Manage Project and Manage Logstore.
Authorization
To grant a RAM user or RAM role permission to call this API, add the following Action to a RAM permission policy.
| Action | Resource |
log:GetLogStoreConfig | acs:log:{#regionId}:{#accountId}:project/{#ProjectName}/logstore/{#LogstoreName} |
Try it now
Test
RAM authorization
Request syntax
GET /logstores/{logstore}/config HTTP/1.1
Path Parameters
|
Parameter |
Type |
Required |
Description |
Example |
| logstore |
string |
Yes |
The name of the Logstore. |
ali-test-logstore |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| project |
string |
Yes |
The name of the Project. |
ali-test-project |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| clientIpHeaders |
array |
An array of header keys used to extract the client IP address when data is written to the Logstore. The keys are case-insensitive, but their order in the array is significant. For this feature to work, you must enable the |
|
|
string |
A case-insensitive header key, such as |
X-Forwarded-For |
Examples
Success response
JSON format
{
"clientIpHeaders": [
"X-Forwarded-For"
]
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.