Skip to contentSkip to navigationSkip to topbar
Page tools
Useful for sharing or LLM
Accelerate development with AI

On this page
Looking for more inspiration?Visit the

Retrieve a subuser's branded link


API Overview

api-overview page anchor

To serve all of the click-tracked links, opens, and images in your emails from your domain, use Email link branding. This replaces sendgrid.net for Global Email send or eu.sendgrid.net for Regional Email send with your domain. To determine whether the email looks trustworthy, spam filters and recipient servers look at the links within emails. To determine if they can trust the links, these systems check the reputation of the root domain.

To manage link branding, go to the Sender Authentication section of the Twilio SendGrid App(link takes you to an external page).

To learn more, see How to set up link branding.


GET/v3/whitelabel/links/subuser

Base url: https://api.sendgrid.com (for global users and subusers)

Base url: https://api.eu.sendgrid.com (for EU regional subusers)

This endpoint allows you to retrieve the branded link associated with a subuser.

Link branding can be associated with subusers from the parent account. This functionality allows subusers to send mail using their parent's link branding. To associate link branding, the parent account must first create a branded link and then validate it. The parent may then associate that branded link with a subuser via the API or the Subuser Management page of the Twilio SendGrid App(link takes you to an external page).


Authentication

authentication page anchor
Property nameTypeRequiredDescription
Authorizationstring
required
Default: Bearer <<YOUR_API_KEY_HERE>>
Property nameTypeRequiredDescription
usernamestring
required

The username of the subuser to retrieve associated branded links for.

200
SchemaExample
Property nameTypeRequiredDescriptionChild properties
idinteger

Optional

The ID of the branded link.


domainstring

Optional

The root domain of the branded link.


subdomainstring

Optional

The subdomain used to generate the DNS records for this link branding. This subdomain must be different from the subdomain used for your authenticated domain.


usernamestring

Optional

The username of the account that this link branding is associated with.


user_idinteger

Optional

The ID of the user that this link branding is associated with.


defaultenum<boolean>

Optional

Indicates if this is the default link branding.

Possible values:
truefalse

validenum<boolean>

Optional

Indicates if this link branding is valid.

Possible values:
truefalse

legacyenum<boolean>

Optional

Indicates if this link branding was created using the legacy whitelabel tool. If it is a legacy whitelabel, it will still function, but you'll need to create new link branding if you need to update it.

Possible values:
truefalse

dnsobject

Optional

The DNS records generated for this link branding.

Retrieve a subuser's branded linkLink to code sample: Retrieve a subuser's branded link
1
const client = require("@sendgrid/client");
2
client.setApiKey(process.env.SENDGRID_API_KEY);
3
4
const queryParams = { username: "username" };
5
6
const request = {
7
url: `/v3/whitelabel/links/subuser`,
8
method: "GET",
9
qs: queryParams,
10
};
11
12
client
13
.request(request)
14
.then(([response, body]) => {
15
console.log(response.statusCode);
16
console.log(response.body);
17
})
18
.catch((error) => {
19
console.error(error);
20
});