Docs

Deep Linking

Handle incoming link data in your web app with the Grovs SDK

On the web, incoming link data is handled through the callback you pass to the Grovs constructor. The callback receives the link data for matching links:

import Grovs from 'grovs';
 
const grovs = new Grovs('your-api-key', (data) => {
    // Called when a matching link is detected
    console.log('Link data:', data);
});
 
// Start the SDK
grovs.start();

Register the callback when you create the instance, then call start() — the SDK must be started before it can detect matching links. See the Constructor and start reference for details.

What the callback receives

The data argument contains the custom payload attached to the link — the key-value pairs set in the Data section when the link was created in the dashboard, or the data object passed to createLink when the link was generated programmatically.

Use those keys to route the user in your web app:

const grovs = new Grovs('your-api-key', (data) => {
    if (data?.screen === 'product_detail') {
        showProduct(data.productId);
    }
});
 
grovs.start();

There are no restrictions on the keys or values a link's data payload can contain — use whatever structure fits your app.

Next steps

Edit this page on GitHubLast updated 2026-07-29