twentythree-skills 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,216 @@
1
+ ---
2
+ name: user
3
+ description: Manage workspace users (admin-scope only). Invite, update, and issue login tokens.
4
+ ---
5
+
6
+ # TwentyThree User Commands
7
+
8
+ > Manage users in a TwentyThree workspace — list, create, update, invite, and issue login tokens.
9
+ > Always use `--json` in agentic contexts for structured output.
10
+
11
+ > **ALL user commands require admin scope.** If your bearer token lacks admin, every command in this topic will fail with 401/403.
12
+
13
+ ## Prerequisites
14
+
15
+ Auth scope required: admin (create, get, list, update, get-login-token, send-invitation), read (tokens, redeem-login-token).
16
+ Run `twentythree auth credentials` if not already configured.
17
+ Verify: `twentythree auth status --json`
18
+
19
+ Run `twentythree auth status --json` to confirm the current workspace's bearer token has admin scope before using these commands.
20
+
21
+ > For any flag not listed here, run `twentythree user <cmd> --agent` to get the complete flag list, types, and defaults.
22
+
23
+ ## Commands
24
+
25
+ ### user list
26
+
27
+ **Auth scope:** admin **Side effects:** none **Output:** table (ID, Username, Display Name, URL)
28
+
29
+ Flags:
30
+
31
+ | Flag | Required | Description |
32
+ |------|----------|-------------|
33
+ | `--page` | no | Page number |
34
+ | `--size` | no | Number of results per page |
35
+ | `--search` | no | Search query (username, display name, or email) |
36
+ | `--user-id` | no | Filter by user ID |
37
+
38
+ ```bash
39
+ # List all users in the workspace
40
+ twentythree user list --json
41
+
42
+ # Search for a user by name or email
43
+ twentythree user list --search "alice" --json
44
+ ```
45
+
46
+ ### user create
47
+
48
+ **Auth scope:** admin **Side effects:** creates **Output:** key-value (user ID)
49
+
50
+ Flags:
51
+
52
+ | Flag | Required | Description |
53
+ |------|----------|-------------|
54
+ | `--email` | yes | Email address for the new user |
55
+ | `--username` | no | Username for the new user |
56
+ | `--full-name` | no | Full display name for the new user |
57
+ | `--site-admin` | no | Grant site admin privileges (boolean) |
58
+ | `--user-type` | no | User type (e.g. standard, administrator) |
59
+
60
+ ```bash
61
+ # Create a new editor user
62
+ twentythree user create --email colleague@example.com --full-name "New User" --user-type editor --json
63
+
64
+ # Create a site admin user
65
+ twentythree user create --email admin@example.com --full-name "Admin User" --site-admin --json
66
+ ```
67
+
68
+ ### user get
69
+
70
+ **Auth scope:** admin **Side effects:** none **Output:** key-value
71
+
72
+ Takes `<user-id>` as positional argument.
73
+
74
+ Flags:
75
+
76
+ | Flag | Required | Description |
77
+ |------|----------|-------------|
78
+ | `--include-invitation` | no | Include invitation details in the response (boolean) |
79
+
80
+ ```bash
81
+ # Get details of a specific user
82
+ twentythree user get <user-id> --json
83
+
84
+ # Get user details including invitation status
85
+ twentythree user get <user-id> --include-invitation --json
86
+ ```
87
+
88
+ ### user update
89
+
90
+ **Auth scope:** admin **Side effects:** updates **Output:** key-value
91
+
92
+ Takes `<user-id>` as positional argument.
93
+
94
+ Flags:
95
+
96
+ | Flag | Required | Description |
97
+ |------|----------|-------------|
98
+ | `--email` | no | New email address |
99
+ | `--full-name` | no | New full display name |
100
+ | `--password` | no | New password |
101
+ | `--profile-image` | no | Path to profile image file |
102
+
103
+ > **Security:** `--password` is visible in process lists and shell history.
104
+ > Prefer the admin UI for password changes in sensitive environments.
105
+
106
+ ```bash
107
+ # Update a user's display name
108
+ twentythree user update <user-id> --full-name "Alice Smith" --json
109
+
110
+ # Update a user's password (see security warning above)
111
+ twentythree user update <user-id> --password "new-password" --json
112
+ ```
113
+
114
+ ### user get-login-token
115
+
116
+ **Auth scope:** admin **Side effects:** none **Output:** key-value (token)
117
+
118
+ Takes `<user-id>` as positional argument. Generates a time-limited login token that allows the user to authenticate without their password.
119
+
120
+ Flags:
121
+
122
+ | Flag | Required | Description |
123
+ |------|----------|-------------|
124
+ | `--return-url` | no | URL to redirect to after login |
125
+
126
+ ```bash
127
+ # Generate a login token for a user
128
+ twentythree user get-login-token <user-id> --json
129
+
130
+ # Generate a token with a post-login redirect
131
+ twentythree user get-login-token <user-id> --return-url https://video.twentythree.com/ --json
132
+ ```
133
+
134
+ ### user send-invitation
135
+
136
+ **Auth scope:** admin **Side effects:** updates **Output:** key-value
137
+
138
+ Takes `<user-id>` as positional argument. Sends an invitation email to the specified user.
139
+
140
+ Flags:
141
+
142
+ | Flag | Required | Description |
143
+ |------|----------|-------------|
144
+ | `--invitation-message` | no | Custom message to include in the invitation email |
145
+
146
+ ```bash
147
+ # Send a default invitation email
148
+ twentythree user send-invitation <user-id> --json
149
+
150
+ # Send an invitation with a custom message
151
+ twentythree user send-invitation <user-id> --invitation-message "Welcome to the platform!" --json
152
+ ```
153
+
154
+ ### user tokens
155
+
156
+ **Auth scope:** read **Side effects:** none **Output:** table (Domain, Token)
157
+
158
+ Lists cross-site tokens for the authenticated user. Useful for auditing active workspace tokens.
159
+
160
+ Flags:
161
+
162
+ | Flag | Required | Description |
163
+ |------|----------|-------------|
164
+ | `--cross-sites` | no | Include cross-site tokens (default: true) |
165
+
166
+ ```bash
167
+ # List all active cross-site tokens
168
+ twentythree user tokens --json
169
+
170
+ # List tokens without cross-site tokens
171
+ twentythree user tokens --no-cross-sites --json
172
+ ```
173
+
174
+ ### user redeem-login-token
175
+
176
+ **Auth scope:** read **Side effects:** none **Output:** key-value
177
+
178
+ Redeems a login token (previously generated by `user get-login-token`) to authenticate a user.
179
+
180
+ Flags:
181
+
182
+ | Flag | Required | Description |
183
+ |------|----------|-------------|
184
+ | `--login-token` | yes | Login token to redeem |
185
+
186
+ ```bash
187
+ # Redeem a login token
188
+ twentythree user redeem-login-token --login-token <token> --json
189
+
190
+ # Redeem a token received from get-login-token output
191
+ twentythree user redeem-login-token --login-token <token> --json
192
+ ```
193
+
194
+ ## Common Patterns
195
+
196
+ ### Invite a new user
197
+
198
+ ```bash
199
+ # Step 1: Create the user account
200
+ twentythree user create --email colleague@example.com --full-name "New User" --user-type editor --json
201
+
202
+ # Step 2: Capture the user_id from the output, then send invitation
203
+ twentythree user send-invitation <user-id> --invitation-message "Welcome to TwentyThree!" --json
204
+ ```
205
+
206
+ ### Issue a time-limited login token
207
+
208
+ ```bash
209
+ twentythree user get-login-token <user-id> --return-url https://video.twentythree.com/ --json
210
+ ```
211
+
212
+ ### Audit active tokens
213
+
214
+ ```bash
215
+ twentythree user tokens --json
216
+ ```