{
"$defs": {
"SpaceJoinPolicy": {
"description": "Who may join a space by themself.",
"oneOf": [
{
"const": "open",
"description": "Any active non-guest member may join.",
"type": "string"
},
{
"const": "invite",
"description": "Members join only when someone adds them (the default).",
"type": "string"
}
]
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false,
"description": "Body of the create-space route.",
"properties": {
"join_policy": {
"anyOf": [
{
"$ref": "#/$defs/SpaceJoinPolicy"
},
{
"type": "null"
}
],
"description": "Who may join by themself; default `invite`."
},
"name": {
"description": "The name, 1–100 characters.",
"type": "string"
},
"slug": {
"description": "The slug; `dm` is reserved.",
"pattern": "^[a-z0-9][a-z0-9-]{0,79}$",
"type": "string"
}
},
"required": [
"slug",
"name"
],
"title": "CreateSpaceRequest",
"type": "object"
}