Pool of .ROBLOSECURITY cookie values (without the cookie name prefix). Can be a single string or an array for multiple accounts. Used for classic Roblox web API authentication.
Callback invoked when Roblox rotates a .ROBLOSECURITY cookie. Roblox is gradually implementing cookie rotation for security. Use this callback to persist the new cookie value to your storage.The internal cookie pool is automatically updated, so you only need this callback if you want to persist the new cookie across restarts.
import { configureServer } from 'rozod';configureServer({ cookies: '_|WARNING:-DO-NOT-SHARE-THIS...'});
RoZod includes built-in browser user agents that are automatically applied in server environments. You can customize this behavior with the userAgents and userAgentRotation options.
type CookieRefreshEvent = { /** The old cookie value that was used in the request */ oldCookie: string; /** The new cookie value received from Roblox */ newCookie: string; /** The index in the cookie pool that was updated (0 for single cookie) */ poolIndex: number;}
Event data passed to the cookie refresh callback when Roblox rotates a cookie.
type CookieRefreshCallback = (event: CookieRefreshEvent) => void | Promise<void>
Callback function invoked when Roblox rotates a .ROBLOSECURITY cookie. Use this to persist the new cookie value to your storage (env vars, database, etc.).