Table of Contents
How to enable Sotion Membership Management API
- Email Sign Up
- Restricted Email List
- Paid Membership (Stripe, Lemon Squeezy, or Gumroad)
Sotion Membership Management API Documentation
Authentication
https://{API_KEY}.api.sotion.app/sites/{SITE_ID}
https://d600c2d2-e07e-46b9-b79a-f0376aaa303d.api.sotion.app/E1CP6DYM2JF6H
LIST ALL MEMBERS
GET
https://{API_KEY}.api.sotion.app/sites/{SITE_ID}/members
{
"siteId": "E1CP6DYM2JF6H",
"status": "active",
"domain": "sub.domain.com",
"pageUrl": "https://sub.domain.com/5d134986fc72480188g18d116118478f",
"authType": "email",
"config": {
"members": [
{
"email": "name@email.com",
"uuid": "5699fa63-f01a-4964-b0ef-3cf8bc61fa04",
"registeredAt": "2022-07-01T14:35:57.347Z",
"verified": true,
"blocked": false,
"paid": true
}
]
}
}
SEARCH MEMBERS
GET
email=name@email.com
verified=true|false
paid=true|false
https://{API_KEY}.api.sotion.app/sites/{SITE_ID}/members?email=name@email.com&verified=true&paid=true
{
"siteId": "E1CP6DYM2JF6H",
"status": "active",
"domain": "sub.domain.com",
"pageUrl": "https://sub.domain.com/5d134986fc72480188g18d116118478f",
"authType": "email",
"config": {
"members": [
{
"email": "name@email.com",
"uuid": "5699fa63-f01a-4964-b0ef-3cf8bc61fa04",
"registeredAt": "2022-07-01T14:35:57.347Z",
"verified": true,
"blocked": false,
"paid": true
}
]
}
}
GET MEMBER
GET
https://{API_KEY}.api.sotion.app/sites/{SITE_ID}/members/{MEMBER_UUID}
{
"siteId": "E1CP6DYM2JF6H",
"status": "active",
"domain": "sub.domain.com",
"pageUrl": "https://sub.domain.com/5d134986fc72480188g18d116118478f",
"authType": "email",
"config": {
"members": [
{
"email": "name@email.com",
"uuid": "5699fa63-f01a-4964-b0ef-3cf8bc61fa04",
"registeredAt": "2022-07-01T14:35:57.347Z",
"verified": true,
"blocked": false,
"paid": true
}
]
}
}
CREATE MEMBER
POST
https://{API_KEY}.api.sotion.app/sites/{SITE_ID}/members
{
"email": "name@email.com",
"paid": false
}
{
"siteId": "E1CP6DYM2JF6H",
"status": "active",
"domain": "sub.domain.com",
"pageUrl": "https://sub.domain.com/5d134986fc72480188g18d116118478f",
"authType": "email",
"config": {
"members": [
{
"email": "name@email.com",
"uuid": "5699fa63-f01a-4964-b0ef-3cf8bc61fa04",
"registeredAt": "2022-07-01T14:35:57.347Z",
"verified": false,
"blocked": false,
"paid": false
}
]
}
}
UPDATE MEMBER
PATCH
https://{API_KEY}.api.sotion.app/sites/{SITE_ID}/members/{MEMBER_UUID}
{
"email": "name@email.com",
"paid": true
}
{
"siteId": "E1CP6DYM2JF6H",
"status": "active",
"domain": "sub.domain.com",
"pageUrl": "https://sub.domain.com/5d134986fc72480188g18d116118478f",
"authType": "email",
"config": {
"members": [
{
"email": "name@email.com",
"uuid": "5699fa63-f01a-4964-b0ef-3cf8bc61fa04",
"registeredAt": "2022-07-01T14:35:57.347Z",
"verified": false,
"blocked": false,
"paid": true
}
]
}
}
DELETE MEMBER
DELETE
https://{API_KEY}.api.sotion.app/sites/{SITE_ID}/members/{MEMBER_UUID}
{
"siteId": "E2SZFRG1WMJOU0",
"memberId": "9bcf796e-3e99-4c86-bf31-a46163effa4b",
"status": "Deleted"
}
MEMBER LOGIN LINK
GET
https://{API_KEY}.api.sotion.app/sites/{SITE_ID}/members/{MEMBER_UUID}/login-link
{
"loginLink": "https://sub.domain.com/_auth?uuid=e36da7cf-71db-456a-8f91-eb3a3dbe3949&email=name%40email.com&magic=verify"
}
SEND MEMBER LOGIN LINK
GET
https://{API_KEY}.api.sotion.app/sites/{SITE_ID}/members/{MEMBER_UUID}/login-link/send
{
"siteId": "E1CP6DYM2JF6H",
"status": "active",
"domain": "sub.domain.com",
"pageUrl": "https://sub.domain.com/5d134986fc72480188g18d116118478f",
"authType": "email",
"config": {
"members": [
{
"email": "name@email.com",
"uuid": "5699fa63-f01a-4964-b0ef-3cf8bc61fa04",
"registeredAt": "2022-07-01T14:35:57.347Z",
"verified": true,
"blocked": false,
"paid": true
}
]
}
}
Data Types
ㅤ | Key | Possible Values | Details |
Site | status | active | deleted | Indicates the status of your site. Most of the time this will be active. If you delete your site then you can still retrieve the members. |
Site | authType | email | whitelist | gumroad | Indicates the Membership Type for your site.
- email: Email Sign Up
- whitelist: Restricted Email List
- gumroad: Paid Membership |
Member | verified | true | false | Indicates if a member has successfully verified their email address using the magic link. |
Member | blocked | true | false | Not used at the moment.
Will be a new feature in future. |
Member | paid | true | false | Indicates if this is a paid member. |
Response Status Codes
HTTP Status Code | Message | Details |
200 | Success | All good |
400 | Bad Request: Invalid siteId | Invalid SITE_ID |
400 | Bad Request: Member email required | Missing email address when creating new member |
400 | Bad Request: Member already exists | Cannot create member with the same email |
401 | Unauthorized | Invalid API_KEY |
404 | Member not found | No Member found for MEMBER_UUID during GET , PATCH , DELETE |
405 | Method Not Allowed | Invalid HTTP Method.
Only GET , POST , PATCH , DELETE are allowed |
500 | Server Error | Something went wrong on our side |