Overview
Theapp.bsky.labeler namespace provides lexicons for declaring and querying labeling services. Labelers apply content moderation labels to posts, profiles, and other content.
Key Concepts
- Labeler: A service that applies content labels
- Labels: Metadata tags indicating content properties (NSFW, spam, etc.)
- Labeling Policies: Which labels a service can apply
- Custom Labels: Service-specific label definitions
- Subscriptions: Users subscribing to labeler services
Record Types
service
Labeler service declaration. Record Structure:object
required
Labeling policies including supported label values
union
Self-applied labels
string
required
Service creation timestamp
Queries
getServices
Get information about labeler services. Endpoint:app.bsky.labeler.getServices
array
required
Array of labeler service DIDs (max 25)
boolean
Return detailed view with policies
array
required
Array of labeler service views
Type Definitions
labelerView
Basic labeler service view.string
required
AT-URI of the labeler service record
string
required
CID of the service record
object
required
Profile of the labeler service operator
integer
Number of users subscribed to this labeler
object
Viewer’s relationship to the labeler
string
required
When the service was indexed
array
Labels applied to the labeler service itself
labelerViewDetailed
Detailed labeler service view with policies. Includes all fields fromlabelerView plus:
object
required
Labeling policies
array
Report reason types this service accepts
array
Subject types this service accepts reports for (account, record, chat)
array
Record collection NSIDs this service labels
labelerPolicies
Labeling policies for a service.array
required
Array of label value strings this service can apply
array
Definitions for custom labels created by this service
labelerViewerState
Viewer’s relationship to a labeler.string
AT-URI of like record if viewer has subscribed to this labeler
Using Labelers
Labelers are managed through user preferences inapp.bsky.actor.defs#labelersPref.
Subscribe to a Labeler
Unsubscribe from a Labeler
Check Subscribed Labelers
Creating a Labeler Service
To create a labeler service:- Declare the Service: Create a
app.bsky.labeler.servicerecord - Implement Label Emission: Emit labels via
com.atproto.label.subscribeLabels - Configure DID Document: Add labeler service endpoint to DID document
- Accept Reports (optional): Implement
com.atproto.moderation.createReporthandling
Example Service Declaration
Label Severity Levels
When defining custom labels, you can set severity:inform: Informational only, content not hidden by defaultalert: Warning shown, content blurred by defaultnone: No special handling
Label Blur Settings
Controls what gets blurred when label is applied:content: Blur the content itselfmedia: Blur embedded media onlynone: Don’t blur anything
Default Settings
How labels are treated by default:hide: Content hidden by defaultwarn: Content shown with warningshow: Content shown normallyignore: Label ignored
Common Use Cases
Find Labelers to Subscribe
Configure Label Preferences
Combine with content label preferences:Related Lexicons
- com.atproto.label - Label definitions and emission
- com.atproto.moderation - Content reporting
- app.bsky.actor - User preferences
Resources
- Labeling Guide
- Ozone Labeler - Reference implementation
- Label Specification
- Custom Labels Guide