Sample Message Data Structure
The API Traffic log data structure fields, which include requests to and from Apinizer, and various metadata information are given below.
These fields are included in the JSON messages that are sent to the log integration tools.
Field Name | Data/Description Retained in the Field | Java Mapping Type | The field that needs to be activated in the settings to be included in the message |
---|---|---|---|
@timestamp | Time Stamp | Instant | Identification Metadata |
aci | Apinizer Correlation ID | String | Identification Metadata |
ei | Environment ID | String | Identification Metadata |
pi | Project ID | String | Identification Metadata |
api | API Proxy ID | String | API Proxy Metadata |
apn | API Proxy Name | String | API Proxy Metadata |
apmi | API Proxy Method ID | String | API Proxy Metadata |
apmn | API Proxy Method Name | String | API Proxy Metadata |
hr1ra | HTTP Request Remote Address | String | Request Metadata |
hr1hm | HTTP Request HTTP Method | String | Request Metadata |
uok | Username or Key | String | Request Metadata |
sc | Status Code | int | Response Metadata |
et | Error Type | Enum | Response Metadata |
pet | Parent Error Type | Enum | Response Metadata |
rt | Result Type | Enum | Response Metadata |
trt | Time Routing Total | Integer | Metrics |
tapt | Time API Proxy Total | Integer | Metrics |
sr1t | Size Request Total | Integer | Metrics |
sr2t | Size Response Total | Integer | Metrics |
ch | Cache Hit | Boolean | Metrics |
fcrp | From Client Read Only Parameter | String | Header from Client |
fcrh | From Client Read Only Header | String | Param from Client |
fcrb | From Client Read Only Body | String | Body from Client |
tbap | To Backend API Parameter | String | |
tbah | To Backend API Header | String | |
tba | To Backend API Body | String | |
ra | Routing/Backend API Address | String | |
fbarh | From Backend API Read Only Header | String | Header from Target |
fbarb | From Backend API Read Only Body | String | Body from Target |
tch | To Client Header | String | Header to Client |
tcb | To Client Body | String | Body to Client |
The resulting sample JSON data:
{
"@timestamp" : "2023-03-16T14:16:41.832Z",
"aci" : "<correlation id>",
"ei" : "<environment id>",
"pi" : "<project id>",
"api" : "<api proxy id>",
"apmi" : "<api proxy method id>",
"apmn" : "<api proxy method name>",
"hr1ra" : "<client address>",
"hr1hm" : "<HTTP Method>",
"uok" : "<username or key>",
"fcrh" : {
"key1" : "value1",
"key2" : "value2",
"key3" : "value3"
},
"fcrp" : {
"key1" : "value1",
"key2" : "value2",
"key3" : "value3"
},
"fcrb" : "<request body from client>",
"tbah" : {
"key1" : "value1",
"key2" : "value2",
"key3" : "value3"
},
"tbap" : {
"key1" : "value1",
"key2" : "value2",
"key3" : "value3"
},
"tba" : "<request body to backend api>",
"ra" : "<backend api address>",
"fbarh" : {
"key1" : "value1",
"key2" : "value2",
"key3" : "value3"
},
"fbarb" : "<body response from backend api>",
"tch" : {
"key1" : "value1",
"key2" : "value2",
"key3" : "value3"
},
"tcb" : "<body response to client>",
"trt" : 100,
"tapt" : 150,
"ch" : false,
"sr1t" : 100,
"sr2t" : 250,
"sc" : 200,
"rt" : "SUCCESS",
"et" : "APIPROXY",
"pet" : "API_PROXY"
}
You can view the list of values in the "rt" field in the "Result Type Enum Values" table on the Error Messages page.
You can view the list of values in the "pet" field in the "Parent Error Type Values" table on the Error Messages page.
You can view the list of values in the "et" field in the "Error Type Values" table on the Error Messages page.