Skip to main content
POST
/
v1
/
auth
/
magic_links
/
verify
Verify Token
curl --request POST \
  --url https://api.streambird.io/v1/auth/magic_links/verify \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "token": "CzJ1WTtyCF2wqhavQYiy9m7GayazthwamK4DKC07Ac6B2Fmn"
}'
{
  "method_id": "email_24oXBL3PufzHkH1Jzyjc2EXYeo7",
  "method_type": "email",
  "user_id": "user_24wFP9pDa9YiMJLun94iKykoZs2"
}

Authorizations

Authorization
string
header
required

Auth Platform API includes all the Auth related features. All Users, Phone Numbers, Emails, and OTPs are associated with an App as the container.

Endpoints only accept App's Secret API keys other than certain endpoints that are used client side or via SDK that accept the public_token.

Authentication using App Api Key

Header:

Authorization: Bearer {api_key}

Authenticated Request

curl \
-X GET https://api.streambird.io/v1/auth/users/user_24wFP9pDa9YiMJLun94iKykoZs2 \
-H "Authorization: Bearer sk_test_pRqweh3wvWmJAAVYv7Z0T5iPLzFM4ql0muoyQcjOxGeN3p1r"

Body

application/json
token
string
required

Required Magic Token in the Magic Link received by the User

Minimum length: 1
session_expires_in
integer

Optional Extend the session expiration time to N minutes from now, must be between 5 to 525600 minutes (365 days). This parameter will create a new session if there is no existing session along with a session_token and session_jwt. However, if a valid session_token or session_jwt is sent in, it will extend that session by the minutes specified. If not sent in, no session will be created by default.

session_token
string

Optional Unique session token to verify.

session_jwt
string

Optional Unique Session JWT to verify.

Response

OK

method_id
string
required

Given ID of the method (email, phone_number, etc.).

Minimum length: 1
method_type
enum<string>
required

Type of the auth method. Possible values: email, phone_number.

Available options:
email,
phone_number
user_id
string
required

Given user ID of the user.

Minimum length: 1
session_token
string
session_jwt
string
session
object