Skip to content

Commit

Permalink
chore: fix delete endpoint for braze (#3791)
Browse files Browse the repository at this point in the history
* chore: fix delete endpoint for braze

* chore: add example inline
  • Loading branch information
utsabc authored Oct 9, 2024
1 parent 5ac8186 commit f2231cb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/v0/destinations/braze/deleteUsers.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,12 @@ const userDeletionHandler = async (userAttributes, config) => {
}
// Endpoints different for different data centers.
// DOC: https://www.braze.com/docs/user_guide/administrative/access_braze/braze_instances/
// Example Data Center: "EU-01", "US-01"
let endPoint;
const endpointPath = '/users/delete';
const dataCenterArr = dataCenter.trim().split('-');
if (dataCenterArr[0].toLowerCase() === 'eu') {
endPoint = 'https://rest.fra-01.braze.eu/users/delete';
endPoint = `https://rest.fra-${dataCenterArr[1]}.braze.eu/users/delete`;
} else {
endPoint = `https://rest.iad-${dataCenterArr[1]}.braze.com/users/delete`;
}
Expand Down

0 comments on commit f2231cb

Please sign in to comment.