Deploy and test the Node.js endpoint

In this step you deploy the sample Node.js application and validate end-to-end communications.

Use the provided server.jsfile as the application entry point, set the SENDGRID_API_KEY, SENDGRID_FROM, and AEM_BEARER environment variables, and start the Node.js runtime.

Connect the exposed endpoint to an Adobe Journey Optimizer custom action, submit the adaptive form to create a new profile in Experience Platform, and confirm that the generated PDF is emailed via SendGrid.

Prerequisites

Before deploying the application, ensure that you have:

Environment Variables

Configure the following environment variables before starting the application:

const SENDGRID_API_KEY = process.env.SEND_GRID_API_KEY; const SENDGRID_FROM = process.env.SENDGRID_FROM; const AEM_BEARER = process.env.AEM_BEARER;

Adobe Journey Optimizer Integration

Once deployed, the endpoint exposed by the Node.js application can be referenced in an Adobe Journey Optimizer custom action. When the custom action is invoked during a journey, the application generates a personalized PDF communication and delivers it to the recipient using SendGrid.

Test the solution by Filling out an adaptive form with the required details, including an email address and the cloud solution of interest. Ensure that the information corresponds to a new customer profile in Adobe Experience Platform. This triggers a journey in Adobe Journey Optimizer, which creates a personalized interactive communication. A PDF version of this communication is then sent to the provided email address.

The video demonstrates the end-user experience for this use case.

After deployment, submit the adaptive form with a new customer profile to trigger the journey and verify email delivery.

Check application logs, SendGrid activity, and Adobe Journey Optimizer execution history if delivery fails.

This completes the deployment and test for the solution.