Auth API reference

Auth API · End-Users

get/v1/apps/{app_id}/end-users/import/mappingsAuth

List saved import mappings of this app (cursor-paginated, most recently edited first).

Drafts (`name: null`) are not listed. Pass `header_fingerprint` to find mappings made for a file with the same columns.

Path parameters

app_id*string

Id of the app.

Query parameters

header_fingerprintstring

Only mappings whose columns have this fingerprint (`headerFingerprint(headers)` from `@repo/user-import`).

limitinteger

Page size. Defaults to 20, clamped to 100.

cursorstring

Opaque `next_cursor` from the previous page.

Response · 200 A page of saved mappings.

data*array

Saved mappings of this app (drafts excluded), most recently edited first.

pagination*object
next_cursor*string

Opaque cursor for the next page. `null` when no more pages are available.

Example: "eyJjcmVhdGVkX2F0IjoiMjAyNi0wNS0wMVQwMDowMDowMFoifQ"

has_more*boolean

True iff another page exists; if true, pass `next_cursor` on the next request.

Example: false

Example

Request

GET https://api.auth.productcraft.co/v1/apps/{app_id}/end-users/import/mappings
Authorization: Bearer YOUR_TOKEN

Response

{
  "data": [
    {
      "id": "00000000-0000-0000-0000-000000000000",
      "app_id": "00000000-0000-0000-0000-000000000000",
      "name": "Clerk export",
      "mapping": {
        "version": 1,
        "fields": {
          "email": {
            "source": "primary_email_address"
          },
          "external_id": {
            "source": "id"
          },
          "display_name": {
            "sources": [
              "first_name",
              "last_name"
            ],
            "transform": "join"
          },
          "email_verified": {
            "source": "verified_email_addresses",
            "transform": "in_list"
          },
          "password_hash": {
            "source": "password_digest"
          },
          "password_hash_algorithm": {
            "sources": [
              "password_hasher"
            ],
            "transform": "hash_algorithm"
          },
          "role": {
            "source": "role",
            "transform": "value_map"
          }
        },
        "value_maps": {
          "role": {
            "administrator": "admin"
          }
        }
      },
      "columns": [
        "id",
        "first_name",
        "last_name",
        "primary_email_address",
        "verified_email_addresses",
        "password_digest",
        "password_hasher",
        "role"
      ],
      "header_fingerprint": "hf1_5c3a9e1f0b7d2a64",
      "created_by": "00000000-0000-0000-0000-000000000000",
      "created_at": "2026-01-01T00:00:00.000Z",
      "updated_at": "2026-01-01T00:00:00.000Z"
    }
  ],
  "pagination": {
    "next_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNi0wNS0wMVQwMDowMDowMFoifQ",
    "has_more": false
  }
}