Sotion Members API

Canonical URL
global_site_name
Sotion

How to enable Sotion Membership Management API

To enable the API, update your page Membership Option to one of these three options:
  • Email Sign Up
  • Restricted Email List
  • Paid Membership
notion image
notion image
 

Sotion Membership Management API Documentation

Authentication

Your API Key will be generated as part of your API URL.
For each request you also have to specify the SITE ID, this will be automatically populated on your dashboard.
Format:
https://{API_KEY}.api.sotion.app/sites/{SITE_ID}
Example:
https://d600c2d2-e07e-46b9-b79a-f0376aaa303d.api.sotion.app/E1CP6DYM2JF6H

LIST ALL MEMBERS

List all the members of your site.
Method: GET
Request:
https://{API_KEY}.api.sotion.app/sites/{SITE_ID}/members
Response:
{
    "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

Search for members based on email, verified status, or paid status.
Method: GET
Parameters (any combination):
  • email=name@email.com
  • verified=true|false
  • paid=true|false
Request:
https://{API_KEY}.api.sotion.app/sites/{SITE_ID}/members?email=name@email.com&verified=true&paid=true
Response:
{
    "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

Fetch a specific member based on their id.
Method: GET
Request:
https://{API_KEY}.api.sotion.app/sites/{SITE_ID}/members/{MEMBER_UUID}
Response:
{
    "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

Create a new Member and add them to your site.
Method: POST
Request:
https://{API_KEY}.api.sotion.app/sites/{SITE_ID}/members
Request Body:
{
    "email": "name@email.com",
    "paid": false
}
Response:
{
    "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

Update the details of an existing member.
Method: PATCH
Request:
https://{API_KEY}.api.sotion.app/sites/{SITE_ID}/members/{MEMBER_UUID}
Request Body:
{
    "email": "name@email.com",
    "paid": true
}
Response:
{
    "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 an existing member based on their id.
Method: DELETE
Request:
https://{API_KEY}.api.sotion.app/sites/{SITE_ID}/members/{MEMBER_UUID}
Response:
{
    "siteId": "E2SZFRG1WMJOU0",
    "memberId": "9bcf796e-3e99-4c86-bf31-a46163effa4b",
    "status": "Deleted"
}
 

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
 

Webhooks

( 👀 coming soon… )