@supernova-studio/client 0.54.4 → 0.54.5

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/dist/index.mjs CHANGED
@@ -20,12 +20,12 @@ import { z as z11 } from "zod";
20
20
  import { z as z12 } from "zod";
21
21
  import { z as z13 } from "zod";
22
22
  import { z as z14 } from "zod";
23
- import { z as z128 } from "zod";
23
+ import { z as z125 } from "zod";
24
24
  import { z as z17 } from "zod";
25
25
  import { z as z15 } from "zod";
26
26
  import { z as z16 } from "zod";
27
- import { z as z127 } from "zod";
28
- import { z as z126 } from "zod";
27
+ import { z as z124 } from "zod";
28
+ import { z as z123 } from "zod";
29
29
  import { z as z18 } from "zod";
30
30
  import { z as z19 } from "zod";
31
31
  import { z as z20 } from "zod";
@@ -125,36 +125,36 @@ import { z as z112 } from "zod";
125
125
  import { z as z113 } from "zod";
126
126
  import { z as z114 } from "zod";
127
127
  import { z as z115 } from "zod";
128
- import { z as z120 } from "zod";
129
- import { z as z119 } from "zod";
130
- import IPCIDR from "ip-cidr";
131
- import { z as z118 } from "zod";
132
- import { z as z116 } from "zod";
133
128
  import { z as z117 } from "zod";
129
+ import { z as z116 } from "zod";
130
+ import { z as z118 } from "zod";
131
+ import { z as z119 } from "zod";
132
+ import { z as z120 } from "zod";
134
133
  import { z as z121 } from "zod";
135
134
  import { z as z122 } from "zod";
136
- import { z as z123 } from "zod";
137
- import { z as z124 } from "zod";
138
- import { z as z125 } from "zod";
139
- import { z as z135 } from "zod";
140
- import { z as z134 } from "zod";
135
+ import { z as z132 } from "zod";
136
+ import { z as z131 } from "zod";
137
+ import { z as z126 } from "zod";
138
+ import { z as z127 } from "zod";
139
+ import { z as z128 } from "zod";
141
140
  import { z as z129 } from "zod";
142
141
  import { z as z130 } from "zod";
143
- import { z as z131 } from "zod";
144
- import { z as z132 } from "zod";
145
- import { z as z133 } from "zod";
146
142
  import { z as z147 } from "zod";
143
+ import { z as z133 } from "zod";
144
+ import { z as z134 } from "zod";
145
+ import { z as z135 } from "zod";
147
146
  import { z as z136 } from "zod";
148
147
  import { z as z137 } from "zod";
149
148
  import { z as z138 } from "zod";
150
149
  import { z as z139 } from "zod";
151
150
  import { z as z140 } from "zod";
152
151
  import { z as z141 } from "zod";
152
+ import { z as z146 } from "zod";
153
153
  import { z as z142 } from "zod";
154
+ import IPCIDR from "ip-cidr";
155
+ import { z as z145 } from "zod";
154
156
  import { z as z143 } from "zod";
155
157
  import { z as z144 } from "zod";
156
- import { z as z146 } from "zod";
157
- import { z as z145 } from "zod";
158
158
  import { z as z148 } from "zod";
159
159
  import { z as z151 } from "zod";
160
160
  import { z as z149 } from "zod";
@@ -3588,120 +3588,37 @@ var Brand = z115.object({
3588
3588
  name: z115.string(),
3589
3589
  description: z115.string()
3590
3590
  });
3591
- var NpmRegistryAuthType = z116.enum(["Basic", "Bearer", "None", "Custom"]);
3592
- var NpmRegistryType = z116.enum(["NPMJS", "GitHub", "AzureDevOps", "Artifactory", "Custom"]);
3593
- var NpmRegistryBasicAuthConfig = z116.object({
3594
- authType: z116.literal(NpmRegistryAuthType.Enum.Basic),
3595
- username: z116.string(),
3596
- password: z116.string()
3597
- });
3598
- var NpmRegistryBearerAuthConfig = z116.object({
3599
- authType: z116.literal(NpmRegistryAuthType.Enum.Bearer),
3600
- accessToken: z116.string()
3601
- });
3602
- var NpmRegistryNoAuthConfig = z116.object({
3603
- authType: z116.literal(NpmRegistryAuthType.Enum.None)
3604
- });
3605
- var NpmRegistrCustomAuthConfig = z116.object({
3606
- authType: z116.literal(NpmRegistryAuthType.Enum.Custom),
3607
- authHeaderName: z116.string(),
3608
- authHeaderValue: z116.string()
3609
- });
3610
- var NpmRegistryAuthConfig = z116.discriminatedUnion("authType", [
3611
- NpmRegistryBasicAuthConfig,
3612
- NpmRegistryBearerAuthConfig,
3613
- NpmRegistryNoAuthConfig,
3614
- NpmRegistrCustomAuthConfig
3615
- ]);
3616
- var NpmRegistryConfigBase = z116.object({
3617
- registryType: NpmRegistryType,
3618
- enabledScopes: z116.array(z116.string()),
3619
- customRegistryUrl: z116.string().optional(),
3620
- bypassProxy: z116.boolean().default(false),
3621
- npmProxyRegistryConfigId: z116.string().optional(),
3622
- npmProxyVersion: z116.number().optional()
3623
- });
3624
- var NpmRegistryConfig = NpmRegistryConfigBase.and(NpmRegistryAuthConfig);
3625
- var SsoProvider = z117.object({
3626
- providerId: z117.string(),
3627
- defaultAutoInviteValue: z117.boolean(),
3628
- autoInviteDomains: z117.record(z117.string(), z117.boolean()),
3629
- skipDocsSupernovaLogin: z117.boolean(),
3630
- areInvitesDisabled: z117.boolean(),
3631
- isTestMode: z117.boolean(),
3632
- emailDomains: z117.array(z117.string()),
3633
- metadataXml: z117.string().nullish()
3634
- });
3635
- var isValidCIDR = (value) => {
3636
- return IPCIDR.isValidAddress(value);
3637
- };
3638
- var WorkspaceIpWhitelistEntry = z118.object({
3639
- isEnabled: z118.boolean(),
3640
- name: z118.string(),
3641
- range: z118.string().refine(isValidCIDR, {
3642
- message: "Invalid IP CIDR"
3643
- })
3644
- });
3645
- var WorkspaceIpSettings = z118.object({
3646
- isEnabledForCloud: z118.boolean(),
3647
- isEnabledForDocs: z118.boolean(),
3648
- entries: z118.array(WorkspaceIpWhitelistEntry)
3649
- });
3650
- var WorkspaceProfile = z118.object({
3651
- name: z118.string(),
3652
- handle: z118.string(),
3653
- color: z118.string(),
3654
- avatar: nullishToOptional(z118.string()),
3655
- billingDetails: nullishToOptional(BillingDetails)
3656
- });
3657
- var WorkspaceProfileUpdate = WorkspaceProfile.omit({
3658
- avatar: true
3659
- });
3660
- var Workspace = z118.object({
3661
- id: z118.string(),
3662
- profile: WorkspaceProfile,
3663
- subscription: Subscription,
3664
- ipWhitelist: nullishToOptional(WorkspaceIpSettings),
3665
- sso: nullishToOptional(SsoProvider),
3666
- npmRegistrySettings: nullishToOptional(NpmRegistryConfig)
3667
- });
3668
- var WorkspaceWithDesignSystems = z118.object({
3669
- workspace: Workspace,
3670
- designSystems: z118.array(DesignSystem)
3671
- });
3672
- var DesignSystemSwitcher = z119.object({
3673
- isEnabled: z119.boolean(),
3674
- designSystemIds: z119.array(z119.string())
3675
- });
3676
- var DesignSystem = z119.object({
3677
- id: z119.string(),
3678
- workspaceId: z119.string(),
3679
- name: z119.string(),
3680
- description: z119.string(),
3681
- docExporterId: nullishToOptional(z119.string()),
3682
- docSlug: z119.string(),
3683
- docUserSlug: nullishToOptional(z119.string()),
3684
- docSlugDeprecated: z119.string(),
3685
- isPublic: z119.boolean(),
3686
- isMultibrand: z119.boolean(),
3687
- docViewUrl: nullishToOptional(z119.string()),
3688
- basePrefixes: z119.array(z119.string()),
3591
+ var DesignSystemAccessMode = z116.enum(["Open", "InviteOnly"]);
3592
+ var DesignSystemSwitcher = z116.object({
3593
+ isEnabled: z116.boolean(),
3594
+ designSystemIds: z116.array(z116.string())
3595
+ });
3596
+ var DesignSystem = z116.object({
3597
+ id: z116.string(),
3598
+ workspaceId: z116.string(),
3599
+ name: z116.string(),
3600
+ description: z116.string(),
3601
+ docExporterId: nullishToOptional(z116.string()),
3602
+ docSlug: z116.string(),
3603
+ docUserSlug: nullishToOptional(z116.string()),
3604
+ docSlugDeprecated: z116.string(),
3605
+ isPublic: z116.boolean(),
3606
+ isMultibrand: z116.boolean(),
3607
+ docViewUrl: nullishToOptional(z116.string()),
3608
+ basePrefixes: z116.array(z116.string()),
3689
3609
  designSystemSwitcher: nullishToOptional(DesignSystemSwitcher),
3690
- isApprovalFeatureEnabled: z119.boolean(),
3691
- approvalRequiredForPublishing: z119.boolean(),
3692
- createdAt: z119.coerce.date(),
3693
- updatedAt: z119.coerce.date()
3694
- });
3695
- var DesignSystemWithWorkspace = z119.object({
3696
- designSystem: DesignSystem,
3697
- workspace: Workspace
3610
+ isApprovalFeatureEnabled: z116.boolean(),
3611
+ approvalRequiredForPublishing: z116.boolean(),
3612
+ accessMode: DesignSystemAccessMode,
3613
+ createdAt: z116.coerce.date(),
3614
+ updatedAt: z116.coerce.date()
3698
3615
  });
3699
3616
  var DS_NAME_MIN_LENGTH = 2;
3700
3617
  var DS_NAME_MAX_LENGTH = 64;
3701
3618
  var DS_DESC_MAX_LENGTH = 2048;
3702
- var DesignSystemUpdateInputMetadata = z120.object({
3703
- name: z120.string().min(DS_NAME_MIN_LENGTH).max(DS_NAME_MAX_LENGTH).trim().optional(),
3704
- description: z120.string().max(DS_DESC_MAX_LENGTH).trim().optional()
3619
+ var DesignSystemUpdateInputMetadata = z117.object({
3620
+ name: z117.string().min(DS_NAME_MIN_LENGTH).max(DS_NAME_MAX_LENGTH).trim().optional(),
3621
+ description: z117.string().max(DS_DESC_MAX_LENGTH).trim().optional()
3705
3622
  });
3706
3623
  var DesignSystemUpdateInput = DesignSystem.partial().omit({
3707
3624
  id: true,
@@ -3716,173 +3633,173 @@ var DesignSystemUpdateInput = DesignSystem.partial().omit({
3716
3633
  var DS_NAME_MIN_LENGTH2 = 2;
3717
3634
  var DS_NAME_MAX_LENGTH2 = 64;
3718
3635
  var DS_DESC_MAX_LENGTH2 = 64;
3719
- var DesignSystemCreateInputMetadata = z121.object({
3720
- name: z121.string().min(DS_NAME_MIN_LENGTH2).max(DS_NAME_MAX_LENGTH2).trim(),
3721
- description: z121.string().max(DS_DESC_MAX_LENGTH2).trim()
3636
+ var DesignSystemCreateInputMetadata = z118.object({
3637
+ name: z118.string().min(DS_NAME_MIN_LENGTH2).max(DS_NAME_MAX_LENGTH2).trim(),
3638
+ description: z118.string().max(DS_DESC_MAX_LENGTH2).trim()
3722
3639
  });
3723
- var DesignSystemCreateInput = z121.object({
3640
+ var DesignSystemCreateInput = z118.object({
3724
3641
  meta: DesignSystemCreateInputMetadata,
3725
- workspaceId: z121.string(),
3726
- isPublic: z121.boolean().optional(),
3727
- basePrefixes: z121.array(z121.string()).optional(),
3728
- docUserSlug: z121.string().nullish().optional(),
3729
- source: z121.array(z121.string()).optional()
3642
+ workspaceId: z118.string(),
3643
+ isPublic: z118.boolean().optional(),
3644
+ basePrefixes: z118.array(z118.string()).optional(),
3645
+ docUserSlug: z118.string().nullish().optional(),
3646
+ source: z118.array(z118.string()).optional()
3730
3647
  });
3731
- var ExporterPropertyImageValue = z122.object({
3648
+ var ExporterPropertyImageValue = z119.object({
3732
3649
  asset: PageBlockAsset.optional(),
3733
- assetId: z122.string().optional(),
3734
- assetUrl: z122.string().optional()
3735
- });
3736
- var ExporterPropertyValue = z122.object({
3737
- key: z122.string(),
3738
- value: z122.union([
3739
- z122.number(),
3740
- z122.string(),
3741
- z122.boolean(),
3650
+ assetId: z119.string().optional(),
3651
+ assetUrl: z119.string().optional()
3652
+ });
3653
+ var ExporterPropertyValue = z119.object({
3654
+ key: z119.string(),
3655
+ value: z119.union([
3656
+ z119.number(),
3657
+ z119.string(),
3658
+ z119.boolean(),
3742
3659
  ExporterPropertyImageValue,
3743
3660
  ColorTokenData,
3744
3661
  TypographyTokenData
3745
3662
  ])
3746
3663
  });
3747
- var ExporterPropertyValuesCollection = z122.object({
3748
- id: z122.string(),
3749
- designSystemId: z122.string(),
3750
- exporterId: z122.string(),
3751
- values: z122.array(ExporterPropertyValue)
3752
- });
3753
- var PublishedDocPage = z123.object({
3754
- id: z123.string(),
3755
- publishedDocId: z123.string(),
3756
- pageShortPersistentId: z123.string(),
3757
- pathV1: z123.string(),
3758
- pathV2: z123.string(),
3759
- storagePath: z123.string(),
3760
- locale: z123.string().optional(),
3761
- isPrivate: z123.boolean(),
3762
- isHidden: z123.boolean(),
3763
- createdAt: z123.coerce.date(),
3764
- updatedAt: z123.coerce.date()
3664
+ var ExporterPropertyValuesCollection = z119.object({
3665
+ id: z119.string(),
3666
+ designSystemId: z119.string(),
3667
+ exporterId: z119.string(),
3668
+ values: z119.array(ExporterPropertyValue)
3669
+ });
3670
+ var PublishedDocPage = z120.object({
3671
+ id: z120.string(),
3672
+ publishedDocId: z120.string(),
3673
+ pageShortPersistentId: z120.string(),
3674
+ pathV1: z120.string(),
3675
+ pathV2: z120.string(),
3676
+ storagePath: z120.string(),
3677
+ locale: z120.string().optional(),
3678
+ isPrivate: z120.boolean(),
3679
+ isHidden: z120.boolean(),
3680
+ createdAt: z120.coerce.date(),
3681
+ updatedAt: z120.coerce.date()
3765
3682
  });
3766
3683
  var publishedDocEnvironments = ["Live", "Preview"];
3767
- var PublishedDocEnvironment = z124.enum(publishedDocEnvironments);
3768
- var PublishedDocsChecksums = z124.record(z124.string());
3769
- var PublishedDocRoutingVersion = z124.enum(["1", "2"]);
3770
- var PublishedDoc = z124.object({
3771
- id: z124.string(),
3772
- designSystemVersionId: z124.string(),
3773
- createdAt: z124.coerce.date(),
3774
- updatedAt: z124.coerce.date(),
3775
- lastPublishedAt: z124.coerce.date(),
3776
- isDefault: z124.boolean(),
3777
- isPublic: z124.boolean(),
3684
+ var PublishedDocEnvironment = z121.enum(publishedDocEnvironments);
3685
+ var PublishedDocsChecksums = z121.record(z121.string());
3686
+ var PublishedDocRoutingVersion = z121.enum(["1", "2"]);
3687
+ var PublishedDoc = z121.object({
3688
+ id: z121.string(),
3689
+ designSystemVersionId: z121.string(),
3690
+ createdAt: z121.coerce.date(),
3691
+ updatedAt: z121.coerce.date(),
3692
+ lastPublishedAt: z121.coerce.date(),
3693
+ isDefault: z121.boolean(),
3694
+ isPublic: z121.boolean(),
3778
3695
  environment: PublishedDocEnvironment,
3779
3696
  checksums: PublishedDocsChecksums,
3780
- storagePath: z124.string(),
3781
- wasMigrated: z124.boolean(),
3697
+ storagePath: z121.string(),
3698
+ wasMigrated: z121.boolean(),
3782
3699
  routingVersion: PublishedDocRoutingVersion,
3783
- usesLocalizations: z124.boolean(),
3784
- wasPublishedWithLocalizations: z124.boolean(),
3785
- tokenCount: z124.number(),
3786
- assetCount: z124.number()
3700
+ usesLocalizations: z121.boolean(),
3701
+ wasPublishedWithLocalizations: z121.boolean(),
3702
+ tokenCount: z121.number(),
3703
+ assetCount: z121.number()
3787
3704
  });
3788
- var DesignSystemVersion = z125.object({
3789
- id: z125.string(),
3790
- version: z125.string(),
3791
- createdAt: z125.coerce.date(),
3792
- designSystemId: z125.string(),
3793
- name: z125.string(),
3794
- comment: z125.string(),
3795
- isReadonly: z125.boolean(),
3796
- changeLog: z125.string(),
3797
- parentId: z125.string().optional(),
3798
- isDraftsFeatureAdopted: z125.boolean()
3799
- });
3800
- var VersionCreationJobStatus = z125.enum(["Success", "InProgress", "Error"]);
3801
- var VersionCreationJob = z125.object({
3802
- id: z125.string(),
3803
- version: z125.string(),
3804
- designSystemId: z125.string(),
3805
- designSystemVersionId: nullishToOptional(z125.string()),
3705
+ var DesignSystemVersion = z122.object({
3706
+ id: z122.string(),
3707
+ version: z122.string(),
3708
+ createdAt: z122.coerce.date(),
3709
+ designSystemId: z122.string(),
3710
+ name: z122.string(),
3711
+ comment: z122.string(),
3712
+ isReadonly: z122.boolean(),
3713
+ changeLog: z122.string(),
3714
+ parentId: z122.string().optional(),
3715
+ isDraftsFeatureAdopted: z122.boolean()
3716
+ });
3717
+ var VersionCreationJobStatus = z122.enum(["Success", "InProgress", "Error"]);
3718
+ var VersionCreationJob = z122.object({
3719
+ id: z122.string(),
3720
+ version: z122.string(),
3721
+ designSystemId: z122.string(),
3722
+ designSystemVersionId: nullishToOptional(z122.string()),
3806
3723
  status: VersionCreationJobStatus,
3807
- errorMessage: nullishToOptional(z125.string())
3724
+ errorMessage: nullishToOptional(z122.string())
3808
3725
  });
3809
3726
  var BITBUCKET_SLUG = /^[-a-zA-Z0-9~]*$/;
3810
3727
  var BITBUCKET_MAX_LENGTH = 64;
3811
- var ExportJobDocumentationChanges = z126.object({
3812
- pagePersistentIds: z126.string().array(),
3813
- groupPersistentIds: z126.string().array()
3728
+ var ExportJobDocumentationChanges = z123.object({
3729
+ pagePersistentIds: z123.string().array(),
3730
+ groupPersistentIds: z123.string().array()
3814
3731
  });
3815
- var ExporterDestinationDocs = z126.object({
3732
+ var ExporterDestinationDocs = z123.object({
3816
3733
  environment: PublishedDocEnvironment,
3817
3734
  changes: nullishToOptional(ExportJobDocumentationChanges)
3818
3735
  });
3819
- var ExporterDestinationS3 = z126.object({});
3820
- var ExporterDestinationGithub = z126.object({
3821
- credentialId: z126.string().optional(),
3736
+ var ExporterDestinationS3 = z123.object({});
3737
+ var ExporterDestinationGithub = z123.object({
3738
+ credentialId: z123.string().optional(),
3822
3739
  // Repository
3823
- url: z126.string(),
3740
+ url: z123.string(),
3824
3741
  // Location
3825
- branch: z126.string(),
3826
- relativePath: nullishToOptional(z126.string()),
3742
+ branch: z123.string(),
3743
+ relativePath: nullishToOptional(z123.string()),
3827
3744
  // Commit metadata
3828
- commitAuthorName: nullishToOptional(z126.string()),
3829
- commitAuthorEmail: nullishToOptional(z126.string()),
3745
+ commitAuthorName: nullishToOptional(z123.string()),
3746
+ commitAuthorEmail: nullishToOptional(z123.string()),
3830
3747
  // Legacy deprecated fields. Use `credentialId` instead
3831
- connectionId: nullishToOptional(z126.string()),
3832
- userId: nullishToOptional(z126.number())
3748
+ connectionId: nullishToOptional(z123.string()),
3749
+ userId: nullishToOptional(z123.number())
3833
3750
  });
3834
- var ExporterDestinationAzure = z126.object({
3835
- credentialId: z126.string().optional(),
3751
+ var ExporterDestinationAzure = z123.object({
3752
+ credentialId: z123.string().optional(),
3836
3753
  // Repository
3837
- organizationId: z126.string(),
3838
- projectId: z126.string(),
3839
- repositoryId: z126.string(),
3754
+ organizationId: z123.string(),
3755
+ projectId: z123.string(),
3756
+ repositoryId: z123.string(),
3840
3757
  // Commit metadata
3841
- commitAuthorName: nullishToOptional(z126.string()),
3842
- commitAuthorEmail: nullishToOptional(z126.string()),
3758
+ commitAuthorName: nullishToOptional(z123.string()),
3759
+ commitAuthorEmail: nullishToOptional(z123.string()),
3843
3760
  // Location
3844
- branch: z126.string(),
3845
- relativePath: nullishToOptional(z126.string()),
3761
+ branch: z123.string(),
3762
+ relativePath: nullishToOptional(z123.string()),
3846
3763
  // Maybe not needed
3847
- url: nullishToOptional(z126.string()),
3764
+ url: nullishToOptional(z123.string()),
3848
3765
  // Legacy deprecated fields. Use `credentialId` instead
3849
- connectionId: nullishToOptional(z126.string()),
3850
- userId: nullishToOptional(z126.number())
3766
+ connectionId: nullishToOptional(z123.string()),
3767
+ userId: nullishToOptional(z123.number())
3851
3768
  });
3852
- var ExporterDestinationGitlab = z126.object({
3853
- credentialId: z126.string().optional(),
3769
+ var ExporterDestinationGitlab = z123.object({
3770
+ credentialId: z123.string().optional(),
3854
3771
  // Repository
3855
- projectId: z126.string(),
3772
+ projectId: z123.string(),
3856
3773
  // Commit metadata
3857
- commitAuthorName: nullishToOptional(z126.string()),
3858
- commitAuthorEmail: nullishToOptional(z126.string()),
3774
+ commitAuthorName: nullishToOptional(z123.string()),
3775
+ commitAuthorEmail: nullishToOptional(z123.string()),
3859
3776
  // Location
3860
- branch: z126.string(),
3861
- relativePath: nullishToOptional(z126.string()),
3777
+ branch: z123.string(),
3778
+ relativePath: nullishToOptional(z123.string()),
3862
3779
  // Maybe not needed
3863
- url: nullishToOptional(z126.string()),
3780
+ url: nullishToOptional(z123.string()),
3864
3781
  // Legacy deprecated fields. Use `credentialId` instead
3865
- connectionId: nullishToOptional(z126.string()),
3866
- userId: nullishToOptional(z126.number())
3782
+ connectionId: nullishToOptional(z123.string()),
3783
+ userId: nullishToOptional(z123.number())
3867
3784
  });
3868
- var ExporterDestinationBitbucket = z126.object({
3869
- credentialId: z126.string().optional(),
3785
+ var ExporterDestinationBitbucket = z123.object({
3786
+ credentialId: z123.string().optional(),
3870
3787
  // Repository
3871
- workspaceSlug: z126.string().max(BITBUCKET_MAX_LENGTH).regex(BITBUCKET_SLUG),
3872
- projectKey: z126.string().max(BITBUCKET_MAX_LENGTH).regex(BITBUCKET_SLUG),
3873
- repoSlug: z126.string().max(BITBUCKET_MAX_LENGTH).regex(BITBUCKET_SLUG),
3788
+ workspaceSlug: z123.string().max(BITBUCKET_MAX_LENGTH).regex(BITBUCKET_SLUG),
3789
+ projectKey: z123.string().max(BITBUCKET_MAX_LENGTH).regex(BITBUCKET_SLUG),
3790
+ repoSlug: z123.string().max(BITBUCKET_MAX_LENGTH).regex(BITBUCKET_SLUG),
3874
3791
  // Commit metadata
3875
- commitAuthorName: nullishToOptional(z126.string()),
3876
- commitAuthorEmail: nullishToOptional(z126.string()),
3792
+ commitAuthorName: nullishToOptional(z123.string()),
3793
+ commitAuthorEmail: nullishToOptional(z123.string()),
3877
3794
  // Location
3878
- branch: z126.string(),
3879
- relativePath: nullishToOptional(z126.string()),
3795
+ branch: z123.string(),
3796
+ relativePath: nullishToOptional(z123.string()),
3880
3797
  // Legacy deprecated fields. Use `credentialId` instead
3881
- connectionId: nullishToOptional(z126.string()),
3882
- userId: nullishToOptional(z126.number())
3798
+ connectionId: nullishToOptional(z123.string()),
3799
+ userId: nullishToOptional(z123.number())
3883
3800
  });
3884
- var ExportDestinationsMap = z126.object({
3885
- webhookUrl: z126.string().optional(),
3801
+ var ExportDestinationsMap = z123.object({
3802
+ webhookUrl: z123.string().optional(),
3886
3803
  destinationSnDocs: ExporterDestinationDocs.optional(),
3887
3804
  destinationS3: ExporterDestinationS3.optional(),
3888
3805
  destinationGithub: ExporterDestinationGithub.optional(),
@@ -3890,92 +3807,92 @@ var ExportDestinationsMap = z126.object({
3890
3807
  destinationGitlab: ExporterDestinationGitlab.optional(),
3891
3808
  destinationBitbucket: ExporterDestinationBitbucket.optional()
3892
3809
  });
3893
- var PipelineEventType = z127.enum(["OnVersionReleased", "OnHeadChanged", "OnSourceUpdated", "None"]);
3894
- var PipelineDestinationGitType = z127.enum(["Github", "Gitlab", "Bitbucket", "Azure"]);
3895
- var PipelineDestinationExtraType = z127.enum(["WebhookUrl", "S3", "Documentation"]);
3896
- var PipelineDestinationType = z127.union([PipelineDestinationGitType, PipelineDestinationExtraType]);
3897
- var Pipeline = z127.object({
3898
- id: z127.string(),
3899
- name: z127.string(),
3810
+ var PipelineEventType = z124.enum(["OnVersionReleased", "OnHeadChanged", "OnSourceUpdated", "None"]);
3811
+ var PipelineDestinationGitType = z124.enum(["Github", "Gitlab", "Bitbucket", "Azure"]);
3812
+ var PipelineDestinationExtraType = z124.enum(["WebhookUrl", "S3", "Documentation"]);
3813
+ var PipelineDestinationType = z124.union([PipelineDestinationGitType, PipelineDestinationExtraType]);
3814
+ var Pipeline = z124.object({
3815
+ id: z124.string(),
3816
+ name: z124.string(),
3900
3817
  eventType: PipelineEventType,
3901
- isEnabled: z127.boolean(),
3902
- workspaceId: z127.string(),
3903
- designSystemId: z127.string(),
3904
- exporterId: z127.string(),
3905
- brandPersistentId: z127.string().optional(),
3906
- themePersistentId: z127.string().optional(),
3818
+ isEnabled: z124.boolean(),
3819
+ workspaceId: z124.string(),
3820
+ designSystemId: z124.string(),
3821
+ exporterId: z124.string(),
3822
+ brandPersistentId: z124.string().optional(),
3823
+ themePersistentId: z124.string().optional(),
3907
3824
  // Destinations
3908
3825
  ...ExportDestinationsMap.shape
3909
3826
  });
3910
- var ExportJobDump = z128.object({
3911
- id: z128.string(),
3912
- createdAt: z128.coerce.date(),
3913
- finishedAt: z128.coerce.date(),
3914
- exportArtefacts: z128.string()
3827
+ var ExportJobDump = z125.object({
3828
+ id: z125.string(),
3829
+ createdAt: z125.coerce.date(),
3830
+ finishedAt: z125.coerce.date(),
3831
+ exportArtefacts: z125.string()
3915
3832
  });
3916
- var CodeIntegrationDump = z128.object({
3833
+ var CodeIntegrationDump = z125.object({
3917
3834
  exporters: Exporter.array(),
3918
3835
  pipelines: Pipeline.array(),
3919
3836
  exportJobs: ExportJobDump.array()
3920
3837
  });
3921
3838
  var DesignSystemVersionRoom = Entity.extend({
3922
- designSystemVersionId: z129.string(),
3923
- liveblocksId: z129.string()
3924
- });
3925
- var DesignSystemVersionRoomInternalSettings = z129.object({
3926
- routingVersion: z129.string(),
3927
- isDraftFeatureAdopted: z129.boolean(),
3928
- isApprovalFeatureEnabled: z129.boolean(),
3929
- approvalRequiredForPublishing: z129.boolean()
3930
- });
3931
- var DesignSystemVersionRoomInitialState = z129.object({
3932
- pages: z129.array(DocumentationPageV2),
3933
- groups: z129.array(ElementGroup),
3934
- pageSnapshots: z129.array(DocumentationPageSnapshot),
3935
- groupSnapshots: z129.array(ElementGroupSnapshot),
3936
- pageApprovals: z129.array(DocumentationPageApproval),
3839
+ designSystemVersionId: z126.string(),
3840
+ liveblocksId: z126.string()
3841
+ });
3842
+ var DesignSystemVersionRoomInternalSettings = z126.object({
3843
+ routingVersion: z126.string(),
3844
+ isDraftFeatureAdopted: z126.boolean(),
3845
+ isApprovalFeatureEnabled: z126.boolean(),
3846
+ approvalRequiredForPublishing: z126.boolean()
3847
+ });
3848
+ var DesignSystemVersionRoomInitialState = z126.object({
3849
+ pages: z126.array(DocumentationPageV2),
3850
+ groups: z126.array(ElementGroup),
3851
+ pageSnapshots: z126.array(DocumentationPageSnapshot),
3852
+ groupSnapshots: z126.array(ElementGroupSnapshot),
3853
+ pageApprovals: z126.array(DocumentationPageApproval),
3937
3854
  internalSettings: DesignSystemVersionRoomInternalSettings
3938
3855
  });
3939
- var DesignSystemVersionRoomUpdate = z129.object({
3940
- pages: z129.array(DocumentationPageV2),
3941
- groups: z129.array(ElementGroup),
3942
- pageIdsToDelete: z129.array(z129.string()),
3943
- groupIdsToDelete: z129.array(z129.string()),
3944
- pageSnapshots: z129.array(DocumentationPageSnapshot),
3945
- groupSnapshots: z129.array(ElementGroupSnapshot),
3946
- pageSnapshotIdsToDelete: z129.array(z129.string()),
3947
- groupSnapshotIdsToDelete: z129.array(z129.string()),
3948
- pageHashesToUpdate: z129.record(z129.string(), z129.string()),
3949
- pageApprovals: z129.array(DocumentationPageApproval),
3950
- pageApprovalIdsToDelete: z129.array(z129.string())
3856
+ var DesignSystemVersionRoomUpdate = z126.object({
3857
+ pages: z126.array(DocumentationPageV2),
3858
+ groups: z126.array(ElementGroup),
3859
+ pageIdsToDelete: z126.array(z126.string()),
3860
+ groupIdsToDelete: z126.array(z126.string()),
3861
+ pageSnapshots: z126.array(DocumentationPageSnapshot),
3862
+ groupSnapshots: z126.array(ElementGroupSnapshot),
3863
+ pageSnapshotIdsToDelete: z126.array(z126.string()),
3864
+ groupSnapshotIdsToDelete: z126.array(z126.string()),
3865
+ pageHashesToUpdate: z126.record(z126.string(), z126.string()),
3866
+ pageApprovals: z126.array(DocumentationPageApproval),
3867
+ pageApprovalIdsToDelete: z126.array(z126.string())
3951
3868
  });
3952
3869
  var DocumentationPageRoom = Entity.extend({
3953
- designSystemVersionId: z130.string(),
3954
- documentationPageId: z130.string(),
3955
- liveblocksId: z130.string(),
3956
- isDirty: z130.boolean()
3870
+ designSystemVersionId: z127.string(),
3871
+ documentationPageId: z127.string(),
3872
+ liveblocksId: z127.string(),
3873
+ isDirty: z127.boolean()
3957
3874
  });
3958
- var DocumentationPageRoomState = z130.object({
3959
- pageItems: z130.array(PageBlockEditorModelV2.or(PageSectionEditorModelV2)),
3875
+ var DocumentationPageRoomState = z127.object({
3876
+ pageItems: z127.array(PageBlockEditorModelV2.or(PageSectionEditorModelV2)),
3960
3877
  itemConfiguration: DocumentationItemConfigurationV2
3961
3878
  });
3962
- var DocumentationPageRoomRoomUpdate = z130.object({
3879
+ var DocumentationPageRoomRoomUpdate = z127.object({
3963
3880
  page: DocumentationPageV2,
3964
3881
  pageParent: ElementGroup
3965
3882
  });
3966
3883
  var DocumentationPageRoomInitialStateUpdate = DocumentationPageRoomRoomUpdate.extend({
3967
- pageItems: z130.array(PageBlockEditorModelV2.or(PageSectionEditorModelV2)),
3968
- blockDefinitions: z130.array(PageBlockDefinition)
3884
+ pageItems: z127.array(PageBlockEditorModelV2.or(PageSectionEditorModelV2)),
3885
+ blockDefinitions: z127.array(PageBlockDefinition)
3969
3886
  });
3970
- var RestoredDocumentationPage = z130.object({
3887
+ var RestoredDocumentationPage = z127.object({
3971
3888
  page: DocumentationPageV2,
3972
3889
  pageParent: ElementGroup,
3973
3890
  pageContent: DocumentationPageContentData,
3974
- contentHash: z130.string(),
3975
- snapshotId: z130.string(),
3976
- roomId: z130.string().optional()
3891
+ contentHash: z127.string(),
3892
+ snapshotId: z127.string(),
3893
+ roomId: z127.string().optional()
3977
3894
  });
3978
- var RestoredDocumentationGroup = z130.object({
3895
+ var RestoredDocumentationGroup = z127.object({
3979
3896
  group: ElementGroup,
3980
3897
  parent: ElementGroup
3981
3898
  });
@@ -3985,28 +3902,28 @@ var RoomTypeEnum = /* @__PURE__ */ ((RoomTypeEnum2) => {
3985
3902
  RoomTypeEnum2["Workspace"] = "workspace";
3986
3903
  return RoomTypeEnum2;
3987
3904
  })(RoomTypeEnum || {});
3988
- var RoomTypeSchema = z131.nativeEnum(RoomTypeEnum);
3905
+ var RoomTypeSchema = z128.nativeEnum(RoomTypeEnum);
3989
3906
  var RoomType = RoomTypeSchema.enum;
3990
3907
  var WorkspaceRoom = Entity.extend({
3991
- workspaceId: z132.string(),
3992
- liveblocksId: z132.string()
3908
+ workspaceId: z129.string(),
3909
+ liveblocksId: z129.string()
3993
3910
  });
3994
- var PublishedDocsDump = z133.object({
3911
+ var PublishedDocsDump = z130.object({
3995
3912
  documentation: PublishedDoc,
3996
3913
  pages: PublishedDocPage.array()
3997
3914
  });
3998
- var DocumentationThreadDump = z134.object({
3915
+ var DocumentationThreadDump = z131.object({
3999
3916
  thread: DocumentationCommentThread,
4000
3917
  comments: DocumentationComment.array()
4001
3918
  });
4002
- var DocumentationPageRoomDump = z134.object({
3919
+ var DocumentationPageRoomDump = z131.object({
4003
3920
  room: DocumentationPageRoom,
4004
3921
  threads: DocumentationThreadDump.array()
4005
3922
  });
4006
- var DesignSystemVersionMultiplayerDump = z134.object({
3923
+ var DesignSystemVersionMultiplayerDump = z131.object({
4007
3924
  documentationPages: DocumentationPageRoomDump.array()
4008
3925
  });
4009
- var DesignSystemVersionDump = z134.object({
3926
+ var DesignSystemVersionDump = z131.object({
4010
3927
  version: DesignSystemVersion,
4011
3928
  brands: Brand.array(),
4012
3929
  elements: DesignElement.array(),
@@ -4019,142 +3936,142 @@ var DesignSystemVersionDump = z134.object({
4019
3936
  publishedDocumentations: PublishedDocsDump.array(),
4020
3937
  assetReferences: AssetReference.array()
4021
3938
  });
4022
- var DesignSystemDump = z135.object({
3939
+ var DesignSystemDump = z132.object({
4023
3940
  designSystem: DesignSystem,
4024
3941
  dataSources: DataSource.array(),
4025
3942
  versions: DesignSystemVersionDump.array(),
4026
3943
  customDomain: CustomDomain.optional(),
4027
3944
  files: Asset.array()
4028
3945
  });
4029
- var IntegrationAuthType = z136.union([z136.literal("OAuth2"), z136.literal("PAT")]);
4030
- var ExternalServiceType = z136.union([
4031
- z136.literal("figma"),
4032
- z136.literal("github"),
4033
- z136.literal("azure"),
4034
- z136.literal("gitlab"),
4035
- z136.literal("bitbucket")
3946
+ var IntegrationAuthType = z133.union([z133.literal("OAuth2"), z133.literal("PAT")]);
3947
+ var ExternalServiceType = z133.union([
3948
+ z133.literal("figma"),
3949
+ z133.literal("github"),
3950
+ z133.literal("azure"),
3951
+ z133.literal("gitlab"),
3952
+ z133.literal("bitbucket")
4036
3953
  ]);
4037
- var IntegrationUserInfo = z136.object({
4038
- id: z136.string(),
4039
- handle: z136.string().optional(),
4040
- avatarUrl: z136.string().optional(),
4041
- email: z136.string().optional(),
3954
+ var IntegrationUserInfo = z133.object({
3955
+ id: z133.string(),
3956
+ handle: z133.string().optional(),
3957
+ avatarUrl: z133.string().optional(),
3958
+ email: z133.string().optional(),
4042
3959
  authType: IntegrationAuthType.optional(),
4043
- customUrl: z136.string().optional()
3960
+ customUrl: z133.string().optional()
4044
3961
  });
4045
- var UserLinkedIntegrations = z136.object({
3962
+ var UserLinkedIntegrations = z133.object({
4046
3963
  figma: IntegrationUserInfo.optional(),
4047
3964
  github: IntegrationUserInfo.array().optional(),
4048
3965
  azure: IntegrationUserInfo.array().optional(),
4049
3966
  gitlab: IntegrationUserInfo.array().optional(),
4050
3967
  bitbucket: IntegrationUserInfo.array().optional()
4051
3968
  });
4052
- var UserAnalyticsCleanupSchedule = z137.object({
4053
- userId: z137.string(),
4054
- createdAt: z137.coerce.date(),
4055
- deleteAt: z137.coerce.date()
3969
+ var UserAnalyticsCleanupSchedule = z134.object({
3970
+ userId: z134.string(),
3971
+ createdAt: z134.coerce.date(),
3972
+ deleteAt: z134.coerce.date()
4056
3973
  });
4057
3974
  var UserAnalyticsCleanupScheduleDbInput = UserAnalyticsCleanupSchedule.omit({
4058
3975
  createdAt: true
4059
3976
  });
4060
- var CreateUserInput = z138.object({
4061
- email: z138.string(),
4062
- name: z138.string(),
4063
- username: z138.string()
3977
+ var CreateUserInput = z135.object({
3978
+ email: z135.string(),
3979
+ name: z135.string(),
3980
+ username: z135.string()
4064
3981
  });
4065
- var UserIdentity = z139.object({
4066
- id: z139.string(),
4067
- userId: z139.string()
3982
+ var UserIdentity = z136.object({
3983
+ id: z136.string(),
3984
+ userId: z136.string()
4068
3985
  });
4069
- var UserMinified = z140.object({
4070
- id: z140.string(),
4071
- name: z140.string(),
4072
- email: z140.string(),
4073
- avatar: z140.string().optional()
3986
+ var UserMinified = z137.object({
3987
+ id: z137.string(),
3988
+ name: z137.string(),
3989
+ email: z137.string(),
3990
+ avatar: z137.string().optional()
4074
3991
  });
4075
- var LiveblocksNotificationSettings = z141.object({
4076
- sendCommentNotificationEmails: z141.boolean()
3992
+ var LiveblocksNotificationSettings = z138.object({
3993
+ sendCommentNotificationEmails: z138.boolean()
4077
3994
  });
4078
- var UserNotificationSettings = z141.object({
3995
+ var UserNotificationSettings = z138.object({
4079
3996
  liveblocksNotificationSettings: LiveblocksNotificationSettings
4080
3997
  });
4081
- var UserOnboardingDepartment = z142.enum(["Design", "Engineering", "Product", "Brand", "Other"]);
4082
- var UserOnboardingJobLevel = z142.enum(["Executive", "Manager", "IndividualContributor", "Other"]);
4083
- var UserOnboarding = z142.object({
4084
- companyName: z142.string().optional(),
4085
- numberOfPeopleInOrg: z142.string().optional(),
4086
- numberOfPeopleInDesignTeam: z142.string().optional(),
3998
+ var UserOnboardingDepartment = z139.enum(["Design", "Engineering", "Product", "Brand", "Other"]);
3999
+ var UserOnboardingJobLevel = z139.enum(["Executive", "Manager", "IndividualContributor", "Other"]);
4000
+ var UserOnboarding = z139.object({
4001
+ companyName: z139.string().optional(),
4002
+ numberOfPeopleInOrg: z139.string().optional(),
4003
+ numberOfPeopleInDesignTeam: z139.string().optional(),
4087
4004
  department: UserOnboardingDepartment.optional(),
4088
- jobTitle: z142.string().optional(),
4089
- phase: z142.string().optional(),
4005
+ jobTitle: z139.string().optional(),
4006
+ phase: z139.string().optional(),
4090
4007
  jobLevel: UserOnboardingJobLevel.optional(),
4091
- designSystemName: z142.string().optional(),
4092
- defaultDestination: z142.string().optional(),
4093
- figmaUrl: z142.string().optional(),
4094
- isPageDraftOnboardingFinished: z142.boolean().optional(),
4095
- isApprovalsOnboardingFinished: z142.boolean().optional()
4096
- });
4097
- var UserProfile = z142.object({
4098
- name: z142.string(),
4099
- avatar: z142.string().optional(),
4100
- nickname: z142.string().optional(),
4008
+ designSystemName: z139.string().optional(),
4009
+ defaultDestination: z139.string().optional(),
4010
+ figmaUrl: z139.string().optional(),
4011
+ isPageDraftOnboardingFinished: z139.boolean().optional(),
4012
+ isApprovalsOnboardingFinished: z139.boolean().optional()
4013
+ });
4014
+ var UserProfile = z139.object({
4015
+ name: z139.string(),
4016
+ avatar: z139.string().optional(),
4017
+ nickname: z139.string().optional(),
4101
4018
  onboarding: UserOnboarding.optional()
4102
4019
  });
4103
4020
  var UserProfileUpdate = UserProfile.partial().omit({
4104
4021
  avatar: true
4105
4022
  });
4106
- var UserTest = z143.object({
4107
- id: z143.string(),
4108
- email: z143.string()
4109
- });
4110
- var User = z144.object({
4111
- id: z144.string(),
4112
- email: z144.string(),
4113
- emailVerified: z144.boolean(),
4114
- createdAt: z144.coerce.date(),
4115
- trialExpiresAt: z144.coerce.date().optional(),
4023
+ var UserTest = z140.object({
4024
+ id: z140.string(),
4025
+ email: z140.string()
4026
+ });
4027
+ var User = z141.object({
4028
+ id: z141.string(),
4029
+ email: z141.string(),
4030
+ emailVerified: z141.boolean(),
4031
+ createdAt: z141.coerce.date(),
4032
+ trialExpiresAt: z141.coerce.date().optional(),
4116
4033
  profile: UserProfile,
4117
4034
  linkedIntegrations: UserLinkedIntegrations.optional(),
4118
- loggedOutAt: z144.coerce.date().optional(),
4119
- isProtected: z144.boolean()
4120
- });
4121
- var IntegrationDesignSystem = z145.object({
4122
- designSystemId: z145.string(),
4123
- brandId: z145.string(),
4124
- title: z145.string().optional(),
4125
- userId: z145.string().optional(),
4126
- date: z145.coerce.date().optional()
4127
- });
4128
- var IntegrationCredentialsType = z145.enum(["OAuth2", "PAT", "GithubApp"]);
4129
- var IntegrationCredentialsState = z145.enum(["Active", "Inactive"]);
4130
- var IntegrationCredentialsProfile = z145.object({
4131
- id: nullishToOptional(z145.string()),
4132
- email: nullishToOptional(z145.string()),
4133
- handle: nullishToOptional(z145.string()),
4134
- type: nullishToOptional(z145.string()),
4135
- avatarUrl: nullishToOptional(z145.string()),
4136
- organization: nullishToOptional(z145.string()),
4137
- collection: nullishToOptional(z145.string())
4138
- });
4139
- var IntegrationCredentials = z145.object({
4140
- id: z145.string(),
4035
+ loggedOutAt: z141.coerce.date().optional(),
4036
+ isProtected: z141.boolean()
4037
+ });
4038
+ var IntegrationDesignSystem = z142.object({
4039
+ designSystemId: z142.string(),
4040
+ brandId: z142.string(),
4041
+ title: z142.string().optional(),
4042
+ userId: z142.string().optional(),
4043
+ date: z142.coerce.date().optional()
4044
+ });
4045
+ var IntegrationCredentialsType = z142.enum(["OAuth2", "PAT", "GithubApp"]);
4046
+ var IntegrationCredentialsState = z142.enum(["Active", "Inactive"]);
4047
+ var IntegrationCredentialsProfile = z142.object({
4048
+ id: nullishToOptional(z142.string()),
4049
+ email: nullishToOptional(z142.string()),
4050
+ handle: nullishToOptional(z142.string()),
4051
+ type: nullishToOptional(z142.string()),
4052
+ avatarUrl: nullishToOptional(z142.string()),
4053
+ organization: nullishToOptional(z142.string()),
4054
+ collection: nullishToOptional(z142.string())
4055
+ });
4056
+ var IntegrationCredentials = z142.object({
4057
+ id: z142.string(),
4141
4058
  type: IntegrationCredentialsType,
4142
- integrationId: z145.string(),
4143
- accessToken: z145.string(),
4144
- userId: z145.string(),
4145
- createdAt: z145.coerce.date(),
4146
- refreshToken: z145.string().optional(),
4147
- tokenName: z145.string().optional(),
4148
- expiresAt: z145.coerce.date().optional(),
4149
- refreshedAt: z145.coerce.date().optional(),
4150
- username: z145.string().optional(),
4151
- appInstallationId: z145.string().optional(),
4059
+ integrationId: z142.string(),
4060
+ accessToken: z142.string(),
4061
+ userId: z142.string(),
4062
+ createdAt: z142.coerce.date(),
4063
+ refreshToken: z142.string().optional(),
4064
+ tokenName: z142.string().optional(),
4065
+ expiresAt: z142.coerce.date().optional(),
4066
+ refreshedAt: z142.coerce.date().optional(),
4067
+ username: z142.string().optional(),
4068
+ appInstallationId: z142.string().optional(),
4152
4069
  profile: IntegrationCredentialsProfile.optional(),
4153
- customUrl: z145.string().optional(),
4070
+ customUrl: z142.string().optional(),
4154
4071
  state: IntegrationCredentialsState,
4155
4072
  user: UserMinified.optional()
4156
4073
  });
4157
- var ExtendedIntegrationType = z145.enum([
4074
+ var ExtendedIntegrationType = z142.enum([
4158
4075
  "Figma",
4159
4076
  "Github",
4160
4077
  "Gitlab",
@@ -4165,26 +4082,26 @@ var ExtendedIntegrationType = z145.enum([
4165
4082
  ]);
4166
4083
  var IntegrationType = ExtendedIntegrationType.exclude(["TokenStudio", "FigmaVariablesPlugin"]);
4167
4084
  var GitIntegrationType = IntegrationType.exclude(["Figma"]);
4168
- var Integration = z145.object({
4169
- id: z145.string(),
4170
- workspaceId: z145.string(),
4085
+ var Integration = z142.object({
4086
+ id: z142.string(),
4087
+ workspaceId: z142.string(),
4171
4088
  type: IntegrationType,
4172
- createdAt: z145.coerce.date(),
4173
- integrationCredentials: z145.array(IntegrationCredentials).optional()
4174
- });
4175
- var IntegrationToken = z145.object({
4176
- access_token: z145.string(),
4177
- refresh_token: z145.string().optional(),
4178
- expires_in: z145.union([z145.number().optional(), z145.string().optional()]),
4179
- token_type: z145.string().optional(),
4180
- token_name: z145.string().optional(),
4181
- token_azure_organization_name: z145.string().optional(),
4089
+ createdAt: z142.coerce.date(),
4090
+ integrationCredentials: z142.array(IntegrationCredentials).optional()
4091
+ });
4092
+ var IntegrationToken = z142.object({
4093
+ access_token: z142.string(),
4094
+ refresh_token: z142.string().optional(),
4095
+ expires_in: z142.union([z142.number().optional(), z142.string().optional()]),
4096
+ token_type: z142.string().optional(),
4097
+ token_name: z142.string().optional(),
4098
+ token_azure_organization_name: z142.string().optional(),
4182
4099
  // Azure Cloud PAT only
4183
- token_azure_collection_name: z145.string().optional(),
4100
+ token_azure_collection_name: z142.string().optional(),
4184
4101
  // Azure Server PAT only
4185
- token_bitbucket_username: z145.string().optional(),
4102
+ token_bitbucket_username: z142.string().optional(),
4186
4103
  // Bitbucket only
4187
- custom_url: z145.string().optional().transform((value) => {
4104
+ custom_url: z142.string().optional().transform((value) => {
4188
4105
  if (!value?.trim())
4189
4106
  return void 0;
4190
4107
  return formatCustomUrl(value);
@@ -4220,6 +4137,87 @@ function formatCustomUrl(url) {
4220
4137
  }
4221
4138
  return forbiddenCustomUrlDomainList.some((domain) => formattedUrl.includes(domain)) ? void 0 : formattedUrl;
4222
4139
  }
4140
+ var NpmRegistryAuthType = z143.enum(["Basic", "Bearer", "None", "Custom"]);
4141
+ var NpmRegistryType = z143.enum(["NPMJS", "GitHub", "AzureDevOps", "Artifactory", "Custom"]);
4142
+ var NpmRegistryBasicAuthConfig = z143.object({
4143
+ authType: z143.literal(NpmRegistryAuthType.Enum.Basic),
4144
+ username: z143.string(),
4145
+ password: z143.string()
4146
+ });
4147
+ var NpmRegistryBearerAuthConfig = z143.object({
4148
+ authType: z143.literal(NpmRegistryAuthType.Enum.Bearer),
4149
+ accessToken: z143.string()
4150
+ });
4151
+ var NpmRegistryNoAuthConfig = z143.object({
4152
+ authType: z143.literal(NpmRegistryAuthType.Enum.None)
4153
+ });
4154
+ var NpmRegistrCustomAuthConfig = z143.object({
4155
+ authType: z143.literal(NpmRegistryAuthType.Enum.Custom),
4156
+ authHeaderName: z143.string(),
4157
+ authHeaderValue: z143.string()
4158
+ });
4159
+ var NpmRegistryAuthConfig = z143.discriminatedUnion("authType", [
4160
+ NpmRegistryBasicAuthConfig,
4161
+ NpmRegistryBearerAuthConfig,
4162
+ NpmRegistryNoAuthConfig,
4163
+ NpmRegistrCustomAuthConfig
4164
+ ]);
4165
+ var NpmRegistryConfigBase = z143.object({
4166
+ registryType: NpmRegistryType,
4167
+ enabledScopes: z143.array(z143.string()),
4168
+ customRegistryUrl: z143.string().optional(),
4169
+ bypassProxy: z143.boolean().default(false),
4170
+ npmProxyRegistryConfigId: z143.string().optional(),
4171
+ npmProxyVersion: z143.number().optional()
4172
+ });
4173
+ var NpmRegistryConfig = NpmRegistryConfigBase.and(NpmRegistryAuthConfig);
4174
+ var SsoProvider = z144.object({
4175
+ providerId: z144.string(),
4176
+ defaultAutoInviteValue: z144.boolean(),
4177
+ autoInviteDomains: z144.record(z144.string(), z144.boolean()),
4178
+ skipDocsSupernovaLogin: z144.boolean(),
4179
+ areInvitesDisabled: z144.boolean(),
4180
+ isTestMode: z144.boolean(),
4181
+ emailDomains: z144.array(z144.string()),
4182
+ metadataXml: z144.string().nullish()
4183
+ });
4184
+ var isValidCIDR = (value) => {
4185
+ return IPCIDR.isValidAddress(value);
4186
+ };
4187
+ var WorkspaceIpWhitelistEntry = z145.object({
4188
+ isEnabled: z145.boolean(),
4189
+ name: z145.string(),
4190
+ range: z145.string().refine(isValidCIDR, {
4191
+ message: "Invalid IP CIDR"
4192
+ })
4193
+ });
4194
+ var WorkspaceIpSettings = z145.object({
4195
+ isEnabledForCloud: z145.boolean(),
4196
+ isEnabledForDocs: z145.boolean(),
4197
+ entries: z145.array(WorkspaceIpWhitelistEntry)
4198
+ });
4199
+ var WorkspaceProfile = z145.object({
4200
+ name: z145.string(),
4201
+ handle: z145.string(),
4202
+ color: z145.string(),
4203
+ avatar: nullishToOptional(z145.string()),
4204
+ billingDetails: nullishToOptional(BillingDetails)
4205
+ });
4206
+ var WorkspaceProfileUpdate = WorkspaceProfile.omit({
4207
+ avatar: true
4208
+ });
4209
+ var Workspace = z145.object({
4210
+ id: z145.string(),
4211
+ profile: WorkspaceProfile,
4212
+ subscription: Subscription,
4213
+ ipWhitelist: nullishToOptional(WorkspaceIpSettings),
4214
+ sso: nullishToOptional(SsoProvider),
4215
+ npmRegistrySettings: nullishToOptional(NpmRegistryConfig)
4216
+ });
4217
+ var WorkspaceWithDesignSystems = z145.object({
4218
+ workspace: Workspace,
4219
+ designSystems: z145.array(DesignSystem)
4220
+ });
4223
4221
  var WorkspaceDump = z146.object({
4224
4222
  workspace: Workspace,
4225
4223
  designSystems: DesignSystemDump.array(),