{ "openapi": "3.0.1", "info": { "title": "game-passes-http-service", "version": "v1", "x-roblox-extensions-version": "1.0.0" }, "paths": { "/game-passes/v1/universes/{universeId}/game-passes": { "post": { "tags": ["GamePasses"], "summary": "Create game pass", "description": "Creates a new game pass with the provided configuration details.", "operationId": "GamePasses_CreateGamePass", "parameters": [ { "name": "universeId", "in": "path", "description": "The universe ID.", "required": true, "schema": { "type": "integer", "format": "int64" } } ], "requestBody": { "content": { "multipart/form-data": { "schema": { "required": ["name"], "type": "object", "properties": { "name": { "type": "string", "description": "The name of the game pass." }, "description": { "type": "string", "description": "The description of the game pass.", "nullable": true }, "imageFile": { "type": "string", "description": "The thumbnail image file to be uploaded.", "format": "binary", "nullable": true }, "isForSale": { "type": "boolean", "description": "Whether the game pass should be on sale.", "nullable": true }, "price": { "type": "integer", "description": "The default price of the game pass.", "format": "int64", "nullable": true }, "isRegionalPricingEnabled": { "type": "boolean", "description": "Whether regional pricing should be enabled for the game pass.", "nullable": true } } }, "encoding": { "name": { "style": "form" }, "description": { "style": "form" }, "imageFile": { "style": "form" }, "isForSale": { "style": "form" }, "price": { "style": "form" }, "isRegionalPricingEnabled": { "style": "form" } } } } }, "responses": { "200": { "description": "Success", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GamePassConfigV2" } } } }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "x-roblox-stability": "BETA", "x-roblox-rate-limits": { "perApiKeyOwner": { "period": "SECOND", "maxInPeriod": 5 } }, "x-roblox-scopes": [ { "name": "game-pass:write" } ], "x-roblox-engine-usability": { "apiKeyWithHttpService": false }, "security": [ { "roblox-legacy-cookie": [] }, { "roblox-api-key": [] } ] } }, "/game-passes/v1/universes/{universeId}/game-passes/{gamePassId}": { "patch": { "tags": ["GamePasses"], "summary": "Update game pass", "description": "Updates a game pass with the provided configuration details.\r\nNote that only fields provided in the request will be updated.", "operationId": "GamePasses_UpdateGamePass", "parameters": [ { "name": "universeId", "in": "path", "description": "The universe ID.", "required": true, "schema": { "type": "integer", "format": "int64" } }, { "name": "gamePassId", "in": "path", "description": "The game pass ID.", "required": true, "schema": { "type": "integer", "format": "int64" } } ], "requestBody": { "content": { "multipart/form-data": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of the game pass.", "nullable": true }, "description": { "type": "string", "description": "The description of the game pass.", "nullable": true }, "file": { "type": "string", "description": "The thumbnail image file to be uploaded.", "format": "binary", "nullable": true }, "isForSale": { "type": "boolean", "description": "Whether the game pass should be on sale.", "nullable": true }, "price": { "type": "integer", "description": "The default price of the game pass.", "format": "int64", "nullable": true }, "isRegionalPricingEnabled": { "type": "boolean", "description": "Whether regional pricing should be enabled for the game pass.", "nullable": true } } }, "encoding": { "name": { "style": "form" }, "description": { "style": "form" }, "file": { "style": "form" }, "isForSale": { "style": "form" }, "price": { "style": "form" }, "isRegionalPricingEnabled": { "style": "form" } } } } }, "responses": { "204": { "description": "No Content" }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "409": { "description": "Conflict", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "x-roblox-stability": "BETA", "x-roblox-rate-limits": { "perApiKeyOwner": { "period": "SECOND", "maxInPeriod": 5 } }, "x-roblox-scopes": [ { "name": "game-pass:write" } ], "x-roblox-engine-usability": { "apiKeyWithHttpService": false }, "security": [ { "roblox-legacy-cookie": [] }, { "roblox-api-key": [] } ] } }, "/game-passes/v1/universes/{universeId}/game-passes/{gamePassId}/creator": { "get": { "tags": ["GamePasses"], "summary": "Get game pass with configuration details", "operationId": "GamePasses_GetGamePassConfig", "parameters": [ { "name": "universeId", "in": "path", "description": "The universe ID.", "required": true, "schema": { "type": "integer", "format": "int64" } }, { "name": "gamePassId", "in": "path", "description": "The game pass ID.", "required": true, "schema": { "type": "integer", "format": "int64" } } ], "responses": { "200": { "description": "Success", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/GamePassConfigV2" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "x-roblox-stability": "BETA", "x-roblox-rate-limits": { "perApiKeyOwner": { "period": "SECOND", "maxInPeriod": 10 } }, "x-roblox-scopes": [ { "name": "game-pass:read" } ], "x-roblox-engine-usability": { "apiKeyWithHttpService": false }, "security": [ { "roblox-legacy-cookie": [] }, { "roblox-api-key": [] } ] } }, "/game-passes/v1/universes/{universeId}/game-passes/creator": { "get": { "tags": ["GamePasses"], "summary": "List game passes by universe with configuration details", "operationId": "GamePasses_ListGamePassConfigsByUniverse", "parameters": [ { "name": "universeId", "in": "path", "description": "The universe ID.", "required": true, "schema": { "type": "integer", "format": "int64" } }, { "name": "pageSize", "in": "query", "description": "The number of results to return. Defaults to 50 if not provided.", "schema": { "type": "integer", "format": "int32" } }, { "name": "pageToken", "in": "query", "description": "The cursor token for pagination.", "schema": { "type": "string" } } ], "responses": { "200": { "description": "Success", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ListGamePassConfigsByUniverseResponse" } } } }, "400": { "description": "Bad Request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "403": { "description": "Forbidden", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "404": { "description": "Not Found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "x-roblox-stability": "BETA", "x-roblox-rate-limits": { "perApiKeyOwner": { "period": "SECOND", "maxInPeriod": 10 } }, "x-roblox-scopes": [ { "name": "game-pass:read" } ], "x-roblox-engine-usability": { "apiKeyWithHttpService": false }, "security": [ { "roblox-legacy-cookie": [] }, { "roblox-api-key": [] } ] } } }, "components": { "schemas": { "ErrorCode": { "enum": [ "InternalError", "BadRequest", "NotFound", "UnauthorizedAccess", "NotAuthenticated", "PassNotFound", "TargetUnauthorizedAccess", "UniverseNotFound", "MissingArgument", "AssetCreationFailure", "PassRevokeFailure", "PassAlreadyRevoked", "SalesNotFound", "CommissionRateNotFound", "AssetNotFound", "FileTooLarge", "ActiveInPO", "NotForSale", "NotSameUniverse", "PricingConfigError", "InvalidCount", "Blocked", "InvalidPageSize" ], "type": "string", "description": "Code representing various error conditions." }, "ErrorResponse": { "type": "object", "properties": { "errorCode": { "allOf": [ { "$ref": "#/components/schemas/ErrorCode" } ], "description": "The ErrorCode for the exception." }, "errorMessage": { "type": "string", "description": "The human readable error message.", "nullable": true }, "field": { "type": "string", "description": "The relevant field that caused the error.", "nullable": true }, "hint": { "type": "string", "description": "A hint as to what caused the error, if applicable.", "nullable": true } }, "additionalProperties": false, "description": "This is the base class for all custom Exceptions that are thrown in this API." }, "GamePassConfigV2": { "required": [ "createdTimestamp", "description", "gamePassId", "iconAssetId", "isForSale", "name", "priceInformation", "updatedTimestamp" ], "type": "object", "properties": { "gamePassId": { "type": "integer", "description": "The game pass ID.", "format": "int64" }, "name": { "type": "string", "description": "The name of the game pass." }, "description": { "type": "string", "description": "The description of the game pass." }, "isForSale": { "type": "boolean", "description": "Whether the game pass is currently on sale." }, "iconAssetId": { "type": "integer", "description": "The icon image (thumbnail) asset ID of the game pass.", "format": "int64" }, "createdTimestamp": { "type": "string", "description": "The timestamp when the game pass was created.", "format": "date-time" }, "updatedTimestamp": { "type": "string", "description": "The timestamp when the game pass was last updated.", "format": "date-time" }, "priceInformation": { "allOf": [ { "$ref": "#/components/schemas/PriceInformationStruct" } ], "description": "The pricing configuration associated with the game pass.", "nullable": true } }, "additionalProperties": false, "description": "Creator-facing representation of a game pass configuration." }, "ListGamePassConfigsByUniverseResponse": { "required": ["gamePasses", "nextPageToken"], "type": "object", "properties": { "gamePasses": { "type": "array", "items": { "$ref": "#/components/schemas/GamePassConfigV2" }, "description": "The list of game passes with their corresponding configuration details." }, "nextPageToken": { "type": "string", "description": "The next page token.", "nullable": true } }, "additionalProperties": false, "description": "Response for listing game pass configuration details by universe" }, "PriceInformationStruct": { "required": ["defaultPriceInRobux", "enabledFeatures"], "type": "object", "properties": { "defaultPriceInRobux": { "type": "integer", "description": "The configured default price in Robux.", "format": "int64", "nullable": true }, "enabledFeatures": { "type": "array", "items": { "$ref": "#/components/schemas/PricingFeature" }, "description": "The enabled pricing features for the game pass." } }, "additionalProperties": false, "description": "The pricing configuration information." }, "PricingFeature": { "enum": [ "Invalid", "PriceOptimization", "UserFixedPrice", "RegionalPricing" ], "type": "string", "description": "Enum representing enabled features for this particular game pass." } }, "securitySchemes": { "roblox-legacy-cookie": { "type": "apiKey", "description": "A browser cookie that represents the identity of a Roblox user. DO NOT SHARE THIS. Sharing this will allow someone to log in as you and to steal your Robux and items. When possible, use API keys with the x-api-key header or OAuth 2.0 instead for authentication.", "in": "cookie", "name": ".ROBLOSECURITY" }, "roblox-api-key": { "type": "apiKey", "description": "A configurable key that allows granular access to Roblox resources. See https://create.roblox.com/docs/cloud/auth/api-keys for more information.", "in": "header", "name": "x-api-key" } } }, "servers": [ { "url": "https://apis.roblox.com" } ] }