@shuffl/cli 0.6.5 → 0.7.1
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.
- package/README.md +1 -1
- package/dist/commands.generated.js +35 -0
- package/dist/index.js +2 -2
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -33,7 +33,7 @@ shuffl programs update --input-file update-program.json --json
|
|
|
33
33
|
shuffl logout
|
|
34
34
|
```
|
|
35
35
|
|
|
36
|
-
Alternatively set `
|
|
36
|
+
Alternatively set `SHUFFL_API_KEY` and `SHUFFL_BASE_URL` through your environment. Tokens are never accepted as command-line arguments or printed after login. Saved credentials are stored with mode `0600` under `$XDG_CONFIG_HOME/shuffl/config.json` (default `~/.config/shuffl/config.json`). `SHUFFL_CONFIG_DIR` overrides the Shuffl directory. Logout removes the local copy; revoke the token in Settings to disable other copies.
|
|
37
37
|
|
|
38
38
|
The saved token cannot be used with a different `--base-url`; log into that server or supply an explicit environment token. Login verifies the token before saving it.
|
|
39
39
|
|
|
@@ -3285,6 +3285,10 @@ export const commands = [
|
|
|
3285
3285
|
const: 'reports.answerFeedback',
|
|
3286
3286
|
type: 'string',
|
|
3287
3287
|
},
|
|
3288
|
+
{
|
|
3289
|
+
const: 'reports.celebrations',
|
|
3290
|
+
type: 'string',
|
|
3291
|
+
},
|
|
3288
3292
|
{
|
|
3289
3293
|
const: 'reports.connections',
|
|
3290
3294
|
type: 'string',
|
|
@@ -14055,6 +14059,37 @@ export const commands = [
|
|
|
14055
14059
|
scope: 'reports:read',
|
|
14056
14060
|
summary: "Read feedback on Mello's answers",
|
|
14057
14061
|
},
|
|
14062
|
+
{
|
|
14063
|
+
access: 'read',
|
|
14064
|
+
command: ['reports', 'celebrations'],
|
|
14065
|
+
input: {
|
|
14066
|
+
$schema: 'https://json-schema.org/draft/2020-12/schema',
|
|
14067
|
+
additionalProperties: false,
|
|
14068
|
+
properties: {
|
|
14069
|
+
days: {
|
|
14070
|
+
anyOf: [
|
|
14071
|
+
{
|
|
14072
|
+
const: 30,
|
|
14073
|
+
type: 'number',
|
|
14074
|
+
},
|
|
14075
|
+
{
|
|
14076
|
+
const: 90,
|
|
14077
|
+
type: 'number',
|
|
14078
|
+
},
|
|
14079
|
+
{
|
|
14080
|
+
const: 180,
|
|
14081
|
+
type: 'number',
|
|
14082
|
+
},
|
|
14083
|
+
],
|
|
14084
|
+
},
|
|
14085
|
+
},
|
|
14086
|
+
type: 'object',
|
|
14087
|
+
},
|
|
14088
|
+
path: ['reports', 'celebrations'],
|
|
14089
|
+
permission: 'reports.celebrations',
|
|
14090
|
+
scope: 'reports:read',
|
|
14091
|
+
summary: 'Celebrations sent, people celebrated, birthdays and anniversaries, shared with the team, team cards and notes, share answers and missed messages over 30, 90 or 180 days against the period before, with a weekly series',
|
|
14092
|
+
},
|
|
14058
14093
|
{
|
|
14059
14094
|
access: 'read',
|
|
14060
14095
|
command: ['reports', 'connections'],
|
package/dist/index.js
CHANGED
|
@@ -203,7 +203,7 @@ export async function runCli(args, io = {
|
|
|
203
203
|
const company = command.credential === 'company';
|
|
204
204
|
const environmentToken = company
|
|
205
205
|
? io.env.SHUFFL_COMPANY_KEY
|
|
206
|
-
: io.env.
|
|
206
|
+
: io.env.SHUFFL_API_KEY;
|
|
207
207
|
const saved = await load(company ? companyFile : configFile);
|
|
208
208
|
const token = environmentToken ?? saved?.token;
|
|
209
209
|
const baseUrl = typeof flags['base-url'] === 'string'
|
|
@@ -212,7 +212,7 @@ export async function runCli(args, io = {
|
|
|
212
212
|
if (!token || !baseUrl)
|
|
213
213
|
throw new Error(company
|
|
214
214
|
? 'Run shuffl login --company, or set SHUFFL_COMPANY_KEY and SHUFFL_BASE_URL.'
|
|
215
|
-
: 'Run shuffl login, or set
|
|
215
|
+
: 'Run shuffl login, or set SHUFFL_API_KEY and SHUFFL_BASE_URL.');
|
|
216
216
|
if (!environmentToken &&
|
|
217
217
|
saved &&
|
|
218
218
|
new URL(baseUrl).origin !== new URL(saved.baseUrl).origin)
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"dependencies": {
|
|
3
3
|
"@orpc/client": "1.15.3",
|
|
4
|
-
"@shuffl/api-contracts": "0.
|
|
5
|
-
"@shuffl/sdk": "0.
|
|
4
|
+
"@shuffl/api-contracts": "0.7.1",
|
|
5
|
+
"@shuffl/sdk": "0.7.1"
|
|
6
6
|
},
|
|
7
7
|
"description": "Shuffl command line: every public API operation as a scriptable command with JSON output.",
|
|
8
8
|
"engines": {
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
"sideEffects": false,
|
|
34
34
|
"type": "module",
|
|
35
35
|
"types": "./dist/index.d.ts",
|
|
36
|
-
"version": "0.
|
|
36
|
+
"version": "0.7.1",
|
|
37
37
|
"bin": {
|
|
38
38
|
"shuffl": "./dist/bin.js"
|
|
39
39
|
}
|