Arrays not supported in custom action responses in Journey Optimizer

When invoking an API from a custom action in Adobe Journey Optimizer (AJO), the response returns an array. However, custom actions only support object-type payloads for both requests and responses. This limitation prevents using array data for personalization within journeys. To resolve the issue, format the response payload as an object instead of an array.

Description description

Environment

Adobe Journey Optimizer (AJO)

Issue/Symptoms

  • An API call from a custom action returns an array response instead of an object.
  • The array cannot be accessed or used for personalization within journeys.
  • Attempts to reference array elements result in syntax errors or validation failures.

Resolution resolution

Follow these steps to resolve the issue:

  1. Review the API response structure and confirm it returns an array. Refer to Troubleshoot your custom actions for validation steps.
  2. Update the API or integration so the response payload is formatted as an object. Refer to Configure a custom action for payload structure guidelines.
  3. Ensure both request and response payloads for custom actions use object structures.
  4. Test the updated custom action to verify personalization works with object-based data.
  5. Validate that no syntax or type mismatch errors occur when accessing object properties.
recommendation-more-help
3d58f420-19b5-47a0-a122-5c9dab55ec7f