CDP API
You can perform CDP Actions using REST API calls
- URL -
https://stage-askribe-askribe-ohlibf5r4a-el.a.run.app/api/v1/consumer/cdp-action - Request Method -
POST - Headers -
"Content-Type": "application/json" - Body
askribeKey- Type:
String - Required
- Obtain the API key required to connect with Askribe servers from the
Settingssection in your Askribe flow dashboard.
- Type:
cdpId- Type:
String - Required
- This can be acquired from the CDP dashboard
- Type:
cdpActionType- Type:
Enum - Required
- Allowed values
CREATE_CONTACT- Used to create a new contact in the CDPUPDATE_CONTACT- Used to update one or more existing contacts in the CDPDELETE_CONTACT- Used to delete one or more existing contacts in the CDPADD_TAGS_TO_CONTACT- Used to add one or more tags to one or more existing contacts in the CDPREMOVE_TAGS_FROM_CONTACT- Used to remove one or more tags from one or more existing contact in the CDPFIND_CONTACT- Used to find ONE contact in the CDP using an identifier columnFILTER_CONTACTS- Used to find multiple contacts using conditionCREATE_TAG- Used to create one or more tags in CDPDELETE_TAG- Used to delete one or more tags in CDP
- Type:
getContactsMechanism- Type:
Enum - Required if
cdpActionTypeis one ofUPDATE_CONTACT||DELETE_CONTACT||ADD_TAGS_TO_CONTACT||REMOVE_TAGS_FROM_CONTACT - Allowed values
FIND_BY_IDENTIFIER- Use this when you want to get a single contact based on an identifier columnFILTER_CONDITION- Use this when you want to get multiple contacts using conditionCONTACT_ID- Use this when you want to get one or more contacts using their ids. This is particularly useful when you have already fetched contacts viaFIND_CONTACTorFILTER_CONTACTSAPI
- Type:
findMap- Type:
Mapwith a singlestringkey andstringvalue - Required when
cdpActionTypeisFIND_CONTACTorgetContactsMechanismisFIND_BY_IDENTIFIER - Used to find a contact with an identifier key-value pair.
- Type:
filterCondition- Type:
String - Required when
cdpActionTypeisFILTER_CONTACTSorgetContactsMechanismisFILTER_CONDITION - Used to find all the contacts that match a condition.
- Type:
contactIds- Type:
List<String> - Required when
getContactsMechanismisCONTACT_ID - Used to find all the contacts by their ids.
- Type:
contactData- Type:
Map<String, String> - Required when cdpActionType is one of
UPDATE_CONTACT||CREATE_CONTACT - Contains the data for the new or updated contact
- Type:
tagNames- Type:
List<String> - Required when cdpActionType is one of
ADD_TAGS_TO_CONTACT||REMOVE_TAGS_FROM_CONTACT||CREATE_TAG||DELETE_TAG - Contains the list of tag names
- Type:
conflictResolutionType- Type:
Enum - To be sent optionally when the cdpActionType =
CREATE_CONTACT - Allowed values
OLD_DATA_WINS- No-opNEW_DATA_WINS- The new contact overrides existing contactMERGE_WITH_OLD_DATA_WINS- An attempt to merge both the contacts is made. In case of conflicting fields, no-op happensMERGE_WITH_NEW_DATA_WINS- An attempt to merge both the contacts is made. In case of conflicting fields, new data overrides exsiting data
- Type: