Stytch API keys
First, you will need a Stytch account. Get your API keys by signing up.
The Stytch API uses basic authentication with your project_id and secret. You'll need to pass these values into the Authorization request header for every API call.
curl --request POST \
--url https://test.stytch.com/v1/b2b/magic_links/email/login_or_signup \
-u '{PROJECT_ID}:{SECRET}' \
-H 'Content-Type: application/json' \
-d '{
"organization_id": "organization-test-07971b06-ac8b-4cdb-9c15-63b17e653931",
"email_address": "sandbox@stytch.com",
}'
You can find your keys in the API keys section of the Stytch Dashboard.
Frontend SDKs
For our frontend SDKs, you'll use your public_token rather than your project_id and secret when communicating with the Stytch API.
Environments
For each Stytch Project, there are two environments:
- Test: https://test.stytch.com
- Live: https://api.stytch.com
The Stytch API keys and data resources are all scoped to an environment and are not shared between environments. For example, a User created in the Test environment will not be available in the Live environment.