viaSocket Help

OAuth 2.0 - Authorization Code

Use this grant for secure, delegated access to user data.

#

Configuration Steps

  1. Configure your Fields: Add optional user-specific inputs (e.g., Region, Environment).

  2. Copy your OAuth Redirect URL: Copy from viaSocket and paste into your app’s developer console. Must match exactly.

  3. Enter Application Credentials: Enter Client ID and Client Secret from your app’s developer dashboard.

  4. Configure Authorization Endpoint: Enter the login page URL (e.g., https://service.com/oauth/authorize).

  5. Configure Access Token API: Enter the endpoint that exchanges the login code for an access_token.

  6. Configure Refresh Token API: (Optional) Enter to extend session life automatically.

  7. Configure Revoke Token API: (Optional) Enter to allow users to disconnect their account.

  8. Configure Test (Me) API: Provide a lightweight endpoint (e.g., /me) to validate the connection.

  9. Add Connection Label: Set a dynamic name using placeholders (e.g., {{email}}).

  10. Add Icon: Enter the key from your Test Endpoint response containing the user's avatar URL (e.g., {{profile_image}}).

  11. Add URLs to Whitelist: Whitelist only the base domains required for your API calls.

  12. Add Unique Connection Identifier: Map a field (e.g., account_id) to prevent duplicate connections.

  13. Set Request Parameters: Define default headers/params applied to every API call.

Disable Whitelist Domain Validation - Allows API calls to any domain, not just the ones listed above.

#

Common Request Parameters

Use Case

Key

Value

Bearer Token

Authorization

Bearer {{access_token}}

API Key

x-api-key

{{api_key}}

⚠️ Warning: Do not include sensitive data or dynamic values that change per-endpoint here. Use this for global, static requirements only.

#

How it Works?

  1. User clicks Connect.

  2. User authenticates via the app's login page.

  3. App sends a temporary code to viaSocket.

  4. viaSocket exchanges the code for an access_token and initiates the session.