API Connect

API Connect

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.


#API Connect
#Applicationintegration
#APIConnect
 View Only
  • 1.  Log policy

    Posted 09/25/24 01:24 PM

    Hi All, Please help me understand how log policy works .

    In my API,I  am using invoke statement and then log policy with gather-only option and log level set default.

    Preceding log policy, I have gateway script  with context.set('log.custom.httpStatusCode',context.get('message.status.code'));.

    When I test the api, I can see the custom log with httpStatusCode in analytics.

    But, I would like to understand when do we use send-only option and gather -send option, what is the use of it ?

    Thank you!



    ------------------------------
    v k
    ------------------------------


  • 2.  RE: Log policy

    Posted 09/26/24 03:14 AM

    Please see the answer and the linked tutorial in this thread:
    https://community.ibm.com/community/user/integration/discussion/logging-in-apic?ReturnUrl=%2fcommunity%2fuser%2fintegration%2fcommunities%2fcommunity-home%2fdigestviewer%3fcommunitykey%3d2106cca0-a9f9-45c6-9b28-01a28f4ce947

    Hope that helps



    ------------------------------
    Chris Dudley
    ------------------------------