AbbieAuth Documentation

Integrate OAuth 2.0 authentication in minutes

Your Credentials
Enter your app credentials to see personalized code examples

Don't have credentials yet? Create an app

Select Scopes
Choose which data fields you want to request. Email is always required.

Basic Information

profile:name

Full Name

profile:firstName

First Name

profile:middleName

Middle Name

profile:lastName

Last Name

profile:preferredName

Preferred Name

profile:nickname

Nickname

profile:dateOfBirth

Date of Birth

profile:placeOfBirth

Place of Birth

Contact Information

profile:email

Email Address

profile:secondaryEmail

Secondary Email

profile:phone

Phone Number

profile:secondaryPhone

Secondary Phone

profile:workPhone

Work Phone

profile:address

Address

profile:mailingAddress

Mailing Address

Identity & Documents

profile:nationality

Nationality

profile:citizenship

Citizenship

profile:passportNumber

Passport Number

profile:passportExpiry

Passport Expiry

profile:passportCountry

Passport Issuing Country

profile:nationalId

National ID

profile:socialSecurityNumber

Social Security Number

profile:taxId

Tax ID

profile:driversLicense

Driver's License

profile:driversLicenseState

License State

profile:driversLicenseExpiry

License Expiry

Demographics

profile:gender

Gender

profile:pronouns

Pronouns

profile:ethnicity

Ethnicity

profile:race

Race

profile:religion

Religion

profile:languagesSpoken

Languages Spoken

profile:primaryLanguage

Primary Language

Family & Relationships

profile:maritalStatus

Marital Status

profile:spouseName

Spouse Name

profile:anniversaryDate

Anniversary Date

profile:numberOfChildren

Number of Children

profile:children

Children

profile:motherName

Mother's Name

profile:fatherName

Father's Name

profile:parentNames

Parent Names

profile:siblings

Siblings

Education

profile:education

Education

profile:highestDegree

Highest Degree

profile:fieldOfStudy

Field of Study

profile:university

University/College

profile:graduationYear

Graduation Year

profile:gpa

GPA

profile:certifications

Certifications

profile:licenses

Professional Licenses

Employment

profile:occupation

Occupation

profile:company

Company

profile:industry

Industry

profile:employmentStatus

Employment Status

profile:jobTitle

Job Title

profile:department

Department

profile:employeeId

Employee ID

profile:startDate

Start Date

profile:endDate

End Date

profile:workExperience

Work Experience

profile:yearsOfExperience

Years of Experience

profile:salary

Salary

profile:salaryCurrency

Salary Currency

profile:skills

Skills

profile:resume

Resume/CV

profile:portfolio

Portfolio

Financial Information

profile:annualIncome

Annual Income

profile:incomeSource

Income Source

profile:bankName

Bank Name

profile:accountNumber

Account Number

profile:routingNumber

Routing Number

profile:iban

IBAN

profile:swiftCode

SWIFT Code

profile:creditScore

Credit Score

profile:netWorth

Net Worth

profile:investmentAccounts

Investment Accounts

profile:cryptoWallets

Crypto Wallets

Health & Medical

profile:bloodType

Blood Type

profile:height

Height

profile:weight

Weight

profile:allergies

Allergies

profile:medications

Medications

profile:medicalConditions

Medical Conditions

profile:disabilities

Disabilities

profile:insuranceProvider

Insurance Provider

profile:insurancePolicyNumber

Policy Number

profile:primaryPhysician

Primary Physician

profile:organDonor

Organ Donor

Lifestyle & Preferences

profile:smokingStatus

Smoking Status

profile:drinkingStatus

Drinking Status

profile:dietaryPreferences

Dietary Preferences

profile:hobbies

Hobbies

profile:interests

Interests

profile:favoriteBooks

Favorite Books

profile:favoriteMovies

Favorite Movies

profile:favoriteMusic

Favorite Music

profile:petOwner

Pet Owner

profile:pets

Pets

profile:vehicleOwner

Vehicle Owner

profile:vehicles

Vehicles

profile:travelFrequency

Travel Frequency

Social & Online Presence

profile:website

Website

profile:blog

Blog

profile:linkedIn

LinkedIn

profile:twitter

Twitter/X

profile:facebook

Facebook

profile:instagram

Instagram

profile:github

GitHub

profile:youtube

YouTube

profile:tiktok

TikTok

profile:discord

Discord

profile:telegram

Telegram

profile:whatsapp

WhatsApp

Legal & Compliance

profile:criminalRecord

Criminal Record

profile:militaryService

Military Service

profile:militaryBranch

Military Branch

profile:militaryRank

Military Rank

profile:veteranStatus

Veteran Status

profile:securityClearance

Security Clearance

profile:politicalAffiliation

Political Affiliation

profile:voterRegistration

Voter Registration

Emergency Information

profile:emergencyContact

Emergency Contact

profile:secondaryEmergencyContact

Secondary Emergency Contact

profile:email

Quick Start Guide

1

Register App

Create OAuth app

2

Add Button

Sign in button

3

Get Token

Exchange code

4

Fetch Data

Access user info

1Add Sign In Button
Add this button to your login page. Users will be redirected to AbbieAuth for authentication.
<a href="https://abbieauth.vercel.app/oauth/consent?client_id=your_client_id&redirect_uri=https%3A%2F%2Fexample.com%2Fcallback&response_type=code&scope=profile%3Aemail&state=random_state_string" class="oauth-button">
  Sign in with AbbieAuth
</a>
User clicks button and is redirected to consent page
2Handle Callback & Exchange Code
After user authorizes, they're redirected to your callback URL with an authorization code.

Callback URL receives:

https://example.com/callback?code=AUTHORIZATION_CODE&state=random_state_string

Exchange code for tokens:

fetch('https://abbieauth.vercel.app/api/oauth/token', {
  method: 'POST',
  headers: { 'Content-Type': 'application/json' },
  body: JSON.stringify({
    grant_type: 'authorization_code',
    code: authorizationCode,
    client_id: 'your_client_id',
    client_secret: 'your_client_secret',
    redirect_uri: 'https://example.com/callback'
  })
})
.then(res => res.json())
.then(data => {
  console.log('Access Token:', data.access_token);
  console.log('Refresh Token:', data.refresh_token);
});

Response:

{
  "access_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
  "refresh_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
  "token_type": "Bearer",
  "expires_in": 3600
}
3Fetch User Information
Use the access token to retrieve user data based on granted scopes.
fetch('https://abbieauth.vercel.app/api/oauth/userinfo', {
  headers: {
    'Authorization': 'Bearer ' + accessToken
  }
})
.then(res => res.json())
.then(user => {
  console.log('User:', user);
});

Response:

{
  "sub": "user_id_12345",
  "email": "user@example.com",
  "name": "John Doe"
}
4Refresh Access Token
Access tokens expire after 1 hour. Use refresh token to get a new one.
fetch('https://abbieauth.vercel.app/api/oauth/token', {
  method: 'POST',
  headers: { 'Content-Type': 'application/json' },
  body: JSON.stringify({
    grant_type: 'refresh_token',
    refresh_token: refreshToken,
    client_id: 'your_client_id',
    client_secret: 'your_client_secret'
  })
})
.then(res => res.json())
.then(data => {
  console.log('New Access Token:', data.access_token);
});

Response:

{
  "access_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
  "token_type": "Bearer",
  "expires_in": 3600
}
Complete Node.js Example
Full Express.js implementation with session management
const express = require('express');
const session = require('express-session');
const crypto = require('crypto');

const app = express();
app.use(session({ secret: 'your-secret', resave: false, saveUninitialized: true }));

const CLIENT_ID = 'your_client_id';
const CLIENT_SECRET = 'your_client_secret';
const REDIRECT_URI = 'https://example.com/callback';
const AUTH_URL = 'https://abbieauth.vercel.app/oauth/consent';
const TOKEN_URL = 'https://abbieauth.vercel.app/api/oauth/token';
const USERINFO_URL = 'https://abbieauth.vercel.app/api/oauth/userinfo';

app.get('/login', (req, res) => {
  const state = crypto.randomBytes(16).toString('hex');
  req.session.oauthState = state;
  
  const authUrl = new URL(AUTH_URL);
  authUrl.searchParams.set('client_id', CLIENT_ID);
  authUrl.searchParams.set('redirect_uri', REDIRECT_URI);
  authUrl.searchParams.set('response_type', 'code');
  authUrl.searchParams.set('scope', 'profile:email profile:name');
  authUrl.searchParams.set('state', state);
  
  res.redirect(authUrl.toString());
});

app.get('/callback', async (req, res) => {
  const { code, state } = req.query;
  
  if (state !== req.session.oauthState) {
    return res.status(400).send('Invalid state');
  }
  
  const tokenResponse = await fetch(TOKEN_URL, {
    method: 'POST',
    headers: { 'Content-Type': 'application/json' },
    body: JSON.stringify({
      grant_type: 'authorization_code',
      code,
      client_id: CLIENT_ID,
      client_secret: CLIENT_SECRET,
      redirect_uri: REDIRECT_URI
    })
  });
  
  const { access_token, refresh_token } = await tokenResponse.json();
  
  const userResponse = await fetch(USERINFO_URL, {
    headers: { 'Authorization': `Bearer ${access_token}` }
  });
  
  const user = await userResponse.json();
  
  req.session.user = user;
  req.session.refreshToken = refresh_token;
  
  res.redirect('/dashboard');
});

app.listen(3000);
All Available Scopes
Complete list of data fields you can request access to. Organized by category.

Basic Information

profile:name

Full Name

Your complete legal name

profile:firstName

First Name

Your given name

profile:middleName

Middle Name

Your middle name(s)

profile:lastName

Last Name

Your family name or surname

profile:preferredName

Preferred Name

Name you prefer to be called

profile:nickname

Nickname

Your nickname or alias

profile:dateOfBirth

Date of Birth

Your birth date

profile:placeOfBirth

Place of Birth

City and country where you were born

Contact Information

profile:email

Email Address

Your primary email

Required
profile:secondaryEmail

Secondary Email

Alternative email address

profile:phone

Phone Number

Your primary phone number

profile:secondaryPhone

Secondary Phone

Alternative phone number

profile:workPhone

Work Phone

Your work phone number

profile:address

Address

Your residential address

profile:mailingAddress

Mailing Address

Address for receiving mail

Identity & Documents

profile:nationality

Nationality

Your country of citizenship

profile:citizenship

Citizenship

Countries where you hold citizenship

profile:passportNumber

Passport Number

Your passport number

profile:passportExpiry

Passport Expiry

Passport expiration date

profile:passportCountry

Passport Issuing Country

Country that issued your passport

profile:nationalId

National ID

National identification number

profile:socialSecurityNumber

Social Security Number

SSN or equivalent

profile:taxId

Tax ID

Tax identification number

profile:driversLicense

Driver's License

Driver's license number

profile:driversLicenseState

License State

State/region that issued license

profile:driversLicenseExpiry

License Expiry

License expiration date

Demographics

profile:gender

Gender

Your gender identity

profile:pronouns

Pronouns

Your preferred pronouns

profile:ethnicity

Ethnicity

Your ethnic background

profile:race

Race

Your racial identity

profile:religion

Religion

Your religious affiliation

profile:languagesSpoken

Languages Spoken

Languages you can speak

profile:primaryLanguage

Primary Language

Your native or primary language

Family & Relationships

profile:maritalStatus

Marital Status

Your relationship status

profile:spouseName

Spouse Name

Name of your spouse/partner

profile:anniversaryDate

Anniversary Date

Wedding or partnership anniversary

profile:numberOfChildren

Number of Children

How many children you have

profile:children

Children

Information about your children

profile:motherName

Mother's Name

Your mother's full name

profile:fatherName

Father's Name

Your father's full name

profile:parentNames

Parent Names

Names of your parents/guardians

profile:siblings

Siblings

Information about siblings

Education

profile:education

Education

Your educational background

profile:highestDegree

Highest Degree

Highest level of education completed

profile:fieldOfStudy

Field of Study

Your major or area of study

profile:university

University/College

Name of your university

profile:graduationYear

Graduation Year

Year you graduated

profile:gpa

GPA

Grade point average

profile:certifications

Certifications

Professional certifications

profile:licenses

Professional Licenses

Professional licenses held

Employment

profile:occupation

Occupation

Your current job title

profile:company

Company

Your current employer

profile:industry

Industry

Industry you work in

profile:employmentStatus

Employment Status

Your current employment status

profile:jobTitle

Job Title

Your official job title

profile:department

Department

Department you work in

profile:employeeId

Employee ID

Your employee identification number

profile:startDate

Start Date

When you started current job

profile:endDate

End Date

When you left the job

profile:workExperience

Work Experience

Your employment history

profile:yearsOfExperience

Years of Experience

Total years of work experience

profile:salary

Salary

Your current salary

profile:salaryCurrency

Salary Currency

Currency of your salary

profile:skills

Skills

Your professional skills

profile:resume

Resume/CV

Link to your resume

profile:portfolio

Portfolio

Link to your portfolio

Financial Information

profile:annualIncome

Annual Income

Your yearly income

profile:incomeSource

Income Source

Primary source of income

profile:bankName

Bank Name

Your primary bank

profile:accountNumber

Account Number

Bank account number

profile:routingNumber

Routing Number

Bank routing number

profile:iban

IBAN

International bank account number

profile:swiftCode

SWIFT Code

Bank SWIFT/BIC code

profile:creditScore

Credit Score

Your credit score

profile:netWorth

Net Worth

Your total net worth

profile:investmentAccounts

Investment Accounts

Your investment accounts

profile:cryptoWallets

Crypto Wallets

Cryptocurrency wallet addresses

Health & Medical

profile:bloodType

Blood Type

Your blood type

profile:height

Height

Your height

profile:weight

Weight

Your weight

profile:allergies

Allergies

Known allergies

profile:medications

Medications

Current medications

profile:medicalConditions

Medical Conditions

Chronic or ongoing conditions

profile:disabilities

Disabilities

Any disabilities

profile:insuranceProvider

Insurance Provider

Health insurance company

profile:insurancePolicyNumber

Policy Number

Insurance policy number

profile:primaryPhysician

Primary Physician

Your primary doctor

profile:organDonor

Organ Donor

Organ donor status

Lifestyle & Preferences

profile:smokingStatus

Smoking Status

Do you smoke

profile:drinkingStatus

Drinking Status

Alcohol consumption

profile:dietaryPreferences

Dietary Preferences

Your diet type

profile:hobbies

Hobbies

Your hobbies and interests

profile:interests

Interests

Things you're interested in

profile:favoriteBooks

Favorite Books

Books you love

profile:favoriteMovies

Favorite Movies

Movies you love

profile:favoriteMusic

Favorite Music

Music genres or artists

profile:petOwner

Pet Owner

Do you have pets

profile:pets

Pets

Information about your pets

profile:vehicleOwner

Vehicle Owner

Do you own a vehicle

profile:vehicles

Vehicles

Vehicles you own

profile:travelFrequency

Travel Frequency

How often you travel

Social & Online Presence

profile:website

Website

Your personal website

profile:blog

Blog

Your blog URL

profile:linkedIn

LinkedIn

LinkedIn profile URL

profile:twitter

Twitter/X

Twitter/X handle

profile:facebook

Facebook

Facebook profile URL

profile:instagram

Instagram

Instagram handle

profile:github

GitHub

GitHub username

profile:youtube

YouTube

YouTube channel URL

profile:tiktok

TikTok

TikTok handle

profile:discord

Discord

Discord username

profile:telegram

Telegram

Telegram username

profile:whatsapp

WhatsApp

WhatsApp number

Legal & Compliance

profile:criminalRecord

Criminal Record

Any criminal history

profile:militaryService

Military Service

Military service history

profile:militaryBranch

Military Branch

Branch of military service

profile:militaryRank

Military Rank

Highest rank achieved

profile:veteranStatus

Veteran Status

Are you a veteran

profile:securityClearance

Security Clearance

Government security clearance level

profile:politicalAffiliation

Political Affiliation

Political party affiliation

profile:voterRegistration

Voter Registration

Voter registration status

Emergency Information

profile:emergencyContact

Emergency Contact

Primary emergency contact

profile:secondaryEmergencyContact

Secondary Emergency Contact

Backup emergency contact

API Endpoints
GET/oauth/consent

Authorization endpoint - redirect users here to start OAuth flow

POST/api/oauth/token

Token endpoint - exchange authorization code or refresh token

GET/api/oauth/userinfo

Resource endpoint - fetch user data with access token

Security Best Practices
  • Always use HTTPS in production
  • Store client secret securely (never in client-side code)
  • Use state parameter to prevent CSRF attacks
  • Validate redirect URI matches registered URIs
  • Request minimal scopes (only data you need)
  • Implement token refresh logic before expiry

Need Help?

Check out example implementations or manage your apps