SecureHandler Docs

Items and commands reference

Documentation

Reference page for SecureHandler item modes, parameters, examples, part structure, and server commands.

SecureHandler Mini Docs

Small reference site for Roblox shop item modes, required parameters, optional fields, and example setup code.

Common Parameters

Required on every item

part
type

Every call to SecureHandler.InitializeItem() needs at least a target part/model and a valid mode name.

Usually required

itemId
gamepassId
itemsId

Depending on the selected mode, you may also need an item ID, gamepass ID, or a bulk item list.

Optional visual params

name
meshId
textureId
scale

If meshId or textureId are missing, the script tries to auto-fetch them from itemId.

SecureHandler.InitializeItem({
    part = script.Parent,
    type = "PaidLim",
    itemId = 123456789,
    name = "My Item",
    scale = 2.5,
})

Supported Modes

PaidLim

Normal paid limited item. Anyone can buy it.

{
    part = script.Parent,
    type = "PaidLim",
    itemId = 123
}

PaidLimGp

Limited item locked behind a gamepass. If player owns the pass, they can buy itemId.

{
    part = script.Parent,
    type = "PaidLimGp",
    itemId = 123,
    gamepassId = 456
}

BulkLimGp

Bulk avatar-item purchase locked behind a gamepass.

{
    part = script.Parent,
    type = "BulkLimGp",
    itemId = 123,
    gamepassId = 456,
    itemsId = {111, 222, 333}
}

ItemIt

Single item gated by already owning an item. If not owned, player gets flung.

{
    part = script.Parent,
    type = "ItemIt",
    itemId = 123
}

BulkItemIt

Bulk purchase gated by owning another item. If not owned, player gets flung.

{
    part = script.Parent,
    type = "BulkItemIt",
    itemId = 123,
    itemsId = {111, 222, 333}
}

BasicOns

Basic onsale item. Shows onsale or offsale state and removes prompt when offsale.

{
    part = script.Parent,
    type = "BasicOns",
    itemId = 123
}
Important: ItemIt currently uses the same itemId for the ownership check and the purchase target.

Examples

Your BulkLimGp example

local ServerScriptService = game:GetService("ServerScriptService")
local SecureHandler = require(ServerScriptService:WaitForChild("SecureHandler"))

SecureHandler.InitializeItem({
    part = script.Parent,
    name = "Full Pack Pirate Hats",
    gamepassId = 1617569326,
    itemId = 112620423988242,
    itemsId = {95810754699174, 96671108416830, 108283639786307, 109508983928947},
    scale = 4,
    type = "BulkLimGp"
})

PaidLimGp example

SecureHandler.InitializeItem({
    part = script.Parent,
    type = "PaidLimGp",
    itemId = 125040824479162,
    gamepassId = 1069695674,
    scale = 2.7
})

Manual mesh override

SecureHandler.InitializeItem({
    part = script.Parent,
    type = "PaidLim",
    itemId = 125040824479162,
    meshId = 120415125294964,
    textureId = 126312375468810,
    scale = 2.7
})

Auto-fetch mesh + texture

SecureHandler.InitializeItem({
    part = script.Parent,
    type = "PaidLim",
    itemId = 125040824479162,
    scale = 2.7
})

Expected Part Structure

Your target part should contain these objects for full functionality.

Part / Model
├─ ProximityPrompt
├─ SM
│  └─ Bl   (SpecialMesh)
└─ Info
   └─ BillboardGui
      ├─ ItemName
      ├─ Stock
      └─ Price
  • ProximityPrompt handles interaction.
  • SM.Bl is the display mesh.
  • Info.BillboardGui contains the text labels the script updates.

Quick Reference

PaidLim     -> part, type, itemId
PaidLimGp   -> part, type, itemId, gamepassId
BulkLimGp   -> part, type, itemId, gamepassId, itemsId
ItemIt      -> part, type, itemId
BulkItemIt  -> part, type, itemId, itemsId
BasicOns    -> part, type, itemId

Game Commands Docs

Reference page for the chat commands in your server script.

Public Commands

!buyitem or /buyitem

Everyone

Teleports the player to the buy-item place. Falls back to a second place if the first teleport fails.

!buyitem
/buyitem

Fun / Special Commands

pinky

User 790144111 only

Clones DualPink and . from ReplicatedStorage.Assets into the backpack.

pimpi

Everyone

Gives Smurf Potion, then teleports most players after 4 seconds.

apocalypsis

Everyone

Gives NuclearLauncher, then teleports most players immediately.

froggy

Everyone

Gives Frog, then teleports most players immediately. User 828797472 is also exempt.

These commands depend on matching assets existing inside ReplicatedStorage.Assets.

Admin Commands

/tpg PLACE_ID

Admins only

Broadcasts a global teleport to every player in every subscribed server.

/tpg 1234567890

/buy USER_ID ITEM_ID

Admins only

Prompts a purchase for a specific avatar item on a specific user across subscribed servers.

/buy 790144111 123456789

/buyb USER_ID ITEM_ID ITEM_ID ...

Admins only

Prompts a bulk purchase for a specific user.

/buyb 790144111 111 222 333

/trollparty

Admins only

Teleports everyone except the caller to the troll-party place.

/shutdown or /restart

Admins only

Restarts the current server by reserving a new private server and teleporting players into it.

/lock and /unlock

Admins only

Locks or unlocks the current server for future joins.

/globalrestart

Admins only

Broadcasts a restart signal to all subscribed servers.

/kick USERNAME [reason]

Admins only

Kicks a player by username across subscribed servers.

/kick Builderman stop trolling

/kickid USER_ID [reason]

Admins only

Kicks a player by user ID across subscribed servers.

/kickid 790144111 rule break

Messaging Topics Used

GlobalKick
GlobalRestart
GlobalTPG
GlobalTrollParty
GlobalBuy
  • GlobalKick handles cross-server kick requests.
  • GlobalRestart handles cross-server restart requests.
  • GlobalTPG handles global teleports.
  • GlobalTrollParty handles troll-party teleports.
  • GlobalBuy handles purchase and bulk-purchase prompts.