@omelhorsite/sdk 0.12.0 → 0.12.2
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
CHANGED
|
@@ -100,7 +100,7 @@ const rows = await oms.http.get<{ id: string }[]>("/some/path");
|
|
|
100
100
|
|
|
101
101
|
## Namespaces
|
|
102
102
|
|
|
103
|
-
- `oms.auth` - OAuth: device grant, refresh, revoke, `whoami`.
|
|
103
|
+
- `oms.auth` - OAuth: device grant, refresh, revoke, `whoami`. `decodeIdToken(idToken).sub` is the stable identifier; `email` is a contact and `email_verified` is often `false`, so never find or merge users by email.
|
|
104
104
|
- `oms.sessions`, `oms.passkeys` - sign-in, sign-up, OTP, passkeys.
|
|
105
105
|
- `oms.account` - the signed-in user, profile, sessions, usage. `oms.account.notificationPreferences` decides, per notification kind, whether it shows in the inbox and whether it is emailed; the security kinds always email, unless the master switch is off.
|
|
106
106
|
- `oms.storage` - files and folders: upload, download, share.
|
package/dist/index.js
CHANGED
|
@@ -10328,6 +10328,7 @@ function updateBody(input) {
|
|
|
10328
10328
|
library_public: input.libraryPublic,
|
|
10329
10329
|
library_name: input.libraryName,
|
|
10330
10330
|
library_description: input.libraryDescription,
|
|
10331
|
+
language: input.language,
|
|
10331
10332
|
share_listening: input.shareListening
|
|
10332
10333
|
};
|
|
10333
10334
|
}
|
|
@@ -10747,6 +10748,7 @@ function adminUpdateBody(input) {
|
|
|
10747
10748
|
set("library_public", input.libraryPublic);
|
|
10748
10749
|
set("library_name", input.libraryName);
|
|
10749
10750
|
set("library_description", input.libraryDescription);
|
|
10751
|
+
set("language", input.language);
|
|
10750
10752
|
set("share_listening", input.shareListening);
|
|
10751
10753
|
set("email", input.email);
|
|
10752
10754
|
set("group", input.group);
|
|
@@ -55,8 +55,22 @@ export interface IdentityClaims {
|
|
|
55
55
|
readonly iat?: number;
|
|
56
56
|
/** Present only when the `profile` scope was granted. Mutable, display only. */
|
|
57
57
|
readonly preferred_username?: string;
|
|
58
|
-
/**
|
|
58
|
+
/**
|
|
59
|
+
* Present only when the `email` scope was granted. Mutable, display only.
|
|
60
|
+
*
|
|
61
|
+
* Never look a user up by this. An account can be created with any address
|
|
62
|
+
* and used without proving it, so the value may belong to someone else;
|
|
63
|
+
* matching on it lets whoever registers with a victim's address into the
|
|
64
|
+
* victim's account on your side. Key on `iss` + `sub`.
|
|
65
|
+
*/
|
|
59
66
|
readonly email?: string;
|
|
67
|
+
/**
|
|
68
|
+
* Whether the server holds proof that `email` belongs to the user. Present
|
|
69
|
+
* whenever `email` is, and often `false`. `true` still only means the
|
|
70
|
+
* server checked it once; confirm it yourself before attaching the address
|
|
71
|
+
* to an account that already existed.
|
|
72
|
+
*/
|
|
73
|
+
readonly email_verified?: boolean;
|
|
60
74
|
readonly [claim: string]: unknown;
|
|
61
75
|
}
|
|
62
76
|
/**
|
|
@@ -28,6 +28,8 @@ export interface User extends BaseRecord {
|
|
|
28
28
|
readonly bio?: string | null;
|
|
29
29
|
/** ISO 3166-1 alpha-2, as the user set it. */
|
|
30
30
|
readonly country_code?: string | null;
|
|
31
|
+
/** `en`, `pt` or `lv`: the language of the emails sent to this account. Own account only. */
|
|
32
|
+
readonly language?: string | null;
|
|
31
33
|
readonly email_is_public?: boolean;
|
|
32
34
|
readonly gender_is_public?: boolean;
|
|
33
35
|
readonly library_public?: boolean;
|
|
@@ -90,6 +92,8 @@ export interface UpdateAccountInput {
|
|
|
90
92
|
readonly libraryName?: string | null;
|
|
91
93
|
/** `null` clears it. */
|
|
92
94
|
readonly libraryDescription?: string | null;
|
|
95
|
+
/** `en`, `pt` or `lv`. */
|
|
96
|
+
readonly language?: string;
|
|
93
97
|
/** Whether friends may see what you are listening to. */
|
|
94
98
|
readonly shareListening?: boolean;
|
|
95
99
|
}
|
|
@@ -20,6 +20,7 @@ export interface AdminUpdateUserInput {
|
|
|
20
20
|
readonly libraryPublic?: boolean;
|
|
21
21
|
readonly libraryName?: string | null;
|
|
22
22
|
readonly libraryDescription?: string | null;
|
|
23
|
+
readonly language?: string;
|
|
23
24
|
readonly shareListening?: boolean;
|
|
24
25
|
readonly email?: string;
|
|
25
26
|
/** Privilege group, e.g. `"administrator"`. */
|
package/package.json
CHANGED