@1password/sdk 0.0.0-credential-broker-dev-preview
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 +220 -0
- package/dist/client.d.ts +23 -0
- package/dist/client.js +32 -0
- package/dist/client_builder.d.ts +18 -0
- package/dist/client_builder.js +64 -0
- package/dist/configuration.d.ts +33 -0
- package/dist/configuration.js +58 -0
- package/dist/core.d.ts +115 -0
- package/dist/core.js +154 -0
- package/dist/credential_broker.d.ts +28 -0
- package/dist/credential_broker.js +31 -0
- package/dist/credential_broker_access_requests.d.ts +43 -0
- package/dist/credential_broker_access_requests.js +78 -0
- package/dist/credential_broker_environment_variables.d.ts +33 -0
- package/dist/credential_broker_environment_variables.js +58 -0
- package/dist/credential_broker_logins.d.ts +38 -0
- package/dist/credential_broker_logins.js +77 -0
- package/dist/environments.d.ts +82 -0
- package/dist/environments.js +132 -0
- package/dist/errors.d.ts +13 -0
- package/dist/errors.js +45 -0
- package/dist/groups.d.ts +19 -0
- package/dist/groups.js +54 -0
- package/dist/items.d.ts +89 -0
- package/dist/items.js +216 -0
- package/dist/items_files.d.ts +40 -0
- package/dist/items_files.js +116 -0
- package/dist/items_shares.d.ts +32 -0
- package/dist/items_shares.js +95 -0
- package/dist/sdk.d.ts +24 -0
- package/dist/sdk.js +57 -0
- package/dist/secrets.d.ts +36 -0
- package/dist/secrets.js +107 -0
- package/dist/shared_lib_core.d.ts +17 -0
- package/dist/shared_lib_core.js +183 -0
- package/dist/types.d.ts +972 -0
- package/dist/types.js +279 -0
- package/dist/vaults.d.ts +83 -0
- package/dist/vaults.js +209 -0
- package/dist/version.d.ts +2 -0
- package/dist/version.js +6 -0
- package/dist/web.d.ts +11 -0
- package/dist/web.js +55 -0
- package/package.json +54 -0
package/dist/types.d.ts
ADDED
|
@@ -0,0 +1,972 @@
|
|
|
1
|
+
export type ErrorMessage = string;
|
|
2
|
+
/** The lifecycle state of an access request. */
|
|
3
|
+
export declare enum AccessRequestState {
|
|
4
|
+
/** The request is awaiting a decision. */
|
|
5
|
+
Pending = "pending",
|
|
6
|
+
/** The request was approved and credentials were granted. */
|
|
7
|
+
Resolved = "resolved",
|
|
8
|
+
/** The request was denied by the user. */
|
|
9
|
+
Denied = "denied",
|
|
10
|
+
/** The request could not be processed. */
|
|
11
|
+
Failed = "failed"
|
|
12
|
+
}
|
|
13
|
+
/** The credential types an access request entry can ask for. */
|
|
14
|
+
export declare enum AccessRequestEntryType {
|
|
15
|
+
/** A login credential (username / password / TOTP). */
|
|
16
|
+
Login = "login"
|
|
17
|
+
}
|
|
18
|
+
/** Type-specific parameters for a requested credential. */
|
|
19
|
+
export interface AccessRequestEntryParameters {
|
|
20
|
+
/** The website the requester needs to sign in to. */
|
|
21
|
+
website?: string;
|
|
22
|
+
}
|
|
23
|
+
/** A requested credential within a created access request. */
|
|
24
|
+
export interface AccessRequestEntry {
|
|
25
|
+
/**
|
|
26
|
+
* The SDK-minted identifier used to correlate this entry with a
|
|
27
|
+
* [`ResolvedAccessRequestEntry`] in the request status.
|
|
28
|
+
*/
|
|
29
|
+
id: string;
|
|
30
|
+
/** The credential type requested. */
|
|
31
|
+
type: AccessRequestEntryType;
|
|
32
|
+
/** Type-specific request parameters. */
|
|
33
|
+
parameters: AccessRequestEntryParameters;
|
|
34
|
+
/** Why this specific credential is needed, shown in the consent prompt. */
|
|
35
|
+
reason?: string;
|
|
36
|
+
/**
|
|
37
|
+
* Soft ranking signal used to order the candidate logins offered to the
|
|
38
|
+
* user.
|
|
39
|
+
*/
|
|
40
|
+
keywords?: string[];
|
|
41
|
+
}
|
|
42
|
+
/** A server-managed access request. */
|
|
43
|
+
export interface AccessRequest {
|
|
44
|
+
/**
|
|
45
|
+
* The canonical resource path.
|
|
46
|
+
* Format: `accounts/{account}/credential-broker-access-requests/{id}`
|
|
47
|
+
*/
|
|
48
|
+
path: string;
|
|
49
|
+
/**
|
|
50
|
+
* The client-generated identifier of the request. Pass to
|
|
51
|
+
* `credentialBroker.accessRequests.getStatus` to poll the request status.
|
|
52
|
+
*/
|
|
53
|
+
id: string;
|
|
54
|
+
/**
|
|
55
|
+
* The canonical AEP resource path of the identity for which
|
|
56
|
+
* credential access is requested.
|
|
57
|
+
*/
|
|
58
|
+
identity: string;
|
|
59
|
+
/** The current lifecycle state. */
|
|
60
|
+
state: AccessRequestState;
|
|
61
|
+
/** The time the request was created. */
|
|
62
|
+
createdAt: Date;
|
|
63
|
+
/**
|
|
64
|
+
* What the requester is trying to accomplish, shown to the user above
|
|
65
|
+
* the individual entries.
|
|
66
|
+
*/
|
|
67
|
+
goal?: string;
|
|
68
|
+
/**
|
|
69
|
+
* The requested entries as created, each carrying its SDK-minted id.
|
|
70
|
+
* Correlate against [`ResolvedAccessRequestEntry::entry_id`] in the
|
|
71
|
+
* request status.
|
|
72
|
+
*/
|
|
73
|
+
entries: AccessRequestEntry[];
|
|
74
|
+
}
|
|
75
|
+
/** A single credential need within an access request. */
|
|
76
|
+
export interface AccessRequestEntryCreateParams {
|
|
77
|
+
/** The credential type requested. */
|
|
78
|
+
type: AccessRequestEntryType;
|
|
79
|
+
/** Type-specific request parameters. */
|
|
80
|
+
parameters: AccessRequestEntryParameters;
|
|
81
|
+
/** Why this specific credential is needed, shown in the consent prompt. */
|
|
82
|
+
reason?: string;
|
|
83
|
+
/**
|
|
84
|
+
* Soft ranking signal used to order the candidate logins offered to the
|
|
85
|
+
* user.
|
|
86
|
+
*/
|
|
87
|
+
keywords?: string[];
|
|
88
|
+
}
|
|
89
|
+
/** The parameters for creating an access request. */
|
|
90
|
+
export interface AccessRequestCreateParams {
|
|
91
|
+
/**
|
|
92
|
+
* What the requester is trying to accomplish, shown to the user above
|
|
93
|
+
* the individual entries.
|
|
94
|
+
*/
|
|
95
|
+
goal?: string;
|
|
96
|
+
/**
|
|
97
|
+
* The requested credentials, in presentation order. Must contain
|
|
98
|
+
* between 1 and 5 entries.
|
|
99
|
+
*/
|
|
100
|
+
entries: AccessRequestEntryCreateParams[];
|
|
101
|
+
}
|
|
102
|
+
/**
|
|
103
|
+
* A reference to a 1Password Credential Broker configuration.
|
|
104
|
+
*
|
|
105
|
+
* Passed to a `client.credential_broker.<kind>.read` call to fetch a
|
|
106
|
+
* credential. The `reference` string has the form:
|
|
107
|
+
*
|
|
108
|
+
* ```text
|
|
109
|
+
* //api.1password.com/credential-broker/accounts/<account>/capability/<name>/configurations/<id>
|
|
110
|
+
* ```
|
|
111
|
+
*/
|
|
112
|
+
export interface CredentialReference {
|
|
113
|
+
/** The reference path. */
|
|
114
|
+
reference: string;
|
|
115
|
+
}
|
|
116
|
+
/** A credential granted in response to a requested entry. */
|
|
117
|
+
export interface ResolvedAccessRequestEntry {
|
|
118
|
+
/**
|
|
119
|
+
* The requested entry satisfied by this credential, if any. When
|
|
120
|
+
* missing, this credential was additionally chosen during
|
|
121
|
+
* resolution on top of the requested credentials.
|
|
122
|
+
*/
|
|
123
|
+
entryId?: string;
|
|
124
|
+
/**
|
|
125
|
+
* The credential-broker reference to fetch the credential with
|
|
126
|
+
* (e.g. via `credentialBroker.logins.read`).
|
|
127
|
+
*/
|
|
128
|
+
reference: CredentialReference;
|
|
129
|
+
}
|
|
130
|
+
/** The non-sensitive status of an access request. */
|
|
131
|
+
export interface AccessRequestStatus {
|
|
132
|
+
/** The current lifecycle state. */
|
|
133
|
+
state: AccessRequestState;
|
|
134
|
+
/** The credentials granted when the request is resolved. */
|
|
135
|
+
resolved: ResolvedAccessRequestEntry[];
|
|
136
|
+
}
|
|
137
|
+
/** Additional attributes for OTP fields. */
|
|
138
|
+
export interface AddressFieldDetails {
|
|
139
|
+
/** The street address */
|
|
140
|
+
street: string;
|
|
141
|
+
/** The city */
|
|
142
|
+
city: string;
|
|
143
|
+
/** The country */
|
|
144
|
+
country: string;
|
|
145
|
+
/** The ZIP code */
|
|
146
|
+
zip: string;
|
|
147
|
+
/** The state */
|
|
148
|
+
state: string;
|
|
149
|
+
}
|
|
150
|
+
export interface DocumentCreateParams {
|
|
151
|
+
/** The name of the file */
|
|
152
|
+
name: string;
|
|
153
|
+
/** The content of the file */
|
|
154
|
+
content: Uint8Array;
|
|
155
|
+
}
|
|
156
|
+
/** A 1Password Environment. */
|
|
157
|
+
export interface Environment {
|
|
158
|
+
/** The Environment's UUID. */
|
|
159
|
+
id: string;
|
|
160
|
+
/** The Environment's name. */
|
|
161
|
+
name: string;
|
|
162
|
+
/** The content version number */
|
|
163
|
+
contentVersion: number;
|
|
164
|
+
/** The secrets count. */
|
|
165
|
+
secrets: number;
|
|
166
|
+
/** The UTC date and time the environment was created */
|
|
167
|
+
createdAt: Date;
|
|
168
|
+
/** The UTC date and time the environment was last updated */
|
|
169
|
+
updatedAt: Date;
|
|
170
|
+
}
|
|
171
|
+
/**
|
|
172
|
+
* One environment variable resolved by the credential broker.
|
|
173
|
+
*
|
|
174
|
+
* Shared between the Environments API (`GetVariablesResponse`) and the
|
|
175
|
+
* Credential Broker API (`EnvironmentCredential`, gated on
|
|
176
|
+
* `brokered-access`), since both surfaces read from the same credential
|
|
177
|
+
* broker enclave endpoint.
|
|
178
|
+
*/
|
|
179
|
+
export interface EnvironmentVariable {
|
|
180
|
+
/** An environment variable's name */
|
|
181
|
+
name: string;
|
|
182
|
+
/** An environment variable's value */
|
|
183
|
+
value: string;
|
|
184
|
+
/** An environment variable's masked state */
|
|
185
|
+
masked: boolean;
|
|
186
|
+
}
|
|
187
|
+
/**
|
|
188
|
+
* An environment credential brokered by 1Password: a bundle of
|
|
189
|
+
* environment variables.
|
|
190
|
+
*
|
|
191
|
+
* Returned by
|
|
192
|
+
* [`EnvironmentVariables::read`](crate::client::EnvironmentVariables::read).
|
|
193
|
+
*/
|
|
194
|
+
export interface EnvironmentCredential {
|
|
195
|
+
/** The environment variables in the bundle. */
|
|
196
|
+
variables: EnvironmentVariable[];
|
|
197
|
+
}
|
|
198
|
+
/** A single secret from a 1Password Environment. */
|
|
199
|
+
export interface EnvironmentSecret {
|
|
200
|
+
/** The secret's name. */
|
|
201
|
+
name: string;
|
|
202
|
+
/** The secret's value. */
|
|
203
|
+
value: string;
|
|
204
|
+
/** Whether the secret's value is concealed. */
|
|
205
|
+
concealed: boolean;
|
|
206
|
+
}
|
|
207
|
+
export interface FileAttributes {
|
|
208
|
+
/** The name of the file */
|
|
209
|
+
name: string;
|
|
210
|
+
/** The ID of the file retrieved from the server */
|
|
211
|
+
id: string;
|
|
212
|
+
/** The size of the file in bytes */
|
|
213
|
+
size: number;
|
|
214
|
+
}
|
|
215
|
+
export interface FileCreateParams {
|
|
216
|
+
/** The name of the file */
|
|
217
|
+
name: string;
|
|
218
|
+
/** The content of the file */
|
|
219
|
+
content: Uint8Array;
|
|
220
|
+
/** The section id where the file should be stored */
|
|
221
|
+
sectionId: string;
|
|
222
|
+
/** The field id where the file should be stored */
|
|
223
|
+
fieldId: string;
|
|
224
|
+
}
|
|
225
|
+
/**
|
|
226
|
+
* For future use, if we want to return more information about the generated password.
|
|
227
|
+
* Currently, it only returns the password itself.
|
|
228
|
+
*/
|
|
229
|
+
export interface GeneratePasswordResponse {
|
|
230
|
+
/** The generated password. */
|
|
231
|
+
password: string;
|
|
232
|
+
}
|
|
233
|
+
/** Response containing the full set of environment variables from an Environment. */
|
|
234
|
+
export interface GetVariablesResponse {
|
|
235
|
+
/** List of environment variables. */
|
|
236
|
+
variables: EnvironmentVariable[];
|
|
237
|
+
}
|
|
238
|
+
export declare enum GroupType {
|
|
239
|
+
/**
|
|
240
|
+
* The owners group, which gives the following permissions:
|
|
241
|
+
* - Do everything the Admin group can do
|
|
242
|
+
* - See every vault other than the personal vaults
|
|
243
|
+
* - Change people's names
|
|
244
|
+
* - See billing
|
|
245
|
+
* - Change billing
|
|
246
|
+
* - Make other people owners
|
|
247
|
+
* - Delete a person
|
|
248
|
+
*/
|
|
249
|
+
Owners = "owners",
|
|
250
|
+
/**
|
|
251
|
+
* The administrators group, which gives the following permissions:
|
|
252
|
+
* - Perform recovery
|
|
253
|
+
* - Create new vaults
|
|
254
|
+
* - Invite new members
|
|
255
|
+
* - See vault metadata, including the vault name and who has access.
|
|
256
|
+
* - Make other people admins
|
|
257
|
+
*/
|
|
258
|
+
Administrators = "administrators",
|
|
259
|
+
/**
|
|
260
|
+
* The recovery group. It contains recovery keysets, and is added to every vault to allow for recovery.
|
|
261
|
+
*
|
|
262
|
+
* No one is added to this.
|
|
263
|
+
*/
|
|
264
|
+
Recovery = "recovery",
|
|
265
|
+
/**
|
|
266
|
+
* The external account managers group or EAM is a mandatory group for managed accounts that has
|
|
267
|
+
* same permissions as the owners.
|
|
268
|
+
*/
|
|
269
|
+
ExternalAccountManagers = "externalAccountManagers",
|
|
270
|
+
/** Members of a team that a user is on. */
|
|
271
|
+
TeamMembers = "teamMembers",
|
|
272
|
+
/** A custom, user defined group. */
|
|
273
|
+
UserDefined = "userDefined",
|
|
274
|
+
/** Support for new or renamed group types */
|
|
275
|
+
Unsupported = "unsupported"
|
|
276
|
+
}
|
|
277
|
+
export declare enum GroupState {
|
|
278
|
+
/** This group is active */
|
|
279
|
+
Active = "active",
|
|
280
|
+
/** This group has been deleted */
|
|
281
|
+
Deleted = "deleted",
|
|
282
|
+
/** This group is in an unknown state */
|
|
283
|
+
Unsupported = "unsupported"
|
|
284
|
+
}
|
|
285
|
+
export declare enum VaultAccessorType {
|
|
286
|
+
User = "user",
|
|
287
|
+
Group = "group",
|
|
288
|
+
Broker = "broker"
|
|
289
|
+
}
|
|
290
|
+
/** Represents the vault access information. */
|
|
291
|
+
export interface VaultAccess {
|
|
292
|
+
/** The vault's UUID. */
|
|
293
|
+
vaultUuid: string;
|
|
294
|
+
/** The vault's accessor type. */
|
|
295
|
+
accessorType: VaultAccessorType;
|
|
296
|
+
/** The vault's accessor UUID. */
|
|
297
|
+
accessorUuid: string;
|
|
298
|
+
/** The permissions granted to this vault */
|
|
299
|
+
permissions: number;
|
|
300
|
+
}
|
|
301
|
+
export interface Group {
|
|
302
|
+
id: string;
|
|
303
|
+
title: string;
|
|
304
|
+
description: string;
|
|
305
|
+
groupType: GroupType;
|
|
306
|
+
state: GroupState;
|
|
307
|
+
vaultAccess?: VaultAccess[];
|
|
308
|
+
}
|
|
309
|
+
/**
|
|
310
|
+
* Represents a group's access to a 1Password vault.
|
|
311
|
+
* This is used for granting permissions
|
|
312
|
+
*/
|
|
313
|
+
export interface GroupAccess {
|
|
314
|
+
/** The group's ID */
|
|
315
|
+
groupId: string;
|
|
316
|
+
/** The group's set of permissions for the vault */
|
|
317
|
+
permissions: number;
|
|
318
|
+
}
|
|
319
|
+
export interface GroupGetParams {
|
|
320
|
+
vaultPermissions?: boolean;
|
|
321
|
+
}
|
|
322
|
+
/** Represents a group's access to a 1Password vault. */
|
|
323
|
+
export interface GroupVaultAccess {
|
|
324
|
+
/** The vault's ID */
|
|
325
|
+
vaultId: string;
|
|
326
|
+
/** The group's ID */
|
|
327
|
+
groupId: string;
|
|
328
|
+
/** The group's set of permissions for the vault */
|
|
329
|
+
permissions: number;
|
|
330
|
+
}
|
|
331
|
+
export declare enum ItemCategory {
|
|
332
|
+
Login = "Login",
|
|
333
|
+
SecureNote = "SecureNote",
|
|
334
|
+
CreditCard = "CreditCard",
|
|
335
|
+
CryptoWallet = "CryptoWallet",
|
|
336
|
+
Identity = "Identity",
|
|
337
|
+
Password = "Password",
|
|
338
|
+
Document = "Document",
|
|
339
|
+
ApiCredentials = "ApiCredentials",
|
|
340
|
+
BankAccount = "BankAccount",
|
|
341
|
+
Database = "Database",
|
|
342
|
+
DriverLicense = "DriverLicense",
|
|
343
|
+
Email = "Email",
|
|
344
|
+
MedicalRecord = "MedicalRecord",
|
|
345
|
+
Membership = "Membership",
|
|
346
|
+
OutdoorLicense = "OutdoorLicense",
|
|
347
|
+
Passport = "Passport",
|
|
348
|
+
Rewards = "Rewards",
|
|
349
|
+
Router = "Router",
|
|
350
|
+
Server = "Server",
|
|
351
|
+
SshKey = "SshKey",
|
|
352
|
+
SocialSecurityNumber = "SocialSecurityNumber",
|
|
353
|
+
SoftwareLicense = "SoftwareLicense",
|
|
354
|
+
Person = "Person",
|
|
355
|
+
Unsupported = "Unsupported"
|
|
356
|
+
}
|
|
357
|
+
export declare enum ItemFieldType {
|
|
358
|
+
Text = "Text",
|
|
359
|
+
Concealed = "Concealed",
|
|
360
|
+
CreditCardType = "CreditCardType",
|
|
361
|
+
CreditCardNumber = "CreditCardNumber",
|
|
362
|
+
Phone = "Phone",
|
|
363
|
+
Url = "Url",
|
|
364
|
+
Totp = "Totp",
|
|
365
|
+
Email = "Email",
|
|
366
|
+
Reference = "Reference",
|
|
367
|
+
SshKey = "SshKey",
|
|
368
|
+
Menu = "Menu",
|
|
369
|
+
MonthYear = "MonthYear",
|
|
370
|
+
Address = "Address",
|
|
371
|
+
Date = "Date",
|
|
372
|
+
Unsupported = "Unsupported"
|
|
373
|
+
}
|
|
374
|
+
/** Field type-specific attributes. */
|
|
375
|
+
export type ItemFieldDetails =
|
|
376
|
+
/** The computed OTP code and other details */
|
|
377
|
+
{
|
|
378
|
+
type: "Otp";
|
|
379
|
+
content: OtpFieldDetails;
|
|
380
|
+
}
|
|
381
|
+
/** Computed SSH Key attributes */
|
|
382
|
+
| {
|
|
383
|
+
type: "SshKey";
|
|
384
|
+
content?: SshKeyAttributes;
|
|
385
|
+
}
|
|
386
|
+
/** Address components */
|
|
387
|
+
| {
|
|
388
|
+
type: "Address";
|
|
389
|
+
content?: AddressFieldDetails;
|
|
390
|
+
};
|
|
391
|
+
/** Represents a field within an item. */
|
|
392
|
+
export interface ItemField {
|
|
393
|
+
/** The field's ID */
|
|
394
|
+
id: string;
|
|
395
|
+
/** The field's title */
|
|
396
|
+
title: string;
|
|
397
|
+
/** The ID of the section containing the field. Built-in fields such as usernames and passwords don't require a section. */
|
|
398
|
+
sectionId?: string;
|
|
399
|
+
/** The field's type */
|
|
400
|
+
fieldType: ItemFieldType;
|
|
401
|
+
/** The string representation of the field's value */
|
|
402
|
+
value: string;
|
|
403
|
+
/** Field type-specific attributes. */
|
|
404
|
+
details?: ItemFieldDetails;
|
|
405
|
+
}
|
|
406
|
+
/** A section groups together multiple fields in an item. */
|
|
407
|
+
export interface ItemSection {
|
|
408
|
+
/** The section's unique ID */
|
|
409
|
+
id: string;
|
|
410
|
+
/** The section's title */
|
|
411
|
+
title: string;
|
|
412
|
+
}
|
|
413
|
+
/**
|
|
414
|
+
* Controls the auto-fill behavior of a website.
|
|
415
|
+
*
|
|
416
|
+
*
|
|
417
|
+
* For more information, visit <https://support.1password.com/autofill-behavior/>
|
|
418
|
+
*/
|
|
419
|
+
export declare enum AutofillBehavior {
|
|
420
|
+
/** Auto-fill any page that’s part of the website, including subdomains */
|
|
421
|
+
AnywhereOnWebsite = "AnywhereOnWebsite",
|
|
422
|
+
/** Auto-fill only if the domain (hostname and port) is an exact match. */
|
|
423
|
+
ExactDomain = "ExactDomain",
|
|
424
|
+
/** Never auto-fill on this website */
|
|
425
|
+
Never = "Never"
|
|
426
|
+
}
|
|
427
|
+
export interface Website {
|
|
428
|
+
/** The website URL */
|
|
429
|
+
url: string;
|
|
430
|
+
/** The label of the website, e.g. 'website', 'sign-in address' */
|
|
431
|
+
label: string;
|
|
432
|
+
/**
|
|
433
|
+
* The auto-fill behavior of the website
|
|
434
|
+
*
|
|
435
|
+
* For more information, visit <https://support.1password.com/autofill-behavior/>
|
|
436
|
+
*/
|
|
437
|
+
autofillBehavior: AutofillBehavior;
|
|
438
|
+
}
|
|
439
|
+
export interface ItemFile {
|
|
440
|
+
/** the attributes of the file */
|
|
441
|
+
attributes: FileAttributes;
|
|
442
|
+
/** the section id where the file should be stored */
|
|
443
|
+
sectionId: string;
|
|
444
|
+
/** the field id where the file should be stored */
|
|
445
|
+
fieldId: string;
|
|
446
|
+
}
|
|
447
|
+
/** Represents an active 1Password item. */
|
|
448
|
+
export interface Item {
|
|
449
|
+
/** The item's ID */
|
|
450
|
+
id: string;
|
|
451
|
+
/** The item's title */
|
|
452
|
+
title: string;
|
|
453
|
+
/** The item's category */
|
|
454
|
+
category: ItemCategory;
|
|
455
|
+
/** The ID of the vault where the item is saved */
|
|
456
|
+
vaultId: string;
|
|
457
|
+
/** The item's fields */
|
|
458
|
+
fields: ItemField[];
|
|
459
|
+
/** The item's sections */
|
|
460
|
+
sections: ItemSection[];
|
|
461
|
+
/** The notes of the item */
|
|
462
|
+
notes: string;
|
|
463
|
+
/** The item's tags */
|
|
464
|
+
tags: string[];
|
|
465
|
+
/** The websites used for autofilling for items of the Login and Password categories. */
|
|
466
|
+
websites: Website[];
|
|
467
|
+
/** The item's version */
|
|
468
|
+
version: number;
|
|
469
|
+
/** The item's file fields */
|
|
470
|
+
files: ItemFile[];
|
|
471
|
+
/** The document file for the Document item category */
|
|
472
|
+
document?: FileAttributes;
|
|
473
|
+
/** The time the item was created at */
|
|
474
|
+
createdAt: Date;
|
|
475
|
+
/** The time the item was updated at */
|
|
476
|
+
updatedAt: Date;
|
|
477
|
+
}
|
|
478
|
+
export interface ItemCreateParams {
|
|
479
|
+
/** The item's category */
|
|
480
|
+
category: ItemCategory;
|
|
481
|
+
/** The ID of the vault where the item is saved */
|
|
482
|
+
vaultId: string;
|
|
483
|
+
/** The item's title */
|
|
484
|
+
title: string;
|
|
485
|
+
/** The item's fields */
|
|
486
|
+
fields?: ItemField[];
|
|
487
|
+
/** The item's sections */
|
|
488
|
+
sections?: ItemSection[];
|
|
489
|
+
/** The item's notes */
|
|
490
|
+
notes?: string;
|
|
491
|
+
/** The item's tags */
|
|
492
|
+
tags?: string[];
|
|
493
|
+
/** The websites used for autofilling for items of the Login and Password categories. */
|
|
494
|
+
websites?: Website[];
|
|
495
|
+
/** The item's files stored as fields */
|
|
496
|
+
files?: FileCreateParams[];
|
|
497
|
+
/** The document file for the Document item type. Empty when the item isn't of Document type. */
|
|
498
|
+
document?: DocumentCreateParams;
|
|
499
|
+
}
|
|
500
|
+
/** Represents the state of an item in the SDK. */
|
|
501
|
+
export declare enum ItemState {
|
|
502
|
+
/** The item is active */
|
|
503
|
+
Active = "active",
|
|
504
|
+
/** The item is archived meaning it's hidden from regular view and stored in the archive. */
|
|
505
|
+
Archived = "archived"
|
|
506
|
+
}
|
|
507
|
+
/** Represents a decrypted 1Password item overview. */
|
|
508
|
+
export interface ItemOverview {
|
|
509
|
+
/** The item's ID */
|
|
510
|
+
id: string;
|
|
511
|
+
/** The item's title */
|
|
512
|
+
title: string;
|
|
513
|
+
/** The item's category */
|
|
514
|
+
category: ItemCategory;
|
|
515
|
+
/** The ID of the vault where the item is saved */
|
|
516
|
+
vaultId: string;
|
|
517
|
+
/** The websites used for autofilling for items of the Login and Password categories. */
|
|
518
|
+
websites: Website[];
|
|
519
|
+
/** The item tags */
|
|
520
|
+
tags: string[];
|
|
521
|
+
/** The time the item was created at */
|
|
522
|
+
createdAt: Date;
|
|
523
|
+
/** The time the item was updated at */
|
|
524
|
+
updatedAt: Date;
|
|
525
|
+
/** Indicates the state of the item */
|
|
526
|
+
state: ItemState;
|
|
527
|
+
}
|
|
528
|
+
/** The valid duration options for sharing an item */
|
|
529
|
+
export declare enum ItemShareDuration {
|
|
530
|
+
/** The share will expire in one hour */
|
|
531
|
+
OneHour = "OneHour",
|
|
532
|
+
/** The share will expire in one day */
|
|
533
|
+
OneDay = "OneDay",
|
|
534
|
+
/** The share will expire in seven days */
|
|
535
|
+
SevenDays = "SevenDays",
|
|
536
|
+
/** The share will expire in fourteen days */
|
|
537
|
+
FourteenDays = "FourteenDays",
|
|
538
|
+
/** The share will expire in thirty days */
|
|
539
|
+
ThirtyDays = "ThirtyDays"
|
|
540
|
+
}
|
|
541
|
+
/** The allowed types of item sharing, enforced by account policy */
|
|
542
|
+
export declare enum AllowedType {
|
|
543
|
+
/** Allows creating share links with specific recipients */
|
|
544
|
+
Authenticated = "Authenticated",
|
|
545
|
+
/** Allows creating public share links */
|
|
546
|
+
Public = "Public"
|
|
547
|
+
}
|
|
548
|
+
/** The allowed recipient types of item sharing, enforced by account policy */
|
|
549
|
+
export declare enum AllowedRecipientType {
|
|
550
|
+
/** Recipients can be specified by email address */
|
|
551
|
+
Email = "Email",
|
|
552
|
+
/** Recipients can be specified by domain */
|
|
553
|
+
Domain = "Domain"
|
|
554
|
+
}
|
|
555
|
+
/** The file sharing policy */
|
|
556
|
+
export interface ItemShareFiles {
|
|
557
|
+
/** Whether files can be included in item shares */
|
|
558
|
+
allowed: boolean;
|
|
559
|
+
/** The maximum encrypted size (in bytes) an included file can be */
|
|
560
|
+
maxSize: number;
|
|
561
|
+
/** The allowed types of item sharing - either "Authenticated" (share to specific users) or "Public" (share to anyone with a link) */
|
|
562
|
+
allowedTypes?: AllowedType[];
|
|
563
|
+
/** The allowed recipient types of item sharing - either "Email" or "Domain" */
|
|
564
|
+
allowedRecipientTypes?: AllowedRecipientType[];
|
|
565
|
+
/** The maximum duration that an item can be shared for */
|
|
566
|
+
maxExpiry?: ItemShareDuration;
|
|
567
|
+
/** The default duration that an item is shared for */
|
|
568
|
+
defaultExpiry?: ItemShareDuration;
|
|
569
|
+
/** The maximum number of times an item can be viewed. A null value means unlimited views */
|
|
570
|
+
maxViews?: number;
|
|
571
|
+
}
|
|
572
|
+
/**
|
|
573
|
+
* The account policy for sharing items, set by your account owner/admin
|
|
574
|
+
* This policy is enforced server-side when sharing items
|
|
575
|
+
*/
|
|
576
|
+
export interface ItemShareAccountPolicy {
|
|
577
|
+
/** The maximum duration that an item can be shared for */
|
|
578
|
+
maxExpiry: ItemShareDuration;
|
|
579
|
+
/** The default duration that an item is shared for */
|
|
580
|
+
defaultExpiry: ItemShareDuration;
|
|
581
|
+
/** The maximum number of times an item can be viewed. A null value means unlimited views */
|
|
582
|
+
maxViews?: number;
|
|
583
|
+
/** The allowed types of item sharing - either "Authenticated" (share to specific users) or "Public" (share to anyone with a link) */
|
|
584
|
+
allowedTypes: AllowedType[];
|
|
585
|
+
/** The allowed recipient types of item sharing - either "Email" or "Domain" */
|
|
586
|
+
allowedRecipientTypes: AllowedRecipientType[];
|
|
587
|
+
/** The file sharing policy */
|
|
588
|
+
files: ItemShareFiles;
|
|
589
|
+
}
|
|
590
|
+
/** The validated recipient of an item share */
|
|
591
|
+
export type ValidRecipient =
|
|
592
|
+
/** This exact email address */
|
|
593
|
+
{
|
|
594
|
+
type: "Email";
|
|
595
|
+
parameters: {
|
|
596
|
+
email: string;
|
|
597
|
+
};
|
|
598
|
+
}
|
|
599
|
+
/** Anyone with an email address from the specified domain */
|
|
600
|
+
| {
|
|
601
|
+
type: "Domain";
|
|
602
|
+
parameters: {
|
|
603
|
+
domain: string;
|
|
604
|
+
};
|
|
605
|
+
};
|
|
606
|
+
/**
|
|
607
|
+
* The configuration options for sharing an item
|
|
608
|
+
* These must respect the account policy on item sharing
|
|
609
|
+
*/
|
|
610
|
+
export interface ItemShareParams {
|
|
611
|
+
/** Emails or domains of the item share recipients. If not provided, everyone with the share link will have access */
|
|
612
|
+
recipients?: ValidRecipient[];
|
|
613
|
+
/** The duration of the share in seconds. If not provided, defaults to the account policy's default expiry */
|
|
614
|
+
expireAfter?: ItemShareDuration;
|
|
615
|
+
/** Whether the item can only be viewed once per recipient */
|
|
616
|
+
oneTimeOnly: boolean;
|
|
617
|
+
}
|
|
618
|
+
export interface Response<T, E> {
|
|
619
|
+
content?: T;
|
|
620
|
+
error?: E;
|
|
621
|
+
}
|
|
622
|
+
export type ItemUpdateFailureReason =
|
|
623
|
+
/** Item update operation failed due to bad user input. */
|
|
624
|
+
{
|
|
625
|
+
type: "itemValidationError";
|
|
626
|
+
message: ErrorMessage;
|
|
627
|
+
}
|
|
628
|
+
/** Item update operation is forbidden, permission issue. Make sure you have the correct permissions to update items in this vault. */
|
|
629
|
+
| {
|
|
630
|
+
type: "itemStatusPermissionError";
|
|
631
|
+
message?: undefined;
|
|
632
|
+
}
|
|
633
|
+
/** Item update operation failed due to incorrect version. */
|
|
634
|
+
| {
|
|
635
|
+
type: "itemStatusIncorrectItemVersion";
|
|
636
|
+
message?: undefined;
|
|
637
|
+
}
|
|
638
|
+
/** Item update operation failed because a file reference didn't match a known file. */
|
|
639
|
+
| {
|
|
640
|
+
type: "itemStatusFileNotFound";
|
|
641
|
+
message?: undefined;
|
|
642
|
+
}
|
|
643
|
+
/** Item update request is too big to be sent to the server. */
|
|
644
|
+
| {
|
|
645
|
+
type: "itemStatusTooBig";
|
|
646
|
+
message?: undefined;
|
|
647
|
+
}
|
|
648
|
+
/** The item was not found */
|
|
649
|
+
| {
|
|
650
|
+
type: "itemNotFound";
|
|
651
|
+
message?: undefined;
|
|
652
|
+
}
|
|
653
|
+
/** Item update operation experienced an internal error. */
|
|
654
|
+
| {
|
|
655
|
+
type: "internal";
|
|
656
|
+
message: ErrorMessage;
|
|
657
|
+
};
|
|
658
|
+
export interface ItemsDeleteAllResponse {
|
|
659
|
+
individualResponses: Record<string, Response<undefined, ItemUpdateFailureReason>>;
|
|
660
|
+
}
|
|
661
|
+
export type ItemsGetAllError = {
|
|
662
|
+
type: "itemNotFound";
|
|
663
|
+
message?: undefined;
|
|
664
|
+
} | {
|
|
665
|
+
type: "internal";
|
|
666
|
+
message: ErrorMessage;
|
|
667
|
+
};
|
|
668
|
+
export interface ItemsGetAllResponse {
|
|
669
|
+
individualResponses: Response<Item, ItemsGetAllError>[];
|
|
670
|
+
}
|
|
671
|
+
export interface ItemsUpdateAllResponse {
|
|
672
|
+
individualResponses: Response<Item, ItemUpdateFailureReason>[];
|
|
673
|
+
}
|
|
674
|
+
/**
|
|
675
|
+
* A login credential brokered by 1Password.
|
|
676
|
+
* Fields are none when the corresponding item field doesn't exist.
|
|
677
|
+
*
|
|
678
|
+
* Returned by
|
|
679
|
+
* [`Logins::read`](crate::client::Logins::read).
|
|
680
|
+
*/
|
|
681
|
+
export interface LoginCredential {
|
|
682
|
+
/** The login's username. */
|
|
683
|
+
username?: string;
|
|
684
|
+
/** The login's password. */
|
|
685
|
+
password?: string;
|
|
686
|
+
/** Current one-time-password code, if the login has a TOTP field. */
|
|
687
|
+
totp?: string;
|
|
688
|
+
}
|
|
689
|
+
/**
|
|
690
|
+
* Non-secret details for a brokered login.
|
|
691
|
+
*
|
|
692
|
+
* Returned by
|
|
693
|
+
* [`Login::get_details`](crate::client::Login::get_details).
|
|
694
|
+
*/
|
|
695
|
+
export interface LoginDetails {
|
|
696
|
+
/** Website URLs associated with the login. */
|
|
697
|
+
websites: string[];
|
|
698
|
+
}
|
|
699
|
+
/** Additional attributes for OTP fields. */
|
|
700
|
+
export interface OtpFieldDetails {
|
|
701
|
+
/** The OTP code, if successfully computed */
|
|
702
|
+
code?: string;
|
|
703
|
+
/** The error message, if the OTP code could not be computed */
|
|
704
|
+
errorMessage?: string;
|
|
705
|
+
}
|
|
706
|
+
export interface ResolvedReference {
|
|
707
|
+
secret: string;
|
|
708
|
+
itemId: string;
|
|
709
|
+
vaultId: string;
|
|
710
|
+
}
|
|
711
|
+
export type ResolveReferenceError =
|
|
712
|
+
/** Error parsing the secret reference */
|
|
713
|
+
{
|
|
714
|
+
type: "parsing";
|
|
715
|
+
message: ErrorMessage;
|
|
716
|
+
}
|
|
717
|
+
/** The specified reference cannot be found within the item */
|
|
718
|
+
| {
|
|
719
|
+
type: "fieldNotFound";
|
|
720
|
+
message?: undefined;
|
|
721
|
+
}
|
|
722
|
+
/** No vault matched the secret reference query */
|
|
723
|
+
| {
|
|
724
|
+
type: "vaultNotFound";
|
|
725
|
+
message?: undefined;
|
|
726
|
+
}
|
|
727
|
+
/** More than one vault matched the secret reference query */
|
|
728
|
+
| {
|
|
729
|
+
type: "tooManyVaults";
|
|
730
|
+
message?: undefined;
|
|
731
|
+
}
|
|
732
|
+
/** No item matched the secret reference query */
|
|
733
|
+
| {
|
|
734
|
+
type: "itemNotFound";
|
|
735
|
+
message?: undefined;
|
|
736
|
+
}
|
|
737
|
+
/** More than one item matched the secret reference query */
|
|
738
|
+
| {
|
|
739
|
+
type: "tooManyItems";
|
|
740
|
+
message?: undefined;
|
|
741
|
+
}
|
|
742
|
+
/** More than one field matched the provided secret reference */
|
|
743
|
+
| {
|
|
744
|
+
type: "tooManyMatchingFields";
|
|
745
|
+
message?: undefined;
|
|
746
|
+
}
|
|
747
|
+
/** No section found within the item for the provided identifier */
|
|
748
|
+
| {
|
|
749
|
+
type: "noMatchingSections";
|
|
750
|
+
message?: undefined;
|
|
751
|
+
}
|
|
752
|
+
/** Incompatiable TOTP query parameters */
|
|
753
|
+
| {
|
|
754
|
+
type: "incompatibleTOTPQueryParameterField";
|
|
755
|
+
message?: undefined;
|
|
756
|
+
}
|
|
757
|
+
/** The totp was not able to be generated */
|
|
758
|
+
| {
|
|
759
|
+
type: "unableToGenerateTotpCode";
|
|
760
|
+
message: ErrorMessage;
|
|
761
|
+
}
|
|
762
|
+
/** Couldn't find attributes specific to an SSH Key field */
|
|
763
|
+
| {
|
|
764
|
+
type: "sSHKeyMetadataNotFound";
|
|
765
|
+
message?: undefined;
|
|
766
|
+
}
|
|
767
|
+
/** Currently only support text files */
|
|
768
|
+
| {
|
|
769
|
+
type: "unsupportedFileFormat";
|
|
770
|
+
message?: undefined;
|
|
771
|
+
}
|
|
772
|
+
/** Trying to convert a non-private key to a private key format */
|
|
773
|
+
| {
|
|
774
|
+
type: "incompatibleSshKeyQueryParameterField";
|
|
775
|
+
message?: undefined;
|
|
776
|
+
}
|
|
777
|
+
/** Unable to properly parse a private key string to convert to an internal Private Key type */
|
|
778
|
+
| {
|
|
779
|
+
type: "unableToParsePrivateKey";
|
|
780
|
+
message?: undefined;
|
|
781
|
+
}
|
|
782
|
+
/** Unable to format a private key to OpenSSH format */
|
|
783
|
+
| {
|
|
784
|
+
type: "unableToFormatPrivateKeyToOpenSsh";
|
|
785
|
+
message?: undefined;
|
|
786
|
+
}
|
|
787
|
+
/** Other type */
|
|
788
|
+
| {
|
|
789
|
+
type: "other";
|
|
790
|
+
message?: undefined;
|
|
791
|
+
};
|
|
792
|
+
export interface ResolveAllResponse {
|
|
793
|
+
individualResponses: Record<string, Response<ResolvedReference, ResolveReferenceError>>;
|
|
794
|
+
}
|
|
795
|
+
export interface SshKeyAttributes {
|
|
796
|
+
/** The public part of the SSH Key */
|
|
797
|
+
publicKey: string;
|
|
798
|
+
/** The fingerprint of the SSH Key */
|
|
799
|
+
fingerprint: string;
|
|
800
|
+
/** The key type ("Ed25519" or "RSA, {length}-bit") */
|
|
801
|
+
keyType: string;
|
|
802
|
+
}
|
|
803
|
+
/** Represents the vault type. */
|
|
804
|
+
export declare enum VaultType {
|
|
805
|
+
Personal = "personal",
|
|
806
|
+
Everyone = "everyone",
|
|
807
|
+
Transfer = "transfer",
|
|
808
|
+
UserCreated = "userCreated",
|
|
809
|
+
Unsupported = "unsupported"
|
|
810
|
+
}
|
|
811
|
+
/** Represents regular vault information together with the vault's access information. */
|
|
812
|
+
export interface Vault {
|
|
813
|
+
/** The vault's ID. */
|
|
814
|
+
id: string;
|
|
815
|
+
/** The vault's title. */
|
|
816
|
+
title: string;
|
|
817
|
+
/** The description of the vault. */
|
|
818
|
+
description: string;
|
|
819
|
+
/** The type of the vault. */
|
|
820
|
+
vaultType: VaultType;
|
|
821
|
+
/** The number of active items within the vault. */
|
|
822
|
+
activeItemCount: number;
|
|
823
|
+
/** The content version number of the vault. It gets incremented whenever the state of the vault's contents changes (e.g. items from within the vault get created or updated). */
|
|
824
|
+
contentVersion: number;
|
|
825
|
+
/** The attribute version number of the vault. It gets incremented whenever vault presentation information changes, such as its name or icon. */
|
|
826
|
+
attributeVersion: number;
|
|
827
|
+
/** The access information associated with the vault. */
|
|
828
|
+
access?: VaultAccess[];
|
|
829
|
+
}
|
|
830
|
+
export interface VaultCreateParams {
|
|
831
|
+
title: string;
|
|
832
|
+
description?: string;
|
|
833
|
+
allowAdminsAccess?: boolean;
|
|
834
|
+
}
|
|
835
|
+
/** Represents the possible query parameters used for retrieving extra information about a vault. */
|
|
836
|
+
export interface VaultGetParams {
|
|
837
|
+
/** The vault's accessor params. */
|
|
838
|
+
accessors?: boolean;
|
|
839
|
+
}
|
|
840
|
+
export interface VaultListParams {
|
|
841
|
+
decryptDetails?: boolean;
|
|
842
|
+
}
|
|
843
|
+
/** Holds information about a 1Password Vault. */
|
|
844
|
+
export interface VaultOverview {
|
|
845
|
+
/** The vault's ID. */
|
|
846
|
+
id: string;
|
|
847
|
+
/** The vault's title. */
|
|
848
|
+
title: string;
|
|
849
|
+
/** The description of this vault. */
|
|
850
|
+
description: string;
|
|
851
|
+
/** The type of the vault. */
|
|
852
|
+
vaultType: VaultType;
|
|
853
|
+
/** The number of active items within the vault. */
|
|
854
|
+
activeItemCount: number;
|
|
855
|
+
/** The content version number of the vault. It gets incremented whenever the state of the vault's contents changes (e.g. items from within the vault get created or updated). */
|
|
856
|
+
contentVersion: number;
|
|
857
|
+
/** The attribute version number of the vault. It gets incremented whenever vault presentation information changes, such as its name or icon. */
|
|
858
|
+
attributeVersion: number;
|
|
859
|
+
/** The time the vault was created at */
|
|
860
|
+
createdAt: Date;
|
|
861
|
+
/** The time the vault was updated at */
|
|
862
|
+
updatedAt: Date;
|
|
863
|
+
}
|
|
864
|
+
export interface VaultUpdateParams {
|
|
865
|
+
title?: string;
|
|
866
|
+
description?: string;
|
|
867
|
+
}
|
|
868
|
+
export type ItemListFilter = {
|
|
869
|
+
type: "ByState";
|
|
870
|
+
content: {
|
|
871
|
+
active: boolean;
|
|
872
|
+
archived: boolean;
|
|
873
|
+
};
|
|
874
|
+
};
|
|
875
|
+
export type PasswordRecipe = {
|
|
876
|
+
type: "Memorable";
|
|
877
|
+
parameters: {
|
|
878
|
+
/** The type of separator between chunks. */
|
|
879
|
+
separatorType: SeparatorType;
|
|
880
|
+
/** Uppercase one randomly selected chunk. */
|
|
881
|
+
capitalize: boolean;
|
|
882
|
+
/** The type of word list used. */
|
|
883
|
+
wordListType: WordListType;
|
|
884
|
+
/** The number of "words" (words or syllables). */
|
|
885
|
+
wordCount: number;
|
|
886
|
+
};
|
|
887
|
+
} | {
|
|
888
|
+
type: "Pin";
|
|
889
|
+
parameters: {
|
|
890
|
+
/** Number of digits in the PIN. */
|
|
891
|
+
length: number;
|
|
892
|
+
};
|
|
893
|
+
} | {
|
|
894
|
+
type: "Random";
|
|
895
|
+
parameters: {
|
|
896
|
+
/** Include at least one digit in the password. */
|
|
897
|
+
includeDigits: boolean;
|
|
898
|
+
/** Include at least one symbol in the password. */
|
|
899
|
+
includeSymbols: boolean;
|
|
900
|
+
/** The length of the password. */
|
|
901
|
+
length: number;
|
|
902
|
+
};
|
|
903
|
+
};
|
|
904
|
+
export declare enum SeparatorType {
|
|
905
|
+
/**
|
|
906
|
+
* Randomly selected digits.
|
|
907
|
+
* E.g, "`correct4horse0battery1staple`"
|
|
908
|
+
*/
|
|
909
|
+
Digits = "digits",
|
|
910
|
+
/**
|
|
911
|
+
* Randomly selected digits and symbols.
|
|
912
|
+
* This is useful to get word-based passwords to meet complexity requirements
|
|
913
|
+
* E.g, "`correct4horse-battery1staple`"
|
|
914
|
+
*/
|
|
915
|
+
DigitsAndSymbols = "digitsAndSymbols",
|
|
916
|
+
/**
|
|
917
|
+
* Spaces, like the original Diceware.
|
|
918
|
+
* Great for mobile keyboards, not so great when people can overhear you type the password.
|
|
919
|
+
* E.g, "`correct horse battery staple`"
|
|
920
|
+
*/
|
|
921
|
+
Spaces = "spaces",
|
|
922
|
+
/**
|
|
923
|
+
* Hyphens "`-`".
|
|
924
|
+
* E.g, "`correct-horse-battery-staple`"
|
|
925
|
+
*/
|
|
926
|
+
Hyphens = "hyphens",
|
|
927
|
+
/**
|
|
928
|
+
* "`_`".
|
|
929
|
+
* E.g, "`correct_horse_battery_staple`"
|
|
930
|
+
*/
|
|
931
|
+
Underscores = "underscores",
|
|
932
|
+
/**
|
|
933
|
+
* Period (full stop) "`.`".
|
|
934
|
+
* E.g, "`correct.horse.battery.staple`"
|
|
935
|
+
*/
|
|
936
|
+
Periods = "periods",
|
|
937
|
+
/**
|
|
938
|
+
* Comma "`,`".
|
|
939
|
+
* E.g, "`correct,horse,battery,staple`"
|
|
940
|
+
*/
|
|
941
|
+
Commas = "commas"
|
|
942
|
+
}
|
|
943
|
+
export declare enum WordListType {
|
|
944
|
+
/** Agile wordlist */
|
|
945
|
+
FullWords = "fullWords",
|
|
946
|
+
/** English-like syllables */
|
|
947
|
+
Syllables = "syllables",
|
|
948
|
+
/** Three (random) letter "words" */
|
|
949
|
+
ThreeLetters = "threeLetters"
|
|
950
|
+
}
|
|
951
|
+
export declare const ARCHIVE_ITEMS: number;
|
|
952
|
+
export declare const CREATE_ITEMS: number;
|
|
953
|
+
export declare const DELETE_ITEMS: number;
|
|
954
|
+
export declare const EXPORT_ITEMS: number;
|
|
955
|
+
export declare const IMPORT_ITEMS: number;
|
|
956
|
+
export declare const MANAGE_VAULT: number;
|
|
957
|
+
export declare const NO_ACCESS: number;
|
|
958
|
+
export declare const PRINT_ITEMS: number;
|
|
959
|
+
export declare const READ_ITEMS: number;
|
|
960
|
+
export declare const RECOVER_VAULT: number;
|
|
961
|
+
export declare const REVEAL_ITEM_PASSWORD: number;
|
|
962
|
+
export declare const SEND_ITEMS: number;
|
|
963
|
+
export declare const UPDATE_ITEMS: number;
|
|
964
|
+
export declare const UPDATE_ITEM_HISTORY: number;
|
|
965
|
+
/**
|
|
966
|
+
* Custom JSON reviver and replacer functions for dynamic data transformation
|
|
967
|
+
* ReviverFunc is used during JSON parsing to detect and transform specific data structures
|
|
968
|
+
* ReplacerFunc is used during JSON serialization to modify certain values before stringifying.
|
|
969
|
+
* These functions allow for flexible encoding and decoding of data, ensuring that complex types are properly handled when converting between TS objects and JSON
|
|
970
|
+
*/
|
|
971
|
+
export declare const ReviverFunc: (key: string, value: unknown) => unknown;
|
|
972
|
+
export declare const ReplacerFunc: (key: string, value: unknown) => unknown;
|