- 31 Oct 2024
- 1 Minute to read
- Print
- DarkLight
- PDF
API Management
- Updated on 31 Oct 2024
- 1 Minute to read
- Print
- DarkLight
- PDF
In this scenario we are exposing an API to a 3rd party application which can submit help desk tickets to our organisation.
I can create a BAM view from the API logs in App Insights to create a user friendly view to help the support operators.
They can also open up a transaction and view additional stages within the transaction.
Walk Thru Video
This video will give a walk thru of this scenario.
Parent Transaction Query
In this case I am looking at the requests for my create ticket api operation.
I am using a replace function to get the ticket id from the query string. You could also use headers you might have tracked for extracting business properties or perhaps you saved message bodies in the log too.
requests
| where customDimensions.["API Name"] == "external-api-helpdesk-system-proxy"
| where customDimensions.["Operation Name"] == "create-ticket"
| extend ticket = replace_string(url, "https://kv-eai-apim.azure-api.net/external/helpdesk/tickets/", "")
| project timestamp, ticket, id, success, resultCode, duration, operation_Id
Stage in Transaction Query
In this case I am looking for the dependency call which would match to my backend on the API. I can correlate with the operation id
dependencies
| where operation_Id == {operation_Id}