- go-sample-frontend: the React front end, shared by all three sample apps.
- go-sample-backend-java: the Java backends.
- go-sample-backend-typescript: the TypeScript backends.
api-implementation/calls the Journey API with hand-written HTTP requests.sdk-implementation/calls the Journey API through the Core SDK.
What this tutorial covers
By the end, you’ll have a patient onboarding application that:- Starts a verification journey through the Journey API v2, either directly or through the Core SDK.
- Renders each screen from the journey’s own configuration, rather than from hardcoded forms.
- Collects consent, identity details, an address, a photo ID, and a selfie.
- Polls for the outcome and shows the decision, including a referral to manual review.
Prerequisites
- Access to the Go dashboard, with permission to create and publish journeys.
- Licences for the modules this tutorial uses. Licences are assigned to your department by GBG, and an unlicensed module shows a warning icon in the Journey builder.
- An API client. See Manage API clients for how to create one and get your client ID and secret.
- Node.js v18 or higher, for the front end and the TypeScript backend.
- JDK 21 and Maven, only if you choose the Java backend.
- Git, to clone the sample repositories.
Part 1: Build the journey
The application renders its screens from whatever your journey collects, so the journey comes first. The finished journey looks like this. Six modules run in sequence, then one evaluation node routes the patient to accept, reject, or manual review.
The healthcare patient onboarding journey
Add the modules
Add the evaluation
positive renders an approval, negative a decline, and neutral a referral to manual review.Give each decision branch an End of journey node.Publish to Preview
Copy the resource ID and version
<resourceId>@<version>, for example:Part 2: Set up the backend
Choose a backend. Each one exposes the same HTTP API, so the front end works with any of them.- Java API
- TypeScript API
- Java SDK
- TypeScript SDK
.env.local and set your client credentials:src/main/resources/application-meridian-health.yml and set your journey:http://localhost:8082. The script finds JDK 21, loads .env.local, and starts the right profile../run.sh meridian-health mock or npm run dev:meridian-health to use it.
Set your region
The samples default to the EU platform. If your tenant is in another region, then change the base URL and the region together, in the folder you chose:- Java
- TypeScript
src/main/resources/application-meridian-health.yml:Part 3: Set up the front end
The front end is one repository holding three applications. This tutorial uses the healthcare one.apps/meridian-health/.env.local, pointing at the backend you chose:
- API backend
- SDK backend
NEXT_PUBLIC_* values into the browser bundle when it starts. Never put credentials here, and restart the front end after you change them.http://localhost:3001. With the backend already running, you’ll land on the consent screen of your own journey.
Troubleshooting
The app shows a generic 'A few more details' form
The app shows a generic 'A few more details' form
No screen mapped for outstanding elements, which names the unmapped elements, then add them to the screen plan.A screen asks for details the customer already entered
A screen asks for details the customer already entered
collects after every republish rather than assuming the shape holds.Every request fails with an expired session
Every request fails with an expired session
sessionStorage, so reloading resumes the journey, but a new tab starts a fresh one.Authentication succeeds but journey calls fail
Authentication succeeds but journey calls fail
region and base-url name the same region.A module returns an error rather than a decision
A module returns an error rather than a decision
The backend logs 'No SDK submit mapping for field'
The backend logs 'No SDK submit mapping for field'
FieldMapping.KNOWN in SdkInteractionMapper.java. In TypeScript, it’s buildSdkSubmitRequest.ts.The front end still talks to the backend you used before
The front end still talks to the backend you used before
NEXT_PUBLIC_API_BASE_URL when it starts. Set it to the port of the backend you’re running now, then stop and restart the front end.The backend won't start because the port is in use
The backend won't start because the port is in use
ConnectionError: fetch failed, or UNABLE_TO_GET_ISSUER_CERT_LOCALLY
ConnectionError: fetch failed, or UNABLE_TO_GET_ISSUER_CERT_LOCALLY
export NODE_OPTIONS=--use-system-ca before you start the backend. On older versions, set NODE_EXTRA_CA_CERTS to the path of your proxy’s root certificate.