---
title: "Register a device key for iOS App Attest"
method: POST
path: "/v2/onramp/mobile/attestation/registrations"
tags: ["Onramp (App2App)"]
---

# Register a device key for iOS App Attest

`POST /v2/onramp/mobile/attestation/registrations`

## Request

- Base URL: `https://api.cdp.coinbase.com/platform`
- URL: `https://api.cdp.coinbase.com/platform/v2/onramp/mobile/attestation/registrations`
- Auth: HTTP none

Verifies an iOS App Attest attestation payload and registers the device's public key for future assertion validation. The server checks that the attestation is genuine and signed by Apple, that the bundle ID is in the partner's allowed mobile clients list, and that the challenge issued by [Create Onramp iOS Attestation Challenge](#operation/createOnrampIosAttestationChallenge) is fresh and unused.

This is a one-time, per-device-install operation; iOS-only (Android validates Play Integrity inline per request and has no registration step). For security, all client-side verification failures are returned as an opaque `400 invalid_request` — the response never reveals which specific check failed.

The Apple App Attest `keyId` is supplied only in the request body (`ios.keyId`). Do not put `keyId` in the URL — App Attest key IDs are standard base64 and frequently contain `/`, which breaks path routing at the edge.

Idempotency is provided by `ios.keyId` itself: the server upserts the device public key on `(app, keyId)`, so repeating registration for the same key replaces the stored public key rather than creating a duplicate. This endpoint does not accept `X-Idempotency-Key` — `ios.keyId` is the natural idempotency key for the registration resource. The challenge remains single-use and is claimed on first receipt. The challenge identifies the project; the device does not supply a CDP project ID.

## Request body

- IosAttestationRegistrationRequest: Request to register device public key for iOS App Attest attestation. This endpoint is iOS-only. Android devices use Play Integrity Standard API tokens sent directly in request headers instead.
  - `challenge` string, required: The challenge received from the challenge endpoint.
  - `ios` IosAttestationPayload, required: iOS App Attest payload for verification.
    - `keyId` string, required: The key identifier generated by DCAppAttestService.
    - `attestation` string, required: Base64-encoded attestation object from DCAppAttestService.attestKey().
    - `bundleId` string, required: iOS application bundle identifier (`CFBundleIdentifier`), as configured in the app's Xcode project / Info.plist, or shown for the App ID in Apple Developer. Must contain only alphanumeric characters (A–Z, a–z, 0–9), hyphens (-), and periods (.), typically in reverse-DNS form (e.g. `com.example.app`). Underscores are not permitted.

## Response `200`

Attestation verified successfully. Device public key registered for assertion validation.

- IosAttestationRegistrationResponse: Response confirming successful attestation verification and device key registration. The device public key is now stored for validating future assertion signatures.
  - `keyId` string, required: The key identifier that was registered. Include this value in subsequent [Create Onramp Mobile Session](#operation/createOnrampMobileSession) requests as `ios.keyId`.
  - `platform` 'ios', required: The mobile platform that was attested (iOS only).
  - `appId` string, required: The verified Apple application identifier in `teamID.bundleID` format. This is not a CDP project ID.
  - `attestedAt` string, date-time, required: Timestamp when the attestation was performed.

## Other responses

- `400`: Invalid request, or the attestation could not be verified. All client-side rejections (unknown bundle ID, bad certificate chain, consumed or expired challenge, unregistered client) collapse into this single opaque error so no detail about the failed check is leaked.
- `429`: Rate limit exceeded.
- `500`: Internal server error.

## Changes

- **2026-12-01** `06cb41a4fb57`: 3 warning
  - added the new `policy_not_applicable` enum value to the `errorType` response property for the response status `400`
  - added the new `policy_not_applicable` enum value to the `errorType` response property for the response status `429`
  - added the new `policy_not_applicable` enum value to the `errorType` response property for the response status `500`
- **2026-10-22** `fa99d7ef723f`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/coinbase/apis/coinbase-developer-platform-apis/changes/v2/onramp/mobile/attestation/registrations/post.md)

---

[API](https://skmtc.dev/coinbase/apis/coinbase-developer-platform-apis.md) - [All operations](https://skmtc.dev/coinbase/apis/coinbase-developer-platform-apis/llms.txt) - [OpenAPI document](https://skmtc.dev/coinbase/apis/coinbase-developer-platform-apis/revisions/06cb41a4fb57?raw)
