How to send a custom alert

Any kind of token, scopes optional

const urlParams = new URLSearchParams(window.location.search);
const anchor = 'anchor_' + urlParams.get('anchor');

Is what I do to grab the anchor from the URL/query string