self_roles_list
Fetch every self-assignable role, with whether you have it and whether you’ve bought it. Use it to build a role picker for members.
Request
Section titled “Request”{ "cmd": "self_roles_list"}No fields besides cmd.
Response
Section titled “Response”{ "cmd": "self_roles_list", "payee": "mistium", "roles": [ { "id": "b7e2d6a1-54c3-4f7a-8e0d-2c9f61a3e4b8", "name": "photography", "description": "Share your shots", "color": "#a78bfa", "icon": "", "gradient": [], "hoisted": false, "permissions": [], "self_assignable": true, "category": "Hobbies", "price": 0, "position": 4, "assigned": true, "owned": false }, { "id": "0d4e8b7c-2a61-4f3e-9c55-7e1a9b2c6d40", "name": "supporter", "description": "Thanks for backing the server", "color": "#f59e0b", "icon": "https://example.com/roles/star.png", "gradient": [], "hoisted": true, "permissions": [], "self_assignable": true, "category": "Perks", "price": 50, "position": 5, "assigned": false, "owned": false } ]}roles holds full role objects sorted by position, with two extra fields:
| Field | Meaning |
|---|---|
assigned |
You have this role now. |
owned |
You’ve bought this role before. You can add it again without paying. |
payee is the Rotur username that receives payments for paid roles (those with price above 0). It is "" when the server can’t take payments. See self_role_add for how buying works.
Permissions
Section titled “Permissions”Any member can call it.
Errors
Section titled “Errors”This command has no command-specific errors.
