SigNoz/signoz · error · errors.Error

CodeLicenseUnavailable

CodeLicenseUnavailable

Error message

a valid license is not available

What it means

CreatePublic (publish a dashboard publicly) is an enterprise feature gated on licensing: if licensing.GetActive(orgID) fails, this CodeLicenseUnavailable error is returned before the dashboard is fetched or stored.

Source

Thrown at ee/modules/dashboard/impldashboard/module.go:52

func NewModule(store dashboardtypes.Store, settings factory.ProviderSettings, analytics analytics.Analytics, orgGetter organization.Getter, queryParser queryparser.QueryParser, querier querier.Querier, licensing licensing.Licensing, tagModule tag.Module) dashboard.Module {
	scopedProviderSettings := factory.NewScopedProviderSettings(settings, "github.com/SigNoz/signoz/ee/modules/dashboard/impldashboard")
	pkgDashboardModule := pkgimpldashboard.NewModule(store, settings, analytics, orgGetter, queryParser, tagModule)

	return &module{
		pkgDashboardModule: pkgDashboardModule,
		store:              store,
		settings:           scopedProviderSettings,
		querier:            querier,
		licensing:          licensing,
		tagModule:          tagModule,
	}
}

func (module *module) CreatePublic(ctx context.Context, orgID valuer.UUID, publicDashboard *dashboardtypes.PublicDashboard) error {
	_, err := module.licensing.GetActive(ctx, orgID)
	if err != nil {
		return errors.New(errors.TypeLicenseUnavailable, errors.CodeLicenseUnavailable, "a valid license is not available").WithAdditional("this feature requires a valid license").WithAdditional(err.Error())
	}

	dashboard, err := module.Get(ctx, orgID, publicDashboard.DashboardID)
	if err != nil {
		return err
	}
	if err := dashboard.ErrIfNotPublishable(); err != nil {
		return err
	}

	storablePublicDashboard, err := module.store.GetPublic(ctx, publicDashboard.DashboardID.StringValue())
	if err != nil && !errors.Ast(err, errors.TypeNotFound) {
		return err
	}
	if storablePublicDashboard != nil {
		return errors.Newf(errors.TypeAlreadyExists, dashboardtypes.ErrCodePublicDashboardAlreadyExists, "dashboard with id %s is already public", storablePublicDashboard.DashboardID)
	}

View on GitHub (pinned to 5069bf80b0)

Solutions

  1. Install/renew an enterprise license for the org
  2. Verify licensing configuration and connectivity via the appended error
  3. Use non-public dashboards if licensing is not intended
Defensive patterns

Strategy: validation

Validate before calling

if _, err := licensing.GetActive(ctx, orgID); err != nil {
	return errors.New(errors.TypeLicenseUnavailable, errors.CodeLicenseUnavailable, "public dashboards unavailable")
}

Try / catch

if err := module.CreatePublic(ctx, orgID, pd); err != nil {
	if errors.HasType(err, errors.TypeLicenseUnavailable) { /* hide public-share toggle */ }
	return err
}

Prevention

When it happens

Trigger: Calling CreatePublic(ctx, orgID, publicDashboard) for an org with no active license.

Common situations: OSS/self-hosted install without EE license attempting public dashboards, expired trial, license service unreachable.

Related errors


AI-assisted analysis of SigNoz/signoz@5069bf80b0 (2026-08-28). Data as JSON: /api/errors/06df35235a89f664. Report an issue: GitHub.