I would like to get dynamically in my mailing image from Open AI API. I configured everything in Open AI and in Postman I get url of the image. However in journey test mode it looks like there is nothing in response?? What do you think? Any suggestions? Then I would like to put response into email template in order to debug but nothing shows up on a templa and in the test mode log.
Solved! Go to Solution.
Topics help categorize Community content and increase your ability to discover relevant content.
Views
Replies
Total Likes
looks like the response is an array object, you can access it on the following lines
{{#each context.journey.actions.<actionId>.data as |res|}}
{{res.revised_prompt}}
<br/>
{{res.url}}
{{/each}}
I believe the response payload is configured in the custom action response. If so, can you try accessing the response attributes in a condition and see if you notice it in the logs ?
Sorry that my response is so late
I am not able to put the Custom Action response directly in the email template without condition?
I put the response in the email template directly but its empty and in the log there are no errors
I do not see any response in the log in Test Mode
Views
Replies
Total Likes
I use the Condition node as you said to check if response from the server == 200
In the Logs I see the response from API:
However its still not put into email template. Checked multiple times. How to debug further?
Views
Replies
Total Likes
Can you share how the response attributes are being accessed in the email message ?
Is this response from API (as JSON) is already parsed to a string?
Views
Replies
Total Likes
looks like the response is an array object, you can access it on the following lines
{{#each context.journey.actions.<actionId>.data as |res|}}
{{res.revised_prompt}}
<br/>
{{res.url}}
{{/each}}
My mistake, did not notice thats array ......
Thank you and happy new year!
Views
Replies
Total Likes
When was the custom action created? I observed a similar issue with a custom action created a couple of months ago. As a fallback option, I switched to using a data source (refer to: Configure Data Sources for Journeys).
However, I recently noticed that responses can now also be personalized in emails via custom actions. I would recommend creating a new custom action from scratch if the existing one was created a couple of months ago
Happy new year!
It was created few days ago. I use Custom Action as I think its more flexible for my use-case....
What is the practical difference between Custom Actions and Data Sources???
Views
Replies
Total Likes
In the initial release, the custom action feature in AJO supported only the POST method, while Data Source was the primary way to retrieve information from third-party systems into AJO.
With recent updates, custom action now supports the GET method, making it possible to fetch data directly from third-party systems. However, during testing, I observed a personalization issue with the custom action response, which did not occur with Data Source responses.
Data Source is specifically used to bring AEP data into AJO. Beyond this, custom action can perform the same functions of Data Source.
Views
Likes
Replies