Reference API Roblox

Engine API

Website

Related

Reference API Roblox

ModerationService

Server-side service for submitting player captures to content moderation review and receiving the results asynchronously.

This class is not replicated. Its interface does not cross the network boundary.
This class is not creatable. Instances of this class cannot be created with Instance.new.
This class is a service. It is a singleton that may be acquired with GetService.
Tags: [NotCreatable, Service, NotReplicated]

Member index 5

HistoryMember
695BindReviewableContentEventProcessor(priority: int, callback: Function): RBXScriptConnection
695CreateReviewableContentAsync(config: Dictionary): string
693CreateReviewableContentKey(content: Content): string
679InternalRequestReviewableContentReviewAsync(config: Dictionary): null
inherited from Instance
553Archivable: bool
670Capabilities: SecurityCapabilities
723IsInSandbox: bool
553Name: string
553Parent: Instance
702PredictionMode: PredictionMode
670Sandboxed: bool
680UniqueId: UniqueId
576AddTag(tag: string): null
573ClearAllChildren(): null
462Clone(): Instance
573Destroy(): null
486FindFirstAncestor(name: string): Instance
486FindFirstAncestorOfClass(className: string): Instance
486FindFirstAncestorWhichIsA(className: string): Instance
486FindFirstChild(name: string, recursive: bool = false): Instance
486FindFirstChildOfClass(className: string): Instance
486FindFirstChildWhichIsA(className: string, recursive: bool = false): Instance
486FindFirstDescendant(name: string): Instance
563GetActor(): Actor
486GetAttribute(attribute: string): Variant
462GetAttributeChangedSignal(attribute: string): RBXScriptSignal
631GetAttributes(): Dictionary
648GetChildren(): Instances
462GetDebugId(scopeLength: int = 4): string
707GetDescendants(): Instances
486GetFullName(): string
706GetStyled(name: string, selector: string?): Variant
657GetStyledPropertyChangedSignal(property: string): RBXScriptSignal
576GetTags(): Array
576HasTag(tag: string): bool
486IsAncestorOf(descendant: Instance): bool
486IsDescendantOf(ancestor: Instance): bool
664IsPropertyModified(property: string): bool
698QueryDescendants(selector: string): Instances
573Remove(): null
576RemoveTag(tag: string): null
664ResetPropertyToDefault(property: string): null
573SetAttribute(attribute: string, value: Variant): null
462WaitForChild(childName: string, timeOut: double): Instance
648children(): Instances
553clone(): Instance
573destroy(): null
553findFirstChild(name: string, recursive: bool = false): Instance
648getChildren(): Instances
553isDescendantOf(ancestor: Instance): bool
573remove(): null
462AncestryChanged(child: Instance, parent: Instance)
462AttributeChanged(attribute: string)
462ChildAdded(child: Instance)
462ChildRemoved(child: Instance)
462DescendantAdded(descendant: Instance)
462DescendantRemoving(descendant: Instance)
500Destroying()
657StyledPropertiesChanged()
553childAdded(child: Instance)
inherited from Object
647ClassName: string
647className: string
647GetPropertyChangedSignal(property: string): RBXScriptSignal
647IsA(className: string): bool
650isA(className: string): bool
647Changed(property: string)

Removed member index 2

HistoryMember
706InternalCreateReviewableContentAsync(config: Dictionary): string
706InternalProcessReviewableContentEvent(event: Dictionary): bool

Description

ModerationService lets server-side experience code submit user-generated captures (screenshots taken with CaptureService:CaptureScreenshot() and videos recorded with CaptureService:StartVideoCaptureAsync()) to Roblox's content moderation pipeline and receive the review results asynchronously.

History 10

Members 5

BindReviewableContentEventProcessor

Parameters (2)
priorityint
callbackFunction
Returns (1)
RBXScriptConnection

Binds a callback that the server invokes for each moderation review event produced for content registered through CreateReviewableContentAsync().

Once at least one processor is bound, review events are delivered to the bound processors in priority order. The callback function receives a single table with the following fields:

  • Id — The reviewable-content ID the event refers to.
  • State — The review state (ReviewableContentState).
  • Ref — The optional caller-supplied reference string passed to CreateReviewableContentAsync(), present only when one was supplied.
  • ModerationResult — Present when a moderation result is available, a table with a Category (ModerationResultCategory) and, when a violation is detected, a Labels array of ModerationResultLabel values.

Processors run as a chain: if a processor returns true, the event is acknowledged, deleted from the backend, and removed from the pending set, and no further processors run for that event. If it returns false (or does not return a boolean), the next processor runs; if no processor returns true, the event is left unacknowledged and redelivered on a later poll.

History 1

CreateReviewableContentAsync

Parameters (1)
configDictionary
Returns (1)
string

Registers one or more captures as a single unit of reviewable content and starts its moderation review. This is a yielding function that must be called on the server and is restricted to allow-listed universes; calling it from a universe that is not permitted to use this API raises an error.

The config table accepts:

  • Id — An optional caller-chosen ID for the reviewable content. Supplying an ID that already exists raises an error.
  • Ref — An optional reference string echoed back on the events delivered to processors bound with BindReviewableContentEventProcessor().
  • Content — A list of items (currently limited to one), each containing either an Image or a Video table with a UserId (the owning player) and a ContentKey obtained from CreateReviewableContentKey().

The method registers the content with the backend and returns the reviewable content ID. Review results are later delivered to bound processors as the moderation review completes.

This function yields. It will block the calling thread until completion.

History 1

Tags: [Yields]

CreateReviewableContentKey

Parameters (1)
contentContent
Returns (1)
string

Produces an opaque key that describes a single capture so it can be submitted to CreateReviewableContentAsync().

The content must reference a supported capture (a temporary content URI produced by CaptureService:CaptureScreenshot(), a ScreenshotCapture object, or a VideoCapture object). Any other content raises an error.

History 1

InternalRequestReviewableContentReviewAsync

Parameters (1)
configDictionary
Returns (1)
null
This function yields. It will block the calling thread until completion.

History 1

Tags: [Yields]

Removed members 2

InternalCreateReviewableContentAsync

Parameters (1)
configDictionary
Returns (1)
string
This function yields. It will block the calling thread until completion.

History 2

Tags: [Yields]

InternalProcessReviewableContentEvent

Parameters (1)
eventDictionary
Returns (1)
bool

History 2

Settings