This guide explains how to connect Mavenoid with Oracle B2C Service to query contacts, create contacts, and set up support incidents using REST APIs and Basic Authentication.
Admin Access To Mavenoid: Contact your Mavenoid representative if you lack admin permissions.
User Credentials: An Oracle B2C Service user with access to the contacts and incidents APIs.
Configure Basic Authentication:
Encode the integration user's username:password
in base64 and add it as a secret in Mavenoid. Refer to the guide Secrets for details on how to add a secret.
Query Contacts:
Use a GET request to find contacts by email: GET https://{YOUR_REST_SERVER_URL}/services/rest/connect/{vx.x}/contacts?q=emails.address='{{$customer-email}}'
Create a Contact:
If no contact exists, create one with a POST request: POST https://{YOUR_REST_SERVER_URL}/services/rest/connect/{vx.x}/contacts
Create an Incident:
Create a new incident with the contact ID referenced in the body of the request:
POST https://{YOUR_REST_SERVER_URL}/services/rest/connect/{vx.x}/incidents
{
"primaryContact": {
"id": {{CUSTOMER_CONTACT_ID}}
}
}
When making API calls, include these headers for authorization and context:
Authorization: Set as Authorization: Basic {{$secrets["YOUR_SECRET"]}}
, where YOUR_SECRET
is the base64-encoded username:password
secret created previously.
Application Context: Use OSvC-CREST-Application-Context: {CONTEXT}
, where {CONTEXT}
specifies the request's purpose, such as Retrieve Data for data queries or Create Data for creating new entries.
For more detailed information on the Oracle B2C Service REST APIs, refer to the Oracle's documentation Get Multiple Contacts, Create a contact, and Create an incident.