Creates an invitation code for a community.
Input
Encoding
application/jsoncommunity
stringdid
Required
The community to create an invitation for.
expiresAt
stringdatetime
Optional
When the invitation stops being redeemable, if ever.
maxUses
integer
Optional
How many times the invitation may be redeemed, if limited.
minimum: 1Output
Encoding
application/jsoninvitation
refsocial.colibri.beta.community.defs#invitationView
Required
The newly created invitation.
Errors
AuthRequired
The request is missing, malformed, or unverifiable service auth. Forbidden
The requesting user lacks the invitation.create permission. CommunityNotFound
No community exists with that DID. Try It
Requests are sent directly from your browser. Some servers may block requests due to CORS.
View raw schema
{
"type": "procedure",
"input": {
"schema": {
"type": "object",
"required": [
"community"
],
"properties": {
"maxUses": {
"type": "integer",
"minimum": 1,
"description": "How many times the invitation may be redeemed, if limited."
},
"community": {
"type": "string",
"format": "did",
"description": "The community to create an invitation for."
},
"expiresAt": {
"type": "string",
"format": "datetime",
"description": "When the invitation stops being redeemable, if ever."
}
}
},
"encoding": "application/json"
},
"errors": [
{
"name": "AuthRequired",
"description": "The request is missing, malformed, or unverifiable service auth."
},
{
"name": "Forbidden",
"description": "The requesting user lacks the invitation.create permission."
},
{
"name": "CommunityNotFound",
"description": "No community exists with that DID."
}
],
"output": {
"schema": {
"type": "object",
"required": [
"invitation"
],
"properties": {
"invitation": {
"ref": "social.colibri.beta.community.defs#invitationView",
"type": "ref",
"description": "The newly created invitation."
}
}
},
"encoding": "application/json"
},
"description": "Creates an invitation code for a community."
}