This commit is contained in:
Joe 2026-02-02 12:08:47 -06:00
parent a9b4f8e83b
commit e6efc04756
8494 changed files with 495610 additions and 0 deletions

View file

@ -0,0 +1,183 @@
# This file is automatically generated. Please don't edit it manually.
# To submit a bug report on the content, see
# https://devforum.roblox.com/c/bug-reports/documentation-issues/72
name: CommerceService
type: class
memory_category: Instances
summary: |
Supports real-world purchases that you can bundle with digital benefits.
description: |
`Class.CommerceService` is a service that supports real-world purchases that
you can bundle with virtual items. For information on eligibility and
implementation, see
[Commerce products](../../../production/monetization/commerce-products.md).
code_samples: []
inherits:
- Instance
descendants: []
tags:
- NotCreatable
- Service
deprecation_message: ''
properties: []
methods:
- name: CommerceService:GetCommerceProductInfoAsync
summary: |
Retrieves information about the commerce products you are selling in
experience.
description: |
Retrieves information about the products that you are selling and surface
them within your experience. How you surface products to your users is
entirely up to you.
<table><thead>
<tr>
<th>Name</th>
<th>string</th>
<th>Localized name of of the physical item</th>
</tr></thead>
<tbody>
<tr>
<td>Description</td>
<td>string</td>
<td>Localized description of the physical item</td>
</tr>
<tr>
<td>IconImageAssetId</td>
<td>number</td>
<td>The image asset ID of main default image of the physical item</td>
</tr>
<tr>
<td>DisplayPrice</td>
<td>string</td>
<td>Localized price string with currency symbol of the physical item. e.g. “$4.99“</td>
</tr>
<tr>
<td>IsPurchasable</td>
<td>bool</td>
<td>If the item can be added to a merchant checkout session, i.e. item is in stock, or can be backordered</td>
</tr>
</tbody>
</table>
code_samples: []
parameters:
- name: commerceProductId
type: string
default:
summary: ''
returns:
- type: Dictionary
summary: ''
tags:
- Yields
deprecation_message: ''
security: None
thread_safety: Unsafe
capabilities:
- Monetization
- name: CommerceService:PromptCommerceProductPurchase
summary: |
Prompts a user to purchase a commerce product using the provided
`commerceProductId`. Opens a webview that guides the user through the
purchasing flow.
description: |
Prompts a user to purchase a commerce product using the provided
`commerceProductId`. Opens a webview that guides the user through the
purchasing flow.
code_samples: []
parameters:
- name: user
type: Player
default:
summary: ''
- name: commerceProductId
type: string
default:
summary: ''
returns:
- type: ()
summary: ''
tags: []
deprecation_message: ''
security: None
thread_safety: Unsafe
capabilities:
- Monetization
- name: CommerceService:PromptRealWorldCommerceBrowser
summary: ''
description: |
This is a legacy endpoint that is not meant for use. To open the webview
to the purchasing flow for real world commerce, see
`Class.CommerceService:PromptCommerceProductPurchase`. For more
information, see
[Commerce products](../../../production/monetization/commerce-products.md)
code_samples: []
parameters:
- name: player
type: Player
default:
summary: ''
- name: url
type: string
default:
summary: ''
returns:
- type: ()
summary: ''
tags: []
deprecation_message: ''
security: None
thread_safety: Unsafe
capabilities:
- Monetization
- name: CommerceService:UserEligibleForRealWorldCommerceAsync
summary: ''
description: |
This is a legacy endpoint that is not meant for use. To check if a user is
eligible for real world commerce, see
`Class.PolicyService.IsEligibleToPurchaseCommerceProduct`. For more
information, see
[Commerce products](../../../production/monetization/commerce-products.md)
code_samples: []
parameters: []
returns:
- type: boolean
summary: ''
tags:
- Yields
deprecation_message: ''
security: None
thread_safety: Unsafe
capabilities:
- Monetization
events:
- name: CommerceService.PromptCommerceProductPurchaseFinished
summary: |
Fires when commerce purchase webview has closed - not an indicator that a
purchase was successful.
description: |
Use this signal to detect when a user has completed the purchasing flow
and the webview has closed to resume gameplay within the experience.
**This signal does not indicate a successful purchase**, so do not grant
virtual items solely from this signal.
While optional, it is recommended to use this signal to reorient your
users on Android, as the commerce purchasing flow will have forced them
into portrait mode.
code_samples: []
parameters:
- name: user
type: Player
default:
summary: ''
- name: productId
type: string
default:
summary: ''
tags: []
deprecation_message: ''
security: None
capabilities:
- Monetization
callbacks: []