Owl.Util.Flag.CreateFlag(name: string, config?: FlagConfig): FlagState

Server Only

Creates a new feature flag with specified scope, rollout, whitelist and blacklist options. Errors if flag already exists.

Parameters

name*
string
Unique identifier for the feature flag.
configConfiguration object containing Scope, Enabled status, RolloutPercent, Whitelist and Blacklist.

Returns

FlagStateThe newly created flag state object.

Related Types

local flag = Owl.Util.Flag.CreateFlag("BetaInventory", {
    Scope = "Public",
    Enabled = true,
    RolloutPercent = 25,
    Whitelist = { 12345678, 87654321 },
    Blacklist = { 99999999 },
})