# Native iOS and Android
Source: https://sovaria.in/docs/mobile-native

The raw HTTP calls behind the SDKs, for stacks without one (Kotlin Multiplatform, .NET MAUI, C++, a custom transport).

Swift and Kotlin have full SDKs ([iOS quickstart (Swift)](https://sovaria.in/docs/mobile-swift), [Android quickstart (Kotlin)](https://sovaria.in/docs/mobile-kotlin)) with the same features as Flutter. For any other stack every feature is plain HTTP on your project URL:

| Task | Request |
|---|---|
| Sign in | `POST /api/v1/auth/project/login` `{ email, password, org_id, project_id }` |
| Refresh (rotates) | `POST /api/v1/auth/refresh` `{ refresh_token }` |
| Provider sign-in | `GET /api/v1/auth/sso/{provider}/authorize?…&code_challenge=…&mode=json` → `POST /api/v1/auth/sso/exchange` |
| Register a push token | `POST /api/v1/push/devices` `{ token, platform, provider }` (user token) |
| Attestation | `POST /api/v1/attest/challenge` → `POST /api/v1/attest/exchange` → header `X-Sovaria-Attestation` |
| Devices | `GET /api/v1/auth/devices`, `DELETE /api/v1/auth/devices/{id}` |

- Send the anon key as `Authorization: Bearer <anon key>` until the user signs in, then their access token.
- Keep the refresh token in the Keychain (`kSecAttrAccessibleAfterFirstUnlockThisDeviceOnly`) or the Android Keystore.
- Use `ASWebAuthenticationSession` (iOS) or Custom Tabs (Android) for provider sign-in, never an embedded web view.
- APNs device tokens (hex) register with `provider: "apns"`; FCM tokens with `provider: "fcm"`.
