mirror of
https://github.com/fleetdm/fleet
synced 2026-05-23 08:58:41 +00:00
Website: Update receive-from-clay webhook. (#30153)
Closes: https://github.com/fleetdm/confidential/issues/11058 Changes: - Updated the receive from clay webhook to log a warning and return a `couldNotCreateActivity` response if it receives information about a contact record with no account record associated with it.
This commit is contained in:
parent
7b3bc166bb
commit
d7016b794c
1 changed files with 5 additions and 0 deletions
|
|
@ -84,6 +84,11 @@ module.exports = {
|
|||
}
|
||||
});
|
||||
|
||||
if(!recordIds.salesforceAccountId) {
|
||||
sails.log.warn(`When the receive-from-clay received information about a user's activity (name: ${firstName} ${lastName}), activity: ${intentSignal}). A contact was successfully updated, but the webhook is unable to continue because this contact is not associated with any Salesforce account record. Contact ID: ${recordIds.salesforceContactId}`);
|
||||
throw 'couldNotCreateActivity';
|
||||
}
|
||||
|
||||
let trimmedLinkedinUrl = linkedinUrl.replace(sails.config.custom.RX_PROTOCOL_AND_COMMON_SUBDOMAINS, '');
|
||||
|
||||
// Create the new Fleet website page view record.
|
||||
|
|
|
|||
Loading…
Reference in a new issue