Best answer

Newbie question - use authentication response payload in subsequent triggers

  • 25 February 2021
  • 7 replies
  • 155 views

I have a JSON response from the authentication step that includes a key pair with a customer ID value that I then need in the next trigger as a form parameter for a POST to retrieve some data for that customer. I am probably being very dim but I just can’t how to reference API call response data in the Zapier code.

icon

Best answer by ikbelkirasan 25 February 2021, 13:02

View original

This post has been closed for comments. Please create a new post if you need help or have a question about this topic.

7 replies

Userlevel 7
Badge +12

Hi @roboticcx - The authentication data is passed to your trigger’s handler via the bundle.authData object. So if the customer ID is stored in customer_id, it can be referenced as bundle.authData.customer_id.

Thanks @ikbelkirasan for the quick response and great answer. I thought it would be something simple I was missing. +

 

@ikbelkirasan Its not working as I thought it would. The authentication response is not getting added to the authData in the bundle. 

Userlevel 7
Badge +12

@roboticcx - Which authentication method is your integration using?

API Key

Userlevel 7
Badge +12

Try using Session Auth instead to be able to fetch the customer ID.

OK. Thanks @ikbelkirasan . Will do.