@spacefast/common 0.2.1 → 0.4.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.
Files changed (226) hide show
  1. package/dist/agents/marketplace-prompts.d.ts +1 -0
  2. package/dist/agents/marketplace-prompts.js +6 -0
  3. package/dist/agents/registry/core.d.ts +4 -12
  4. package/dist/agents/registry/core.js +7 -28
  5. package/dist/config/domains.d.ts +10 -8
  6. package/dist/config/domains.js +4 -7
  7. package/dist/contracts/access-core.d.ts +135 -0
  8. package/dist/contracts/access-core.js +242 -0
  9. package/dist/contracts/access-profiles.d.ts +8 -8
  10. package/dist/contracts/access-profiles.js +8 -8
  11. package/dist/contracts/access.d.ts +14 -103
  12. package/dist/contracts/access.js +10 -210
  13. package/dist/contracts/activity.d.ts +54 -55
  14. package/dist/contracts/activity.js +38 -9
  15. package/dist/contracts/api-keys.d.ts +69 -26
  16. package/dist/contracts/api-keys.js +29 -2
  17. package/dist/contracts/application-journal.d.ts +197 -4
  18. package/dist/contracts/application-journal.js +97 -16
  19. package/dist/contracts/auth.d.ts +20 -0
  20. package/dist/contracts/auth.js +18 -0
  21. package/dist/contracts/beta.d.ts +13 -0
  22. package/dist/contracts/beta.js +28 -0
  23. package/dist/contracts/billing.d.ts +2 -2
  24. package/dist/contracts/bootstrap.d.ts +23 -6
  25. package/dist/contracts/builds.d.ts +24 -4
  26. package/dist/contracts/builds.js +16 -4
  27. package/dist/contracts/channels.d.ts +43 -0
  28. package/dist/contracts/channels.js +22 -6
  29. package/dist/contracts/comments.d.ts +49 -0
  30. package/dist/contracts/comments.js +61 -2
  31. package/dist/contracts/commerce.d.ts +19 -13
  32. package/dist/contracts/connector-access.d.ts +28 -0
  33. package/dist/contracts/connector-access.js +31 -0
  34. package/dist/contracts/connectors.d.ts +2382 -0
  35. package/dist/contracts/connectors.js +941 -0
  36. package/dist/contracts/content-contract-verification.d.ts +112 -58
  37. package/dist/contracts/content-contract-verification.js +42 -54
  38. package/dist/contracts/content-model-emit.d.ts +97 -0
  39. package/dist/contracts/content-model-emit.js +306 -0
  40. package/dist/contracts/content-model-sdk.d.ts +101 -0
  41. package/dist/contracts/content-model-sdk.js +232 -0
  42. package/dist/contracts/{content-program.d.ts → content-model.d.ts} +338 -82
  43. package/dist/contracts/{content-program.js → content-model.js} +291 -63
  44. package/dist/contracts/content-platform-fixture.d.ts +380 -110
  45. package/dist/contracts/content-platform-fixture.js +8 -8
  46. package/dist/contracts/content-sync.d.ts +197 -74
  47. package/dist/contracts/content-sync.js +98 -37
  48. package/dist/contracts/content.d.ts +30 -422
  49. package/dist/contracts/content.js +34 -294
  50. package/dist/contracts/dashboard-prefs.d.ts +10 -3
  51. package/dist/contracts/dashboard-prefs.js +6 -3
  52. package/dist/contracts/data-location.d.ts +9 -0
  53. package/dist/contracts/data-location.js +7 -0
  54. package/dist/contracts/deployment-comparison.d.ts +67 -0
  55. package/dist/contracts/deployment-comparison.js +68 -0
  56. package/dist/contracts/device-auth.d.ts +55 -11
  57. package/dist/contracts/domains.d.ts +40 -16
  58. package/dist/contracts/domains.js +23 -0
  59. package/dist/contracts/enums.d.ts +1 -10
  60. package/dist/contracts/enums.js +0 -15
  61. package/dist/contracts/error-code-meta.d.ts +388 -20
  62. package/dist/contracts/error-code-meta.js +201 -5
  63. package/dist/contracts/error-codes.d.ts +17 -4
  64. package/dist/contracts/error-codes.js +109 -10
  65. package/dist/contracts/events.d.ts +5 -0
  66. package/dist/contracts/events.js +12 -3
  67. package/dist/contracts/execution.d.ts +5 -1
  68. package/dist/contracts/execution.js +4 -0
  69. package/dist/contracts/feature-lifecycle.d.ts +53 -20
  70. package/dist/contracts/feature-lifecycle.js +65 -23
  71. package/dist/contracts/features.d.ts +57 -31
  72. package/dist/contracts/features.js +0 -1
  73. package/dist/contracts/feedback.d.ts +124 -0
  74. package/dist/contracts/feedback.js +64 -0
  75. package/dist/contracts/fixtures/content-model-sdk-v1.generated.d.ts +129 -0
  76. package/dist/contracts/fixtures/content-model-sdk-v1.generated.js +48 -0
  77. package/dist/contracts/fixtures/content-platform-v1.json +101 -49
  78. package/dist/contracts/frame-session.d.ts +60 -10
  79. package/dist/contracts/frame-session.js +52 -12
  80. package/dist/contracts/functions.d.ts +28 -2
  81. package/dist/contracts/functions.js +25 -2
  82. package/dist/contracts/grant-copy.d.ts +2 -0
  83. package/dist/contracts/grant-copy.js +2 -0
  84. package/dist/contracts/grants-core.d.ts +95 -0
  85. package/dist/contracts/grants-core.js +435 -0
  86. package/dist/contracts/grants.d.ts +13 -84
  87. package/dist/contracts/grants.js +21 -369
  88. package/dist/contracts/ids-core.d.ts +11 -0
  89. package/dist/contracts/ids-core.js +14 -0
  90. package/dist/contracts/ids.d.ts +7 -4
  91. package/dist/contracts/ids.js +12 -4
  92. package/dist/contracts/internal.d.ts +18 -0
  93. package/dist/contracts/internal.js +19 -0
  94. package/dist/contracts/mcp.d.ts +8 -18
  95. package/dist/contracts/mcp.js +2 -23
  96. package/dist/contracts/notifications.d.ts +4 -1
  97. package/dist/contracts/notifications.js +1 -0
  98. package/dist/contracts/oauth-resources.d.ts +55 -9
  99. package/dist/contracts/oauth-resources.js +64 -1
  100. package/dist/contracts/oauth-scope-actions.d.ts +27 -3
  101. package/dist/contracts/oauth-scope-actions.js +18 -8
  102. package/dist/contracts/operations.d.ts +1 -1
  103. package/dist/contracts/partner-account.d.ts +629 -0
  104. package/dist/contracts/partner-account.js +18 -0
  105. package/dist/contracts/principal-assertion.d.ts +74 -1
  106. package/dist/contracts/principal-assertion.js +67 -3
  107. package/dist/contracts/publish-archive.d.ts +22 -1
  108. package/dist/contracts/push-new.d.ts +3 -3
  109. package/dist/contracts/push-new.js +1 -1
  110. package/dist/contracts/quotas.js +2 -1
  111. package/dist/contracts/repository-connections.d.ts +10 -6
  112. package/dist/contracts/repository-connections.js +15 -0
  113. package/dist/contracts/resources.d.ts +6 -5
  114. package/dist/contracts/resources.js +7 -0
  115. package/dist/contracts/route-inventory.d.ts +74 -19
  116. package/dist/contracts/route-inventory.js +20 -6
  117. package/dist/contracts/runtime-api.d.ts +415 -4
  118. package/dist/contracts/runtime-api.js +60 -15
  119. package/dist/contracts/runtime-app.d.ts +6 -1
  120. package/dist/contracts/runtime-components.d.ts +646 -18
  121. package/dist/contracts/runtime-components.js +304 -188
  122. package/dist/contracts/runtime-services.d.ts +15 -0
  123. package/dist/contracts/runtime-services.js +25 -0
  124. package/dist/contracts/runtime-storage.d.ts +32 -0
  125. package/dist/contracts/runtime-storage.js +37 -0
  126. package/dist/contracts/source-workspaces.d.ts +511 -0
  127. package/dist/contracts/source-workspaces.js +276 -0
  128. package/dist/contracts/space-config-spacefast.d.ts +394 -0
  129. package/dist/contracts/space-config-spacefast.js +70 -0
  130. package/dist/contracts/space-config.d.ts +177 -90
  131. package/dist/contracts/space-config.js +77 -92
  132. package/dist/contracts/spaces.d.ts +132 -24
  133. package/dist/contracts/spaces.js +77 -13
  134. package/dist/contracts/superadmin-connectors.d.ts +371 -0
  135. package/dist/contracts/superadmin-connectors.js +61 -0
  136. package/dist/contracts/superadmin-emails.d.ts +1 -1
  137. package/dist/contracts/superadmin-emails.js +1 -1
  138. package/dist/contracts/superadmin-entities.d.ts +105 -0
  139. package/dist/contracts/superadmin-entities.js +64 -0
  140. package/dist/contracts/superadmin-runtime.d.ts +35 -116
  141. package/dist/contracts/superadmin-runtime.js +13 -69
  142. package/dist/contracts/superadmin-search.d.ts +12 -14
  143. package/dist/contracts/superadmin-search.js +2 -2
  144. package/dist/contracts/superadmin-spaces.d.ts +15 -72
  145. package/dist/contracts/superadmin-spaces.js +2 -7
  146. package/dist/contracts/superadmin-teams.d.ts +12 -0
  147. package/dist/contracts/superadmin-teams.js +7 -1
  148. package/dist/contracts/superadmin-tenants.d.ts +44 -16
  149. package/dist/contracts/superadmin.d.ts +2 -2
  150. package/dist/contracts/tags.d.ts +12 -12
  151. package/dist/contracts/teams.d.ts +29 -1
  152. package/dist/contracts/teams.js +24 -2
  153. package/dist/contracts/tenants.d.ts +98 -0
  154. package/dist/contracts/tenants.js +20 -0
  155. package/dist/contracts/transfers.d.ts +92 -0
  156. package/dist/contracts/transfers.js +37 -0
  157. package/dist/contracts/usage.d.ts +9 -1
  158. package/dist/contracts/usage.js +2 -0
  159. package/dist/contracts/visual-review.d.ts +448 -0
  160. package/dist/contracts/visual-review.js +156 -0
  161. package/dist/contracts/wordpress-php-toolkit.json +9 -0
  162. package/dist/contracts/work-mode.d.ts +24 -0
  163. package/dist/contracts/work-mode.js +17 -0
  164. package/dist/contracts/wp-cli.d.ts +66 -0
  165. package/dist/contracts/wp-cli.js +68 -0
  166. package/dist/contracts/zero-catalog.d.ts +29 -0
  167. package/dist/contracts/zero-catalog.js +55 -0
  168. package/dist/contracts/zero-platform-abilities.generated.d.ts +31 -0
  169. package/dist/contracts/zero-platform-abilities.generated.js +373 -0
  170. package/dist/contracts/zero-spacefast.d.ts +444 -0
  171. package/dist/contracts/zero-spacefast.js +149 -0
  172. package/dist/contracts/zero-types.d.ts +47 -0
  173. package/dist/contracts/zero-types.js +263 -0
  174. package/dist/contracts/zero.d.ts +781 -14
  175. package/dist/contracts/zero.js +204 -10
  176. package/dist/dashboard-paths/index.d.ts +2 -2
  177. package/dist/dashboard-paths/route-reservations.generated.d.ts +2 -2
  178. package/dist/dashboard-paths/route-reservations.generated.js +5 -0
  179. package/dist/docs/agent-prose.d.ts +1 -1
  180. package/dist/docs/agent-prose.js +15 -18
  181. package/dist/docs/agent-setup.d.ts +1 -1
  182. package/dist/docs/agent-setup.js +5 -13
  183. package/dist/docs/catalog.d.ts +64 -28
  184. package/dist/docs/catalog.js +155 -28
  185. package/dist/docs/error-docs.d.ts +365 -17
  186. package/dist/docs/error-docs.js +369 -21
  187. package/dist/docs/reference-urls.js +1 -1
  188. package/dist/docs/skills.d.ts +84 -84
  189. package/dist/docs/skills.js +66 -47
  190. package/dist/docs/start-prompts.d.ts +14 -0
  191. package/dist/docs/start-prompts.js +20 -0
  192. package/dist/utils/account-labels.d.ts +7 -0
  193. package/dist/utils/account-labels.js +15 -0
  194. package/dist/utils/auth.d.ts +1 -0
  195. package/dist/utils/auth.js +1 -0
  196. package/dist/utils/credential-policy.d.ts +22 -1
  197. package/dist/utils/credential-policy.js +55 -6
  198. package/dist/utils/local-space-state.d.ts +7 -0
  199. package/dist/utils/local-space-state.js +7 -0
  200. package/dist/utils/logger.d.ts +34 -0
  201. package/dist/utils/logger.js +144 -0
  202. package/dist/utils/page-routes.d.ts +9 -0
  203. package/dist/utils/page-routes.js +82 -0
  204. package/dist/utils/pages.d.ts +2 -0
  205. package/dist/utils/pages.js +7 -0
  206. package/dist/utils/publish-form-data.d.ts +2 -0
  207. package/dist/utils/publish-form-data.js +2 -0
  208. package/dist/utils/publish-policy-spacefast.d.ts +13 -0
  209. package/dist/utils/publish-policy-spacefast.js +117 -0
  210. package/dist/utils/publish-policy.d.ts +22 -16
  211. package/dist/utils/publish-policy.fixtures.json +15 -0
  212. package/dist/utils/publish-policy.js +62 -139
  213. package/dist/utils/query-client.js +9 -1
  214. package/dist/utils/runtime-upload.d.ts +4 -0
  215. package/dist/utils/runtime-upload.js +5 -0
  216. package/dist/utils/space-config.d.ts +2 -3
  217. package/dist/utils/space-config.js +1 -1
  218. package/dist/utils/uploaded-source.d.ts +4 -0
  219. package/dist/utils/uploaded-source.js +12 -0
  220. package/dist/visual-review.d.ts +4 -0
  221. package/dist/visual-review.js +208 -0
  222. package/dist/vocabulary.d.ts +38 -0
  223. package/dist/vocabulary.js +55 -0
  224. package/package.json +7 -2
  225. package/dist/agents/registry/deeplink-probes.d.ts +0 -23
  226. package/dist/agents/registry/deeplink-probes.js +0 -18
@@ -2,8 +2,8 @@ import { z } from "zod";
2
2
  export declare const tagRevisionStatusSchema: z.ZodEnum<{
3
3
  approved: "approved";
4
4
  published: "published";
5
- draft: "draft";
6
5
  publishing: "publishing";
6
+ draft: "draft";
7
7
  in_review: "in_review";
8
8
  abandoned: "abandoned";
9
9
  }>;
@@ -175,8 +175,8 @@ export declare const tagRevisionSchema: z.ZodObject<{
175
175
  status: z.ZodEnum<{
176
176
  approved: "approved";
177
177
  published: "published";
178
- draft: "draft";
179
178
  publishing: "publishing";
179
+ draft: "draft";
180
180
  in_review: "in_review";
181
181
  abandoned: "abandoned";
182
182
  }>;
@@ -230,8 +230,8 @@ export declare const tagRevisionListQuerySchema: z.ZodObject<{
230
230
  status: z.ZodOptional<z.ZodEnum<{
231
231
  approved: "approved";
232
232
  published: "published";
233
- draft: "draft";
234
233
  publishing: "publishing";
234
+ draft: "draft";
235
235
  in_review: "in_review";
236
236
  abandoned: "abandoned";
237
237
  }>>;
@@ -245,8 +245,8 @@ export declare const tagRevisionListResponseSchema: z.ZodObject<{
245
245
  status: z.ZodEnum<{
246
246
  approved: "approved";
247
247
  published: "published";
248
- draft: "draft";
249
248
  publishing: "publishing";
249
+ draft: "draft";
250
250
  in_review: "in_review";
251
251
  abandoned: "abandoned";
252
252
  }>;
@@ -308,8 +308,8 @@ export declare const tagRevisionResponseSchema: z.ZodObject<{
308
308
  status: z.ZodEnum<{
309
309
  approved: "approved";
310
310
  published: "published";
311
- draft: "draft";
312
311
  publishing: "publishing";
312
+ draft: "draft";
313
313
  in_review: "in_review";
314
314
  abandoned: "abandoned";
315
315
  }>;
@@ -624,8 +624,8 @@ export declare const tagApplyResponseSchema: z.ZodObject<{
624
624
  status: z.ZodEnum<{
625
625
  approved: "approved";
626
626
  published: "published";
627
- draft: "draft";
628
627
  publishing: "publishing";
628
+ draft: "draft";
629
629
  in_review: "in_review";
630
630
  abandoned: "abandoned";
631
631
  }>;
@@ -819,6 +819,7 @@ export declare const TAG_TRIGGER_PRESETS: Array<{
819
819
  description: string;
820
820
  }>;
821
821
  export declare const tagTemplateIdSchema: z.ZodEnum<{
822
+ segment: "segment";
822
823
  intercom: "intercom";
823
824
  "google-analytics": "google-analytics";
824
825
  "google-tag-manager": "google-tag-manager";
@@ -828,7 +829,6 @@ export declare const tagTemplateIdSchema: z.ZodEnum<{
828
829
  posthog: "posthog";
829
830
  plausible: "plausible";
830
831
  amplitude: "amplitude";
831
- segment: "segment";
832
832
  "sentry-browser": "sentry-browser";
833
833
  hubspot: "hubspot";
834
834
  crisp: "crisp";
@@ -837,6 +837,7 @@ export declare const tagTemplateIdSchema: z.ZodEnum<{
837
837
  export type TagTemplateId = z.infer<typeof tagTemplateIdSchema>;
838
838
  export declare const tagTemplateDefinitionSchema: z.ZodObject<{
839
839
  id: z.ZodEnum<{
840
+ segment: "segment";
840
841
  intercom: "intercom";
841
842
  "google-analytics": "google-analytics";
842
843
  "google-tag-manager": "google-tag-manager";
@@ -846,7 +847,6 @@ export declare const tagTemplateDefinitionSchema: z.ZodObject<{
846
847
  posthog: "posthog";
847
848
  plausible: "plausible";
848
849
  amplitude: "amplitude";
849
- segment: "segment";
850
850
  "sentry-browser": "sentry-browser";
851
851
  hubspot: "hubspot";
852
852
  crisp: "crisp";
@@ -897,6 +897,7 @@ export declare const tagTemplateDefinitionSchema: z.ZodObject<{
897
897
  export type TagTemplateDefinition = z.infer<typeof tagTemplateDefinitionSchema>;
898
898
  export declare const tagTemplateSelectionSchema: z.ZodObject<{
899
899
  templateId: z.ZodEnum<{
900
+ segment: "segment";
900
901
  intercom: "intercom";
901
902
  "google-analytics": "google-analytics";
902
903
  "google-tag-manager": "google-tag-manager";
@@ -906,7 +907,6 @@ export declare const tagTemplateSelectionSchema: z.ZodObject<{
906
907
  posthog: "posthog";
907
908
  plausible: "plausible";
908
909
  amplitude: "amplitude";
909
- segment: "segment";
910
910
  "sentry-browser": "sentry-browser";
911
911
  hubspot: "hubspot";
912
912
  crisp: "crisp";
@@ -946,6 +946,7 @@ export declare const tagTemplateListResponseSchema: z.ZodObject<{
946
946
  data: z.ZodObject<{
947
947
  templates: z.ZodArray<z.ZodObject<{
948
948
  id: z.ZodEnum<{
949
+ segment: "segment";
949
950
  intercom: "intercom";
950
951
  "google-analytics": "google-analytics";
951
952
  "google-tag-manager": "google-tag-manager";
@@ -955,7 +956,6 @@ export declare const tagTemplateListResponseSchema: z.ZodObject<{
955
956
  posthog: "posthog";
956
957
  plausible: "plausible";
957
958
  amplitude: "amplitude";
958
- segment: "segment";
959
959
  "sentry-browser": "sentry-browser";
960
960
  hubspot: "hubspot";
961
961
  crisp: "crisp";
@@ -1070,6 +1070,7 @@ export declare const tagConsentPolicyResponseSchema: z.ZodObject<{
1070
1070
  export declare const tagTemplateGraphSchema: z.ZodObject<{
1071
1071
  templates: z.ZodDefault<z.ZodArray<z.ZodObject<{
1072
1072
  templateId: z.ZodEnum<{
1073
+ segment: "segment";
1073
1074
  intercom: "intercom";
1074
1075
  "google-analytics": "google-analytics";
1075
1076
  "google-tag-manager": "google-tag-manager";
@@ -1079,7 +1080,6 @@ export declare const tagTemplateGraphSchema: z.ZodObject<{
1079
1080
  posthog: "posthog";
1080
1081
  plausible: "plausible";
1081
1082
  amplitude: "amplitude";
1082
- segment: "segment";
1083
1083
  "sentry-browser": "sentry-browser";
1084
1084
  hubspot: "hubspot";
1085
1085
  crisp: "crisp";
@@ -1132,7 +1132,7 @@ export declare const tagTemplateGraphSchema: z.ZodObject<{
1132
1132
  export declare const TAG_TEMPLATE_DEFINITIONS: TagTemplateDefinition[];
1133
1133
  export declare function listTagTemplates(): {
1134
1134
  templates: {
1135
- id: "intercom" | "google-analytics" | "google-tag-manager" | "meta-pixel" | "tiktok-pixel" | "linkedin-insight" | "posthog" | "plausible" | "amplitude" | "segment" | "sentry-browser" | "hubspot" | "crisp" | "custom-javascript";
1135
+ id: "segment" | "intercom" | "google-analytics" | "google-tag-manager" | "meta-pixel" | "tiktok-pixel" | "linkedin-insight" | "posthog" | "plausible" | "amplitude" | "sentry-browser" | "hubspot" | "crisp" | "custom-javascript";
1136
1136
  name: string;
1137
1137
  category: "analytics" | "support" | "custom" | "advertising" | "product" | "monitoring";
1138
1138
  description: string;
@@ -10,6 +10,7 @@ export declare const teamMemberRole: z.ZodEnum<{
10
10
  * privilege, so they read as `member`.
11
11
  */
12
12
  export declare function normalizeTeamMemberRole(role: string | null | undefined): "admin" | "owner" | "member";
13
+ export declare const teamInvitationEmailSchema: z.ZodString;
13
14
  export declare const teamInvitationCreateSchema: z.ZodObject<{
14
15
  teamId: z.ZodString;
15
16
  email: z.ZodString;
@@ -116,6 +117,9 @@ export declare const teamPlanCode: z.ZodEnum<{
116
117
  personal: "personal";
117
118
  enterprise: "enterprise";
118
119
  }>;
120
+ export declare const TeamPartnerSchema: z.ZodNullable<z.ZodObject<{
121
+ enabledAt: z.ZodString;
122
+ }, z.core.$strip>>;
119
123
  export declare const TeamSummarySchema: z.ZodObject<{
120
124
  id: z.ZodString;
121
125
  tenantId: z.ZodString;
@@ -133,6 +137,9 @@ export declare const TeamSummarySchema: z.ZodObject<{
133
137
  personal: "personal";
134
138
  enterprise: "enterprise";
135
139
  }>;
140
+ partner: z.ZodNullable<z.ZodObject<{
141
+ enabledAt: z.ZodString;
142
+ }, z.core.$strip>>;
136
143
  defaultDataLocation: z.ZodString;
137
144
  createdAt: z.ZodString;
138
145
  updatedAt: z.ZodString;
@@ -154,6 +161,9 @@ export declare const TeamDetailSchema: z.ZodObject<{
154
161
  personal: "personal";
155
162
  enterprise: "enterprise";
156
163
  }>;
164
+ partner: z.ZodNullable<z.ZodObject<{
165
+ enabledAt: z.ZodString;
166
+ }, z.core.$strip>>;
157
167
  defaultDataLocation: z.ZodString;
158
168
  createdAt: z.ZodString;
159
169
  updatedAt: z.ZodString;
@@ -171,6 +181,7 @@ export declare const TeamDetailSchema: z.ZodObject<{
171
181
  }>;
172
182
  detail: z.ZodOptional<z.ZodString>;
173
183
  since: z.ZodString;
184
+ challenge: z.ZodOptional<z.ZodString>;
174
185
  audience: z.ZodOptional<z.ZodString>;
175
186
  }, z.core.$strip>>;
176
187
  sourceVersionId: z.ZodNullable<z.ZodString>;
@@ -203,6 +214,9 @@ export declare const teamListResponseSchema: z.ZodObject<{
203
214
  personal: "personal";
204
215
  enterprise: "enterprise";
205
216
  }>;
217
+ partner: z.ZodNullable<z.ZodObject<{
218
+ enabledAt: z.ZodString;
219
+ }, z.core.$strip>>;
206
220
  defaultDataLocation: z.ZodString;
207
221
  createdAt: z.ZodString;
208
222
  updatedAt: z.ZodString;
@@ -283,10 +297,24 @@ export declare const teamInvitationListResponseSchema: z.ZodObject<{
283
297
  }, z.core.$strip>;
284
298
  }, z.core.$strip>;
285
299
  export declare const teamDataLocationSchema: z.ZodString;
300
+ export declare const connectorsServingSchema: z.ZodObject<{
301
+ adminOnly: z.ZodBoolean;
302
+ allowlist: z.ZodNullable<z.ZodArray<z.ZodString>>;
303
+ }, z.core.$strip>;
286
304
  export declare const teamSettingsUpdateSchema: z.ZodObject<{
287
- defaultDataLocation: z.ZodString;
305
+ defaultDataLocation: z.ZodOptional<z.ZodString>;
306
+ connectorsServing: z.ZodOptional<z.ZodObject<{
307
+ adminOnly: z.ZodBoolean;
308
+ allowlist: z.ZodNullable<z.ZodArray<z.ZodString>>;
309
+ }, z.core.$strip>>;
310
+ githubPreviewCommentsEnabled: z.ZodOptional<z.ZodBoolean>;
288
311
  }, z.core.$strip>;
289
312
  export declare const teamSettingsResponseSchema: z.ZodObject<{
313
+ connectorsServing: z.ZodDefault<z.ZodObject<{
314
+ adminOnly: z.ZodBoolean;
315
+ allowlist: z.ZodNullable<z.ZodArray<z.ZodString>>;
316
+ }, z.core.$strip>>;
317
+ githubPreviewCommentsEnabled: z.ZodOptional<z.ZodBoolean>;
290
318
  teamId: z.ZodString;
291
319
  defaultDataLocation: z.ZodString;
292
320
  regionOptions: z.ZodArray<z.ZodObject<{
@@ -16,9 +16,10 @@ export function normalizeTeamMemberRole(role) {
16
16
  // An invitation is its own resource under `/v1/team-invitations`, so the team
17
17
  // it belongs to travels in the body (create) or the query (list) instead of a
18
18
  // path segment.
19
+ export const teamInvitationEmailSchema = z.string().trim().email().toLowerCase();
19
20
  export const teamInvitationCreateSchema = z.object({
20
21
  teamId: z.string().trim().min(1).describe("The team to invite this person to."),
21
- email: z.string().trim().email().toLowerCase(),
22
+ email: teamInvitationEmailSchema,
22
23
  role: teamMemberRole.default("member"),
23
24
  });
24
25
  export const teamMemberListQuerySchema = cursorListQuerySchema;
@@ -83,6 +84,12 @@ export const TeamInvitationSchema = z.object({
83
84
  // Team (the platform spec "Team"): Better Auth team in the main
84
85
  // tenant, carrying the resolved plan and default data location.
85
86
  export const teamPlanCode = planCodeSchema;
87
+ export const TeamPartnerSchema = z
88
+ .object({
89
+ enabledAt: z.string().datetime().describe("The instant this team became a partner."),
90
+ })
91
+ .nullable()
92
+ .describe("Partner access for this team, or null when the team is not a partner.");
86
93
  export const TeamSummarySchema = z.object({
87
94
  id: z.string().describe("The team id (the Better Auth team id in the main tenant)."),
88
95
  tenantId: z.string().describe("The owning tenant id; `ten_main` for self-serve teams."),
@@ -90,6 +97,7 @@ export const TeamSummarySchema = z.object({
90
97
  slug: z.string().describe("URL-safe team slug, unique per tenant."),
91
98
  role: teamMemberRole.describe("Requesting member's role; member for non-session credentials."),
92
99
  plan: teamPlanCode.describe("Resolved plan code from the active subscription."),
100
+ partner: TeamPartnerSchema,
93
101
  defaultDataLocation: z
94
102
  .string()
95
103
  .describe('Default placement region for new spaces; "auto" lets placement decide.'),
@@ -157,8 +165,17 @@ export const teamDataLocationSchema = z
157
165
  .min(1)
158
166
  .max(64)
159
167
  .describe('Default placement region for new spaces; "auto" lets placement decide.');
168
+ export const connectorsServingSchema = z.object({
169
+ adminOnly: z.boolean(),
170
+ allowlist: z.array(z.string().min(1)).nullable(),
171
+ });
160
172
  export const teamSettingsUpdateSchema = z.object({
161
- defaultDataLocation: teamDataLocationSchema,
173
+ defaultDataLocation: teamDataLocationSchema.optional(),
174
+ connectorsServing: connectorsServingSchema.optional(),
175
+ githubPreviewCommentsEnabled: z
176
+ .boolean()
177
+ .optional()
178
+ .describe("Controls GitHub preview comments for Spaces that use the team setting."),
162
179
  });
163
180
  const infraCapabilityOptionSchema = z.object({
164
181
  id: z.string(),
@@ -166,6 +183,11 @@ const infraCapabilityOptionSchema = z.object({
166
183
  });
167
184
  // Served by `GET /v1/teams/{teamId}/settings`, and echoed by the PATCH.
168
185
  export const teamSettingsResponseSchema = z.object({
186
+ connectorsServing: connectorsServingSchema.default({ adminOnly: false, allowlist: null }),
187
+ githubPreviewCommentsEnabled: z
188
+ .boolean()
189
+ .optional()
190
+ .describe("Controls GitHub preview comments for Spaces that use the team setting."),
169
191
  teamId: z.string().describe("The team id the settings belong to."),
170
192
  defaultDataLocation: teamDataLocationSchema,
171
193
  regionOptions: z
@@ -15,6 +15,7 @@ export declare const ManifestStatusItemSchema: z.ZodObject<{
15
15
  }>;
16
16
  detail: z.ZodOptional<z.ZodString>;
17
17
  since: z.ZodString;
18
+ challenge: z.ZodOptional<z.ZodString>;
18
19
  audience: z.ZodOptional<z.ZodString>;
19
20
  }, z.core.$strip>;
20
21
  export type ManifestStatusItem = z.infer<typeof ManifestStatusItemSchema>;
@@ -34,6 +35,7 @@ export declare const ManifestStatusSchema: z.ZodObject<{
34
35
  }>;
35
36
  detail: z.ZodOptional<z.ZodString>;
36
37
  since: z.ZodString;
38
+ challenge: z.ZodOptional<z.ZodString>;
37
39
  audience: z.ZodOptional<z.ZodString>;
38
40
  }, z.core.$strip>>;
39
41
  sourceVersionId: z.ZodNullable<z.ZodString>;
@@ -52,6 +54,54 @@ export type ManifestStatus = z.infer<typeof ManifestStatusSchema>;
52
54
  * the answer follows the actual account wiring instead of a flag someone has to
53
55
  * remember to flip.
54
56
  */
57
+ export declare const TenantDomainSetupSchema: z.ZodObject<{
58
+ api: z.ZodNullable<z.ZodObject<{
59
+ origin: z.ZodString;
60
+ dnsInstructions: z.ZodArray<z.ZodObject<{
61
+ type: z.ZodEnum<{
62
+ A: "A";
63
+ AAAA: "AAAA";
64
+ CNAME: "CNAME";
65
+ TXT: "TXT";
66
+ ALIAS: "ALIAS";
67
+ }>;
68
+ name: z.ZodString;
69
+ value: z.ZodString;
70
+ ttl: z.ZodOptional<z.ZodNumber>;
71
+ purpose: z.ZodEnum<{
72
+ verification: "verification";
73
+ routing: "routing";
74
+ ssl: "ssl";
75
+ }>;
76
+ }, z.core.$strip>>;
77
+ probeUrl: z.ZodString;
78
+ upstreamOrigin: z.ZodString;
79
+ proxyHeaders: z.ZodObject<{
80
+ "x-spacefast-tenant-id": z.ZodString;
81
+ }, z.core.$strip>;
82
+ }, z.core.$strip>>;
83
+ hostnames: z.ZodNullable<z.ZodObject<{
84
+ apex: z.ZodString;
85
+ dnsInstructions: z.ZodArray<z.ZodObject<{
86
+ type: z.ZodEnum<{
87
+ A: "A";
88
+ AAAA: "AAAA";
89
+ CNAME: "CNAME";
90
+ TXT: "TXT";
91
+ ALIAS: "ALIAS";
92
+ }>;
93
+ name: z.ZodString;
94
+ value: z.ZodString;
95
+ ttl: z.ZodOptional<z.ZodNumber>;
96
+ purpose: z.ZodEnum<{
97
+ verification: "verification";
98
+ routing: "routing";
99
+ ssl: "ssl";
100
+ }>;
101
+ }, z.core.$strip>>;
102
+ }, z.core.$strip>>;
103
+ }, z.core.$strip>;
104
+ export type TenantDomainSetup = z.infer<typeof TenantDomainSetupSchema>;
55
105
  export declare const TenantSelfSchema: z.ZodObject<{
56
106
  id: z.ZodString;
57
107
  kind: z.ZodEnum<{
@@ -70,6 +120,53 @@ export declare const TenantSelfSchema: z.ZodObject<{
70
120
  deleted: "deleted";
71
121
  }>;
72
122
  name: z.ZodString;
123
+ domainSetup: z.ZodOptional<z.ZodObject<{
124
+ api: z.ZodNullable<z.ZodObject<{
125
+ origin: z.ZodString;
126
+ dnsInstructions: z.ZodArray<z.ZodObject<{
127
+ type: z.ZodEnum<{
128
+ A: "A";
129
+ AAAA: "AAAA";
130
+ CNAME: "CNAME";
131
+ TXT: "TXT";
132
+ ALIAS: "ALIAS";
133
+ }>;
134
+ name: z.ZodString;
135
+ value: z.ZodString;
136
+ ttl: z.ZodOptional<z.ZodNumber>;
137
+ purpose: z.ZodEnum<{
138
+ verification: "verification";
139
+ routing: "routing";
140
+ ssl: "ssl";
141
+ }>;
142
+ }, z.core.$strip>>;
143
+ probeUrl: z.ZodString;
144
+ upstreamOrigin: z.ZodString;
145
+ proxyHeaders: z.ZodObject<{
146
+ "x-spacefast-tenant-id": z.ZodString;
147
+ }, z.core.$strip>;
148
+ }, z.core.$strip>>;
149
+ hostnames: z.ZodNullable<z.ZodObject<{
150
+ apex: z.ZodString;
151
+ dnsInstructions: z.ZodArray<z.ZodObject<{
152
+ type: z.ZodEnum<{
153
+ A: "A";
154
+ AAAA: "AAAA";
155
+ CNAME: "CNAME";
156
+ TXT: "TXT";
157
+ ALIAS: "ALIAS";
158
+ }>;
159
+ name: z.ZodString;
160
+ value: z.ZodString;
161
+ ttl: z.ZodOptional<z.ZodNumber>;
162
+ purpose: z.ZodEnum<{
163
+ verification: "verification";
164
+ routing: "routing";
165
+ ssl: "ssl";
166
+ }>;
167
+ }, z.core.$strip>>;
168
+ }, z.core.$strip>>;
169
+ }, z.core.$strip>>;
73
170
  defaultRegion: z.ZodNullable<z.ZodString>;
74
171
  provisioning: z.ZodObject<{
75
172
  mode: z.ZodEnum<{
@@ -89,6 +186,7 @@ export declare const TenantSelfSchema: z.ZodObject<{
89
186
  }>;
90
187
  detail: z.ZodOptional<z.ZodString>;
91
188
  since: z.ZodString;
189
+ challenge: z.ZodOptional<z.ZodString>;
92
190
  audience: z.ZodOptional<z.ZodString>;
93
191
  }, z.core.$strip>>;
94
192
  sourceVersionId: z.ZodNullable<z.ZodString>;
@@ -1,4 +1,5 @@
1
1
  import { z } from "zod";
2
+ import { DnsInstructionSchema } from "./common.js";
2
3
  import { tenantKind, tenantMode, tenantStatus } from "./enums.js";
3
4
  import { systemPresentationSchema } from "./space-config.js";
4
5
  /**
@@ -21,6 +22,10 @@ export const ManifestStatusItemSchema = z.object({
21
22
  .string()
22
23
  .datetime()
23
24
  .describe("When this key last CHANGED state — stable across no-op re-runs, so it reads as `<state> since …`."),
25
+ challenge: z
26
+ .string()
27
+ .optional()
28
+ .describe("Sign this challenge with every new issuer key, using the supplied audience, then republish proofs. Existing active keys remain usable while rotation is pending."),
24
29
  audience: z
25
30
  .string()
26
31
  .optional()
@@ -52,12 +57,27 @@ export const ManifestStatusSchema = z.object({
52
57
  * the answer follows the actual account wiring instead of a flag someone has to
53
58
  * remember to flip.
54
59
  */
60
+ export const TenantDomainSetupSchema = z.object({
61
+ api: z
62
+ .object({
63
+ origin: z.string().url(),
64
+ dnsInstructions: z.array(DnsInstructionSchema),
65
+ probeUrl: z.string().url(),
66
+ upstreamOrigin: z.string().url(),
67
+ proxyHeaders: z.object({ "x-spacefast-tenant-id": z.string() }),
68
+ })
69
+ .nullable(),
70
+ hostnames: z
71
+ .object({ apex: z.string(), dnsInstructions: z.array(DnsInstructionSchema) })
72
+ .nullable(),
73
+ });
55
74
  export const TenantSelfSchema = z.object({
56
75
  id: z.string().describe("Tenant id."),
57
76
  kind: tenantKind.describe("Tenant class."),
58
77
  mode: tenantMode.describe("`test` for a linked test tenant (a sandbox twin), `live` otherwise. Distinct from `provisioning.mode`."),
59
78
  status: tenantStatus.describe("Whether the tenant is active, past due, suspended, or deleted."),
60
79
  name: z.string().describe("Human-readable tenant name."),
80
+ domainSetup: TenantDomainSetupSchema.optional().describe("DNS ownership and routing instructions for declared custom domains. Test tenants do not configure live domains."),
61
81
  defaultRegion: z
62
82
  .string()
63
83
  .nullable()
@@ -25,6 +25,16 @@ export declare const spaceTransferCreateSchema: z.ZodObject<{
25
25
  principalId: z.ZodString;
26
26
  }, z.core.$strip>;
27
27
  }, z.core.$strip>;
28
+ export declare const spaceTransferListQuerySchema: z.ZodObject<{
29
+ team: z.ZodString;
30
+ spaceId: z.ZodOptional<z.ZodString>;
31
+ status: z.ZodOptional<z.ZodEnum<{
32
+ pending_confirmation: "pending_confirmation";
33
+ completed: "completed";
34
+ canceled: "canceled";
35
+ expired: "expired";
36
+ }>>;
37
+ }, z.core.$strip>;
28
38
  export declare const spaceTransferSchema: z.ZodObject<{
29
39
  id: z.ZodString;
30
40
  spaceId: z.ZodString;
@@ -54,3 +64,85 @@ export declare const spaceTransferSchema: z.ZodObject<{
54
64
  createdAt: z.ZodString;
55
65
  updatedAt: z.ZodString;
56
66
  }, z.core.$strip>;
67
+ export declare const spaceTransferListItemSchema: z.ZodObject<{
68
+ id: z.ZodString;
69
+ spaceId: z.ZodString;
70
+ from: z.ZodObject<{
71
+ principalType: z.ZodEnum<{
72
+ team: "team";
73
+ external: "external";
74
+ }>;
75
+ principalId: z.ZodString;
76
+ tenantId: z.ZodString;
77
+ }, z.core.$strip>;
78
+ to: z.ZodObject<{
79
+ principalType: z.ZodEnum<{
80
+ team: "team";
81
+ external: "external";
82
+ }>;
83
+ principalId: z.ZodString;
84
+ tenantId: z.ZodString;
85
+ }, z.core.$strip>;
86
+ status: z.ZodEnum<{
87
+ pending_confirmation: "pending_confirmation";
88
+ completed: "completed";
89
+ canceled: "canceled";
90
+ expired: "expired";
91
+ }>;
92
+ expiresAt: z.ZodString;
93
+ createdAt: z.ZodString;
94
+ updatedAt: z.ZodString;
95
+ direction: z.ZodEnum<{
96
+ outgoing: "outgoing";
97
+ incoming: "incoming";
98
+ }>;
99
+ space: z.ZodObject<{
100
+ id: z.ZodString;
101
+ slug: z.ZodString;
102
+ title: z.ZodString;
103
+ }, z.core.$strip>;
104
+ fromDisplayName: z.ZodNullable<z.ZodString>;
105
+ toDisplayName: z.ZodNullable<z.ZodString>;
106
+ }, z.core.$strip>;
107
+ export declare const spaceTransferListSchema: z.ZodObject<{
108
+ data: z.ZodArray<z.ZodObject<{
109
+ id: z.ZodString;
110
+ spaceId: z.ZodString;
111
+ from: z.ZodObject<{
112
+ principalType: z.ZodEnum<{
113
+ team: "team";
114
+ external: "external";
115
+ }>;
116
+ principalId: z.ZodString;
117
+ tenantId: z.ZodString;
118
+ }, z.core.$strip>;
119
+ to: z.ZodObject<{
120
+ principalType: z.ZodEnum<{
121
+ team: "team";
122
+ external: "external";
123
+ }>;
124
+ principalId: z.ZodString;
125
+ tenantId: z.ZodString;
126
+ }, z.core.$strip>;
127
+ status: z.ZodEnum<{
128
+ pending_confirmation: "pending_confirmation";
129
+ completed: "completed";
130
+ canceled: "canceled";
131
+ expired: "expired";
132
+ }>;
133
+ expiresAt: z.ZodString;
134
+ createdAt: z.ZodString;
135
+ updatedAt: z.ZodString;
136
+ direction: z.ZodEnum<{
137
+ outgoing: "outgoing";
138
+ incoming: "incoming";
139
+ }>;
140
+ space: z.ZodObject<{
141
+ id: z.ZodString;
142
+ slug: z.ZodString;
143
+ title: z.ZodString;
144
+ }, z.core.$strip>;
145
+ fromDisplayName: z.ZodNullable<z.ZodString>;
146
+ toDisplayName: z.ZodNullable<z.ZodString>;
147
+ }, z.core.$strip>>;
148
+ }, z.core.$strip>;
@@ -30,6 +30,16 @@ export const spaceTransferCreateSchema = z.object({
30
30
  spaceId: z.string().min(1).describe("Space to transfer (`spc_`)."),
31
31
  to: transferPrincipalInputSchema.describe("Receiving principal. Must live in the space's tenant; cross-tenant transfers are unsupported."),
32
32
  });
33
+ export const spaceTransferListQuerySchema = z.object({
34
+ team: z
35
+ .string()
36
+ .min(1)
37
+ .describe("Team id or slug whose transfers to list. The caller must hold transfer authority on it."),
38
+ spaceId: z.string().min(1).optional().describe("Filter to transfers of one space (`spc_`)."),
39
+ status: spaceTransferStatus
40
+ .optional()
41
+ .describe("Filter by transfer state. Omitted, only `pending_confirmation` transfers return."),
42
+ });
33
43
  export const spaceTransferSchema = z.object({
34
44
  id: z.string().describe("SpaceTransfer id (`trf_`)."),
35
45
  spaceId: z.string().describe("Space being transferred."),
@@ -43,3 +53,30 @@ export const spaceTransferSchema = z.object({
43
53
  createdAt: z.string().datetime(),
44
54
  updatedAt: z.string().datetime(),
45
55
  });
56
+ // List items carry what each side's UI needs before it can read anything else:
57
+ // the receiving side cannot `getSpace` until it accepts, so the space summary
58
+ // and the counterpart team's name ride on the transfer itself.
59
+ export const spaceTransferListItemSchema = spaceTransferSchema.extend({
60
+ direction: z
61
+ .enum(["outgoing", "incoming"])
62
+ .describe("Whether the queried team is sending (`outgoing`) or receiving (`incoming`)."),
63
+ space: z
64
+ .object({
65
+ id: z.string(),
66
+ slug: z.string(),
67
+ title: z.string(),
68
+ })
69
+ .describe("Summary of the space under transfer."),
70
+ fromDisplayName: z
71
+ .string()
72
+ .nullable()
73
+ .describe("Sending team's name; null when the sender is an external principal."),
74
+ toDisplayName: z
75
+ .string()
76
+ .nullable()
77
+ .describe("Receiving team's name; null when the receiver is an external principal."),
78
+ });
79
+ // Pending transfers expire in 7 days, so a team's list is bounded: no cursor.
80
+ export const spaceTransferListSchema = z.object({
81
+ data: z.array(spaceTransferListItemSchema),
82
+ });