Skip to main content

What is an organization slug?

A slug is a short, URL-safe name for something. It uses lowercase letters, digits and hyphens, no spaces, no special characters, so it can sit inside a web address without being escaped. The word comes from newspaper jargon, where a slug was the short working title of a story. An organization slug is that short name for your organization inside a product. Where the display name can be “Courtney’s Pantry”, the slug is courtneys-pantry. Two organizations can have the same display name, but never the same slug, because the slug is what identifies the organization in URLs and API calls. In PayGlue every publication you connect is an organization, and its slug is the identifier we use everywhere a name has to be machine-readable.

Where you see it in PayGlue

  • Dashboard URL. Every page of your dashboard carries it: https://app.payglue.io/t/your-slug/.... That is the quickest place to read it off.
  • Webhook URLs. Each payment provider sends its events to an address that names your organization:
The parameter is called tenant, which is our internal word for the same thing.
  • Paywall header script. The script you paste into Ghost’s code injection names your organization in its data-org attribute, so the paywall knows whose members to check.
  • Settings. Under Settings > Organization the slug is shown with a copy button, and this is where it can be renamed.

Where does it come from?

PayGlue derives the slug from the organization name you type when you create it: lowercased, everything that is not a letter, a digit or a hyphen becomes a hyphen, runs of hyphens collapse into one. It has to be at least three characters long and not taken yet; the form checks that as you type, and if the name is taken you pick a different one. You can change the slug afterwards, see below.

Can I change it?

Yes, but read the next section first. Only the organization’s Owner can rename the slug. Go to Settings > Organization, enter the new slug and check both confirmation boxes before saving. PayGlue will not save without them, because the consequences are easy to underestimate.

What changes when you rename it

Your dashboard URL changes. Bookmarks to the old address stop working; sign in and pick the publication again, then bookmark the new one. Your webhook URLs change too, and those do not redirect. Every payment provider you connected keeps sending events to the old address, which no longer belongs to anyone. Purchases still go through at the provider, but PayGlue never hears about them, and nobody gets access in Ghost until the URL is fixed.
After renaming, update the webhook URL in every connected payment provider’s dashboard and replace the paywall header script in Ghost, the same day. Events sent to the old URL are lost, they are not queued for you.
Update the webhook URL (https://api.payglue.io/webhooks/{provider}?tenant={slug}&key=...) in every connected provider’s dashboard. The full URL with your key is shown on each provider’s connection page in PayGlue. The paywall header script in Ghost’s code injection carries the slug in data-org and has to be replaced with the new snippet from Header Script, or the paywall stops recognising your members. The embed snippets for buttons and pricing tables are not affected; they identify the widget by its own id.

Is the slug secret?

No. It is visible in your dashboard URL and it would be visible to anyone who saw your webhook URL. That is why every webhook URL also carries a key parameter, a secret that belongs to your organization alone. The slug says who you are, the key proves it. Keep the key out of screenshots; the slug can be public.