weave-typescript 0.37.0 → 0.39.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -143,6 +143,11 @@ export interface AuthOrganization {
143
143
  slug: string;
144
144
  name: string;
145
145
  kind: OrganizationKind;
146
+ /**
147
+ * Deprecated: provider identifiers are backend-only; use id.
148
+ *
149
+ * @deprecated
150
+ */
146
151
  stytchOrganizationId: string;
147
152
  roleIds: string[];
148
153
  membershipStatus: MembershipStatus;
@@ -151,7 +156,17 @@ export interface DiscoveryOrganization {
151
156
  organizationId: string;
152
157
  organizationSlug: string;
153
158
  organizationName: string;
159
+ /**
160
+ * Deprecated: provider identifiers are backend-only; use organization_id.
161
+ *
162
+ * @deprecated
163
+ */
154
164
  stytchOrganizationId: string;
165
+ /**
166
+ * Deprecated: provider identifiers are backend-only; use organization_slug.
167
+ *
168
+ * @deprecated
169
+ */
155
170
  stytchOrganizationSlug: string;
156
171
  organizationKind: OrganizationKind;
157
172
  status: DiscoveryOrganizationStatus;
@@ -165,7 +180,17 @@ export interface InviteOnboardingState {
165
180
  organizationSlug: string;
166
181
  organizationName: string;
167
182
  organizationKind: OrganizationKind;
183
+ /**
184
+ * Deprecated: provider identifiers are backend-only; use organization_id.
185
+ *
186
+ * @deprecated
187
+ */
168
188
  stytchOrganizationId: string;
189
+ /**
190
+ * Deprecated: provider identifiers are backend-only; use invite_session_id.
191
+ *
192
+ * @deprecated
193
+ */
169
194
  stytchMemberId: string;
170
195
  email: string;
171
196
  displayName: string;
@@ -212,7 +237,17 @@ export interface UserPreferences_OrganizationPagePositionsEntry {
212
237
  export interface OrganizationAuthSettings {
213
238
  organizationId: string;
214
239
  organizationSlug: string;
240
+ /**
241
+ * Deprecated: provider identifiers are backend-only; use organization_id.
242
+ *
243
+ * @deprecated
244
+ */
215
245
  stytchOrganizationId: string;
246
+ /**
247
+ * Deprecated: provider identifiers are backend-only; use organization_slug.
248
+ *
249
+ * @deprecated
250
+ */
216
251
  stytchOrganizationSlug: string;
217
252
  organizationKind: OrganizationKind;
218
253
  allowedAuthMethods: AuthMethod[];
@@ -229,9 +264,16 @@ export interface OrganizationAuthSettings {
229
264
  } | undefined;
230
265
  }
231
266
  export interface OrganizationMember {
267
+ /** Weave organization_memberships.id. */
232
268
  id: string;
269
+ /** Weave users.id. */
233
270
  userId: string;
234
271
  organizationId: string;
272
+ /**
273
+ * Deprecated: provider identifiers are backend-only; use id.
274
+ *
275
+ * @deprecated
276
+ */
235
277
  stytchMemberId: string;
236
278
  email: string;
237
279
  displayName: string;
@@ -92,9 +92,20 @@ export interface CompleteInviteOAuthResponse {
92
92
  export interface RequestInviteRecoveryRequest {
93
93
  email: string;
94
94
  organizationSlug: string;
95
+ /**
96
+ * Deprecated: provider identifiers are backend-only; use invite_session_id.
97
+ *
98
+ * @deprecated
99
+ */
95
100
  stytchOrganizationId: string;
101
+ /**
102
+ * Deprecated: provider identifiers are backend-only; use invite_session_id.
103
+ *
104
+ * @deprecated
105
+ */
96
106
  stytchMemberId: string;
97
107
  reason: InviteRecoveryReason;
108
+ inviteSessionId: string;
98
109
  }
99
110
  export interface RequestInviteRecoveryResponse {
100
111
  accepted: boolean;
@@ -104,6 +115,11 @@ export interface RequestInviteRecoveryResponse {
104
115
  export interface ExchangeDiscoveryOrganizationRequest {
105
116
  discoverySessionId: string;
106
117
  organizationId: string;
118
+ /**
119
+ * Deprecated: provider identifiers are backend-only; use organization_id.
120
+ *
121
+ * @deprecated
122
+ */
107
123
  stytchOrganizationId: string;
108
124
  }
109
125
  export interface ExchangeDiscoveryOrganizationResponse {
@@ -190,6 +206,7 @@ export interface CreateOrganizationMemberResponse {
190
206
  }
191
207
  export interface UpdateOrganizationMemberRequest {
192
208
  organizationSlug: string;
209
+ /** Weave organization_memberships.id. */
193
210
  memberId: string;
194
211
  status: MembershipStatus;
195
212
  roleIds: string[];
@@ -199,6 +216,7 @@ export interface UpdateOrganizationMemberResponse {
199
216
  }
200
217
  export interface RemoveOrganizationMemberRequest {
201
218
  organizationSlug: string;
219
+ /** Weave organization_memberships.id. */
202
220
  memberId: string;
203
221
  }
204
222
  export interface RemoveOrganizationMemberResponse {
@@ -206,6 +224,7 @@ export interface RemoveOrganizationMemberResponse {
206
224
  }
207
225
  export interface ResendOrganizationMemberInviteRequest {
208
226
  organizationSlug: string;
227
+ /** Weave organization_memberships.id. */
209
228
  memberId: string;
210
229
  }
211
230
  export interface ResendOrganizationMemberInviteResponse {
@@ -213,6 +232,7 @@ export interface ResendOrganizationMemberInviteResponse {
213
232
  }
214
233
  export interface RevokeOrganizationMemberInviteRequest {
215
234
  organizationSlug: string;
235
+ /** Weave organization_memberships.id. */
216
236
  memberId: string;
217
237
  }
218
238
  export interface RevokeOrganizationMemberInviteResponse {
@@ -230,6 +250,7 @@ export interface CreateOrganizationTeamRequest {
230
250
  slug: string;
231
251
  description: string;
232
252
  roleIds: string[];
253
+ /** Weave organization_memberships.id values. */
233
254
  memberIds: string[];
234
255
  }
235
256
  export interface CreateOrganizationTeamResponse {
@@ -249,6 +270,7 @@ export interface UpdateOrganizationTeamRequest {
249
270
  slug: string;
250
271
  description: string;
251
272
  roleIds: string[];
273
+ /** Weave organization_memberships.id values. */
252
274
  memberIds: string[];
253
275
  }
254
276
  export interface UpdateOrganizationTeamResponse {
@@ -1612,7 +1612,14 @@ exports.CompleteInviteOAuthResponse = {
1612
1612
  },
1613
1613
  };
1614
1614
  function createBaseRequestInviteRecoveryRequest() {
1615
- return { email: "", organizationSlug: "", stytchOrganizationId: "", stytchMemberId: "", reason: 0 };
1615
+ return {
1616
+ email: "",
1617
+ organizationSlug: "",
1618
+ stytchOrganizationId: "",
1619
+ stytchMemberId: "",
1620
+ reason: 0,
1621
+ inviteSessionId: "",
1622
+ };
1616
1623
  }
1617
1624
  exports.RequestInviteRecoveryRequest = {
1618
1625
  encode(message, writer = new wire_1.BinaryWriter()) {
@@ -1631,6 +1638,9 @@ exports.RequestInviteRecoveryRequest = {
1631
1638
  if (message.reason !== 0) {
1632
1639
  writer.uint32(40).int32(message.reason);
1633
1640
  }
1641
+ if (message.inviteSessionId !== "") {
1642
+ writer.uint32(50).string(message.inviteSessionId);
1643
+ }
1634
1644
  return writer;
1635
1645
  },
1636
1646
  decode(input, length) {
@@ -1675,6 +1685,13 @@ exports.RequestInviteRecoveryRequest = {
1675
1685
  message.reason = reader.int32();
1676
1686
  continue;
1677
1687
  }
1688
+ case 6: {
1689
+ if (tag !== 50) {
1690
+ break;
1691
+ }
1692
+ message.inviteSessionId = reader.string();
1693
+ continue;
1694
+ }
1678
1695
  }
1679
1696
  if ((tag & 7) === 4 || tag === 0) {
1680
1697
  break;
@@ -1702,6 +1719,11 @@ exports.RequestInviteRecoveryRequest = {
1702
1719
  ? globalThis.String(object.stytch_member_id)
1703
1720
  : "",
1704
1721
  reason: isSet(object.reason) ? (0, auth_pb_1.inviteRecoveryReasonFromJSON)(object.reason) : 0,
1722
+ inviteSessionId: isSet(object.inviteSessionId)
1723
+ ? globalThis.String(object.inviteSessionId)
1724
+ : isSet(object.invite_session_id)
1725
+ ? globalThis.String(object.invite_session_id)
1726
+ : "",
1705
1727
  };
1706
1728
  },
1707
1729
  toJSON(message) {
@@ -1721,19 +1743,23 @@ exports.RequestInviteRecoveryRequest = {
1721
1743
  if (message.reason !== 0) {
1722
1744
  obj.reason = (0, auth_pb_1.inviteRecoveryReasonToJSON)(message.reason);
1723
1745
  }
1746
+ if (message.inviteSessionId !== "") {
1747
+ obj.inviteSessionId = message.inviteSessionId;
1748
+ }
1724
1749
  return obj;
1725
1750
  },
1726
1751
  create(base) {
1727
1752
  return exports.RequestInviteRecoveryRequest.fromPartial(base !== null && base !== void 0 ? base : {});
1728
1753
  },
1729
1754
  fromPartial(object) {
1730
- var _a, _b, _c, _d, _e;
1755
+ var _a, _b, _c, _d, _e, _f;
1731
1756
  const message = createBaseRequestInviteRecoveryRequest();
1732
1757
  message.email = (_a = object.email) !== null && _a !== void 0 ? _a : "";
1733
1758
  message.organizationSlug = (_b = object.organizationSlug) !== null && _b !== void 0 ? _b : "";
1734
1759
  message.stytchOrganizationId = (_c = object.stytchOrganizationId) !== null && _c !== void 0 ? _c : "";
1735
1760
  message.stytchMemberId = (_d = object.stytchMemberId) !== null && _d !== void 0 ? _d : "";
1736
1761
  message.reason = (_e = object.reason) !== null && _e !== void 0 ? _e : 0;
1762
+ message.inviteSessionId = (_f = object.inviteSessionId) !== null && _f !== void 0 ? _f : "";
1737
1763
  return message;
1738
1764
  },
1739
1765
  };
@@ -17,6 +17,7 @@ export declare enum KnowledgeRealmKind {
17
17
  KNOWLEDGE_REALM_KIND_ORG = 1,
18
18
  KNOWLEDGE_REALM_KIND_TAG = 2,
19
19
  KNOWLEDGE_REALM_KIND_USER = 3,
20
+ KNOWLEDGE_REALM_KIND_RESTRICTED_GROUP = 4,
20
21
  UNRECOGNIZED = -1
21
22
  }
22
23
  export declare function knowledgeRealmKindFromJSON(object: any): KnowledgeRealmKind;
@@ -81,6 +81,7 @@ var KnowledgeRealmKind;
81
81
  KnowledgeRealmKind[KnowledgeRealmKind["KNOWLEDGE_REALM_KIND_ORG"] = 1] = "KNOWLEDGE_REALM_KIND_ORG";
82
82
  KnowledgeRealmKind[KnowledgeRealmKind["KNOWLEDGE_REALM_KIND_TAG"] = 2] = "KNOWLEDGE_REALM_KIND_TAG";
83
83
  KnowledgeRealmKind[KnowledgeRealmKind["KNOWLEDGE_REALM_KIND_USER"] = 3] = "KNOWLEDGE_REALM_KIND_USER";
84
+ KnowledgeRealmKind[KnowledgeRealmKind["KNOWLEDGE_REALM_KIND_RESTRICTED_GROUP"] = 4] = "KNOWLEDGE_REALM_KIND_RESTRICTED_GROUP";
84
85
  KnowledgeRealmKind[KnowledgeRealmKind["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
85
86
  })(KnowledgeRealmKind || (exports.KnowledgeRealmKind = KnowledgeRealmKind = {}));
86
87
  function knowledgeRealmKindFromJSON(object) {
@@ -97,6 +98,9 @@ function knowledgeRealmKindFromJSON(object) {
97
98
  case 3:
98
99
  case "KNOWLEDGE_REALM_KIND_USER":
99
100
  return KnowledgeRealmKind.KNOWLEDGE_REALM_KIND_USER;
101
+ case 4:
102
+ case "KNOWLEDGE_REALM_KIND_RESTRICTED_GROUP":
103
+ return KnowledgeRealmKind.KNOWLEDGE_REALM_KIND_RESTRICTED_GROUP;
100
104
  case -1:
101
105
  case "UNRECOGNIZED":
102
106
  default:
@@ -113,6 +117,8 @@ function knowledgeRealmKindToJSON(object) {
113
117
  return "KNOWLEDGE_REALM_KIND_TAG";
114
118
  case KnowledgeRealmKind.KNOWLEDGE_REALM_KIND_USER:
115
119
  return "KNOWLEDGE_REALM_KIND_USER";
120
+ case KnowledgeRealmKind.KNOWLEDGE_REALM_KIND_RESTRICTED_GROUP:
121
+ return "KNOWLEDGE_REALM_KIND_RESTRICTED_GROUP";
116
122
  case KnowledgeRealmKind.UNRECOGNIZED:
117
123
  default:
118
124
  return "UNRECOGNIZED";
@@ -109,6 +109,15 @@ export declare enum DocumentSourceBlockKind {
109
109
  }
110
110
  export declare function documentSourceBlockKindFromJSON(object: any): DocumentSourceBlockKind;
111
111
  export declare function documentSourceBlockKindToJSON(object: DocumentSourceBlockKind): string;
112
+ export declare enum RestrictedGroupReplacementTarget {
113
+ RESTRICTED_GROUP_REPLACEMENT_TARGET_UNSPECIFIED = 0,
114
+ RESTRICTED_GROUP_REPLACEMENT_TARGET_PUBLIC = 1,
115
+ RESTRICTED_GROUP_REPLACEMENT_TARGET_PRIVATE = 2,
116
+ RESTRICTED_GROUP_REPLACEMENT_TARGET_RESTRICTED_GROUPS = 3,
117
+ UNRECOGNIZED = -1
118
+ }
119
+ export declare function restrictedGroupReplacementTargetFromJSON(object: any): RestrictedGroupReplacementTarget;
120
+ export declare function restrictedGroupReplacementTargetToJSON(object: RestrictedGroupReplacementTarget): string;
112
121
  export interface DocumentTag {
113
122
  tag: string;
114
123
  confidence: number;
@@ -129,6 +138,23 @@ export interface UserSensitivityClearance {
129
138
  sensitivityTagSlug: string;
130
139
  createdAt: Date | undefined;
131
140
  }
141
+ export interface RestrictedGroup {
142
+ id: string;
143
+ organizationId: string;
144
+ slug: string;
145
+ name: string;
146
+ description: string;
147
+ active: boolean;
148
+ userIds: string[];
149
+ orgTeamIds: string[];
150
+ documentCount: number;
151
+ createdAt: Date | undefined;
152
+ updatedAt: Date | undefined;
153
+ }
154
+ export interface RestrictedGroupReplacement {
155
+ target: RestrictedGroupReplacementTarget;
156
+ restrictedGroupIds: string[];
157
+ }
132
158
  export interface SourceLocation {
133
159
  type: string;
134
160
  value: any | undefined;
@@ -177,6 +203,7 @@ export interface Document {
177
203
  [key: string]: any;
178
204
  } | undefined;
179
205
  sensitivityTags: string[];
206
+ restrictedGroups: RestrictedGroup[];
180
207
  }
181
208
  export interface DocumentThreadCounts {
182
209
  total: number;
@@ -206,6 +233,7 @@ export interface DocumentSummary {
206
233
  metadata: {
207
234
  [key: string]: any;
208
235
  } | undefined;
236
+ restrictedGroups: RestrictedGroup[];
209
237
  }
210
238
  export interface DocumentActionPermissions {
211
239
  canReviewThreads: boolean;
@@ -344,6 +372,7 @@ export interface ListDocumentsRequest {
344
372
  pageToken: string;
345
373
  sortField: DocumentSortField;
346
374
  sortDirection: SortDirection;
375
+ restrictedGroupIds: string[];
347
376
  }
348
377
  export interface ListDocumentsResponse {
349
378
  documents: DocumentSummary[];
@@ -389,6 +418,57 @@ export interface DeleteDocumentRequest {
389
418
  export interface DeleteDocumentResponse {
390
419
  deleted: boolean;
391
420
  }
421
+ export interface ListRestrictedGroupsRequest {
422
+ organizationId: string;
423
+ actingUserId: string;
424
+ }
425
+ export interface ListRestrictedGroupsResponse {
426
+ restrictedGroups: RestrictedGroup[];
427
+ }
428
+ export interface GetRestrictedGroupRequest {
429
+ organizationId: string;
430
+ restrictedGroupId: string;
431
+ actingUserId: string;
432
+ }
433
+ export interface GetRestrictedGroupResponse {
434
+ restrictedGroup: RestrictedGroup | undefined;
435
+ }
436
+ export interface CreateRestrictedGroupRequest {
437
+ organizationId: string;
438
+ actingUserId: string;
439
+ slug: string;
440
+ name: string;
441
+ description: string;
442
+ userIds: string[];
443
+ orgTeamIds: string[];
444
+ }
445
+ export interface CreateRestrictedGroupResponse {
446
+ restrictedGroup: RestrictedGroup | undefined;
447
+ }
448
+ export interface UpdateRestrictedGroupRequest {
449
+ organizationId: string;
450
+ restrictedGroupId: string;
451
+ actingUserId: string;
452
+ slug: string;
453
+ name: string;
454
+ description: string;
455
+ userIds: string[];
456
+ orgTeamIds: string[];
457
+ active: boolean;
458
+ }
459
+ export interface UpdateRestrictedGroupResponse {
460
+ restrictedGroup: RestrictedGroup | undefined;
461
+ }
462
+ export interface DeleteRestrictedGroupRequest {
463
+ organizationId: string;
464
+ restrictedGroupId: string;
465
+ actingUserId: string;
466
+ replacement: RestrictedGroupReplacement | undefined;
467
+ }
468
+ export interface DeleteRestrictedGroupResponse {
469
+ deleted: boolean;
470
+ affectedDocumentCount: number;
471
+ }
392
472
  export interface RetryIngestionRequest {
393
473
  organizationId: string;
394
474
  ingestionRunId: string;
@@ -553,6 +633,8 @@ export interface PipelineEvent_PipelineFailed {
553
633
  export declare const DocumentTag: MessageFns<DocumentTag>;
554
634
  export declare const SensitivityTagDefinition: MessageFns<SensitivityTagDefinition>;
555
635
  export declare const UserSensitivityClearance: MessageFns<UserSensitivityClearance>;
636
+ export declare const RestrictedGroup: MessageFns<RestrictedGroup>;
637
+ export declare const RestrictedGroupReplacement: MessageFns<RestrictedGroupReplacement>;
556
638
  export declare const SourceLocation: MessageFns<SourceLocation>;
557
639
  export declare const TemporalValidity: MessageFns<TemporalValidity>;
558
640
  export declare const FacetFieldDefinition: MessageFns<FacetFieldDefinition>;
@@ -583,6 +665,16 @@ export declare const UpdateDocumentTagsRequest: MessageFns<UpdateDocumentTagsReq
583
665
  export declare const UpdateDocumentTagsResponse: MessageFns<UpdateDocumentTagsResponse>;
584
666
  export declare const DeleteDocumentRequest: MessageFns<DeleteDocumentRequest>;
585
667
  export declare const DeleteDocumentResponse: MessageFns<DeleteDocumentResponse>;
668
+ export declare const ListRestrictedGroupsRequest: MessageFns<ListRestrictedGroupsRequest>;
669
+ export declare const ListRestrictedGroupsResponse: MessageFns<ListRestrictedGroupsResponse>;
670
+ export declare const GetRestrictedGroupRequest: MessageFns<GetRestrictedGroupRequest>;
671
+ export declare const GetRestrictedGroupResponse: MessageFns<GetRestrictedGroupResponse>;
672
+ export declare const CreateRestrictedGroupRequest: MessageFns<CreateRestrictedGroupRequest>;
673
+ export declare const CreateRestrictedGroupResponse: MessageFns<CreateRestrictedGroupResponse>;
674
+ export declare const UpdateRestrictedGroupRequest: MessageFns<UpdateRestrictedGroupRequest>;
675
+ export declare const UpdateRestrictedGroupResponse: MessageFns<UpdateRestrictedGroupResponse>;
676
+ export declare const DeleteRestrictedGroupRequest: MessageFns<DeleteRestrictedGroupRequest>;
677
+ export declare const DeleteRestrictedGroupResponse: MessageFns<DeleteRestrictedGroupResponse>;
586
678
  export declare const RetryIngestionRequest: MessageFns<RetryIngestionRequest>;
587
679
  export declare const RetryIngestionResponse: MessageFns<RetryIngestionResponse>;
588
680
  export declare const GetThreadRequest: MessageFns<GetThreadRequest>;