Skip to main content

EntitySlugService

A service that handles slug generation for entities, ensuring uniqueness and handling conflicts by appending numbers.

Signature

constructor

method(slugService: SlugService, connection: TransactionalConnection) => EntitySlugService

generateSlugFromInput

method(ctx: RequestContext, params: GenerateSlugFromInputParams) => Promise<string>

Generates a slug from input value for an entity, ensuring uniqueness. Automatically detects if the field exists on the base entity or its translation entity.

Was this chapter helpful?
Report Issue
Edited Feb 25, 2026ยทEdit this page