Skip to main content

Make your first request

This quickstart uses hosted auth to obtain a member token, then calls GET /v1/user with both required credentials.

Before you begin

In Settings > Developer Access in the TheFaithApp dashboard:
  1. Copy your public client key.
  2. Add the exact callback URL that will receive the member after sign-in.
For local development, save a dedicated callback such as http://localhost:3000/auth/callback. Production and local callback URLs must each be added explicitly.
1

Create a hosted sign-in URL

Generate a cryptographically random state and a 43–128 character PKCE verifier. Send the verifier’s base64url-encoded SHA-256 challenge with your callback URL.
The response includes auth_url. Open it in the system browser or a browser-based mobile auth session.
2

Validate the callback

After sign-in, the member returns to your callback URL:
Reject the callback if state does not exactly match the value stored when sign-in began. Exchange code immediately; it is short-lived and single-use.
3

Exchange the code

Store the returned access_token in secure server-side storage, an HTTP-only secure session cookie, Keychain, or Keystore.
4

Load the member

A successful response contains status: "Success" and the member record in data.

JavaScript example

The client key is a public church-app identifier, not an authentication secret. Keep member access tokens out of source code and store them in a secure server-side session, Keychain, or Keystore.

Next steps