/mwdat-ios:permissions-registrationfrom mwdat-ios
Registers an iOS app with Meta AI and manages device permission flows (e.g., camera) through the Meta AI companion app. Covers registration state observation, deep link handling, and multi-device behavior.
Ships in mwdat-ios. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Register your app with Meta AI, then request the device permissions it needs.
The DAT SDK separates two concepts:
All permission grants occur through the Meta AI companion app.
func startRegistration() async throws {
try await Wearables.shared.startRegistration()
}
This opens the Meta AI app where the user approves your app. Meta AI then calls back via your URL scheme.
Filter on the metaWearablesAction query item so unrelated deep links are not forwarded to the SDK:
.onOpenURL { url in
guard
let components = URLComponents(url: url, resolvingAgainstBaseURL: false),
components.queryItems?.contains(where: { $0.name == "metaWearablesAction" }) == true
else {
return
}
Task {
do {
_ = try await Wearables.shared.handleUrl(url)
} catch let error as WearablesHandleURLError {
showError(error.description)
} catch {
showError(error.localizedDescription)
}
}
}
Task {
for await state in Wearables.shared.registrationStateStream() {
switch state {
case .registered:
// App is registered, can request permissions
break
case .unavailable:
// Registration is unavailable
break
case .available:
// Ready to register
break
case .registering:
// Registration in progress
break
}
}
}
func startUnregistration() async throws {
try await Wearables.shared.startUnregistration()
}
let status = try await Wearables.shared.checkPermissionStatus(.camera)
let status = try await Wearables.shared.requestPermission(.camera)
The SDK opens Meta AI for the user to grant access. Users can choose:
Users can link multiple glasses to Meta AI. The SDK handles this transparently:
Registration and permission APIs use typed throws. Prefer error.description or
error.localizedDescription over your own error strings:
startRegistration() throws RegistrationError: .alreadyRegistered, .configurationInvalid, .metaAINotInstalled, .networkUnavailable, .unknownstartUnregistration() throws UnregistrationError: .alreadyUnregistered, .configurationInvalid, .metaAINotInstalled, .unknownhandleUrl(_:) throws WearablesHandleURLError: .registrationError, .unregistrationErrorcheckPermissionStatus(_:) and requestPermission(_:) throw PermissionError: .noDevice, .noDeviceWithConnection, .connectionError, .metaAINotInstalled, .requestInProgress, .requestTimeout, .internalErroropenFirmwareUpdate() and openDATGlassesAppUpdate() throw NavigationError: .metaAINotInstalled, .notRegisteredWhen a device reports compatibility() == .deviceUpdateRequired, offer a firmware
update. When session start reports DeviceSessionError.datAppOnTheGlassesUpdateRequired,
offer the glasses app update. Both open Meta AI:
try await Wearables.shared.openFirmwareUpdate()
try await Wearables.shared.openDATGlassesAppUpdate()
| Mode | Registration behavior |
|---|---|
| Developer Mode | Registration always allowed. MetaAppID is empty, 0, or an unexpanded $(META_APP_ID) placeholder, so the SDK skips attestation |
| Production | MetaAppID, ClientToken, and TeamID must all be set, and users must be in the proper release channel |
For production, get your app ID and client token from the Wearables Developer Center, and use your Apple Developer Team ID for TeamID.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub meta/meta-wearables-dat-ios --plugin mwdat-ios18 skills in this plugin
/audio-streamingReceive synchronized PCM audio frames through a Camera stream on iOS/camera-captureCapture standalone high-quality photos from connected glasses on iOS/camera-streamingStream, video frames, photo capture, resolution/frame rate configuration/dat-conventionsSwift patterns, async/await, naming conventions, key types for DAT SDK iOS development/dat-docs-mcpUse the Wearables DAT MCP server for live DAT documentation search with `search_dat_docs`, Muse Code, Claude Code, Codex, Cursor, and MCP Inspector/debuggingCommon issues, Developer Mode, version compatibility, state machine diagnosisOther plugins' skills for the same job