OAuth for iCloud developer guide

OAuth for iCloud:
Connect Apple Data to Your App

OAuth for iCloud gives your app a scoped, Figment-issued grant tied to a user's Apple connection, and your code never sees the Apple password. Sandbox is free; plans are $14 or $29 per connected Apple Account per month.

Figment editorial teamPublished Updated Facts checked November 11, 2026

Short answer: OAuth for iCloud is a Figment product that gives your app a scoped, Figment-issued OAuth grant tied to a user's existing Apple connection. Your app redirects the user to a Figment-hosted consent screen, and your codebase never receives the Apple Account password. Figment is the token issuer; Apple does not issue this grant or these tokens.

This page is the overview. The guides it links to cover each step in detail.

What is the difference between connection setup and app authorization?

They are two separate events, and mixing them up causes most failed grant flows.

Connection setup is the user's Apple Account connection through Figment. Native Apple sign-in and trusted-device two-factor authentication happen here, on a connected Mac. It is entirely separate from the OAuth redirect your app starts, and the Figment OAuth redirect does not itself perform Apple authentication.

App authorization is the Figment OAuth flow. The user signs into Figment, selects their existing Apple connection, and approves each scope individually. Figment redirects back to your registered callback with a Figment-issued authorization code.

ScenarioWhat must happen firstYour app's action
Sandbox: no connection yetNone. Synthetic sandbox connections require no Apple sign-inUse a sandbox connection_id from developer setup
Live: user has no Figment connectionUser completes Apple connection setup on a connected Mac (native Apple sign-in and trusted-device approval happen during this step, not during your OAuth redirect)Direct the user to connection setup before starting OAuth
Connection exists; no grant for your appNoneRedirect to /icloud/authorize
Grant exists; access token expiredNonePOST to /api/icloud/oauth/token with grant_type=refresh_token

How is this different from Apple's own authorization and Sign in with Apple?

They are three distinct mechanisms. Apple natively supports third-party authorization for iCloud Mail, Calendar, and Contacts, and users can grant a compatible app access directly from Apple (Apple HT121539). That is Apple's own authorization path, not a Figment feature. Figment's consent model is a separate system: it extends user-approved, scoped app access to Apple services using an authorized Mac session held on the user's behalf. "Sign in with Apple" proves identity only and is not data-access authorization. For a closer comparison, see Sign in with Apple vs iCloud Data Authorization and iCloud OAuth or a Signed-In Mac Connection.

How do I register my app and get tokens?

Register at figment.so/icloud/developers to receive a client_id and configure your callback URL. The callback URL is developer-defined: you register your own exact HTTPS path during setup.

OAuth for iCloud uses an authorization-code flow with PKCE (S256). Generate a fresh state value and a fresh PKCE verifier for every authorization attempt, validate the returned state before exchanging the code, and exchange it at POST /api/icloud/oauth/token. The token response includes access_token, refresh_token, expires_in, scope, and connection_id. Tokens are opaque. Access tokens normally expire after 900 seconds. Store the new refresh token after each refresh and serialize refresh per grant. Full PKCE request shapes are in the developer setup docs at figment.so/icloud/developers. A worked walkthrough is in Use PKCE for an Apple Data Connection Flow.

How do I check that a service is ready?

Read the service state from the connection endpoint, because a signed-in Apple Account does not mean every service is ready. Each service has its own status. Possible values are connecting, needs_approval, syncing, ready, offline, reconnect_required, and revoked. Not every service passes through every state, and a service can become offline or revoked at any point.

A non-ready or revoked service rejects operations with a non-2xx response, so handle those instead of assuming success. For setup status, use the account connection screen at figment.so/icloud/account. To inspect the connection state directly:

GET https://figment.so/api/icloud/v1/connections/con_...
Authorization: Bearer ACCESS_TOKEN

The response is {connection:{id,mode,services,...}}. Each service entry carries state, reason, and observedAt. A ready state on one service says nothing about another, and ready does not prove complete message history, so treat each service independently.

Which scopes and services are available?

The same connect-then-grant model applies across services. The product page lists four scopes that a user can approve on one consent screen: credentials:use, messages:read, notes:read, and reminders:read. Sending is a separate permission, messages:send. iMessage is the reference example in these guides.

ServiceScopeNotes
Apple Passwordscredentials:useOne saved login at a time, with its verification code
iMessage history and searchmessages:readOne scope covers both. There is no separate search permission
iMessage sendmessages:sendRequires selected existing conversations in the send grant
Notesnotes:readRead only
Remindersreminders:readRead only

For reads, check historyComplete and hasMore, because history may be incomplete while the connector catches up. SMS, MMS, and RCS need an eligible connected iPhone. Messages in iCloud includes their forwarding when enabled, and a separate Text Message Forwarding switch is an alternative.

For sends, generate and persist one idempotency key per intended action before its first request. A failed receipt polled again returns the same failure and does not retry the send. An unknown receipt status means poll the original key, and never issue a new key to resend.

Endpoint details for history, search, send, and receipts are in the developer setup docs at figment.so/icloud/developers.

Where do I go for each task?

How much does it cost?

Sandbox is free and includes synthetic data. It cannot send to real people. Live plans are priced per connected Apple Account per month: $14 for Apple Passwords and $29 for the Full iCloud suite (Passwords, Messages, Notes, and Reminders). More than 25 connected accounts is an Enterprise plan with custom pricing. The developer pays, with no platform fee and no charge per request. For live access, request a demo.

What happens when a grant is revoked?

Revoking a single app grant stops that app's access and queued operations without affecting other apps on the same Apple connection. Disconnecting the Apple Account stops every grant and every queued operation for that connection. As a design practice, your app's own audit records should omit Apple Account passwords, two-factor verification codes, and message bodies from application logs.

Manage grants at figment.so/icloud/account. For Apple's native Mail, Calendar, and Contacts authorization, users manage per-app access at account.apple.com under Sign-In and Security › Account Data Sharing (Apple HT121539).

How do I get started?

Register your app and begin building in sandbox at figment.so/icloud/developers.

Connect Apple data to your app

Register your app and start with synthetic sandbox data. Choose the permissions your app needs.

Connect Apple Account

Sandbox is free. Live access is $14 or $29 per connected Apple Account, per month.