Skip to content

LinksResource

type LinksResource =
| {
tenant: string;
type: "tenant";
}
| {
hostname: string;
tenant?: string;
type: "domain";
}
| {
linkId?: string;
tenant: string;
type: "link";
}
| {
linkIds?: string[];
tenant: string;
type: "analytics";
}
| {
tenant: string;
type: "customer";
}
| {
tenant?: string;
type: "audit";
}
| {
tenant: string;
type: "conversion";
}
| {
tenant: string;
type: "viewer-token";
};

Defined in: src/authorization/contract.ts:44

The resource an action targets. Every resource carries the tenant it belongs to ("*" for “all tenants”, e.g. listing tenants; absent for shared domains and the global audit log), plus the link id or hostname when the action targets one record.