Log
Methods
Entity Properties
Use the API as a reference when writing a log message.
log.write
(object $logData)
Create new product.
Parameters
order | description |
---|---|
0 | object - Log data. |
Return Value
true if log entity was successfully created.
Example Request
{
"jsonrpc" : 2.0,
"id" : 1234,
"method" : "call",
"params" : [
"be1c13ed4e03f0ed7f1e4053dfff9658",
"log.write",
{
"store_id" : 1,
"facility" : "Submit Order",
"entity" : "100000005",
"severity" : "info",
"message" : "Submitted order # 10000001",
"detail" : "Additional information about the order could be here"
}
]
}
Example Response
{
"jsonrpc" : 2.0,
"id" : 1234,
"error" : null,
"result" : true
}
Error Codes
code | message |
---|---|
100 | Invalid data given. Details in error message. |
101 | An unexpected error occurred while creating the new log entity. |
Entity Properties
Log Properties
store_id |
The internal store ID.
|
---|---|
facility |
The "Facility" property. The maximum length is 32 characters.
|
entity |
The "Entity" property.
|
severity |
The "Severity" property. Allowed values: "debug", "info", "warn", "error".
|
message |
The "Message" property. The maximum length is 255 characters.
|
detail |
The "Detail" property. The maximum length is 2048 characters.
|