How to log / send email for every Execution Error raised by Access Control Policy or Spike Arrest Policy?

We have included below policies in all our API proxies:

1. Access Control Policy. (We follow Deny all, and Allow necessary IPs)

2. Spike Arrest Policy.

3. Regular Expression Protection.

We want to track hits coming from all non-whitelisted IPs, any incoming spike, or regular expression violation in a log (or send email notifications for that).

How can we put into log below things:

1. IP (non-whitelisted) from which the hit came.

2. timestamp and number of hits from the same IP for a duration.

3. Proxy, it was trying to reach.

Please advise.

Solved Solved
1 1 184
1 ACCEPTED SOLUTION

I think, we should use Message Logging Policy in the Post Client Flow to achieve this.

Here I got an example to implement this using Loggly:

https://community.apigee.com/questions/18906/messagelogging-to-loggly.html

Will appreciate any other guidance.

View solution in original post

1 REPLY 1

I think, we should use Message Logging Policy in the Post Client Flow to achieve this.

Here I got an example to implement this using Loggly:

https://community.apigee.com/questions/18906/messagelogging-to-loggly.html

Will appreciate any other guidance.