Configuring Log Collection Paths
Function
This API is used to configure the log collection paths of a specified ICAgent. This API applies only to configurations of log collection paths on the Log > Path Configuration page of the Application Operations Management (AOM) console.
URI
POST /v3/{project_id}/log-paths
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
project_id |
Yes |
String |
Project ID. For details about how to obtain a project ID, see Obtaining the Account Tenant ID, Log Group ID, and Log Stream ID. Minimum: 32 Maximum: 32 |
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
X-Auth-Token |
Yes |
String |
User token obtained from IAM. Minimum: 1000 Maximum: 2000 |
Content-Type |
Yes |
String |
Set this parameter to application/json;charset=utf8. Minimum: 29 Maximum: 29 |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
agent_config_infos |
Yes |
Array of AgentConfInfo1 objects |
ICAgent collection path configuration array. |
Response Parameters
Status code: 400
Parameter |
Type |
Description |
---|---|---|
errorCode |
String |
Status code. |
errorMessage |
String |
Description of the response for calling the API. |
Status code: 401
Parameter |
Type |
Description |
---|---|---|
errorCode |
String |
Status code. |
errorMessage |
String |
Description of the response for calling the API. |
Status code: 500
Parameter |
Type |
Description |
---|---|---|
errorCode |
String |
Status code. |
errorMessage |
String |
Description of the response for calling the API. |
Status code: 503
Parameter |
Type |
Description |
---|---|---|
errorCode |
String |
Status code. |
errorMessage |
String |
Description of the response for calling the API. |
Example Requests
POST https://{endpoint}/v3/${project_id}/log-paths { "agent_config_infos" : [ { "agent_id" : "c44fd66b-4bf5-4424-8c13-a2bfc927f51d", "log_paths" : [ "/log/root.log", "/var/ICAgent" ] } ] }
Example Responses
Status code: 401
The authentication information is incorrect or invalid.
{ "errorCode" : "SVCSTG.ALS.403.105", "errorMessage" : "Project id is invalid." }
Status Codes
Status Code |
Description |
---|---|
200 |
The request is successful. The log collection path is configured. |
400 |
BadRequest. Invalid request. Modify the request based on the description in error_msg before a retry. |
401 |
The authentication information is incorrect or invalid. |
500 |
Internal server error. |
503 |
ServiceUnavailable. The requested service is unavailable. |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot