> ## Documentation Index
> Fetch the complete documentation index at: https://docs.fau.run/developer/llms.txt
> Use this file to discover all available pages before exploring further.

# Build a mobile client

> Build or fork an iOS/Android approval app that pairs, signs /papi, and registers Expo push.

**Purpose:** ship a phone client that can **approve agent requests** for a FAU node.

**Audience:** mobile engineers forking `apps/phone/` or writing a new client.

## What this client is

A paired **device**, not an inbox. It holds an Ed25519 secret, signs `/papi/*`, and
optionally wakes via Expo Push.

Protocol pages: [Mobile clients](https://docs.fau.run/developer/protocol/client-mobile.md), [Apps overview](https://docs.fau.run/developer/apps/overview.md).

## Path A — Reference app (`apps/phone`)

### Prerequisites

* Node.js 20+
* Expo / EAS account
* Physical device for push (simulator is insufficient to sign off)
* Apple Developer membership for iOS

### 1. Install and test

```bash theme={null}
cd apps/phone
npm install
npm test
npx tsc --noEmit
```

### 2. Configure push credentials

```bash theme={null}
npx eas-cli login
npx eas-cli credentials -p ios
# Push Notifications → assign/upload APNs Auth Key
```

### 3. Build for a device

```bash theme={null}
npx eas-cli build --platform ios --profile preview
```

Install via the Expo link. Register the device for ad hoc if integrity verification
fails.

### 4. Pair and verify

1. Mac shows pair QR → scan in app → allow notifications.
2. Settings: alerts **registered**.
3. Dashboard → **Send test alert** → banner while app backgrounded.
4. Optional: create a real approval and decide.

Device signatures **must** match [Device signing vectors](https://docs.fau.run/developer/reference/device-signing.md).

## Path B — Your own app

Implement:

1. [Pairing](https://docs.fau.run/developer/apps/pairing.md)
2. [Device signing](https://docs.fau.run/developer/apps/signing.md)
3. [Phone API](https://docs.fau.run/developer/apps/phone-api.md)
4. [Push](https://docs.fau.run/developer/apps/push.md) — **your** EAS/APNs project; node only stores tokens

Ship bar: [App checklist](https://docs.fau.run/developer/apps/checklist.md).

## Invariants

* Never put mail content in push payloads
* Never put the device secret on your servers
* Never use the Mac dashboard `X-FAU-Local` token from mobile
* Polling remains mandatory even when push works

## Next

* [Run a node](https://docs.fau.run/developer/developers/run-node.md)
* [Extend the codebase](https://docs.fau.run/developer/developers/extend.md) if changing `/papi`


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.