Skip to main content
GET
/
api
/
{authType}
/
auth
JavaScript
import SnagSolutions from '@snagsolutions/sdk';

const client = new SnagSolutions({
  apiKey: 'My API Key',
});

const response = await client.auth.connectAuth('twitter');

console.log(response.url);
{
  "url": "https://example.com"
}

Authorizations

X-API-KEY
string
header
required

Path Parameters

authType
enum<string>
required
Available options:
twitter,
discord,
telegram,
epic,
steam,
ultra,
google,
tiktok,
email

Query Parameters

websiteId
string<uuid>

The ID of the website

Example:

"123e4567-e89b-12d3-a456-426614174000"

userId
string<uuid>

The ID of the user

Example:

"123e4567-e89b-12d3-a456-426614174001"

walletAddress
string

The wallet address of the user

Example:

"0x1234567890abcdef1234567890abcdef12345678"

redirect
string

The redirect URL where the user will land after completing the auth

Example:

"https://example.com"

responseType
enum<string>
default:redirect

The type of response to return, this is not valid for email auth, email auth only supports the redirect flow via verification link.

Available options:
redirect,
json
Example:

"redirect"

skipYTChannelCheck
string
default:true

Whether to skip the YouTube channel check, this is only value for google auth

Example:

false

emailAddress
string<email>

The email address of the user, this is only required for email auth

Response

200

Schema for a connect social auth response schema

url
string<uri>
required

The URL to redirect to

Example:

"https://example.com"

I