System Operational

Your Centralized OAuth Bridge.

A single endpoint to manage authentication for Google Workspace and Microsoft Graph APIs. Generate tokens manually or route them directly to your app via webhooks.

Token Generator Tool

API Endpoints

GET /start-auth/{service} Redirect user to provider consent screen
GET /oauth_callback Provider callback — exchanges code for tokens
POST /refresh Renew expired token (requires provider info in body)

Available Services

Google Workspace APIs
/start-auth/driveDrive
/start-auth/gmailGmail
/start-auth/calendarCalendar
/start-auth/docsDocs
/start-auth/sheetsSheets
/start-auth/slidesSlides
/start-auth/formsForms
/start-auth/chatChat
/start-auth/contactsContacts
/start-auth/tasksTasks
/start-auth/allAll Services
Microsoft Graph APIs
/start-auth/mailMail
/start-auth/onedriveOnedrive
/start-auth/calendarCalendar
/start-auth/contactsContacts

Integration Guide

Follow these exact steps to connect your backend application with Open Auth Bridge via webhooks.

1

Construct the Routing Payload

Create a JSON object containing three required keys:

  • u: Your internal User ID (e.g., "user_890")
  • r: Your server's Webhook URL where tokens will be delivered
  • p: The provider name (google or microsoft)
{
  "u": "user_890",
  "r": "https://api.yourdomain.com/v1/save-tokens",
  "p": "microsoft"
}
2

Redirect User to Auth Bridge

Convert the JSON object to a string, Base64 encode it, and pass it via the state parameter:

GET https://oauth.arshman.me/start-auth/onedrive?state=BASE64_ENCODED_STATE
3

Receive Tokens via Webhook

Once the user grants permission, Auth Bridge will POST the following payload to your webhook:

POST https://api.yourdomain.com/v1/save-tokens
Content-Type: application/json

{
  "status": "success",
  "provider": "microsoft",
  "user_id": "user_890",
  "email": "user@outlook.com",
  "credentials": {
    "access_token": "eyJ0eXAiOiJKV1...",
    "refresh_token": "M.R3_BAY...",
    "expires_at": 1704100000.5
  }
}

Note: Your endpoint must return a 200 OK status immediately upon receiving this request.

4

Refresh Expired Tokens

When the access token expires, send a POST request from your backend to renew it:

POST https://oauth.arshman.me/refresh
Content-Type: application/json

{
  "refresh_token": "M.R3_BAY...",
  "provider": "microsoft"
}