@mobilerun/sdk 6.0.1 → 6.1.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.
- package/CHANGELOG.md +8 -0
- package/package.json +1 -1
- package/resources/assistant/conversations.d.mts +1 -0
- package/resources/assistant/conversations.d.mts.map +1 -1
- package/resources/assistant/conversations.d.ts +1 -0
- package/resources/assistant/conversations.d.ts.map +1 -1
- package/resources/connect/connect.d.mts +2 -2
- package/resources/connect/connect.d.mts.map +1 -1
- package/resources/connect/connect.d.ts +2 -2
- package/resources/connect/connect.d.ts.map +1 -1
- package/resources/connect/connect.js.map +1 -1
- package/resources/connect/connect.mjs.map +1 -1
- package/resources/connect/index.d.mts +1 -1
- package/resources/connect/index.d.mts.map +1 -1
- package/resources/connect/index.d.ts +1 -1
- package/resources/connect/index.d.ts.map +1 -1
- package/resources/connect/index.js.map +1 -1
- package/resources/connect/index.mjs.map +1 -1
- package/resources/connect/proxies.d.mts +22 -1
- package/resources/connect/proxies.d.mts.map +1 -1
- package/resources/connect/proxies.d.ts +22 -1
- package/resources/connect/proxies.d.ts.map +1 -1
- package/resources/connect/proxies.js +8 -0
- package/resources/connect/proxies.js.map +1 -1
- package/resources/connect/proxies.mjs +8 -0
- package/resources/connect/proxies.mjs.map +1 -1
- package/resources/credentials/credentials.d.mts +20 -0
- package/resources/credentials/credentials.d.mts.map +1 -1
- package/resources/credentials/credentials.d.ts +20 -0
- package/resources/credentials/credentials.d.ts.map +1 -1
- package/resources/credentials/credentials.js +4 -0
- package/resources/credentials/credentials.js.map +1 -1
- package/resources/credentials/credentials.mjs +4 -0
- package/resources/credentials/credentials.mjs.map +1 -1
- package/resources/credentials/index.d.mts +1 -0
- package/resources/credentials/index.d.mts.map +1 -1
- package/resources/credentials/index.d.ts +1 -0
- package/resources/credentials/index.d.ts.map +1 -1
- package/resources/credentials/index.js +5 -3
- package/resources/credentials/index.js.map +1 -1
- package/resources/credentials/index.mjs +1 -0
- package/resources/credentials/index.mjs.map +1 -1
- package/resources/credentials/onepassword/index.d.mts +3 -0
- package/resources/credentials/onepassword/index.d.mts.map +1 -0
- package/resources/credentials/onepassword/index.d.ts +3 -0
- package/resources/credentials/onepassword/index.d.ts.map +1 -0
- package/resources/credentials/onepassword/index.js +9 -0
- package/resources/credentials/onepassword/index.js.map +1 -0
- package/resources/credentials/onepassword/index.mjs +4 -0
- package/resources/credentials/onepassword/index.mjs.map +1 -0
- package/resources/credentials/onepassword/onepassword.d.mts +65 -0
- package/resources/credentials/onepassword/onepassword.d.mts.map +1 -0
- package/resources/credentials/onepassword/onepassword.d.ts +65 -0
- package/resources/credentials/onepassword/onepassword.d.ts.map +1 -0
- package/resources/credentials/onepassword/onepassword.js +35 -0
- package/resources/credentials/onepassword/onepassword.js.map +1 -0
- package/resources/credentials/onepassword/onepassword.mjs +30 -0
- package/resources/credentials/onepassword/onepassword.mjs.map +1 -0
- package/resources/credentials/onepassword/vaults/index.d.mts +3 -0
- package/resources/credentials/onepassword/vaults/index.d.mts.map +1 -0
- package/resources/credentials/onepassword/vaults/index.d.ts +3 -0
- package/resources/credentials/onepassword/vaults/index.d.ts.map +1 -0
- package/resources/credentials/onepassword/vaults/index.js +9 -0
- package/resources/credentials/onepassword/vaults/index.js.map +1 -0
- package/resources/credentials/onepassword/vaults/index.mjs +4 -0
- package/resources/credentials/onepassword/vaults/index.mjs.map +1 -0
- package/resources/credentials/onepassword/vaults/items/fields.d.mts +27 -0
- package/resources/credentials/onepassword/vaults/items/fields.d.mts.map +1 -0
- package/resources/credentials/onepassword/vaults/items/fields.d.ts +27 -0
- package/resources/credentials/onepassword/vaults/items/fields.d.ts.map +1 -0
- package/resources/credentials/onepassword/vaults/items/fields.js +17 -0
- package/resources/credentials/onepassword/vaults/items/fields.js.map +1 -0
- package/resources/credentials/onepassword/vaults/items/fields.mjs +13 -0
- package/resources/credentials/onepassword/vaults/items/fields.mjs.map +1 -0
- package/resources/credentials/onepassword/vaults/items/index.d.mts +3 -0
- package/resources/credentials/onepassword/vaults/items/index.d.mts.map +1 -0
- package/resources/credentials/onepassword/vaults/items/index.d.ts +3 -0
- package/resources/credentials/onepassword/vaults/items/index.d.ts.map +1 -0
- package/resources/credentials/onepassword/vaults/items/index.js +9 -0
- package/resources/credentials/onepassword/vaults/items/index.js.map +1 -0
- package/resources/credentials/onepassword/vaults/items/index.mjs +4 -0
- package/resources/credentials/onepassword/vaults/items/index.mjs.map +1 -0
- package/resources/credentials/onepassword/vaults/items/items.d.mts +34 -0
- package/resources/credentials/onepassword/vaults/items/items.d.mts.map +1 -0
- package/resources/credentials/onepassword/vaults/items/items.d.ts +34 -0
- package/resources/credentials/onepassword/vaults/items/items.d.ts.map +1 -0
- package/resources/credentials/onepassword/vaults/items/items.js +24 -0
- package/resources/credentials/onepassword/vaults/items/items.js.map +1 -0
- package/resources/credentials/onepassword/vaults/items/items.mjs +19 -0
- package/resources/credentials/onepassword/vaults/items/items.mjs.map +1 -0
- package/resources/credentials/onepassword/vaults/items.d.mts +2 -0
- package/resources/credentials/onepassword/vaults/items.d.mts.map +1 -0
- package/resources/credentials/onepassword/vaults/items.d.ts +2 -0
- package/resources/credentials/onepassword/vaults/items.d.ts.map +1 -0
- package/resources/credentials/onepassword/vaults/items.js +6 -0
- package/resources/credentials/onepassword/vaults/items.js.map +1 -0
- package/resources/credentials/onepassword/vaults/items.mjs +3 -0
- package/resources/credentials/onepassword/vaults/items.mjs.map +1 -0
- package/resources/credentials/onepassword/vaults/vaults.d.mts +10 -0
- package/resources/credentials/onepassword/vaults/vaults.d.mts.map +1 -0
- package/resources/credentials/onepassword/vaults/vaults.d.ts +10 -0
- package/resources/credentials/onepassword/vaults/vaults.d.ts.map +1 -0
- package/resources/credentials/onepassword/vaults/vaults.js +17 -0
- package/resources/credentials/onepassword/vaults/vaults.js.map +1 -0
- package/resources/credentials/onepassword/vaults/vaults.mjs +12 -0
- package/resources/credentials/onepassword/vaults/vaults.mjs.map +1 -0
- package/resources/credentials/onepassword/vaults.d.mts +2 -0
- package/resources/credentials/onepassword/vaults.d.mts.map +1 -0
- package/resources/credentials/onepassword/vaults.d.ts +2 -0
- package/resources/credentials/onepassword/vaults.d.ts.map +1 -0
- package/resources/credentials/onepassword/vaults.js +6 -0
- package/resources/credentials/onepassword/vaults.js.map +1 -0
- package/resources/credentials/onepassword/vaults.mjs +3 -0
- package/resources/credentials/onepassword/vaults.mjs.map +1 -0
- package/resources/credentials/onepassword.d.mts +2 -0
- package/resources/credentials/onepassword.d.mts.map +1 -0
- package/resources/credentials/onepassword.d.ts +2 -0
- package/resources/credentials/onepassword.d.ts.map +1 -0
- package/resources/credentials/onepassword.js +6 -0
- package/resources/credentials/onepassword.js.map +1 -0
- package/resources/credentials/onepassword.mjs +3 -0
- package/resources/credentials/onepassword.mjs.map +1 -0
- package/resources/credentials/packages/credentials/credentials.d.mts +32 -32
- package/resources/credentials/packages/credentials/credentials.d.mts.map +1 -1
- package/resources/credentials/packages/credentials/credentials.d.ts +32 -32
- package/resources/credentials/packages/credentials/credentials.d.ts.map +1 -1
- package/resources/credentials/packages/credentials/credentials.js +0 -8
- package/resources/credentials/packages/credentials/credentials.js.map +1 -1
- package/resources/credentials/packages/credentials/credentials.mjs +0 -8
- package/resources/credentials/packages/credentials/credentials.mjs.map +1 -1
- package/resources/credentials/packages/credentials/fields.d.mts +48 -0
- package/resources/credentials/packages/credentials/fields.d.mts.map +1 -1
- package/resources/credentials/packages/credentials/fields.d.ts +48 -0
- package/resources/credentials/packages/credentials/fields.d.ts.map +1 -1
- package/resources/credentials/packages/credentials/index.d.mts +1 -1
- package/resources/credentials/packages/credentials/index.d.mts.map +1 -1
- package/resources/credentials/packages/credentials/index.d.ts +1 -1
- package/resources/credentials/packages/credentials/index.d.ts.map +1 -1
- package/resources/credentials/packages/credentials/index.js.map +1 -1
- package/resources/credentials/packages/credentials/index.mjs.map +1 -1
- package/resources/credentials/packages/index.d.mts +2 -1
- package/resources/credentials/packages/index.d.mts.map +1 -1
- package/resources/credentials/packages/index.d.ts +2 -1
- package/resources/credentials/packages/index.d.ts.map +1 -1
- package/resources/credentials/packages/index.js +3 -1
- package/resources/credentials/packages/index.js.map +1 -1
- package/resources/credentials/packages/index.mjs +1 -0
- package/resources/credentials/packages/index.mjs.map +1 -1
- package/resources/credentials/packages/links.d.mts +65 -0
- package/resources/credentials/packages/links.d.mts.map +1 -0
- package/resources/credentials/packages/links.d.ts +65 -0
- package/resources/credentials/packages/links.d.ts.map +1 -0
- package/resources/credentials/packages/links.js +16 -0
- package/resources/credentials/packages/links.js.map +1 -0
- package/resources/credentials/packages/links.mjs +12 -0
- package/resources/credentials/packages/links.mjs.map +1 -0
- package/resources/credentials/packages/packages.d.mts +22 -2
- package/resources/credentials/packages/packages.d.mts.map +1 -1
- package/resources/credentials/packages/packages.d.ts +22 -2
- package/resources/credentials/packages/packages.d.ts.map +1 -1
- package/resources/credentials/packages/packages.js +4 -0
- package/resources/credentials/packages/packages.js.map +1 -1
- package/resources/credentials/packages/packages.mjs +4 -0
- package/resources/credentials/packages/packages.mjs.map +1 -1
- package/resources/devices/apps.d.mts +2 -2
- package/resources/devices/apps.d.ts +2 -2
- package/resources/devices/devices.d.mts +43 -28
- package/resources/devices/devices.d.mts.map +1 -1
- package/resources/devices/devices.d.ts +43 -28
- package/resources/devices/devices.d.ts.map +1 -1
- package/resources/devices/devices.js +23 -19
- package/resources/devices/devices.js.map +1 -1
- package/resources/devices/devices.mjs +23 -19
- package/resources/devices/devices.mjs.map +1 -1
- package/resources/devices/keyboard.d.mts +1 -1
- package/resources/devices/keyboard.d.ts +1 -1
- package/resources/devices/language.d.mts +6 -4
- package/resources/devices/language.d.mts.map +1 -1
- package/resources/devices/language.d.ts +6 -4
- package/resources/devices/language.d.ts.map +1 -1
- package/resources/devices/language.js +3 -2
- package/resources/devices/language.js.map +1 -1
- package/resources/devices/language.mjs +3 -2
- package/resources/devices/language.mjs.map +1 -1
- package/resources/devices/state.d.mts +1 -0
- package/resources/devices/state.d.mts.map +1 -1
- package/resources/devices/state.d.ts +1 -0
- package/resources/devices/state.d.ts.map +1 -1
- package/resources/mailboxes/messages.d.mts +13 -0
- package/resources/mailboxes/messages.d.mts.map +1 -1
- package/resources/mailboxes/messages.d.ts +13 -0
- package/resources/mailboxes/messages.d.ts.map +1 -1
- package/resources/mailboxes/messages.js +2 -2
- package/resources/mailboxes/messages.js.map +1 -1
- package/resources/mailboxes/messages.mjs +2 -2
- package/resources/mailboxes/messages.mjs.map +1 -1
- package/resources/messages/conversations.d.mts +6 -0
- package/resources/messages/conversations.d.mts.map +1 -1
- package/resources/messages/conversations.d.ts +6 -0
- package/resources/messages/conversations.d.ts.map +1 -1
- package/resources/messages/messages.d.mts +16 -0
- package/resources/messages/messages.d.mts.map +1 -1
- package/resources/messages/messages.d.ts +16 -0
- package/resources/messages/messages.d.ts.map +1 -1
- package/resources/messages/messages.js.map +1 -1
- package/resources/messages/messages.mjs.map +1 -1
- package/resources/numbers/messages.d.mts +15 -1
- package/resources/numbers/messages.d.mts.map +1 -1
- package/resources/numbers/messages.d.ts +15 -1
- package/resources/numbers/messages.d.ts.map +1 -1
- package/resources/tasks/tasks.d.mts +4 -2
- package/resources/tasks/tasks.d.mts.map +1 -1
- package/resources/tasks/tasks.d.ts +4 -2
- package/resources/tasks/tasks.d.ts.map +1 -1
- package/resources/tasks/tasks.js.map +1 -1
- package/resources/tasks/tasks.mjs.map +1 -1
- package/src/resources/assistant/conversations.ts +2 -0
- package/src/resources/connect/connect.ts +2 -0
- package/src/resources/connect/index.ts +1 -0
- package/src/resources/connect/proxies.ts +27 -0
- package/src/resources/credentials/credentials.ts +51 -0
- package/src/resources/credentials/index.ts +7 -0
- package/src/resources/credentials/onepassword/index.ts +10 -0
- package/src/resources/credentials/onepassword/onepassword.ts +101 -0
- package/src/resources/credentials/onepassword/vaults/index.ts +4 -0
- package/src/resources/credentials/onepassword/vaults/items/fields.ts +40 -0
- package/src/resources/credentials/onepassword/vaults/items/index.ts +4 -0
- package/src/resources/credentials/onepassword/vaults/items/items.ts +55 -0
- package/src/resources/credentials/onepassword/vaults/items.ts +3 -0
- package/src/resources/credentials/onepassword/vaults/vaults.ts +15 -0
- package/src/resources/credentials/onepassword/vaults.ts +3 -0
- package/src/resources/credentials/onepassword.ts +3 -0
- package/src/resources/credentials/packages/credentials/credentials.ts +58 -55
- package/src/resources/credentials/packages/credentials/fields.ts +99 -0
- package/src/resources/credentials/packages/credentials/index.ts +0 -2
- package/src/resources/credentials/packages/index.ts +1 -2
- package/src/resources/credentials/packages/links.ts +122 -0
- package/src/resources/credentials/packages/packages.ts +43 -4
- package/src/resources/devices/apps.ts +2 -2
- package/src/resources/devices/devices.ts +48 -37
- package/src/resources/devices/keyboard.ts +1 -1
- package/src/resources/devices/language.ts +6 -4
- package/src/resources/devices/state.ts +2 -0
- package/src/resources/mailboxes/messages.ts +17 -2
- package/src/resources/messages/conversations.ts +6 -0
- package/src/resources/messages/messages.ts +16 -0
- package/src/resources/numbers/messages.ts +15 -1
- package/src/resources/tasks/tasks.ts +4 -2
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -2,6 +2,14 @@
|
|
|
2
2
|
|
|
3
3
|
import { APIResource } from '../../core/resource';
|
|
4
4
|
import * as Shared from '../shared';
|
|
5
|
+
import * as OnepasswordAPI from './onepassword/onepassword';
|
|
6
|
+
import {
|
|
7
|
+
Onepassword,
|
|
8
|
+
OnepasswordConnectParams,
|
|
9
|
+
OnepasswordConnectResponse,
|
|
10
|
+
OnepasswordDisconnectResponse,
|
|
11
|
+
OnepasswordRetrieveResponse,
|
|
12
|
+
} from './onepassword/onepassword';
|
|
5
13
|
import * as PackagesAPI from './packages/packages';
|
|
6
14
|
import {
|
|
7
15
|
PackageCreateParams,
|
|
@@ -15,6 +23,7 @@ import { RequestOptions } from '../../internal/request-options';
|
|
|
15
23
|
|
|
16
24
|
export class Credentials extends APIResource {
|
|
17
25
|
packages: PackagesAPI.Packages = new PackagesAPI.Packages(this._client);
|
|
26
|
+
onepassword: OnepasswordAPI.Onepassword = new OnepasswordAPI.Onepassword(this._client);
|
|
18
27
|
|
|
19
28
|
/**
|
|
20
29
|
* Returns a paginated list of all credentials belonging to the authenticated user
|
|
@@ -54,6 +63,10 @@ export namespace CredentialListResponse {
|
|
|
54
63
|
* for credentials created before rollout.
|
|
55
64
|
*/
|
|
56
65
|
userId: string | null;
|
|
66
|
+
|
|
67
|
+
link?: Item.Link;
|
|
68
|
+
|
|
69
|
+
source?: 'mobilerun' | 'onepassword';
|
|
57
70
|
}
|
|
58
71
|
|
|
59
72
|
export namespace Item {
|
|
@@ -69,6 +82,35 @@ export namespace CredentialListResponse {
|
|
|
69
82
|
|
|
70
83
|
value: string;
|
|
71
84
|
}
|
|
85
|
+
|
|
86
|
+
export interface Link {
|
|
87
|
+
fieldMap: Array<Link.FieldMap>;
|
|
88
|
+
|
|
89
|
+
itemId: string;
|
|
90
|
+
|
|
91
|
+
itemTitle: string;
|
|
92
|
+
|
|
93
|
+
provider: 'onepassword';
|
|
94
|
+
|
|
95
|
+
vaultId: string;
|
|
96
|
+
|
|
97
|
+
vaultName: string;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
export namespace Link {
|
|
101
|
+
export interface FieldMap {
|
|
102
|
+
fieldId: string;
|
|
103
|
+
|
|
104
|
+
fieldType:
|
|
105
|
+
| 'email'
|
|
106
|
+
| 'username'
|
|
107
|
+
| 'password'
|
|
108
|
+
| 'api_token'
|
|
109
|
+
| 'phone_number'
|
|
110
|
+
| 'two_factor_secret'
|
|
111
|
+
| 'backup_codes';
|
|
112
|
+
}
|
|
113
|
+
}
|
|
72
114
|
}
|
|
73
115
|
}
|
|
74
116
|
|
|
@@ -79,6 +121,7 @@ export interface CredentialListParams {
|
|
|
79
121
|
}
|
|
80
122
|
|
|
81
123
|
Credentials.Packages = Packages;
|
|
124
|
+
Credentials.Onepassword = Onepassword;
|
|
82
125
|
|
|
83
126
|
export declare namespace Credentials {
|
|
84
127
|
export {
|
|
@@ -93,4 +136,12 @@ export declare namespace Credentials {
|
|
|
93
136
|
type PackageListAllResponse as PackageListAllResponse,
|
|
94
137
|
type PackageCreateParams as PackageCreateParams,
|
|
95
138
|
};
|
|
139
|
+
|
|
140
|
+
export {
|
|
141
|
+
Onepassword as Onepassword,
|
|
142
|
+
type OnepasswordRetrieveResponse as OnepasswordRetrieveResponse,
|
|
143
|
+
type OnepasswordConnectResponse as OnepasswordConnectResponse,
|
|
144
|
+
type OnepasswordDisconnectResponse as OnepasswordDisconnectResponse,
|
|
145
|
+
type OnepasswordConnectParams as OnepasswordConnectParams,
|
|
146
|
+
};
|
|
96
147
|
}
|
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
3
|
export { Credentials, type CredentialListResponse, type CredentialListParams } from './credentials';
|
|
4
|
+
export {
|
|
5
|
+
Onepassword,
|
|
6
|
+
type OnepasswordRetrieveResponse,
|
|
7
|
+
type OnepasswordConnectResponse,
|
|
8
|
+
type OnepasswordDisconnectResponse,
|
|
9
|
+
type OnepasswordConnectParams,
|
|
10
|
+
} from './onepassword/index';
|
|
4
11
|
export {
|
|
5
12
|
Packages,
|
|
6
13
|
type PackageCreateResponse,
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
export {
|
|
4
|
+
Onepassword,
|
|
5
|
+
type OnepasswordRetrieveResponse,
|
|
6
|
+
type OnepasswordConnectResponse,
|
|
7
|
+
type OnepasswordDisconnectResponse,
|
|
8
|
+
type OnepasswordConnectParams,
|
|
9
|
+
} from './onepassword';
|
|
10
|
+
export { Vaults } from './vaults/index';
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
import { APIResource } from '../../../core/resource';
|
|
4
|
+
import * as VaultsAPI from './vaults/vaults';
|
|
5
|
+
import { Vaults } from './vaults/vaults';
|
|
6
|
+
import { APIPromise } from '../../../core/api-promise';
|
|
7
|
+
import { RequestOptions } from '../../../internal/request-options';
|
|
8
|
+
|
|
9
|
+
export class Onepassword extends APIResource {
|
|
10
|
+
vaults: VaultsAPI.Vaults = new VaultsAPI.Vaults(this._client);
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* Get 1Password connection
|
|
14
|
+
*/
|
|
15
|
+
retrieve(options?: RequestOptions): APIPromise<OnepasswordRetrieveResponse> {
|
|
16
|
+
return this._client.get('/credentials/onepassword', options);
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* Connect a 1Password service account
|
|
21
|
+
*/
|
|
22
|
+
connect(body: OnepasswordConnectParams, options?: RequestOptions): APIPromise<OnepasswordConnectResponse> {
|
|
23
|
+
return this._client.put('/credentials/onepassword', { body, ...options });
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* Disconnect 1Password
|
|
28
|
+
*/
|
|
29
|
+
disconnect(options?: RequestOptions): APIPromise<OnepasswordDisconnectResponse> {
|
|
30
|
+
return this._client.delete('/credentials/onepassword', options);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
export interface OnepasswordRetrieveResponse {
|
|
35
|
+
data: OnepasswordRetrieveResponse.Data;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export namespace OnepasswordRetrieveResponse {
|
|
39
|
+
export interface Data {
|
|
40
|
+
connected: boolean;
|
|
41
|
+
|
|
42
|
+
connectedAt?: string;
|
|
43
|
+
|
|
44
|
+
connectedBy?: string;
|
|
45
|
+
|
|
46
|
+
vaults?: Array<Data.Vault>;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export namespace Data {
|
|
50
|
+
export interface Vault {
|
|
51
|
+
id: string;
|
|
52
|
+
|
|
53
|
+
title: string;
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export interface OnepasswordConnectResponse {
|
|
59
|
+
data: OnepasswordConnectResponse.Data;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
export namespace OnepasswordConnectResponse {
|
|
63
|
+
export interface Data {
|
|
64
|
+
connected: boolean;
|
|
65
|
+
|
|
66
|
+
connectedAt?: string;
|
|
67
|
+
|
|
68
|
+
connectedBy?: string;
|
|
69
|
+
|
|
70
|
+
vaults?: Array<Data.Vault>;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export namespace Data {
|
|
74
|
+
export interface Vault {
|
|
75
|
+
id: string;
|
|
76
|
+
|
|
77
|
+
title: string;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
export interface OnepasswordDisconnectResponse {
|
|
83
|
+
message: string;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
export interface OnepasswordConnectParams {
|
|
87
|
+
serviceAccountToken: string;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
Onepassword.Vaults = Vaults;
|
|
91
|
+
|
|
92
|
+
export declare namespace Onepassword {
|
|
93
|
+
export {
|
|
94
|
+
type OnepasswordRetrieveResponse as OnepasswordRetrieveResponse,
|
|
95
|
+
type OnepasswordConnectResponse as OnepasswordConnectResponse,
|
|
96
|
+
type OnepasswordDisconnectResponse as OnepasswordDisconnectResponse,
|
|
97
|
+
type OnepasswordConnectParams as OnepasswordConnectParams,
|
|
98
|
+
};
|
|
99
|
+
|
|
100
|
+
export { Vaults as Vaults };
|
|
101
|
+
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
import { APIResource } from '../../../../../core/resource';
|
|
4
|
+
import { APIPromise } from '../../../../../core/api-promise';
|
|
5
|
+
import { RequestOptions } from '../../../../../internal/request-options';
|
|
6
|
+
import { path } from '../../../../../internal/utils/path';
|
|
7
|
+
|
|
8
|
+
export class Fields extends APIResource {
|
|
9
|
+
/**
|
|
10
|
+
* List 1Password field metadata
|
|
11
|
+
*/
|
|
12
|
+
list(itemID: string, params: FieldListParams, options?: RequestOptions): APIPromise<FieldListResponse> {
|
|
13
|
+
const { vaultId } = params;
|
|
14
|
+
return this._client.get(path`/credentials/onepassword/vaults/${vaultId}/items/${itemID}/fields`, options);
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export interface FieldListResponse {
|
|
19
|
+
data: Array<FieldListResponse.Data>;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export namespace FieldListResponse {
|
|
23
|
+
export interface Data {
|
|
24
|
+
id: string;
|
|
25
|
+
|
|
26
|
+
fieldType: string;
|
|
27
|
+
|
|
28
|
+
title: string;
|
|
29
|
+
|
|
30
|
+
sectionId?: string;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
export interface FieldListParams {
|
|
35
|
+
vaultId: string;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export declare namespace Fields {
|
|
39
|
+
export { type FieldListResponse as FieldListResponse, type FieldListParams as FieldListParams };
|
|
40
|
+
}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
import { APIResource } from '../../../../../core/resource';
|
|
4
|
+
import * as FieldsAPI from './fields';
|
|
5
|
+
import { FieldListParams, FieldListResponse, Fields } from './fields';
|
|
6
|
+
import { APIPromise } from '../../../../../core/api-promise';
|
|
7
|
+
import { RequestOptions } from '../../../../../internal/request-options';
|
|
8
|
+
import { path } from '../../../../../internal/utils/path';
|
|
9
|
+
|
|
10
|
+
export class Items extends APIResource {
|
|
11
|
+
fields: FieldsAPI.Fields = new FieldsAPI.Fields(this._client);
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* List 1Password item metadata
|
|
15
|
+
*/
|
|
16
|
+
list(vaultID: string, options?: RequestOptions): APIPromise<ItemListResponse> {
|
|
17
|
+
return this._client.get(path`/credentials/onepassword/vaults/${vaultID}/items`, options);
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export interface ItemListResponse {
|
|
22
|
+
data: Array<ItemListResponse.Data>;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
export namespace ItemListResponse {
|
|
26
|
+
export interface Data {
|
|
27
|
+
id: string;
|
|
28
|
+
|
|
29
|
+
category: string;
|
|
30
|
+
|
|
31
|
+
title: string;
|
|
32
|
+
|
|
33
|
+
websites: Array<Data.Website>;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export namespace Data {
|
|
37
|
+
export interface Website {
|
|
38
|
+
label: string;
|
|
39
|
+
|
|
40
|
+
url: string;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
Items.Fields = Fields;
|
|
46
|
+
|
|
47
|
+
export declare namespace Items {
|
|
48
|
+
export { type ItemListResponse as ItemListResponse };
|
|
49
|
+
|
|
50
|
+
export {
|
|
51
|
+
Fields as Fields,
|
|
52
|
+
type FieldListResponse as FieldListResponse,
|
|
53
|
+
type FieldListParams as FieldListParams,
|
|
54
|
+
};
|
|
55
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
import { APIResource } from '../../../../core/resource';
|
|
4
|
+
import * as ItemsAPI from './items/items';
|
|
5
|
+
import { ItemListResponse, Items } from './items/items';
|
|
6
|
+
|
|
7
|
+
export class Vaults extends APIResource {
|
|
8
|
+
items: ItemsAPI.Items = new ItemsAPI.Items(this._client);
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
Vaults.Items = Items;
|
|
12
|
+
|
|
13
|
+
export declare namespace Vaults {
|
|
14
|
+
export { Items as Items, type ItemListResponse as ItemListResponse };
|
|
15
|
+
}
|
|
@@ -31,22 +31,6 @@ export class Credentials extends APIResource {
|
|
|
31
31
|
return this._client.post(path`/credentials/packages/${packageName}`, { body, ...options });
|
|
32
32
|
}
|
|
33
33
|
|
|
34
|
-
/**
|
|
35
|
-
* Fetches a single credential by `packageName` and `credentialName`, including all
|
|
36
|
-
* of its stored fields. Returns not found if no matching credential exists.
|
|
37
|
-
*/
|
|
38
|
-
retrieve(
|
|
39
|
-
credentialName: string,
|
|
40
|
-
params: CredentialRetrieveParams,
|
|
41
|
-
options?: RequestOptions,
|
|
42
|
-
): APIPromise<CredentialRetrieveResponse> {
|
|
43
|
-
const { packageName } = params;
|
|
44
|
-
return this._client.get(
|
|
45
|
-
path`/credentials/packages/${packageName}/credentials/${credentialName}`,
|
|
46
|
-
options,
|
|
47
|
-
);
|
|
48
|
-
}
|
|
49
|
-
|
|
50
34
|
/**
|
|
51
35
|
* Permanently deletes the credential identified by `packageName` and
|
|
52
36
|
* `credentialName`, removing all of its fields. Returns the deleted credential.
|
|
@@ -91,6 +75,10 @@ export namespace CredentialCreateResponse {
|
|
|
91
75
|
* for credentials created before rollout.
|
|
92
76
|
*/
|
|
93
77
|
userId: string | null;
|
|
78
|
+
|
|
79
|
+
link?: Data.Link;
|
|
80
|
+
|
|
81
|
+
source?: 'mobilerun' | 'onepassword';
|
|
94
82
|
}
|
|
95
83
|
|
|
96
84
|
export namespace Data {
|
|
@@ -106,46 +94,34 @@ export namespace CredentialCreateResponse {
|
|
|
106
94
|
|
|
107
95
|
value: string;
|
|
108
96
|
}
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
97
|
|
|
112
|
-
export interface
|
|
113
|
-
|
|
114
|
-
}
|
|
98
|
+
export interface Link {
|
|
99
|
+
fieldMap: Array<Link.FieldMap>;
|
|
115
100
|
|
|
116
|
-
|
|
117
|
-
export interface Data {
|
|
118
|
-
createdBy: string | null;
|
|
119
|
-
|
|
120
|
-
credentialName: string;
|
|
101
|
+
itemId: string;
|
|
121
102
|
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
ownerId: string;
|
|
103
|
+
itemTitle: string;
|
|
125
104
|
|
|
126
|
-
|
|
105
|
+
provider: 'onepassword';
|
|
127
106
|
|
|
128
|
-
|
|
107
|
+
vaultId: string;
|
|
129
108
|
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
* for credentials created before rollout.
|
|
133
|
-
*/
|
|
134
|
-
userId: string | null;
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
export namespace Data {
|
|
138
|
-
export interface Field {
|
|
139
|
-
fieldType:
|
|
140
|
-
| 'email'
|
|
141
|
-
| 'username'
|
|
142
|
-
| 'password'
|
|
143
|
-
| 'api_token'
|
|
144
|
-
| 'phone_number'
|
|
145
|
-
| 'two_factor_secret'
|
|
146
|
-
| 'backup_codes';
|
|
109
|
+
vaultName: string;
|
|
110
|
+
}
|
|
147
111
|
|
|
148
|
-
|
|
112
|
+
export namespace Link {
|
|
113
|
+
export interface FieldMap {
|
|
114
|
+
fieldId: string;
|
|
115
|
+
|
|
116
|
+
fieldType:
|
|
117
|
+
| 'email'
|
|
118
|
+
| 'username'
|
|
119
|
+
| 'password'
|
|
120
|
+
| 'api_token'
|
|
121
|
+
| 'phone_number'
|
|
122
|
+
| 'two_factor_secret'
|
|
123
|
+
| 'backup_codes';
|
|
124
|
+
}
|
|
149
125
|
}
|
|
150
126
|
}
|
|
151
127
|
}
|
|
@@ -177,6 +153,10 @@ export namespace CredentialDeleteResponse {
|
|
|
177
153
|
* for credentials created before rollout.
|
|
178
154
|
*/
|
|
179
155
|
userId: string | null;
|
|
156
|
+
|
|
157
|
+
link?: Data.Link;
|
|
158
|
+
|
|
159
|
+
source?: 'mobilerun' | 'onepassword';
|
|
180
160
|
}
|
|
181
161
|
|
|
182
162
|
export namespace Data {
|
|
@@ -192,6 +172,35 @@ export namespace CredentialDeleteResponse {
|
|
|
192
172
|
|
|
193
173
|
value: string;
|
|
194
174
|
}
|
|
175
|
+
|
|
176
|
+
export interface Link {
|
|
177
|
+
fieldMap: Array<Link.FieldMap>;
|
|
178
|
+
|
|
179
|
+
itemId: string;
|
|
180
|
+
|
|
181
|
+
itemTitle: string;
|
|
182
|
+
|
|
183
|
+
provider: 'onepassword';
|
|
184
|
+
|
|
185
|
+
vaultId: string;
|
|
186
|
+
|
|
187
|
+
vaultName: string;
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
export namespace Link {
|
|
191
|
+
export interface FieldMap {
|
|
192
|
+
fieldId: string;
|
|
193
|
+
|
|
194
|
+
fieldType:
|
|
195
|
+
| 'email'
|
|
196
|
+
| 'username'
|
|
197
|
+
| 'password'
|
|
198
|
+
| 'api_token'
|
|
199
|
+
| 'phone_number'
|
|
200
|
+
| 'two_factor_secret'
|
|
201
|
+
| 'backup_codes';
|
|
202
|
+
}
|
|
203
|
+
}
|
|
195
204
|
}
|
|
196
205
|
}
|
|
197
206
|
|
|
@@ -216,10 +225,6 @@ export namespace CredentialCreateParams {
|
|
|
216
225
|
}
|
|
217
226
|
}
|
|
218
227
|
|
|
219
|
-
export interface CredentialRetrieveParams {
|
|
220
|
-
packageName: string;
|
|
221
|
-
}
|
|
222
|
-
|
|
223
228
|
export interface CredentialDeleteParams {
|
|
224
229
|
packageName: string;
|
|
225
230
|
}
|
|
@@ -229,10 +234,8 @@ Credentials.Fields = Fields;
|
|
|
229
234
|
export declare namespace Credentials {
|
|
230
235
|
export {
|
|
231
236
|
type CredentialCreateResponse as CredentialCreateResponse,
|
|
232
|
-
type CredentialRetrieveResponse as CredentialRetrieveResponse,
|
|
233
237
|
type CredentialDeleteResponse as CredentialDeleteResponse,
|
|
234
238
|
type CredentialCreateParams as CredentialCreateParams,
|
|
235
|
-
type CredentialRetrieveParams as CredentialRetrieveParams,
|
|
236
239
|
type CredentialDeleteParams as CredentialDeleteParams,
|
|
237
240
|
};
|
|
238
241
|
|
|
@@ -98,6 +98,10 @@ export namespace FieldCreateResponse {
|
|
|
98
98
|
* for credentials created before rollout.
|
|
99
99
|
*/
|
|
100
100
|
userId: string | null;
|
|
101
|
+
|
|
102
|
+
link?: Data.Link;
|
|
103
|
+
|
|
104
|
+
source?: 'mobilerun' | 'onepassword';
|
|
101
105
|
}
|
|
102
106
|
|
|
103
107
|
export namespace Data {
|
|
@@ -113,6 +117,35 @@ export namespace FieldCreateResponse {
|
|
|
113
117
|
|
|
114
118
|
value: string;
|
|
115
119
|
}
|
|
120
|
+
|
|
121
|
+
export interface Link {
|
|
122
|
+
fieldMap: Array<Link.FieldMap>;
|
|
123
|
+
|
|
124
|
+
itemId: string;
|
|
125
|
+
|
|
126
|
+
itemTitle: string;
|
|
127
|
+
|
|
128
|
+
provider: 'onepassword';
|
|
129
|
+
|
|
130
|
+
vaultId: string;
|
|
131
|
+
|
|
132
|
+
vaultName: string;
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
export namespace Link {
|
|
136
|
+
export interface FieldMap {
|
|
137
|
+
fieldId: string;
|
|
138
|
+
|
|
139
|
+
fieldType:
|
|
140
|
+
| 'email'
|
|
141
|
+
| 'username'
|
|
142
|
+
| 'password'
|
|
143
|
+
| 'api_token'
|
|
144
|
+
| 'phone_number'
|
|
145
|
+
| 'two_factor_secret'
|
|
146
|
+
| 'backup_codes';
|
|
147
|
+
}
|
|
148
|
+
}
|
|
116
149
|
}
|
|
117
150
|
}
|
|
118
151
|
|
|
@@ -143,6 +176,10 @@ export namespace FieldUpdateResponse {
|
|
|
143
176
|
* for credentials created before rollout.
|
|
144
177
|
*/
|
|
145
178
|
userId: string | null;
|
|
179
|
+
|
|
180
|
+
link?: Data.Link;
|
|
181
|
+
|
|
182
|
+
source?: 'mobilerun' | 'onepassword';
|
|
146
183
|
}
|
|
147
184
|
|
|
148
185
|
export namespace Data {
|
|
@@ -158,6 +195,35 @@ export namespace FieldUpdateResponse {
|
|
|
158
195
|
|
|
159
196
|
value: string;
|
|
160
197
|
}
|
|
198
|
+
|
|
199
|
+
export interface Link {
|
|
200
|
+
fieldMap: Array<Link.FieldMap>;
|
|
201
|
+
|
|
202
|
+
itemId: string;
|
|
203
|
+
|
|
204
|
+
itemTitle: string;
|
|
205
|
+
|
|
206
|
+
provider: 'onepassword';
|
|
207
|
+
|
|
208
|
+
vaultId: string;
|
|
209
|
+
|
|
210
|
+
vaultName: string;
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
export namespace Link {
|
|
214
|
+
export interface FieldMap {
|
|
215
|
+
fieldId: string;
|
|
216
|
+
|
|
217
|
+
fieldType:
|
|
218
|
+
| 'email'
|
|
219
|
+
| 'username'
|
|
220
|
+
| 'password'
|
|
221
|
+
| 'api_token'
|
|
222
|
+
| 'phone_number'
|
|
223
|
+
| 'two_factor_secret'
|
|
224
|
+
| 'backup_codes';
|
|
225
|
+
}
|
|
226
|
+
}
|
|
161
227
|
}
|
|
162
228
|
}
|
|
163
229
|
|
|
@@ -188,6 +254,10 @@ export namespace FieldDeleteResponse {
|
|
|
188
254
|
* for credentials created before rollout.
|
|
189
255
|
*/
|
|
190
256
|
userId: string | null;
|
|
257
|
+
|
|
258
|
+
link?: Data.Link;
|
|
259
|
+
|
|
260
|
+
source?: 'mobilerun' | 'onepassword';
|
|
191
261
|
}
|
|
192
262
|
|
|
193
263
|
export namespace Data {
|
|
@@ -203,6 +273,35 @@ export namespace FieldDeleteResponse {
|
|
|
203
273
|
|
|
204
274
|
value: string;
|
|
205
275
|
}
|
|
276
|
+
|
|
277
|
+
export interface Link {
|
|
278
|
+
fieldMap: Array<Link.FieldMap>;
|
|
279
|
+
|
|
280
|
+
itemId: string;
|
|
281
|
+
|
|
282
|
+
itemTitle: string;
|
|
283
|
+
|
|
284
|
+
provider: 'onepassword';
|
|
285
|
+
|
|
286
|
+
vaultId: string;
|
|
287
|
+
|
|
288
|
+
vaultName: string;
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
export namespace Link {
|
|
292
|
+
export interface FieldMap {
|
|
293
|
+
fieldId: string;
|
|
294
|
+
|
|
295
|
+
fieldType:
|
|
296
|
+
| 'email'
|
|
297
|
+
| 'username'
|
|
298
|
+
| 'password'
|
|
299
|
+
| 'api_token'
|
|
300
|
+
| 'phone_number'
|
|
301
|
+
| 'two_factor_secret'
|
|
302
|
+
| 'backup_codes';
|
|
303
|
+
}
|
|
304
|
+
}
|
|
206
305
|
}
|
|
207
306
|
}
|
|
208
307
|
|
|
@@ -3,12 +3,11 @@
|
|
|
3
3
|
export {
|
|
4
4
|
Credentials,
|
|
5
5
|
type CredentialCreateResponse,
|
|
6
|
-
type CredentialRetrieveResponse,
|
|
7
6
|
type CredentialDeleteResponse,
|
|
8
7
|
type CredentialCreateParams,
|
|
9
|
-
type CredentialRetrieveParams,
|
|
10
8
|
type CredentialDeleteParams,
|
|
11
9
|
} from './credentials/index';
|
|
10
|
+
export { Links, type LinkCreateResponse, type LinkCreateParams } from './links';
|
|
12
11
|
export {
|
|
13
12
|
Packages,
|
|
14
13
|
type PackageCreateResponse,
|