POST
/
api
/
v1
/
createSpace
curl --request POST \
  --url https://hero.page/api/v1/createSpace \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "name": "My wonderful space",
  "isPublic": true,
  "img": "https://firebasestorage.googleapis.com/v0/b/focushero-1650416072840.appspot.com/o/FCMImages%2Fdefault_spacey.webp?alt=media&token=e37eecbd-6b99-430c-b073-b57622ef8440"
}'
{
  "id": "<string>",
  "shareable_link": "<string>",
  "online_editor": "<string>",
  "space": {
    "id": "<string>",
    "createdAt": "2023-11-07T05:31:56Z",
    "img": "<string>",
    "name": "<string>",
    "slug": "<string>",
    "isOwner": true
  }
}

Authorizations

Authorization
string
headerrequired

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
name
string

The name of the space

isPublic
boolean

Whether the space is public

img
string

Image URL for the space

Response

201 - application/json
id
string

The ID of the created space

shareable_link
string

Shareable link if the space is public

online_editor
string

Link to the online editor for the space

space
object