Skip to main content
Every Tusky user gets a private aggregator — a dedicated HTTP endpoint for serving their content from the Walrus network. The tusky.aggregator module lets you view and configure your aggregator settings programmatically.

Get Aggregator Configuration

Retrieve your current aggregator settings:
const aggregator = await tusky.aggregator.get();

console.log("Subdomain:", aggregator.subdomain);
console.log("URL:", aggregator.url);
console.log("Custom domain:", aggregator.customDomain || "Not configured");
console.log("SSL:", aggregator.sslEnabled);

Aggregator Object

FieldTypeDescription
idstringUnique aggregator identifier.
subdomainstringYour aggregator subdomain (e.g. myproject).
urlstringFull aggregator URL (e.g. https://myproject.mytusky.xyz).
customDomainstring | nullCustom domain if configured, otherwise null.
sslEnabledbooleanWhether SSL is active on the aggregator.
createdAtstringISO 8601 creation timestamp.

Update Aggregator Settings

Customize your aggregator’s subdomain or attach a custom domain:

Change Subdomain

const updated = await tusky.aggregator.update({
  subdomain: "brand-assets",
});

console.log("New URL:", updated.url);
// https://brand-assets.mytusky.xyz

Attach a Custom Domain

const updated = await tusky.aggregator.update({
  customDomain: "cdn.example.com",
});

console.log("Custom domain:", updated.customDomain);
console.log("SSL:", updated.sslEnabled);
Before attaching a custom domain, you must add a CNAME record pointing your domain to Tusky. See Custom Domains for the full setup guide.

Complete Example

import { Tusky } from "@tusky-io/ts-sdk";

const tusky = new Tusky({ apiKey: process.env.TUSKY_API_KEY });

// View current aggregator
const aggregator = await tusky.aggregator.get();
console.log("Current aggregator URL:", aggregator.url);

// Update subdomain
const updated = await tusky.aggregator.update({
  subdomain: "my-new-subdomain",
});
console.log("Updated aggregator URL:", updated.url);

// Attach custom domain (after DNS setup)
const withDomain = await tusky.aggregator.update({
  customDomain: "files.mydomain.com",
});
console.log("Custom domain active:", withDomain.customDomain);
Your aggregator serves only your own content. Unlike public Walrus aggregators, a Tusky private aggregator will not resolve blobs that belong to other users. This provides security isolation and prevents abuse.

What’s Next