GET
/
api
/
{authType}
/
auth
import SnagSolutions from '@snagsolutions/sdk';

const client = new SnagSolutions({
  apiKey: process.env['X_API_KEY'], // This is the default and can be omitted
});

async function main() {
  const response = await client.auth.connectAuth('twitter');

  console.log(response.url);
}

main();
{
  "url": "https://example.com"
}

Authorizations

X-API-KEY
string
header
required

Path Parameters

authType
enum<string>
required
Available options:
twitter,
discord,
telegram,
epic,
steam

Query Parameters

websiteId
string

The ID of the website

Example:

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

userId
string

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

Available options:
redirect,
json
Example:

"redirect"

Response

200
application/json
200

Schema for a connect social auth response schema

url
string
required

The URL to redirect to

Example:

"https://example.com"