azureazure-api-managementazure-log-analyticsazure-monitoringibm-api-management

Azure API Management logs request and response bodies


I would like to log the request and response bodies of my API calls in Azure API Management for debugging purpose.

To do that I have created a Log Analytics workspace and configured the diagnostic settings to store the logs in it. But when I check the logs in Log Analytics tool (Logs of the last 100 calls), I see my API calls with status code, subscription key, etc but the body columns are always empty.

I tried to enable the body request logging in the API Azure Monitor advanced settings but it doesn't change a thing, still empty bodies and headers.

Do I have forgotten something or is there a notion of Azure Monitor that I do not understand?


Solution

  • I think there isn't anything you forgot to configure the monitor for APIM, I also test it in my side and also can't see the requestbody and responsebody column in logs.

    Here find an answer from MSFT about this problem for your reference, I think that's the official answer.

    enter image description here