@capgo/cli 8.85.0 → 8.86.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 +153 -2
- package/dist/index.js +850 -835
- package/dist/notify-app-ready-worker.js +1 -1
- package/dist/onboarding-worker.js +1 -1
- package/dist/package.json +3 -2
- package/dist/src/mcp/tool-schemas.d.ts +74 -4
- package/dist/src/organization/index.d.ts +1 -0
- package/dist/src/organization/member-manage.d.ts +22 -0
- package/dist/src/organization/set.d.ts +4 -4
- package/dist/src/schemas/account.d.ts +29 -0
- package/dist/src/schemas/channel.d.ts +3 -0
- package/dist/src/schemas/index.d.ts +4 -2
- package/dist/src/schemas/organization.d.ts +20 -0
- package/dist/src/schemas/sdk.d.ts +72 -0
- package/dist/src/sdk.d.ts +44 -2
- package/dist/src/sdk.js +363 -363
- package/dist/src/shared/docs-search.d.ts +7 -0
- package/dist/src/shared/email-preferences.d.ts +9 -0
- package/dist/src/types/supabase.types.d.ts +0 -301
- package/dist/src/user/settings.d.ts +6 -0
- package/dist/src/utils.d.ts +0 -602
- package/dist/updater-installed-worker.js +1 -1
- package/package.json +3 -2
- package/skills/organization-management/SKILL.md +37 -0
- package/skills/release-management/SKILL.md +2 -0
- package/skills/usage/SKILL.md +2 -2
|
@@ -5,6 +5,20 @@ export declare const mcpAddAppInputSchema: z.ZodObject<{
|
|
|
5
5
|
icon: z.ZodOptional<z.ZodString>;
|
|
6
6
|
}, z.core.$strip>;
|
|
7
7
|
export declare const mcpUpdateAppInputSchema: z.ZodObject<{
|
|
8
|
+
appId: z.ZodString;
|
|
9
|
+
name: z.ZodOptional<z.ZodString>;
|
|
10
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
11
|
+
retention: z.ZodOptional<z.ZodNumber>;
|
|
12
|
+
exposeMetadata: z.ZodOptional<z.ZodBoolean>;
|
|
13
|
+
preview: z.ZodOptional<z.ZodBoolean>;
|
|
14
|
+
allowDeviceCustomId: z.ZodOptional<z.ZodBoolean>;
|
|
15
|
+
blockProviderInfraRequests: z.ZodOptional<z.ZodBoolean>;
|
|
16
|
+
buildTimeoutMinutes: z.ZodOptional<z.ZodNumber>;
|
|
17
|
+
iosStoreUrl: z.ZodOptional<z.ZodString>;
|
|
18
|
+
androidStoreUrl: z.ZodOptional<z.ZodString>;
|
|
19
|
+
defaultUploadChannel: z.ZodOptional<z.ZodString>;
|
|
20
|
+
defaultDownloadChannel: z.ZodOptional<z.ZodString>;
|
|
21
|
+
disableDownloadChannels: z.ZodOptional<z.ZodBoolean>;
|
|
8
22
|
collectCountry: z.ZodOptional<z.ZodBoolean>;
|
|
9
23
|
collectPlatform: z.ZodOptional<z.ZodBoolean>;
|
|
10
24
|
collectOsVersion: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -13,10 +27,6 @@ export declare const mcpUpdateAppInputSchema: z.ZodObject<{
|
|
|
13
27
|
collectIsEmulator: z.ZodOptional<z.ZodBoolean>;
|
|
14
28
|
collectIsProd: z.ZodOptional<z.ZodBoolean>;
|
|
15
29
|
collectInstallSource: z.ZodOptional<z.ZodBoolean>;
|
|
16
|
-
appId: z.ZodString;
|
|
17
|
-
name: z.ZodOptional<z.ZodString>;
|
|
18
|
-
icon: z.ZodOptional<z.ZodString>;
|
|
19
|
-
retention: z.ZodOptional<z.ZodNumber>;
|
|
20
30
|
}, z.core.$strip>;
|
|
21
31
|
export declare const mcpDeleteAppInputSchema: z.ZodObject<{
|
|
22
32
|
appId: z.ZodString;
|
|
@@ -87,8 +97,18 @@ export declare const mcpUpdateChannelInputSchema: z.ZodObject<{
|
|
|
87
97
|
downgrade: z.ZodOptional<z.ZodBoolean>;
|
|
88
98
|
ios: z.ZodOptional<z.ZodBoolean>;
|
|
89
99
|
android: z.ZodOptional<z.ZodBoolean>;
|
|
100
|
+
electron: z.ZodOptional<z.ZodBoolean>;
|
|
101
|
+
pause: z.ZodOptional<z.ZodBoolean>;
|
|
102
|
+
resume: z.ZodOptional<z.ZodBoolean>;
|
|
90
103
|
selfAssign: z.ZodOptional<z.ZodBoolean>;
|
|
91
104
|
disableAutoUpdate: z.ZodOptional<z.ZodString>;
|
|
105
|
+
updatePackage: z.ZodOptional<z.ZodEnum<{
|
|
106
|
+
all: "all";
|
|
107
|
+
zip: "zip";
|
|
108
|
+
delta: "delta";
|
|
109
|
+
zip_from_builtin: "zip_from_builtin";
|
|
110
|
+
delta_from_builtin: "delta_from_builtin";
|
|
111
|
+
}>>;
|
|
92
112
|
dev: z.ZodOptional<z.ZodBoolean>;
|
|
93
113
|
emulator: z.ZodOptional<z.ZodBoolean>;
|
|
94
114
|
device: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -139,6 +159,56 @@ export declare const mcpAddOrganizationInputSchema: z.ZodObject<{
|
|
|
139
159
|
name: z.ZodString;
|
|
140
160
|
email: z.ZodString;
|
|
141
161
|
}, z.core.$strip>;
|
|
162
|
+
export declare const mcpOrgIdInputSchema: z.ZodObject<{
|
|
163
|
+
orgId: z.ZodString;
|
|
164
|
+
}, z.core.$strip>;
|
|
165
|
+
export declare const mcpUpdateOrganizationInputSchema: z.ZodObject<{
|
|
166
|
+
email: z.ZodOptional<z.ZodString>;
|
|
167
|
+
name: z.ZodOptional<z.ZodString>;
|
|
168
|
+
website: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
169
|
+
orgId: z.ZodString;
|
|
170
|
+
enforce2fa: z.ZodOptional<z.ZodBoolean>;
|
|
171
|
+
passwordPolicy: z.ZodOptional<z.ZodBoolean>;
|
|
172
|
+
minLength: z.ZodOptional<z.ZodNumber>;
|
|
173
|
+
requireUppercase: z.ZodOptional<z.ZodBoolean>;
|
|
174
|
+
requireNumber: z.ZodOptional<z.ZodBoolean>;
|
|
175
|
+
requireSpecial: z.ZodOptional<z.ZodBoolean>;
|
|
176
|
+
requireApikeyExpiration: z.ZodOptional<z.ZodBoolean>;
|
|
177
|
+
maxApikeyExpirationDays: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
178
|
+
enforceHashedApiKeys: z.ZodOptional<z.ZodBoolean>;
|
|
179
|
+
enforceEncryptedBundles: z.ZodOptional<z.ZodBoolean>;
|
|
180
|
+
requiredEncryptionKey: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
181
|
+
emailPreferences: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
|
|
182
|
+
}, z.core.$strip>;
|
|
183
|
+
export declare const mcpOrganizationMemberRoleInputSchema: z.ZodObject<{
|
|
184
|
+
email: z.ZodString;
|
|
185
|
+
role: z.ZodEnum<{
|
|
186
|
+
org_member: "org_member";
|
|
187
|
+
org_billing_admin: "org_billing_admin";
|
|
188
|
+
org_admin: "org_admin";
|
|
189
|
+
org_super_admin: "org_super_admin";
|
|
190
|
+
}>;
|
|
191
|
+
orgId: z.ZodString;
|
|
192
|
+
}, z.core.$strip>;
|
|
193
|
+
export declare const mcpRemoveOrganizationMemberInputSchema: z.ZodObject<{
|
|
194
|
+
email: z.ZodString;
|
|
195
|
+
orgId: z.ZodString;
|
|
196
|
+
}, z.core.$strip>;
|
|
197
|
+
export declare const mcpGetAccountInputSchema: z.ZodObject<{}, z.core.$strip>;
|
|
198
|
+
export declare const mcpUpdateAccountInputSchema: z.ZodObject<{
|
|
199
|
+
notifications: z.ZodOptional<z.ZodBoolean>;
|
|
200
|
+
country: z.ZodOptional<z.ZodString>;
|
|
201
|
+
emailPreferences: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
|
|
202
|
+
firstName: z.ZodOptional<z.ZodString>;
|
|
203
|
+
lastName: z.ZodOptional<z.ZodString>;
|
|
204
|
+
discordUsername: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
205
|
+
formatLocale: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
206
|
+
newsletter: z.ZodOptional<z.ZodBoolean>;
|
|
207
|
+
}, z.core.$strip>;
|
|
208
|
+
export declare const mcpSearchDocsInputSchema: z.ZodObject<{
|
|
209
|
+
query: z.ZodString;
|
|
210
|
+
limit: z.ZodOptional<z.ZodNumber>;
|
|
211
|
+
}, z.core.$strip>;
|
|
142
212
|
export declare const mcpDoctorInputSchema: z.ZodObject<{
|
|
143
213
|
packageJson: z.ZodOptional<z.ZodString>;
|
|
144
214
|
}, z.core.$strip>;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export { addOrganization } from './add';
|
|
2
2
|
export { deleteOrganization } from './delete';
|
|
3
3
|
export { listOrganizations } from './list';
|
|
4
|
+
export { inviteMember, removeMember, setMemberRole } from './member-manage';
|
|
4
5
|
export { listMembers } from './members';
|
|
5
6
|
export { setOrganization } from './set';
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { OrganizationMemberOptions } from '../schemas/organization';
|
|
2
|
+
export declare function inviteMemberInternal(orgId: string, options: OrganizationMemberOptions, silent?: boolean): Promise<{
|
|
3
|
+
orgId: string;
|
|
4
|
+
email: string;
|
|
5
|
+
role: "org_member" | "org_billing_admin" | "org_admin" | "org_super_admin" | undefined;
|
|
6
|
+
data: Record<string, unknown> | null;
|
|
7
|
+
}>;
|
|
8
|
+
export declare function removeMemberInternal(orgId: string, options: OrganizationMemberOptions, silent?: boolean): Promise<{
|
|
9
|
+
orgId: string;
|
|
10
|
+
email: string;
|
|
11
|
+
role: "org_member" | "org_billing_admin" | "org_admin" | "org_super_admin" | undefined;
|
|
12
|
+
data: Record<string, unknown> | null;
|
|
13
|
+
}>;
|
|
14
|
+
export declare function setMemberRoleInternal(orgId: string, options: OrganizationMemberOptions, silent?: boolean): Promise<{
|
|
15
|
+
orgId: string;
|
|
16
|
+
email: string;
|
|
17
|
+
role: "org_member" | "org_billing_admin" | "org_admin" | "org_super_admin" | undefined;
|
|
18
|
+
data: Record<string, unknown> | null;
|
|
19
|
+
}>;
|
|
20
|
+
export declare function inviteMember(orgId: string, options: OrganizationMemberOptions): Promise<void>;
|
|
21
|
+
export declare function removeMember(orgId: string, options: OrganizationMemberOptions): Promise<void>;
|
|
22
|
+
export declare function setMemberRole(orgId: string, options: OrganizationMemberOptions): Promise<void>;
|
|
@@ -6,19 +6,19 @@ export declare function setOrganizationInternal(orgId: string, options: Organiza
|
|
|
6
6
|
orgId: string;
|
|
7
7
|
name: string;
|
|
8
8
|
email: string;
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
passwordPolicy: boolean;
|
|
10
|
+
enforce2fa?: undefined;
|
|
11
11
|
} | {
|
|
12
12
|
orgId: string;
|
|
13
13
|
name: string;
|
|
14
14
|
email: string;
|
|
15
|
-
passwordPolicy
|
|
15
|
+
passwordPolicy?: undefined;
|
|
16
16
|
enforce2fa?: undefined;
|
|
17
17
|
} | {
|
|
18
18
|
orgId: string;
|
|
19
19
|
name: string;
|
|
20
20
|
email: string;
|
|
21
|
-
enforce2fa
|
|
21
|
+
enforce2fa: boolean | undefined;
|
|
22
22
|
passwordPolicy?: undefined;
|
|
23
23
|
}>;
|
|
24
24
|
export declare function setOrganization(orgId: string, options: OrganizationSetOptions): Promise<void>;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const accountSetOptionsSchema: z.ZodObject<{
|
|
3
|
+
apikey: z.ZodString;
|
|
4
|
+
supaHost: z.ZodOptional<z.ZodString>;
|
|
5
|
+
supaAnon: z.ZodOptional<z.ZodString>;
|
|
6
|
+
firstName: z.ZodOptional<z.ZodString>;
|
|
7
|
+
lastName: z.ZodOptional<z.ZodString>;
|
|
8
|
+
country: z.ZodOptional<z.ZodString>;
|
|
9
|
+
discordUsername: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
10
|
+
formatLocale: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
11
|
+
notifications: z.ZodOptional<z.ZodBoolean>;
|
|
12
|
+
newsletter: z.ZodOptional<z.ZodBoolean>;
|
|
13
|
+
emailPreference: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
14
|
+
emailPreferences: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
|
|
15
|
+
}, z.core.$strip>;
|
|
16
|
+
export type AccountSetOptions = z.infer<typeof accountSetOptionsSchema>;
|
|
17
|
+
export interface AccountProfile {
|
|
18
|
+
id: string;
|
|
19
|
+
email: string;
|
|
20
|
+
first_name: string | null;
|
|
21
|
+
last_name: string | null;
|
|
22
|
+
country: string | null;
|
|
23
|
+
discord_username: string | null;
|
|
24
|
+
format_locale: string | null;
|
|
25
|
+
enable_notifications: boolean;
|
|
26
|
+
opt_for_newsletters: boolean;
|
|
27
|
+
email_preferences: Record<string, boolean> | null;
|
|
28
|
+
[key: string]: unknown;
|
|
29
|
+
}
|
|
@@ -61,6 +61,9 @@ export declare const optionsSetChannelSchema: z.ZodObject<{
|
|
|
61
61
|
latestRemote: z.ZodOptional<z.ZodBoolean>;
|
|
62
62
|
ios: z.ZodOptional<z.ZodBoolean>;
|
|
63
63
|
android: z.ZodOptional<z.ZodBoolean>;
|
|
64
|
+
electron: z.ZodOptional<z.ZodBoolean>;
|
|
65
|
+
pause: z.ZodOptional<z.ZodBoolean>;
|
|
66
|
+
resume: z.ZodOptional<z.ZodBoolean>;
|
|
64
67
|
selfAssign: z.ZodOptional<z.ZodBoolean>;
|
|
65
68
|
disableAutoUpdate: z.ZodOptional<z.ZodString>;
|
|
66
69
|
updatePackage: z.ZodOptional<z.ZodEnum<{
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
export { accountSetOptionsSchema } from './account';
|
|
2
|
+
export type { AccountProfile, AccountSetOptions } from './account';
|
|
1
3
|
export { appDebugOptionsSchema, appOptionsSchema, appSettingOptionsSchema } from './app';
|
|
2
4
|
export type { AppDebugOptions, AppOptions, AppSettingOptions } from './app';
|
|
3
5
|
export { mcpLoginInputSchema, mcpLogoutInputSchema } from './auth';
|
|
@@ -12,8 +14,8 @@ export type { Channel, ChannelAddOptions, ChannelCurrentBundleOptions, ChannelDe
|
|
|
12
14
|
export { compatibilityDetailsSchema, compatibilitySchema, incompatibilityReasonSchema, localizedReleaseNotesSchema, nativePackageSchema, parsedSecurityErrorSchema } from './common';
|
|
13
15
|
export type { Compatibility, CompatibilityDetails, IncompatibilityReason, NativePackage, ParsedSecurityError } from './common';
|
|
14
16
|
export type { CapacitorConfig, ExtConfigPairs } from './config';
|
|
15
|
-
export { organizationAddOptionsSchema, organizationDeleteOptionsSchema, organizationSetOptionsSchema, passwordPolicyConfigSchema } from './organization';
|
|
16
|
-
export type { OrganizationAddOptions, OrganizationDeleteOptions, OrganizationSetOptions, PasswordPolicyConfig } from './organization';
|
|
17
|
+
export { organizationAddOptionsSchema, organizationDeleteOptionsSchema, organizationMemberOptionsSchema, organizationMemberRoleSchema, organizationSetOptionsSchema, passwordPolicyConfigSchema } from './organization';
|
|
18
|
+
export type { OrganizationAddOptions, OrganizationDeleteOptions, OrganizationMemberOptions, OrganizationMemberRole, OrganizationSetOptions, PasswordPolicyConfig } from './organization';
|
|
17
19
|
export { accountIdOptionsSchema, addAppOptionsSchema, addChannelOptionsSchema, addOrganizationOptionsSchema, appInfoSchema, bundleInfoSchema, cleanupOptionsSchema, currentBundleOptionsSchema, decryptBundleOptionsSchema, deleteOldKeyOptionsSchema, deleteOrganizationOptionsSchema, deviceStatsSchema, doctorOptionsSchema, encryptBundleOptionsSchema, generateKeyOptionsSchema, getStatsOptionsSchema, listOrganizationsOptionsSchema, loginOptionsSchema, observeOptionsObjectSchema, observeOptionsSchema, observeDaysSchema, observeSortSchema, observeViewSchema, organizationInfoSchema, promoteChannelOptionsSchema, saveKeyOptionsSchema, bundleCompatibilityOptionsSchema as sdkBundleCompatibilityOptionsSchema, requestBuildOptionsSchema as sdkRequestBuildOptionsSchema, setSettingOptionsSchema, statsOrderSchema, updateAppOptionsSchema, updateChannelOptionsSchema, updateOrganizationOptionsSchema, uploadOptionsSchema, uploadResultSchema, zipBundleOptionsSchema, } from './sdk';
|
|
18
20
|
export type { AccountIdOptions, AddAppOptions, AddChannelOptions, AddOrganizationOptions, AppInfo, BundleInfo, CleanupOptions, CurrentBundleOptions, DecryptBundleOptions, DeleteOldKeyOptions, DeleteOrganizationOptions, DeviceStats, DoctorOptions, EncryptBundleOptions, GenerateKeyOptions, GetStatsOptions, ListOrganizationsOptions, LoginOptions, ObserveOptions, ObserveView, OrganizationInfo, PromoteChannelOptions, SaveKeyOptions, BundleCompatibilityOptions as SdkBundleCompatibilityOptions, RequestBuildOptions as SdkRequestBuildOptions, SDKResult, SetSettingOptions, StatsOrder, UpdateAppOptions, UpdateChannelOptions, UpdateOrganizationOptions, UploadOptions, UploadResult, ZipBundleOptions, } from './sdk';
|
|
19
21
|
export { validateOptions } from './validate';
|
|
@@ -37,5 +37,25 @@ export declare const organizationSetOptionsSchema: z.ZodObject<{
|
|
|
37
37
|
requireApikeyExpiration: z.ZodOptional<z.ZodBoolean>;
|
|
38
38
|
maxApikeyExpirationDays: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
39
39
|
enforceHashedApiKeys: z.ZodOptional<z.ZodBoolean>;
|
|
40
|
+
website: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
41
|
+
enforceEncryptedBundles: z.ZodOptional<z.ZodBoolean>;
|
|
42
|
+
requiredEncryptionKey: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
43
|
+
emailPreference: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
44
|
+
emailPreferences: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
|
|
40
45
|
}, z.core.$strip>;
|
|
41
46
|
export type OrganizationSetOptions = z.infer<typeof organizationSetOptionsSchema>;
|
|
47
|
+
export declare const organizationMemberRoleSchema: z.ZodEnum<{
|
|
48
|
+
org_member: "org_member";
|
|
49
|
+
org_billing_admin: "org_billing_admin";
|
|
50
|
+
org_admin: "org_admin";
|
|
51
|
+
org_super_admin: "org_super_admin";
|
|
52
|
+
}>;
|
|
53
|
+
export type OrganizationMemberRole = z.infer<typeof organizationMemberRoleSchema>;
|
|
54
|
+
export declare const organizationMemberOptionsSchema: z.ZodObject<{
|
|
55
|
+
apikey: z.ZodString;
|
|
56
|
+
supaHost: z.ZodOptional<z.ZodString>;
|
|
57
|
+
supaAnon: z.ZodOptional<z.ZodString>;
|
|
58
|
+
email: z.ZodOptional<z.ZodString>;
|
|
59
|
+
role: z.ZodOptional<z.ZodString>;
|
|
60
|
+
}, z.core.$strip>;
|
|
61
|
+
export type OrganizationMemberOptions = z.infer<typeof organizationMemberOptionsSchema>;
|
|
@@ -23,6 +23,16 @@ export declare const updateAppOptionsSchema: z.ZodObject<{
|
|
|
23
23
|
name: z.ZodOptional<z.ZodString>;
|
|
24
24
|
icon: z.ZodOptional<z.ZodString>;
|
|
25
25
|
retention: z.ZodOptional<z.ZodNumber>;
|
|
26
|
+
exposeMetadata: z.ZodOptional<z.ZodBoolean>;
|
|
27
|
+
preview: z.ZodOptional<z.ZodBoolean>;
|
|
28
|
+
allowDeviceCustomId: z.ZodOptional<z.ZodBoolean>;
|
|
29
|
+
blockProviderInfraRequests: z.ZodOptional<z.ZodBoolean>;
|
|
30
|
+
buildTimeoutMinutes: z.ZodOptional<z.ZodNumber>;
|
|
31
|
+
iosStoreUrl: z.ZodOptional<z.ZodString>;
|
|
32
|
+
androidStoreUrl: z.ZodOptional<z.ZodString>;
|
|
33
|
+
defaultUploadChannel: z.ZodOptional<z.ZodString>;
|
|
34
|
+
defaultDownloadChannel: z.ZodOptional<z.ZodString>;
|
|
35
|
+
disableDownloadChannels: z.ZodOptional<z.ZodBoolean>;
|
|
26
36
|
apikey: z.ZodOptional<z.ZodString>;
|
|
27
37
|
supaHost: z.ZodOptional<z.ZodString>;
|
|
28
38
|
supaAnon: z.ZodOptional<z.ZodString>;
|
|
@@ -173,6 +183,9 @@ export declare const updateChannelOptionsBaseSchema: z.ZodObject<{
|
|
|
173
183
|
downgrade: z.ZodOptional<z.ZodBoolean>;
|
|
174
184
|
ios: z.ZodOptional<z.ZodBoolean>;
|
|
175
185
|
android: z.ZodOptional<z.ZodBoolean>;
|
|
186
|
+
electron: z.ZodOptional<z.ZodBoolean>;
|
|
187
|
+
pause: z.ZodOptional<z.ZodBoolean>;
|
|
188
|
+
resume: z.ZodOptional<z.ZodBoolean>;
|
|
176
189
|
selfAssign: z.ZodOptional<z.ZodBoolean>;
|
|
177
190
|
disableAutoUpdate: z.ZodOptional<z.ZodString>;
|
|
178
191
|
updatePackage: z.ZodOptional<z.ZodEnum<{
|
|
@@ -222,6 +235,9 @@ export declare const updateChannelOptionsSchema: z.ZodObject<{
|
|
|
222
235
|
downgrade: z.ZodOptional<z.ZodBoolean>;
|
|
223
236
|
ios: z.ZodOptional<z.ZodBoolean>;
|
|
224
237
|
android: z.ZodOptional<z.ZodBoolean>;
|
|
238
|
+
electron: z.ZodOptional<z.ZodBoolean>;
|
|
239
|
+
pause: z.ZodOptional<z.ZodBoolean>;
|
|
240
|
+
resume: z.ZodOptional<z.ZodBoolean>;
|
|
225
241
|
selfAssign: z.ZodOptional<z.ZodBoolean>;
|
|
226
242
|
disableAutoUpdate: z.ZodOptional<z.ZodString>;
|
|
227
243
|
updatePackage: z.ZodOptional<z.ZodEnum<{
|
|
@@ -303,8 +319,64 @@ export declare const updateOrganizationOptionsSchema: z.ZodObject<{
|
|
|
303
319
|
orgId: z.ZodString;
|
|
304
320
|
name: z.ZodOptional<z.ZodString>;
|
|
305
321
|
email: z.ZodOptional<z.ZodString>;
|
|
322
|
+
website: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
323
|
+
enforce2fa: z.ZodOptional<z.ZodBoolean>;
|
|
324
|
+
passwordPolicy: z.ZodOptional<z.ZodBoolean>;
|
|
325
|
+
minLength: z.ZodOptional<z.ZodNumber>;
|
|
326
|
+
requireUppercase: z.ZodOptional<z.ZodBoolean>;
|
|
327
|
+
requireNumber: z.ZodOptional<z.ZodBoolean>;
|
|
328
|
+
requireSpecial: z.ZodOptional<z.ZodBoolean>;
|
|
329
|
+
requireApikeyExpiration: z.ZodOptional<z.ZodBoolean>;
|
|
330
|
+
maxApikeyExpirationDays: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
331
|
+
enforceHashedApiKeys: z.ZodOptional<z.ZodBoolean>;
|
|
332
|
+
enforceEncryptedBundles: z.ZodOptional<z.ZodBoolean>;
|
|
333
|
+
requiredEncryptionKey: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
334
|
+
emailPreferences: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
|
|
306
335
|
}, z.core.$strip>;
|
|
307
336
|
export type UpdateOrganizationOptions = z.infer<typeof updateOrganizationOptionsSchema>;
|
|
337
|
+
export declare const organizationMemberSdkOptionsSchema: z.ZodObject<{
|
|
338
|
+
apikey: z.ZodOptional<z.ZodString>;
|
|
339
|
+
supaHost: z.ZodOptional<z.ZodString>;
|
|
340
|
+
supaAnon: z.ZodOptional<z.ZodString>;
|
|
341
|
+
orgId: z.ZodString;
|
|
342
|
+
email: z.ZodString;
|
|
343
|
+
}, z.core.$strip>;
|
|
344
|
+
export type RemoveOrganizationMemberOptions = z.infer<typeof organizationMemberSdkOptionsSchema>;
|
|
345
|
+
export declare const organizationMemberRoleOptionsSchema: z.ZodObject<{
|
|
346
|
+
apikey: z.ZodOptional<z.ZodString>;
|
|
347
|
+
supaHost: z.ZodOptional<z.ZodString>;
|
|
348
|
+
supaAnon: z.ZodOptional<z.ZodString>;
|
|
349
|
+
orgId: z.ZodString;
|
|
350
|
+
email: z.ZodString;
|
|
351
|
+
role: z.ZodEnum<{
|
|
352
|
+
org_member: "org_member";
|
|
353
|
+
org_billing_admin: "org_billing_admin";
|
|
354
|
+
org_admin: "org_admin";
|
|
355
|
+
org_super_admin: "org_super_admin";
|
|
356
|
+
}>;
|
|
357
|
+
}, z.core.$strip>;
|
|
358
|
+
export type InviteOrganizationMemberOptions = z.infer<typeof organizationMemberRoleOptionsSchema>;
|
|
359
|
+
export type UpdateOrganizationMemberRoleOptions = z.infer<typeof organizationMemberRoleOptionsSchema>;
|
|
360
|
+
export declare const getAccountOptionsSchema: z.ZodObject<{
|
|
361
|
+
apikey: z.ZodOptional<z.ZodString>;
|
|
362
|
+
supaHost: z.ZodOptional<z.ZodString>;
|
|
363
|
+
supaAnon: z.ZodOptional<z.ZodString>;
|
|
364
|
+
}, z.core.$strip>;
|
|
365
|
+
export type GetAccountOptions = z.infer<typeof getAccountOptionsSchema>;
|
|
366
|
+
export declare const updateAccountOptionsSchema: z.ZodObject<{
|
|
367
|
+
apikey: z.ZodOptional<z.ZodString>;
|
|
368
|
+
supaHost: z.ZodOptional<z.ZodString>;
|
|
369
|
+
supaAnon: z.ZodOptional<z.ZodString>;
|
|
370
|
+
firstName: z.ZodOptional<z.ZodString>;
|
|
371
|
+
lastName: z.ZodOptional<z.ZodString>;
|
|
372
|
+
country: z.ZodOptional<z.ZodString>;
|
|
373
|
+
discordUsername: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
374
|
+
formatLocale: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
375
|
+
notifications: z.ZodOptional<z.ZodBoolean>;
|
|
376
|
+
newsletter: z.ZodOptional<z.ZodBoolean>;
|
|
377
|
+
emailPreferences: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodBoolean>>;
|
|
378
|
+
}, z.core.$strip>;
|
|
379
|
+
export type UpdateAccountOptions = z.infer<typeof updateAccountOptionsSchema>;
|
|
308
380
|
export declare const organizationInfoSchema: z.ZodObject<{
|
|
309
381
|
id: z.ZodString;
|
|
310
382
|
name: z.ZodString;
|
package/dist/src/sdk.d.ts
CHANGED
|
@@ -4,9 +4,11 @@ import type { EncryptResult } from './bundle/encrypt';
|
|
|
4
4
|
import type { ZipResult } from './bundle/zip';
|
|
5
5
|
import type { StarAllRepositoryResult } from './github';
|
|
6
6
|
import type { ProbeInternalResult } from './probe';
|
|
7
|
-
import type { AccountIdOptions, AddAppOptions, AddChannelOptions, AddOrganizationOptions, AppInfo, BundleCompatibilityOptions, BundleInfo, CleanupOptions, CurrentBundleOptions, DecryptBundleOptions, DeleteOldKeyOptions, DeleteOrganizationOptions, DeviceStats, DoctorOptions, EncryptBundleOptions, GenerateKeyOptions, GetStatsOptions, ListOrganizationsOptions, LoginOptions, ObserveOptions, OrganizationInfo, ProbeOptions, PromoteChannelOptions, RequestBuildOptions, SaveKeyOptions, SDKResult, SetSettingOptions, StarAllRepositoriesOptions, StarRepoOptions, UpdateAppOptions, UpdateChannelOptions, UpdateOrganizationOptions, UploadOptions, UploadResult, ZipBundleOptions } from './schemas/sdk';
|
|
7
|
+
import type { AccountIdOptions, AddAppOptions, AddChannelOptions, AddOrganizationOptions, AppInfo, BundleCompatibilityOptions, BundleInfo, CleanupOptions, CurrentBundleOptions, DecryptBundleOptions, DeleteOldKeyOptions, DeleteOrganizationOptions, DeviceStats, DoctorOptions, EncryptBundleOptions, GenerateKeyOptions, GetAccountOptions, GetStatsOptions, InviteOrganizationMemberOptions, ListOrganizationsOptions, LoginOptions, ObserveOptions, OrganizationInfo, ProbeOptions, PromoteChannelOptions, RemoveOrganizationMemberOptions, RequestBuildOptions, SaveKeyOptions, SDKResult, SetSettingOptions, StarAllRepositoriesOptions, StarRepoOptions, UpdateAccountOptions, UpdateAppOptions, UpdateChannelOptions, UpdateOrganizationMemberRoleOptions, UpdateOrganizationOptions, UploadOptions, UploadResult, ZipBundleOptions } from './schemas/sdk';
|
|
8
|
+
import type { AccountProfile } from './schemas/account';
|
|
8
9
|
import { getInfoInternal } from './app/info';
|
|
9
10
|
import { checkCompatibilityInternal } from './bundle/compatibility';
|
|
11
|
+
import { listMembersInternal } from './organization/members';
|
|
10
12
|
export type DoctorInfo = Awaited<ReturnType<typeof getInfoInternal>>;
|
|
11
13
|
type CompatibilityReport = Awaited<ReturnType<typeof checkCompatibilityInternal>>['finalCompatibility'];
|
|
12
14
|
export type BundleCompatibilityEntry = CompatibilityReport[number];
|
|
@@ -332,6 +334,40 @@ export declare class CapgoSDK {
|
|
|
332
334
|
deleteOrganization(orgId: string, options?: DeleteOrganizationOptions): Promise<SDKResult<{
|
|
333
335
|
deleted: boolean;
|
|
334
336
|
}>>;
|
|
337
|
+
/**
|
|
338
|
+
* List the members of an organization with their role, invite state, and 2FA status
|
|
339
|
+
*/
|
|
340
|
+
listOrganizationMembers(orgId: string, options?: ListOrganizationsOptions): Promise<SDKResult<Awaited<ReturnType<typeof listMembersInternal>>>>;
|
|
341
|
+
/**
|
|
342
|
+
* Invite a user to an organization by email
|
|
343
|
+
*
|
|
344
|
+
* @example
|
|
345
|
+
* ```typescript
|
|
346
|
+
* await sdk.inviteOrganizationMember({ orgId, email: 'teammate@example.com', role: 'org_admin' })
|
|
347
|
+
* ```
|
|
348
|
+
*/
|
|
349
|
+
inviteOrganizationMember(options: InviteOrganizationMemberOptions): Promise<SDKResult>;
|
|
350
|
+
/**
|
|
351
|
+
* Change the role of an organization member or pending invite
|
|
352
|
+
*/
|
|
353
|
+
updateOrganizationMemberRole(options: UpdateOrganizationMemberRoleOptions): Promise<SDKResult>;
|
|
354
|
+
/**
|
|
355
|
+
* Remove a member from an organization
|
|
356
|
+
*/
|
|
357
|
+
removeOrganizationMember(options: RemoveOrganizationMemberOptions): Promise<SDKResult>;
|
|
358
|
+
/**
|
|
359
|
+
* Get the profile and email notification settings of the account that owns the API key
|
|
360
|
+
*/
|
|
361
|
+
getAccount(options?: GetAccountOptions): Promise<SDKResult<AccountProfile>>;
|
|
362
|
+
/**
|
|
363
|
+
* Update the profile and email notification settings of the account that owns the API key
|
|
364
|
+
*
|
|
365
|
+
* @example
|
|
366
|
+
* ```typescript
|
|
367
|
+
* await sdk.updateAccount({ firstName: 'Ada', emailPreferences: { weekly_stats: false } })
|
|
368
|
+
* ```
|
|
369
|
+
*/
|
|
370
|
+
updateAccount(options: UpdateAccountOptions): Promise<SDKResult<AccountProfile>>;
|
|
335
371
|
/**
|
|
336
372
|
* Get device statistics/logs from Capgo backend
|
|
337
373
|
*
|
|
@@ -428,6 +464,11 @@ export declare function updateOrganization(options: UpdateOrganizationOptions):
|
|
|
428
464
|
export declare function deleteOrganization(orgId: string, options?: DeleteOrganizationOptions): Promise<SDKResult<{
|
|
429
465
|
deleted: boolean;
|
|
430
466
|
}>>;
|
|
467
|
+
export declare function inviteOrganizationMember(options: InviteOrganizationMemberOptions): Promise<SDKResult>;
|
|
468
|
+
export declare function updateOrganizationMemberRole(options: UpdateOrganizationMemberRoleOptions): Promise<SDKResult>;
|
|
469
|
+
export declare function removeOrganizationMember(options: RemoveOrganizationMemberOptions): Promise<SDKResult>;
|
|
470
|
+
export declare function getAccount(options?: GetAccountOptions): Promise<SDKResult<AccountProfile>>;
|
|
471
|
+
export declare function updateAccount(options: UpdateAccountOptions): Promise<SDKResult<AccountProfile>>;
|
|
431
472
|
/**
|
|
432
473
|
* Add a new app to Capgo Cloud (functional API)
|
|
433
474
|
*
|
|
@@ -555,7 +596,8 @@ export declare function getCapacitorConfig(): Promise<import("./config").ExtConf
|
|
|
555
596
|
export type { BuildCredentials } from './build/request';
|
|
556
597
|
export type { CapacitorConfig } from './config';
|
|
557
598
|
export type { ProbeInternalResult } from './probe';
|
|
558
|
-
export type { AccountIdOptions, AddAppOptions, AddChannelOptions, AddOrganizationOptions, AppInfo, BundleCompatibilityOptions, BundleInfo, CleanupOptions, CurrentBundleOptions, DecryptBundleOptions, DeleteOldKeyOptions, DeleteOrganizationOptions, DeviceStats, DoctorOptions, EncryptBundleOptions, GenerateKeyOptions, GetStatsOptions, ListOrganizationsOptions, LoginOptions, ObserveOptions, OrganizationInfo, ProbeOptions, PromoteChannelOptions, RequestBuildOptions, SaveKeyOptions, SDKResult, SetSettingOptions, StarAllRepositoriesOptions, StarRepoOptions, StatsOrder, UpdateAppOptions, UpdateChannelOptions, UpdateOrganizationOptions, UploadOptions, UploadResult, ZipBundleOptions, } from './schemas/sdk';
|
|
599
|
+
export type { AccountIdOptions, AddAppOptions, AddChannelOptions, AddOrganizationOptions, AppInfo, BundleCompatibilityOptions, BundleInfo, CleanupOptions, CurrentBundleOptions, DecryptBundleOptions, DeleteOldKeyOptions, DeleteOrganizationOptions, DeviceStats, DoctorOptions, EncryptBundleOptions, GenerateKeyOptions, GetAccountOptions, GetStatsOptions, InviteOrganizationMemberOptions, ListOrganizationsOptions, LoginOptions, ObserveOptions, OrganizationInfo, ProbeOptions, PromoteChannelOptions, RemoveOrganizationMemberOptions, RequestBuildOptions, SaveKeyOptions, SDKResult, SetSettingOptions, StarAllRepositoriesOptions, StarRepoOptions, StatsOrder, UpdateAccountOptions, UpdateAppOptions, UpdateChannelOptions, UpdateOrganizationMemberRoleOptions, UpdateOrganizationOptions, UploadOptions, UploadResult, ZipBundleOptions, } from './schemas/sdk';
|
|
600
|
+
export type { AccountProfile } from './schemas/account';
|
|
559
601
|
export type { Database } from './types/supabase.types';
|
|
560
602
|
export { createSupabaseClient } from './utils';
|
|
561
603
|
export { formatApiErrorForCli, getSecurityPolicyMessage, isSecurityPolicyError, parseSecurityPolicyError, SECURITY_POLICY_ERRORS, SECURITY_POLICY_MESSAGES, } from './utils/security_policy_errors';
|