@workos-inc/widgets 1.16.0 → 1.16.1-next.1786560778114

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.
@@ -49,136 +49,284 @@ type Scalars = {
49
49
  input: string;
50
50
  output: string;
51
51
  };
52
+ /** The `JSON` scalar type represents JSON values as specified by [ECMA-404](http://www.ecma-international.org/publications/files/ECMA-ST/ECMA-404.pdf). */
53
+ JSON: {
54
+ input: any;
55
+ output: any;
56
+ };
57
+ };
58
+ /** All other sessions were revoked successfully. */
59
+ type AllSessionsRevoked = {
60
+ __typename?: "AllSessionsRevoked";
61
+ success: Scalars["Boolean"]["output"];
62
+ };
63
+ type AssignPermissionToRoleInput = {
64
+ /** The slug of the permission to assign. */
65
+ permissionSlug: Scalars["String"]["input"];
66
+ /** The ID of the role to assign the permission to. */
67
+ roleId: Scalars["ID"]["input"];
68
+ };
69
+ type AuditEvent = {
70
+ __typename?: "AuditEvent";
71
+ action: Scalars["String"]["output"];
72
+ actor: AuditEventActor;
73
+ createdAt: Scalars["DateTime"]["output"];
74
+ data: Scalars["JSON"]["output"];
75
+ id: Scalars["ID"]["output"];
76
+ occurredAt: Scalars["DateTime"]["output"];
77
+ targets: Array<Scalars["String"]["output"]>;
78
+ updatedAt: Scalars["DateTime"]["output"];
79
+ };
80
+ type AuditEventActor = {
81
+ __typename?: "AuditEventActor";
82
+ id: Scalars["String"]["output"];
83
+ name?: Maybe<Scalars["String"]["output"]>;
84
+ type: Scalars["String"]["output"];
85
+ };
86
+ type AuditEventFilterInput = {
87
+ actions?: InputMaybe<Array<Scalars["String"]["input"]>>;
88
+ actorIds?: InputMaybe<Array<Scalars["String"]["input"]>>;
89
+ actorNames?: InputMaybe<Array<Scalars["String"]["input"]>>;
90
+ rangeEnd: Scalars["DateTime"]["input"];
91
+ rangeStart: Scalars["DateTime"]["input"];
92
+ search?: InputMaybe<Scalars["String"]["input"]>;
93
+ targetIds?: InputMaybe<Array<Scalars["String"]["input"]>>;
94
+ targetTypes?: InputMaybe<Array<Scalars["String"]["input"]>>;
95
+ };
96
+ type AuditEventList = {
97
+ __typename?: "AuditEventList";
98
+ data: Array<AuditEvent>;
99
+ listMetadata: ListMetadata;
100
+ };
101
+ type AuditLogExport = {
102
+ __typename?: "AuditLogExport";
103
+ id: Scalars["ID"]["output"];
104
+ state: AuditLogExportState;
105
+ };
106
+ type AuditLogExportState = "Error" | "Expired" | "Pending" | "Ready";
107
+ /** The authentication methods the environment allows, and the password policy it enforces. Distinct from what the authenticated user has set up, which lives on `me`. */
108
+ type AuthenticationSettings = {
109
+ __typename?: "AuthenticationSettings";
110
+ /** Whether multi-factor authentication is available in this environment. When `false`, TOTP enrollment should not be offered. */
111
+ mfaEnabled: Scalars["Boolean"]["output"];
112
+ /** Whether multi-factor authentication is mandatory for every user in this environment. */
113
+ mfaRequired: Scalars["Boolean"]["output"];
114
+ /** Whether users may authenticate with a passkey. */
115
+ passkeyAuthEnabled: Scalars["Boolean"]["output"];
116
+ /** Whether users may authenticate with a password. When `false`, `createPassword` and `updatePassword` should not be offered. */
117
+ passwordAuthEnabled: Scalars["Boolean"]["output"];
118
+ passwordPolicy: PasswordPolicy;
119
+ };
120
+ /** Input for confirming an email change with the verification code. */
121
+ type ConfirmEmailChangeInput = {
122
+ /** The verification code sent to the new email address. */
123
+ code: Scalars["String"]["input"];
124
+ /** The elevated access token from a successful `verifyCurrentEmail` call. */
125
+ elevatedAccessToken: Scalars["String"]["input"];
52
126
  };
127
+ type ConfirmEmailChangeResult = EmailChangeCodeExpired | EmailChangeCodeIncorrect | EmailChangeCodePreviouslyUsed | EmailChangeConfirmed | EmailChangeTooManyAttempts | EmailManagedByProvider | EmailNotAvailable | IdentityVerificationExpired | IdentityVerificationInvalid | InvalidEmail | NoPendingEmailChange;
53
128
  /** An OAuth profile linked to the authenticated user. */
54
- type ClientApi_ConnectedAccount = {
55
- __typename?: "ClientApi_ConnectedAccount";
129
+ type ConnectedAccount = {
130
+ __typename?: "ConnectedAccount";
56
131
  email?: Maybe<Scalars["String"]["output"]>;
57
132
  firstName?: Maybe<Scalars["String"]["output"]>;
58
133
  id: Scalars["ID"]["output"];
59
134
  lastLoginAt?: Maybe<Scalars["DateTime"]["output"]>;
60
135
  lastName?: Maybe<Scalars["String"]["output"]>;
61
136
  profilePictureUrl?: Maybe<Scalars["String"]["output"]>;
62
- provider: ClientApi_OAuthProvider;
137
+ provider: OAuthProvider;
63
138
  };
64
- /** OAuth provider for a connected account. */
65
- type ClientApi_OAuthProvider = "AppleOAuth" | "BitbucketOAuth" | "DiscordOAuth" | "GitLabOAuth" | "GithubOAuth" | "GoogleOAuth" | "IntuitOAuth" | "LinkedInOAuth" | "MicrosoftOAuth" | "SalesforceOAuth" | "SlackOAuth" | "VercelMarketplaceOAuth" | "VercelOAuth" | "XeroOAuth";
66
- /** An organization in the current environment. */
67
- type ClientApi_Organization = {
68
- __typename?: "ClientApi_Organization";
69
- /** Whether the organization allows profiles outside the organization domains. */
70
- allowProfilesOutsideOrganization: Scalars["Boolean"]["output"];
139
+ /** An SSO connection belonging to the organization. Mirrors the SSO Connection exposed by the REST connections API. */
140
+ type Connection = {
141
+ __typename?: "Connection";
71
142
  createdAt: Scalars["DateTime"]["output"];
72
143
  id: Scalars["ID"]["output"];
144
+ /** A human-readable name for the connection. */
73
145
  name: Scalars["String"]["output"];
146
+ /** The organization the connection belongs to. */
147
+ organizationId?: Maybe<Scalars["ID"]["output"]>;
148
+ /** Whether the connection has completed its IdP setup and can authenticate users (equivalent to an `Active` state). */
149
+ setupComplete: Scalars["Boolean"]["output"];
150
+ /** The connection's IdP setup status. `Active` indicates setup is complete; other states indicate where the connection is in its setup flow. */
151
+ state: ConnectionState;
152
+ /** The identity provider type of the connection. */
153
+ type: ConnectionType;
74
154
  updatedAt: Scalars["DateTime"]["output"];
75
155
  };
76
- /** A registered passkey (WebAuthn credential) for the authenticated user. */
77
- type ClientApi_Passkey = {
78
- __typename?: "ClientApi_Passkey";
79
- createdAt: Scalars["DateTime"]["output"];
80
- id: Scalars["ID"]["output"];
81
- /** When this passkey was last used to authenticate. */
82
- lastVerifiedAt?: Maybe<Scalars["DateTime"]["output"]>;
83
- updatedAt: Scalars["DateTime"]["output"];
156
+ /** Enum represents the state of the connection. */
157
+ type ConnectionState = "Active" | "Deleting" | "Inactive" | "Validating";
158
+ /** Enum represents the type of connection. */
159
+ type ConnectionType = "ADFSSAML" | "AdpOidc" | "AppleOAuth" | "Auth0Migration" | "Auth0SAML" | "AzureSAML" | "BitbucketOAuth" | "CasSAML" | "ClassLinkSAML" | "CleverOIDC" | "CloudflareSAML" | "CyberArkSAML" | "DiscordOAuth" | "DuoSAML" | "EntraIdOIDC" | "GenericOIDC" | "GenericSAML" | "GitLabOAuth" | "GithubOAuth" | "GoogleOAuth" | "GoogleOIDC" | "GoogleSAML" | "GrokOAuth" | "IntuitOAuth" | "JumpCloudSAML" | "KeycloakSAML" | "LastPassSAML" | "LinkedInOAuth" | "LoginGovOidc" | "MagicLink" | "MicrosoftOAuth" | "MiniOrangeSAML" | "NetIqSAML" | "OktaOIDC" | "OktaSAML" | "OneLoginSAML" | "OracleSAML" | "PingFederateSAML" | "PingOneSAML" | "RipplingSAML" | "SalesforceOAuth" | "SalesforceSAML" | "ShibbolethGenericSAML" | "ShibbolethSAML" | "SimpleSamlPhpSAML" | "SlackOAuth" | "TestIdp" | "VMwareSAML" | "VercelMarketplaceOAuth" | "VercelOAuth" | "XOAuth" | "XeroOAuth";
160
+ type CreateAuditLogExportInput = {
161
+ actions?: InputMaybe<Array<Scalars["String"]["input"]>>;
162
+ actorIds?: InputMaybe<Array<Scalars["String"]["input"]>>;
163
+ actorNames?: InputMaybe<Array<Scalars["String"]["input"]>>;
164
+ rangeEnd: Scalars["DateTime"]["input"];
165
+ rangeStart: Scalars["DateTime"]["input"];
166
+ targetIds?: InputMaybe<Array<Scalars["String"]["input"]>>;
167
+ targetTypes?: InputMaybe<Array<Scalars["String"]["input"]>>;
168
+ };
169
+ type CreateAuditLogExportResult = AuditLogExport | InvalidAuditLogExportDateRange | NoAuditEventsFound;
170
+ /** Input for setting a password on an account that does not yet have one (e.g. signed up via OAuth). */
171
+ type CreatePasswordInput = {
172
+ /** An elevated access token obtained by verifying the current email address. Required to prove recent re-authentication. */
173
+ elevatedAccessToken: Scalars["String"]["input"];
174
+ /** The password to set. Must satisfy the environment password policy. */
175
+ password: Scalars["String"]["input"];
84
176
  };
85
- /** A role available within the organization. */
86
- type ClientApi_Role = {
87
- __typename?: "ClientApi_Role";
177
+ type CreatePasswordResult = ElevatedAccessTokenExpired | ElevatedAccessTokenInvalid | PasswordCreated | PasswordPolicyViolation | UserAlreadyHasPassword;
178
+ type CreateRoleInput = {
179
+ /** Optional human-readable description of the role. */
180
+ description?: InputMaybe<Scalars["String"]["input"]>;
181
+ /** Human-readable name for the role. */
182
+ name: Scalars["String"]["input"];
183
+ /** Slugs of the permissions granted to the role. */
184
+ permissions?: InputMaybe<Array<Scalars["String"]["input"]>>;
185
+ /** Unique slug identifying the role. Generated from the name when omitted. */
186
+ slug?: InputMaybe<Scalars["String"]["input"]>;
187
+ };
188
+ type CreateSsoConnectionInput = {
189
+ /** A human-readable name for the connection. Defaults to the organization's name. */
190
+ name?: InputMaybe<Scalars["String"]["input"]>;
191
+ /** The identity provider type of the connection to create. */
192
+ type: ConnectionType;
193
+ };
194
+ /** The current email was verified successfully. */
195
+ type CurrentEmailVerified = {
196
+ __typename?: "CurrentEmailVerified";
197
+ /** The elevated access token to pass to `sendEmailChange` and `confirmEmailChange`. */
198
+ elevatedAccessToken: Scalars["String"]["output"];
199
+ /** When the elevated access token expires (ISO 8601). */
200
+ expiresAt: Scalars["String"]["output"];
201
+ };
202
+ /** Daily verification email quota exceeded. */
203
+ type DailyEmailQuotaExceeded = {
204
+ __typename?: "DailyEmailQuotaExceeded";
205
+ message: Scalars["String"]["output"];
206
+ };
207
+ /** A third-party data provider configured for the current environment. */
208
+ type DataProvider = {
209
+ __typename?: "DataProvider";
210
+ /** How accounts authenticate with this data provider. */
211
+ authMethods: Array<Scalars["String"]["output"]>;
88
212
  createdAt: Scalars["DateTime"]["output"];
89
213
  description?: Maybe<Scalars["String"]["output"]>;
214
+ /** Whether the data provider is enabled in the environment. */
215
+ enabled: Scalars["Boolean"]["output"];
90
216
  id: Scalars["ID"]["output"];
91
- /** Whether this is the default role assigned to new members. */
92
- isDefault: Scalars["Boolean"]["output"];
217
+ /** The provider type this data provider was created from. */
218
+ integrationType: Scalars["String"]["output"];
219
+ /** The display name of the data provider. */
93
220
  name: Scalars["String"]["output"];
221
+ /** The OAuth scopes configured for the data provider. `null` when the provider's default scopes are used. */
222
+ scopes?: Maybe<Array<Scalars["String"]["output"]>>;
223
+ /** The slug of the data provider. */
94
224
  slug: Scalars["String"]["output"];
225
+ /** The configuration state of the data provider: `valid`, `invalid`, or `requested`. */
226
+ state: Scalars["String"]["output"];
95
227
  updatedAt: Scalars["DateTime"]["output"];
96
228
  };
97
- /** Roles available in the organization along with role assignment configuration. */
98
- type ClientApi_RolesResult = {
99
- __typename?: "ClientApi_RolesResult";
100
- /** Whether members can be assigned multiple roles simultaneously. */
101
- multipleRolesEnabled: Scalars["Boolean"]["output"];
102
- roles: Array<ClientApi_Role>;
103
- };
104
- /** An active user session. */
105
- type ClientApi_Session = {
106
- __typename?: "ClientApi_Session";
229
+ /** A connection between a data provider and the authenticated user's account. */
230
+ type DataProviderConnection = {
231
+ __typename?: "DataProviderConnection";
232
+ /** How the connection authenticates: `oauth`, `api_key`, or `client_credentials`. */
233
+ authMethod: Scalars["String"]["output"];
107
234
  createdAt: Scalars["DateTime"]["output"];
108
- currentLocation?: Maybe<ClientApi_SessionLocation>;
235
+ /** The data provider this connection was created for. */
236
+ dataProviderId: Scalars["ID"]["output"];
237
+ /** The slug of the connected data provider. */
238
+ dataProviderSlug: Scalars["String"]["output"];
109
239
  id: Scalars["ID"]["output"];
110
- ipAddress?: Maybe<Scalars["String"]["output"]>;
111
- /** Whether this session is the one making the request. */
112
- isCurrent: Scalars["Boolean"]["output"];
113
- lastActivityAt?: Maybe<Scalars["DateTime"]["output"]>;
114
- organizationId?: Maybe<Scalars["String"]["output"]>;
115
- state: ClientApi_SessionState;
240
+ organizationId?: Maybe<Scalars["ID"]["output"]>;
241
+ /** The OAuth scopes granted for this connection. */
242
+ scopes: Array<Scalars["String"]["output"]>;
243
+ /** The status of the connection: `connected` or `needs_reauthorization`. */
244
+ state: Scalars["String"]["output"];
116
245
  updatedAt: Scalars["DateTime"]["output"];
117
- userAgent?: Maybe<Scalars["String"]["output"]>;
246
+ userId?: Maybe<Scalars["ID"]["output"]>;
118
247
  };
119
- /** Approximate geographic location derived from the session IP. */
120
- type ClientApi_SessionLocation = {
121
- __typename?: "ClientApi_SessionLocation";
122
- cityName: Scalars["String"]["output"];
123
- countryISOCode: Scalars["String"]["output"];
248
+ type DataProviderConnectionList = {
249
+ __typename?: "DataProviderConnectionList";
250
+ data: Array<DataProviderConnection>;
251
+ listMetadata: ListMetadata;
124
252
  };
125
- /** The lifecycle state of a session. */
126
- type ClientApi_SessionState = {
127
- __typename?: "ClientApi_SessionState";
128
- expiresAt?: Maybe<Scalars["DateTime"]["output"]>;
129
- /** Session state: Issued, Revoked, etc. */
130
- tag: Scalars["String"]["output"];
253
+ type DataProviderList = {
254
+ __typename?: "DataProviderList";
255
+ data: Array<DataProvider>;
256
+ listMetadata: ListMetadata;
131
257
  };
132
- /** A user in the current environment. */
133
- type ClientApi_User = {
134
- __typename?: "ClientApi_User";
135
- connectedAccounts: Array<ClientApi_ConnectedAccount>;
258
+ type DeleteRoleInput = {
259
+ /** The ID of the role to delete. */
260
+ id: Scalars["ID"]["input"];
261
+ };
262
+ /** A Directory Sync connection within the current environment. */
263
+ type Directory = {
264
+ __typename?: "Directory";
136
265
  createdAt: Scalars["DateTime"]["output"];
137
- email: Scalars["String"]["output"];
138
- emailVerified: Scalars["Boolean"]["output"];
139
- firstName?: Maybe<Scalars["String"]["output"]>;
266
+ externalKey: Scalars["String"]["output"];
140
267
  id: Scalars["ID"]["output"];
141
- lastName?: Maybe<Scalars["String"]["output"]>;
142
- /** Whether multi-factor authentication (TOTP) is set up for this user. Only populated on `me`. */
143
- mfaEnabled: Scalars["Boolean"]["output"];
144
- /** When MFA was last used to authenticate. Only populated on `me`. */
145
- mfaLastUsedAt?: Maybe<Scalars["DateTime"]["output"]>;
146
- profilePictureUrl?: Maybe<Scalars["String"]["output"]>;
268
+ name: Scalars["String"]["output"];
269
+ organizationId: Scalars["ID"]["output"];
270
+ /** The linking state of the directory. */
271
+ state: Scalars["String"]["output"];
272
+ /** The provider type of the directory. */
273
+ type: Scalars["String"]["output"];
147
274
  updatedAt: Scalars["DateTime"]["output"];
148
275
  };
149
- /** An organization the authenticated user belongs to, with a flag indicating whether it is the token's current organization. */
150
- type ClientApi_UserOrganization = {
151
- __typename?: "ClientApi_UserOrganization";
276
+ /** A group provisioned through a Directory Sync connection. */
277
+ type DirectoryGroup = {
278
+ __typename?: "DirectoryGroup";
279
+ createdAt: Scalars["DateTime"]["output"];
280
+ directoryId: Scalars["ID"]["output"];
152
281
  id: Scalars["ID"]["output"];
153
- /** Whether this is the organization the token is currently scoped to. */
154
- isCurrent: Scalars["Boolean"]["output"];
282
+ /** The identifier of the group in the identity provider. */
283
+ idpId: Scalars["String"]["output"];
155
284
  name: Scalars["String"]["output"];
285
+ organizationId: Scalars["ID"]["output"];
286
+ updatedAt: Scalars["DateTime"]["output"];
156
287
  };
157
- /** Input for confirming an email change with the verification code. */
158
- type ConfirmEmailChangeInput = {
159
- /** The verification code sent to the new email address. */
160
- code: Scalars["String"]["input"];
161
- /** The elevated access token from a successful `verifyCurrentEmail` call. */
162
- elevatedAccessToken: Scalars["String"]["input"];
288
+ type DirectoryGroupList = {
289
+ __typename?: "DirectoryGroupList";
290
+ data: Array<DirectoryGroup>;
291
+ listMetadata: ListMetadata;
163
292
  };
164
- type ConfirmEmailChangeResult = EmailChangeCodeExpired | EmailChangeCodeIncorrect | EmailChangeCodePreviouslyUsed | EmailChangeConfirmed | EmailChangeTooManyAttempts | EmailManagedByProvider | EmailNotAvailable | IdentityVerificationExpired | IdentityVerificationInvalid | InvalidEmail | NoPendingEmailChange;
165
- /** Input for setting a password on an account that does not yet have one (e.g. signed up via OAuth). */
166
- type CreatePasswordInput = {
167
- /** The password to set. Must satisfy the environment password policy. */
168
- password: Scalars["String"]["input"];
293
+ type DirectoryList = {
294
+ __typename?: "DirectoryList";
295
+ data: Array<Directory>;
296
+ listMetadata: ListMetadata;
169
297
  };
170
- type CreatePasswordResult = PasswordCreated | PasswordPolicyViolation | UserAlreadyHasPassword;
171
- /** The current email was verified successfully. */
172
- type CurrentEmailVerified = {
173
- __typename?: "CurrentEmailVerified";
174
- /** The elevated access token to pass to `sendEmailChange` and `confirmEmailChange`. */
175
- elevatedAccessToken: Scalars["String"]["output"];
176
- /** When the elevated access token expires (ISO 8601). */
177
- expiresAt: Scalars["String"]["output"];
298
+ /** A user provisioned through a Directory Sync connection. */
299
+ type DirectoryUser = {
300
+ __typename?: "DirectoryUser";
301
+ createdAt: Scalars["DateTime"]["output"];
302
+ directoryId: Scalars["ID"]["output"];
303
+ email?: Maybe<Scalars["String"]["output"]>;
304
+ firstName?: Maybe<Scalars["String"]["output"]>;
305
+ id: Scalars["ID"]["output"];
306
+ /** The identifier of the user in the identity provider. */
307
+ idpId: Scalars["String"]["output"];
308
+ lastName?: Maybe<Scalars["String"]["output"]>;
309
+ organizationId: Scalars["ID"]["output"];
310
+ /** The provisioning state of the directory user. */
311
+ state: Scalars["String"]["output"];
312
+ updatedAt: Scalars["DateTime"]["output"];
313
+ username?: Maybe<Scalars["String"]["output"]>;
178
314
  };
179
- /** Daily verification email quota exceeded. */
180
- type DailyEmailQuotaExceeded = {
181
- __typename?: "DailyEmailQuotaExceeded";
315
+ type DirectoryUserList = {
316
+ __typename?: "DirectoryUserList";
317
+ data: Array<DirectoryUser>;
318
+ listMetadata: ListMetadata;
319
+ };
320
+ /** The DNS name server provider detected for a domain. */
321
+ type DomainVerificationNameServer = "AwsRoute53" | "CloudFlare" | "GoDaddy" | "GoogleDomains" | "Other";
322
+ /** The elevated access token has expired. The user must re-verify their identity. */
323
+ type ElevatedAccessTokenExpired = {
324
+ __typename?: "ElevatedAccessTokenExpired";
325
+ message: Scalars["String"]["output"];
326
+ };
327
+ /** The elevated access token is invalid. */
328
+ type ElevatedAccessTokenInvalid = {
329
+ __typename?: "ElevatedAccessTokenInvalid";
182
330
  message: Scalars["String"]["output"];
183
331
  };
184
332
  /** The verification code has expired. */
@@ -203,7 +351,7 @@ type EmailChangeConfirmed = {
203
351
  elevatedAccessToken: Scalars["String"]["output"];
204
352
  /** When the elevated access token expires (ISO 8601). */
205
353
  expiresAt: Scalars["String"]["output"];
206
- user: ClientApi_User;
354
+ user: User;
207
355
  };
208
356
  /** Email change is not available for this account. */
209
357
  type EmailChangeNotAvailable = {
@@ -231,7 +379,35 @@ type EmailNotAvailable = {
231
379
  __typename?: "EmailNotAvailable";
232
380
  message: Scalars["String"]["output"];
233
381
  };
234
- type EnrollTotpResult = TotpAlreadyEnrolled | TotpFactor;
382
+ /** Input for enrolling a new TOTP factor. */
383
+ type EnrollTotpInput = {
384
+ /** An elevated access token obtained by verifying the current email address. Required to prove recent re-authentication. */
385
+ elevatedAccessToken: Scalars["String"]["input"];
386
+ };
387
+ type EnrollTotpResult = ElevatedAccessTokenExpired | ElevatedAccessTokenInvalid | TotpAlreadyEnrolled | TotpFactor;
388
+ /** A feature flag defined in the project that owns the environment the token was issued for. Mirrors the Feature Flag exposed by the REST feature flags API. */
389
+ type Flag = {
390
+ __typename?: "Flag";
391
+ createdAt: Scalars["DateTime"]["output"];
392
+ /** The value returned for users and organizations that do not match any targeting rule in the environment the token was issued for. */
393
+ defaultValue: Scalars["Boolean"]["output"];
394
+ description?: Maybe<Scalars["String"]["output"]>;
395
+ /** Whether the feature flag is active in the environment the token was issued for. */
396
+ enabled: Scalars["Boolean"]["output"];
397
+ id: Scalars["ID"]["output"];
398
+ /** A descriptive name for the feature flag. */
399
+ name: Scalars["String"]["output"];
400
+ /** A unique key used to reference the feature flag. */
401
+ slug: Scalars["String"]["output"];
402
+ /** Labels assigned to the feature flag. */
403
+ tags: Array<Scalars["String"]["output"]>;
404
+ updatedAt: Scalars["DateTime"]["output"];
405
+ };
406
+ type FlagList = {
407
+ __typename?: "FlagList";
408
+ data: Array<Flag>;
409
+ listMetadata: ListMetadata;
410
+ };
235
411
  /** The identity verification has expired. Please verify your current email again. */
236
412
  type IdentityVerificationExpired = {
237
413
  __typename?: "IdentityVerificationExpired";
@@ -247,6 +423,10 @@ type IncorrectPassword = {
247
423
  __typename?: "IncorrectPassword";
248
424
  _placeholder: Scalars["Boolean"]["output"];
249
425
  };
426
+ type InvalidAuditLogExportDateRange = {
427
+ __typename?: "InvalidAuditLogExportDateRange";
428
+ message: Scalars["String"]["output"];
429
+ };
250
430
  /** The provided email address is invalid. */
251
431
  type InvalidEmail = {
252
432
  __typename?: "InvalidEmail";
@@ -301,7 +481,7 @@ type InviteUserInput = {
301
481
  /** Slug of the role to grant on acceptance. Defaults to the organization default role when omitted. */
302
482
  roleSlug?: InputMaybe<Scalars["String"]["input"]>;
303
483
  };
304
- type InviteUserResult = InvalidInvitationExpiry | InvalidInviteeEmail | InvalidInviteeRole | InviteeAlreadyInvited | InviteeAlreadyMember | UserInvited;
484
+ type InviteUserResult = InvalidInvitationExpiry | InvalidInviteeEmail | InvalidInviteeRole | InviteeAlreadyInvited | InviteeAlreadyMember | InviteeEmailNotDeliverable | OrganizationBlockedFromSendingInvites | UserInvited;
305
485
  /** The user has already accepted their invitation and is an active member. */
306
486
  type InviteeAlreadyAccepted = {
307
487
  __typename?: "InviteeAlreadyAccepted";
@@ -317,6 +497,11 @@ type InviteeAlreadyMember = {
317
497
  __typename?: "InviteeAlreadyMember";
318
498
  email: Scalars["String"]["output"];
319
499
  };
500
+ /** The invitee's email domain has no mail servers, so the invitation email cannot be delivered. */
501
+ type InviteeEmailNotDeliverable = {
502
+ __typename?: "InviteeEmailNotDeliverable";
503
+ email: Scalars["String"]["output"];
504
+ };
320
505
  type ListMetadata = {
321
506
  __typename?: "ListMetadata";
322
507
  after?: Maybe<Scalars["String"]["output"]>;
@@ -352,10 +537,25 @@ type MfaFactorRemoved = {
352
537
  };
353
538
  type Mutation = {
354
539
  __typename?: "Mutation";
540
+ /** Grant a permission to a role belonging to the organization the token was issued for. */
541
+ assignPermissionToRole: Role;
355
542
  /** Confirms an email change using the verification code sent to the new email address. Requires an elevated access token from `verifyCurrentEmail`. */
356
543
  confirmEmailChange: ConfirmEmailChangeResult;
544
+ createAuditLogExport: CreateAuditLogExportResult;
545
+ /** Add a domain to the token's organization and begin DNS verification. */
546
+ createOrganizationDomain: OrganizationDomain;
357
547
  /** Set a password for the authenticated user who does not yet have one (e.g. signed up via OAuth). Validates against the environment password policy. */
358
548
  createPassword: CreatePasswordResult;
549
+ /** Create a role for the organization the token was issued for. */
550
+ createRole: Role;
551
+ /** Create an SSO connection for the token’s organization. */
552
+ createSsoConnection: Connection;
553
+ /** Delete a domain belonging to the token's organization and return it. */
554
+ deleteOrganizationDomain: OrganizationDomain;
555
+ /** Delete a role belonging to the organization the token was issued for. */
556
+ deleteRole: RoleDeleted;
557
+ /** Delete an SSO connection belonging to the token’s organization. */
558
+ deleteSsoConnection: Scalars["ID"]["output"];
359
559
  /** Create a TOTP factor and return the secret and QR URI for the user to scan. This is step 1 of TOTP enrollment. */
360
560
  enrollTotp: EnrollTotpResult;
361
561
  /** Invite a user to the organization the token was issued for, assigning a role and sending the invitation email. */
@@ -366,8 +566,14 @@ type Mutation = {
366
566
  removeMfaFactor: RemoveMfaFactorResult;
367
567
  /** Resend a pending, expired, or revoked invitation for the organization the token was issued for. If the original invitation has expired or been revoked, a new invitation is created with the same role. */
368
568
  resendInvitation: ResendInvitationResult;
569
+ /** Restart verification for a domain belonging to the token's organization. */
570
+ reverifyOrganizationDomain: OrganizationDomain;
571
+ /** Revokes all active sessions for the authenticated user except the current one. */
572
+ revokeAllSessions: RevokeAllSessionsResult;
369
573
  /** Revoke a pending invitation for the organization the token was issued for. */
370
574
  revokeInvitation: RevokeInvitationResult;
575
+ /** Revokes a specific session by ID. */
576
+ revokeSession: RevokeSessionResult;
371
577
  /** Sends a verification code to the new email address. Requires an elevated access token from `verifyCurrentEmail`. The user must confirm with the code via `confirmEmailChange`. */
372
578
  sendEmailChange: SendEmailChangeResult;
373
579
  /** Sends a verification code to the user's current email address to prove ownership before changing email. */
@@ -378,29 +584,69 @@ type Mutation = {
378
584
  updatePassword: UpdatePasswordResult;
379
585
  /** Updates the authenticated user's profile (first name, last name, locale). */
380
586
  updateProfile: UpdateProfileResult;
587
+ /** Update a role belonging to the organization the token was issued for. */
588
+ updateRole: Role;
589
+ /** Update an SSO connection belonging to the token’s organization. */
590
+ updateSsoConnection: Connection;
381
591
  /** Verifies the code sent to the current email address. Returns an elevated access token required for `sendEmailChange` and `confirmEmailChange`. */
382
592
  verifyCurrentEmail: VerifyCurrentEmailResult;
383
593
  /** Confirm TOTP enrollment by verifying a code from the authenticator app. Marks the factor as verified. */
384
594
  verifyTotp: VerifyTotpResult;
385
595
  };
596
+ type MutationAssignPermissionToRoleArgs = {
597
+ input: AssignPermissionToRoleInput;
598
+ };
386
599
  type MutationConfirmEmailChangeArgs = {
387
600
  input: ConfirmEmailChangeInput;
388
601
  };
602
+ type MutationCreateAuditLogExportArgs = {
603
+ input: CreateAuditLogExportInput;
604
+ };
605
+ type MutationCreateOrganizationDomainArgs = {
606
+ domain: Scalars["String"]["input"];
607
+ };
389
608
  type MutationCreatePasswordArgs = {
390
609
  input: CreatePasswordInput;
391
610
  };
611
+ type MutationCreateRoleArgs = {
612
+ input: CreateRoleInput;
613
+ };
614
+ type MutationCreateSsoConnectionArgs = {
615
+ input: CreateSsoConnectionInput;
616
+ };
617
+ type MutationDeleteOrganizationDomainArgs = {
618
+ id: Scalars["ID"]["input"];
619
+ };
620
+ type MutationDeleteRoleArgs = {
621
+ input: DeleteRoleInput;
622
+ };
623
+ type MutationDeleteSsoConnectionArgs = {
624
+ id: Scalars["ID"]["input"];
625
+ };
626
+ type MutationEnrollTotpArgs = {
627
+ input: EnrollTotpInput;
628
+ };
392
629
  type MutationInviteUserArgs = {
393
630
  input: InviteUserInput;
394
631
  };
395
632
  type MutationRemoveMemberArgs = {
396
633
  input: RemoveMemberInput;
397
634
  };
635
+ type MutationRemoveMfaFactorArgs = {
636
+ input: RemoveMfaFactorInput;
637
+ };
398
638
  type MutationResendInvitationArgs = {
399
639
  input: ResendInvitationInput;
400
640
  };
641
+ type MutationReverifyOrganizationDomainArgs = {
642
+ id: Scalars["ID"]["input"];
643
+ };
401
644
  type MutationRevokeInvitationArgs = {
402
645
  input: RevokeInvitationInput;
403
646
  };
647
+ type MutationRevokeSessionArgs = {
648
+ input: RevokeSessionInput;
649
+ };
404
650
  type MutationSendEmailChangeArgs = {
405
651
  input: SendEmailChangeInput;
406
652
  };
@@ -413,12 +659,22 @@ type MutationUpdatePasswordArgs = {
413
659
  type MutationUpdateProfileArgs = {
414
660
  input: UpdateProfileInput;
415
661
  };
662
+ type MutationUpdateRoleArgs = {
663
+ input: UpdateRoleInput;
664
+ };
665
+ type MutationUpdateSsoConnectionArgs = {
666
+ input: UpdateSsoConnectionInput;
667
+ };
416
668
  type MutationVerifyCurrentEmailArgs = {
417
669
  input: VerifyCurrentEmailInput;
418
670
  };
419
671
  type MutationVerifyTotpArgs = {
420
672
  input: VerifyTotpInput;
421
673
  };
674
+ type NoAuditEventsFound = {
675
+ __typename?: "NoAuditEventsFound";
676
+ message: Scalars["String"]["output"];
677
+ };
422
678
  /** The user has no TOTP factors to remove. */
423
679
  type NoMfaFactorsEnrolled = {
424
680
  __typename?: "NoMfaFactorsEnrolled";
@@ -429,6 +685,44 @@ type NoPendingEmailChange = {
429
685
  __typename?: "NoPendingEmailChange";
430
686
  message: Scalars["String"]["output"];
431
687
  };
688
+ /** OAuth provider for a connected account. */
689
+ type OAuthProvider = "AppleOAuth" | "BitbucketOAuth" | "DiscordOAuth" | "GitLabOAuth" | "GithubOAuth" | "GoogleOAuth" | "GrokOAuth" | "IntuitOAuth" | "LinkedInOAuth" | "MicrosoftOAuth" | "SalesforceOAuth" | "SlackOAuth" | "VercelMarketplaceOAuth" | "VercelOAuth" | "XOAuth" | "XeroOAuth";
690
+ /** An organization in the current environment. */
691
+ type Organization = {
692
+ __typename?: "Organization";
693
+ /** Whether the organization allows profiles outside the organization domains. */
694
+ allowProfilesOutsideOrganization: Scalars["Boolean"]["output"];
695
+ createdAt: Scalars["DateTime"]["output"];
696
+ id: Scalars["ID"]["output"];
697
+ name: Scalars["String"]["output"];
698
+ updatedAt: Scalars["DateTime"]["output"];
699
+ };
700
+ /** This organization is not allowed to send invites. */
701
+ type OrganizationBlockedFromSendingInvites = {
702
+ __typename?: "OrganizationBlockedFromSendingInvites";
703
+ /** Placeholder field to allow an empty @ObjectType. */
704
+ _placeholder?: Maybe<Scalars["Boolean"]["output"]>;
705
+ };
706
+ /** A domain belonging to the organization the token was issued for. */
707
+ type OrganizationDomain = {
708
+ __typename?: "OrganizationDomain";
709
+ createdAt: Scalars["DateTime"]["output"];
710
+ /** The fully qualified domain name. */
711
+ domain: Scalars["String"]["output"];
712
+ id: Scalars["ID"]["output"];
713
+ /** The DNS name server provider detected for the domain. */
714
+ nameServer: DomainVerificationNameServer;
715
+ organizationId: Scalars["ID"]["output"];
716
+ state: OrganizationDomainState;
717
+ /** The subdomain portion of the domain, if any. */
718
+ subdomain?: Maybe<Scalars["String"]["output"]>;
719
+ /** The DNS record prefix the customer must add to verify the domain. */
720
+ verificationPrefix?: Maybe<Scalars["String"]["output"]>;
721
+ /** The DNS record value the customer must add to verify the domain. */
722
+ verificationToken?: Maybe<Scalars["String"]["output"]>;
723
+ };
724
+ /** The verification state of an organization domain. */
725
+ type OrganizationDomainState = "Failed" | "LegacyVerified" | "Pending" | "Verified";
432
726
  /** An invitation to join the organization the token was issued for. */
433
727
  type OrganizationInvitation = {
434
728
  __typename?: "OrganizationInvitation";
@@ -475,49 +769,230 @@ type OrganizationMemberRole = {
475
769
  type OrganizationMemberStatus = "Active" | "InviteExpired" | "InviteRevoked" | "Invited" | "NoInvite";
476
770
  /** Enum represents the pagination order. */
477
771
  type PaginationOrder = "Asc" | "Desc" | "Normal";
772
+ /** A registered passkey (WebAuthn credential) for the authenticated user. */
773
+ type Passkey = {
774
+ __typename?: "Passkey";
775
+ createdAt: Scalars["DateTime"]["output"];
776
+ id: Scalars["ID"]["output"];
777
+ /** When this passkey was last used to authenticate. */
778
+ lastVerifiedAt?: Maybe<Scalars["DateTime"]["output"]>;
779
+ updatedAt: Scalars["DateTime"]["output"];
780
+ };
781
+ /** The types of characters in a password. */
782
+ type PasswordCharacterType = "Lowercase" | "Number" | "Symbol" | "Uppercase";
478
783
  /** The password was created successfully. */
479
784
  type PasswordCreated = {
480
785
  __typename?: "PasswordCreated";
481
786
  success: Scalars["Boolean"]["output"];
482
787
  };
788
+ /** The password requirements configured for the environment. Use these to describe the requirements before a password is submitted; `createPassword` and `updatePassword` enforce them. */
789
+ type PasswordPolicy = {
790
+ __typename?: "PasswordPolicy";
791
+ /** The minimum number of characters. */
792
+ minimumLength: Scalars["Int"]["output"];
793
+ /** The minimum zxcvbn strength score (0–4) a password must reach. */
794
+ minimumStrength: Scalars["Int"]["output"];
795
+ /** Whether passwords found in known data breaches are rejected. */
796
+ rejectsBreachedPasswords: Scalars["Boolean"]["output"];
797
+ /** Whether a lowercase letter is required. */
798
+ requiresLowercase: Scalars["Boolean"]["output"];
799
+ /** Whether a number is required. */
800
+ requiresNumber: Scalars["Boolean"]["output"];
801
+ /** Whether a special character is required. */
802
+ requiresSymbol: Scalars["Boolean"]["output"];
803
+ /** Whether an uppercase letter is required. */
804
+ requiresUppercase: Scalars["Boolean"]["output"];
805
+ };
483
806
  /** The provided password does not meet the environment password policy requirements. */
484
807
  type PasswordPolicyViolation = {
485
808
  __typename?: "PasswordPolicyViolation";
486
- /** A machine-readable error code. */
809
+ /** A machine-readable error code. Matches the `code` of the first entry in `violations`. */
487
810
  code: Scalars["String"]["output"];
488
- /** A human-readable description of the policy violation. */
811
+ /** A human-readable description of the policy violation. Describes the first entry in `violations`. */
489
812
  message: Scalars["String"]["output"];
813
+ /** Every way in which the password failed the policy, so all of them can be surfaced at once. */
814
+ violations: Array<PasswordViolation>;
490
815
  };
491
816
  /** The password was updated successfully. */
492
817
  type PasswordUpdated = {
493
818
  __typename?: "PasswordUpdated";
494
819
  success: Scalars["Boolean"]["output"];
495
820
  };
821
+ /** A single way in which a password failed the environment password policy. Fields other than `code` and `message` are only populated for the codes that carry them. */
822
+ type PasswordViolation = {
823
+ __typename?: "PasswordViolation";
824
+ /** For a missing `Symbol` character type, the symbols that satisfy the requirement. */
825
+ allowedSymbols?: Maybe<Scalars["String"]["output"]>;
826
+ /** For `password_pwned`, how many times the password appears in known data breaches. */
827
+ breachOccurrences?: Maybe<Scalars["Int"]["output"]>;
828
+ /** For `password_missing_character_type`, the class of character that is missing. */
829
+ characterType?: Maybe<PasswordCharacterType>;
830
+ /** A machine-readable error code, e.g. `password_too_short`, `password_missing_character_type`, `password_pwned`, `password_reused`, `password_too_weak`, `password_contains_email`, `password_too_long`. */
831
+ code: Scalars["String"]["output"];
832
+ /** For `password_too_long`, the allowed maximum length. */
833
+ maximumLength?: Maybe<Scalars["Int"]["output"]>;
834
+ /** A human-readable description of this violation. */
835
+ message: Scalars["String"]["output"];
836
+ /** For `password_too_short`, the required minimum length. */
837
+ minimumLength?: Maybe<Scalars["Int"]["output"]>;
838
+ /** For `password_too_weak`, suggestions for choosing a stronger password. Empty for other codes. */
839
+ strengthSuggestions: Array<Scalars["String"]["output"]>;
840
+ /** For `password_too_weak`, a summary of why it is weak. */
841
+ strengthWarning?: Maybe<Scalars["String"]["output"]>;
842
+ };
843
+ /** A permission that can be granted to a role within the environment. */
844
+ type Permission = {
845
+ __typename?: "Permission";
846
+ createdAt: Scalars["DateTime"]["output"];
847
+ description?: Maybe<Scalars["String"]["output"]>;
848
+ id: Scalars["ID"]["output"];
849
+ name: Scalars["String"]["output"];
850
+ slug: Scalars["String"]["output"];
851
+ /** Whether this is a WorkOS-managed system permission that cannot be modified. */
852
+ system: Scalars["Boolean"]["output"];
853
+ updatedAt: Scalars["DateTime"]["output"];
854
+ };
496
855
  /** The profile was updated successfully. */
497
856
  type ProfileUpdated = {
498
857
  __typename?: "ProfileUpdated";
499
- user: ClientApi_User;
858
+ user: User;
500
859
  };
501
860
  type Query = {
502
861
  __typename?: "Query";
862
+ auditEvent: AuditEvent;
863
+ auditEvents: AuditEventList;
864
+ /** The authentication methods the environment allows and the password policy it enforces. Requires a session token. */
865
+ authenticationSettings: AuthenticationSettings;
503
866
  /** Placeholder query for the Client GraphQL API scaffold. Returns a static value and is replaced by real resolvers. */
504
867
  clientApiStatus: Scalars["String"]["output"];
868
+ /** Return a data provider by ID within the token's environment. */
869
+ dataProvider: DataProvider;
870
+ /** Return one of the authenticated user's data provider connections by ID. */
871
+ dataProviderConnection: DataProviderConnection;
872
+ /** List the authenticated user's data provider connections, including their status. */
873
+ dataProviderConnections: DataProviderConnectionList;
874
+ /** List the data providers configured in the token's environment. */
875
+ dataProviders: DataProviderList;
876
+ /** Return a Directory Sync connection by ID within the token's organization. */
877
+ directoryConnection: Directory;
878
+ /** List the Directory Sync connections for the token's organization. */
879
+ directoryConnections: DirectoryList;
880
+ /** List the groups of a Directory Sync connection. */
881
+ directoryGroups: DirectoryGroupList;
882
+ /** List the users of a Directory Sync connection. */
883
+ directoryUsers: DirectoryUserList;
884
+ /** The permissions a user effectively has in the organization the token was issued for, including permissions inherited through the user's roles. Callers may read their own effective permissions; reading another member's requires the elevated user:read grant. */
885
+ effectivePermissions: Array<Permission>;
886
+ /** The feature flags that evaluate to enabled for a user in the environment the token was issued for, including flags targeted at the token's organization. Flags absent from the list evaluate to false. Callers may evaluate their own flags; evaluating another member of the token's organization requires the elevated user:read grant. */
887
+ evaluatedFlags: FlagList;
888
+ /** Fetch a feature flag by ID from the project that owns the token's environment. */
889
+ flag: Flag;
890
+ /** Fetch a feature flag by slug from the project that owns the token's environment. */
891
+ flagBySlug: Flag;
892
+ /** List the feature flags of the project that owns the token's environment, with their state in that environment. */
893
+ flags: FlagList;
505
894
  /** Returns the currently authenticated user (the subject of the token). */
506
- me: ClientApi_User;
895
+ me: User;
507
896
  /** Returns an organization by ID within the token's environment. */
508
- organization: ClientApi_Organization;
897
+ organization: Organization;
898
+ /** List the domains belonging to the organization the token was issued for. */
899
+ organizationDomains: Array<OrganizationDomain>;
509
900
  /** List members of the organization the token was issued for, with their roles. */
510
901
  organizationMemberships: OrganizationMemberList;
511
902
  /** List organizations the authenticated user belongs to. */
512
- organizations: Array<ClientApi_UserOrganization>;
903
+ organizations: Array<UserOrganization>;
513
904
  /** List registered passkeys for the authenticated user. Requires a session token. */
514
- passkeys: Array<ClientApi_Passkey>;
905
+ passkeys: Array<Passkey>;
906
+ /** List the permissions defined in the environment the token was issued for. */
907
+ permissions: Array<Permission>;
908
+ /** Fetch a single role available to the organization the token was issued for. */
909
+ role?: Maybe<Role>;
515
910
  /** List roles available to the organization the token was issued for, with role assignment configuration. */
516
- roles: ClientApi_RolesResult;
911
+ roles: RolesResult;
517
912
  /** List active sessions for the authenticated user. Requires a session token. */
518
- sessions: Array<ClientApi_Session>;
913
+ sessions: Array<Session>;
914
+ /** Returns an SSO connection by ID, including its IdP setup status, provided it belongs to the token's organization. */
915
+ ssoConnection: Connection;
916
+ /** List the SSO connections belonging to the organization the token was issued for. */
917
+ ssoConnections: Array<Connection>;
519
918
  /** Returns a user by ID, provided they are a member of the token's organization. */
520
- user: ClientApi_User;
919
+ user: User;
920
+ };
921
+ type QueryAuditEventArgs = {
922
+ id: Scalars["ID"]["input"];
923
+ };
924
+ type QueryAuditEventsArgs = {
925
+ after?: InputMaybe<Scalars["String"]["input"]>;
926
+ before?: InputMaybe<Scalars["String"]["input"]>;
927
+ filter: AuditEventFilterInput;
928
+ limit?: InputMaybe<Scalars["Int"]["input"]>;
929
+ order?: InputMaybe<PaginationOrder>;
930
+ };
931
+ type QueryDataProviderArgs = {
932
+ id: Scalars["ID"]["input"];
933
+ };
934
+ type QueryDataProviderConnectionArgs = {
935
+ id: Scalars["ID"]["input"];
936
+ };
937
+ type QueryDataProviderConnectionsArgs = {
938
+ after?: InputMaybe<Scalars["String"]["input"]>;
939
+ before?: InputMaybe<Scalars["String"]["input"]>;
940
+ limit?: InputMaybe<Scalars["Int"]["input"]>;
941
+ order?: InputMaybe<PaginationOrder>;
942
+ };
943
+ type QueryDataProvidersArgs = {
944
+ after?: InputMaybe<Scalars["String"]["input"]>;
945
+ before?: InputMaybe<Scalars["String"]["input"]>;
946
+ limit?: InputMaybe<Scalars["Int"]["input"]>;
947
+ order?: InputMaybe<PaginationOrder>;
948
+ };
949
+ type QueryDirectoryConnectionArgs = {
950
+ id: Scalars["ID"]["input"];
951
+ };
952
+ type QueryDirectoryConnectionsArgs = {
953
+ after?: InputMaybe<Scalars["String"]["input"]>;
954
+ before?: InputMaybe<Scalars["String"]["input"]>;
955
+ limit?: InputMaybe<Scalars["Int"]["input"]>;
956
+ order?: InputMaybe<PaginationOrder>;
957
+ search?: InputMaybe<Scalars["String"]["input"]>;
958
+ };
959
+ type QueryDirectoryGroupsArgs = {
960
+ after?: InputMaybe<Scalars["String"]["input"]>;
961
+ before?: InputMaybe<Scalars["String"]["input"]>;
962
+ directoryId: Scalars["ID"]["input"];
963
+ limit?: InputMaybe<Scalars["Int"]["input"]>;
964
+ order?: InputMaybe<PaginationOrder>;
965
+ };
966
+ type QueryDirectoryUsersArgs = {
967
+ after?: InputMaybe<Scalars["String"]["input"]>;
968
+ before?: InputMaybe<Scalars["String"]["input"]>;
969
+ directoryId: Scalars["ID"]["input"];
970
+ limit?: InputMaybe<Scalars["Int"]["input"]>;
971
+ order?: InputMaybe<PaginationOrder>;
972
+ };
973
+ type QueryEffectivePermissionsArgs = {
974
+ userId: Scalars["ID"]["input"];
975
+ };
976
+ type QueryEvaluatedFlagsArgs = {
977
+ after?: InputMaybe<Scalars["String"]["input"]>;
978
+ before?: InputMaybe<Scalars["String"]["input"]>;
979
+ limit?: InputMaybe<Scalars["Int"]["input"]>;
980
+ order?: InputMaybe<PaginationOrder>;
981
+ userId: Scalars["ID"]["input"];
982
+ };
983
+ type QueryFlagArgs = {
984
+ id: Scalars["ID"]["input"];
985
+ };
986
+ type QueryFlagBySlugArgs = {
987
+ slug: Scalars["String"]["input"];
988
+ };
989
+ type QueryFlagsArgs = {
990
+ after?: InputMaybe<Scalars["String"]["input"]>;
991
+ before?: InputMaybe<Scalars["String"]["input"]>;
992
+ enabled?: InputMaybe<Scalars["Boolean"]["input"]>;
993
+ limit?: InputMaybe<Scalars["Int"]["input"]>;
994
+ order?: InputMaybe<PaginationOrder>;
995
+ search?: InputMaybe<Scalars["String"]["input"]>;
521
996
  };
522
997
  type QueryOrganizationArgs = {
523
998
  id: Scalars["ID"]["input"];
@@ -530,6 +1005,12 @@ type QueryOrganizationMembershipsArgs = {
530
1005
  roleSlug?: InputMaybe<Scalars["String"]["input"]>;
531
1006
  search?: InputMaybe<Scalars["String"]["input"]>;
532
1007
  };
1008
+ type QueryRoleArgs = {
1009
+ id: Scalars["ID"]["input"];
1010
+ };
1011
+ type QuerySsoConnectionArgs = {
1012
+ id: Scalars["ID"]["input"];
1013
+ };
533
1014
  type QueryUserArgs = {
534
1015
  id: Scalars["ID"]["input"];
535
1016
  };
@@ -538,7 +1019,12 @@ type RemoveMemberInput = {
538
1019
  userId: Scalars["ID"]["input"];
539
1020
  };
540
1021
  type RemoveMemberResult = MemberIsManagedByDirectory | MemberNotFound | MemberRemoved;
541
- type RemoveMfaFactorResult = MfaFactorRemoved | NoMfaFactorsEnrolled;
1022
+ /** Input for removing all TOTP factors. */
1023
+ type RemoveMfaFactorInput = {
1024
+ /** An elevated access token obtained by verifying the current email address. Required to prove recent re-authentication. */
1025
+ elevatedAccessToken: Scalars["String"]["input"];
1026
+ };
1027
+ type RemoveMfaFactorResult = ElevatedAccessTokenExpired | ElevatedAccessTokenInvalid | MfaFactorRemoved | NoMfaFactorsEnrolled;
542
1028
  type ResendInvitationInput = {
543
1029
  /** The ID of the user whose invitation should be resent. */
544
1030
  userId: Scalars["ID"]["input"];
@@ -548,18 +1034,50 @@ type ResendInvitationNotFound = {
548
1034
  __typename?: "ResendInvitationNotFound";
549
1035
  userId: Scalars["ID"]["output"];
550
1036
  };
551
- type ResendInvitationResult = InvitationResent | InviteeAlreadyAccepted | ResendInvitationNotFound;
1037
+ type ResendInvitationResult = InvitationResent | InviteeAlreadyAccepted | InviteeEmailNotDeliverable | ResendInvitationNotFound;
1038
+ type RevokeAllSessionsResult = AllSessionsRevoked;
552
1039
  type RevokeInvitationInput = {
553
1040
  /** The ID of the user whose pending invitation should be revoked. */
554
1041
  userId: Scalars["ID"]["input"];
555
1042
  };
556
1043
  type RevokeInvitationResult = InvitationNotFound | InvitationNotPending | InvitationRevoked;
1044
+ /** Input for revoking a specific session. */
1045
+ type RevokeSessionInput = {
1046
+ /** The ID of the session to revoke. */
1047
+ sessionId: Scalars["ID"]["input"];
1048
+ };
1049
+ type RevokeSessionResult = SessionNotFound | SessionRevoked;
1050
+ /** A role available within the organization. */
1051
+ type Role = {
1052
+ __typename?: "Role";
1053
+ createdAt: Scalars["DateTime"]["output"];
1054
+ description?: Maybe<Scalars["String"]["output"]>;
1055
+ id: Scalars["ID"]["output"];
1056
+ /** Whether this is the default role assigned to new members. */
1057
+ isDefault: Scalars["Boolean"]["output"];
1058
+ name: Scalars["String"]["output"];
1059
+ slug: Scalars["String"]["output"];
1060
+ updatedAt: Scalars["DateTime"]["output"];
1061
+ };
1062
+ /** Confirms that a role has been scheduled for deletion. */
1063
+ type RoleDeleted = {
1064
+ __typename?: "RoleDeleted";
1065
+ /** The ID of the deleted role. */
1066
+ id: Scalars["ID"]["output"];
1067
+ };
557
1068
  /** No active roles with the given slugs exist in the environment. */
558
1069
  type RoleNotFound = {
559
1070
  __typename?: "RoleNotFound";
560
1071
  /** The role slugs that did not resolve to active roles. */
561
1072
  roleSlugs: Array<Scalars["String"]["output"]>;
562
1073
  };
1074
+ /** Roles available in the organization along with role assignment configuration. */
1075
+ type RolesResult = {
1076
+ __typename?: "RolesResult";
1077
+ /** Whether members can be assigned multiple roles simultaneously. */
1078
+ multipleRolesEnabled: Scalars["Boolean"]["output"];
1079
+ roles: Array<Role>;
1080
+ };
563
1081
  /** Input for requesting an email change verification code. */
564
1082
  type SendEmailChangeInput = {
565
1083
  /** The elevated access token from a successful `verifyCurrentEmail` call. */
@@ -569,6 +1087,45 @@ type SendEmailChangeInput = {
569
1087
  };
570
1088
  type SendEmailChangeResult = DailyEmailQuotaExceeded | EmailChangeNotAvailable | EmailChangeSent | EmailManagedByProvider | EmailNotAvailable | IdentityVerificationExpired | IdentityVerificationInvalid | InvalidEmail;
571
1089
  type SendVerificationCodeResult = DailyEmailQuotaExceeded | VerificationCodeSent;
1090
+ /** An active user session. */
1091
+ type Session = {
1092
+ __typename?: "Session";
1093
+ createdAt: Scalars["DateTime"]["output"];
1094
+ currentLocation?: Maybe<SessionLocation>;
1095
+ id: Scalars["ID"]["output"];
1096
+ ipAddress?: Maybe<Scalars["String"]["output"]>;
1097
+ /** Whether this session is the one making the request. */
1098
+ isCurrent: Scalars["Boolean"]["output"];
1099
+ lastActivityAt?: Maybe<Scalars["DateTime"]["output"]>;
1100
+ organizationId?: Maybe<Scalars["String"]["output"]>;
1101
+ state: SessionState;
1102
+ updatedAt: Scalars["DateTime"]["output"];
1103
+ userAgent?: Maybe<Scalars["String"]["output"]>;
1104
+ };
1105
+ /** Approximate geographic location derived from the session IP. */
1106
+ type SessionLocation = {
1107
+ __typename?: "SessionLocation";
1108
+ cityName: Scalars["String"]["output"];
1109
+ countryISOCode: Scalars["String"]["output"];
1110
+ };
1111
+ /** No session was found with the given ID. */
1112
+ type SessionNotFound = {
1113
+ __typename?: "SessionNotFound";
1114
+ /** The session ID that did not resolve to a session. */
1115
+ sessionId: Scalars["ID"]["output"];
1116
+ };
1117
+ /** The session was revoked successfully. */
1118
+ type SessionRevoked = {
1119
+ __typename?: "SessionRevoked";
1120
+ session: Session;
1121
+ };
1122
+ /** The lifecycle state of a session. */
1123
+ type SessionState = {
1124
+ __typename?: "SessionState";
1125
+ expiresAt?: Maybe<Scalars["DateTime"]["output"]>;
1126
+ /** Session state: Issued, Revoked, etc. */
1127
+ tag: Scalars["String"]["output"];
1128
+ };
572
1129
  /** The user already has a verified TOTP factor enrolled. */
573
1130
  type TotpAlreadyEnrolled = {
574
1131
  __typename?: "TotpAlreadyEnrolled";
@@ -623,6 +1180,42 @@ type UpdateProfileInput = {
623
1180
  locale?: InputMaybe<Scalars["String"]["input"]>;
624
1181
  };
625
1182
  type UpdateProfileResult = InvalidLocale | ProfileUpdated;
1183
+ type UpdateRoleInput = {
1184
+ /** Human-readable description of the role. This is a full replace of the role, so an omitted or null description clears it — resupply the current value to preserve it. */
1185
+ description?: InputMaybe<Scalars["String"]["input"]>;
1186
+ /** The ID of the role to update. */
1187
+ id: Scalars["ID"]["input"];
1188
+ /** Human-readable name for the role. */
1189
+ name: Scalars["String"]["input"];
1190
+ /** Slugs of the permissions granted to the role. Replaces the existing set when provided. */
1191
+ permissions?: InputMaybe<Array<Scalars["String"]["input"]>>;
1192
+ };
1193
+ type UpdateSsoConnectionInput = {
1194
+ id: Scalars["ID"]["input"];
1195
+ /** A new human-readable name for the connection. */
1196
+ name?: InputMaybe<Scalars["String"]["input"]>;
1197
+ };
1198
+ /** A user in the current environment. */
1199
+ type User = {
1200
+ __typename?: "User";
1201
+ connectedAccounts: Array<ConnectedAccount>;
1202
+ createdAt: Scalars["DateTime"]["output"];
1203
+ email: Scalars["String"]["output"];
1204
+ emailVerified: Scalars["Boolean"]["output"];
1205
+ firstName?: Maybe<Scalars["String"]["output"]>;
1206
+ id: Scalars["ID"]["output"];
1207
+ lastName?: Maybe<Scalars["String"]["output"]>;
1208
+ /** Whether multi-factor authentication (TOTP) is set up for this user. Always `false` when the environment has MFA turned off — use `authenticationSettings.mfaEnabled` to tell the two apart. Only populated on `me`. */
1209
+ mfaEnabled: Scalars["Boolean"]["output"];
1210
+ /** When MFA was last used to authenticate. Only populated on `me`. */
1211
+ mfaLastUsedAt?: Maybe<Scalars["DateTime"]["output"]>;
1212
+ /** When a password was last used to authenticate. Only populated on `me`. */
1213
+ passwordLastUsedAt?: Maybe<Scalars["DateTime"]["output"]>;
1214
+ /** Whether this user has a password set. Reflects the user regardless of whether the environment allows password authentication; use `authenticationSettings.passwordAuthEnabled` for that. Only populated on `me`. */
1215
+ passwordSet: Scalars["Boolean"]["output"];
1216
+ profilePictureUrl?: Maybe<Scalars["String"]["output"]>;
1217
+ updatedAt: Scalars["DateTime"]["output"];
1218
+ };
626
1219
  /** The user already has a password set. */
627
1220
  type UserAlreadyHasPassword = {
628
1221
  __typename?: "UserAlreadyHasPassword";
@@ -633,6 +1226,14 @@ type UserInvited = {
633
1226
  __typename?: "UserInvited";
634
1227
  invitation: OrganizationInvitation;
635
1228
  };
1229
+ /** An organization the authenticated user belongs to, with a flag indicating whether it is the token's current organization. */
1230
+ type UserOrganization = {
1231
+ __typename?: "UserOrganization";
1232
+ id: Scalars["ID"]["output"];
1233
+ /** Whether this is the organization the token is currently scoped to. */
1234
+ isCurrent: Scalars["Boolean"]["output"];
1235
+ name: Scalars["String"]["output"];
1236
+ };
636
1237
  /** The verification code has expired. */
637
1238
  type VerificationCodeExpired = {
638
1239
  __typename?: "VerificationCodeExpired";
@@ -675,8 +1276,10 @@ type VerifyTotpInput = {
675
1276
  authenticationChallengeId: Scalars["String"]["input"];
676
1277
  /** The TOTP code from the authenticator app. */
677
1278
  code: Scalars["String"]["input"];
1279
+ /** An elevated access token obtained by verifying the current email address. Required to prove recent re-authentication. */
1280
+ elevatedAccessToken: Scalars["String"]["input"];
678
1281
  };
679
- type VerifyTotpResult = TotpVerificationFailed | TotpVerified;
1282
+ type VerifyTotpResult = ElevatedAccessTokenExpired | ElevatedAccessTokenInvalid | TotpVerificationFailed | TotpVerified;
680
1283
  type ClientApiStatusQueryVariables = Exact<{
681
1284
  [key: string]: never;
682
1285
  }>;
@@ -691,4 +1294,4 @@ declare function getSdk(client: GraphQLClient, withWrapper?: SdkFunctionWrapper)
691
1294
  };
692
1295
  type Sdk = ReturnType<typeof getSdk>;
693
1296
 
694
- export { ClientApiStatusDocument, type ClientApiStatusQuery, type ClientApiStatusQueryVariables, type ClientApi_ConnectedAccount, type ClientApi_OAuthProvider, type ClientApi_Organization, type ClientApi_Passkey, type ClientApi_Role, type ClientApi_RolesResult, type ClientApi_Session, type ClientApi_SessionLocation, type ClientApi_SessionState, type ClientApi_User, type ClientApi_UserOrganization, type ConfirmEmailChangeInput, type ConfirmEmailChangeResult, type CreatePasswordInput, type CreatePasswordResult, type CurrentEmailVerified, type DailyEmailQuotaExceeded, type EmailChangeCodeExpired, type EmailChangeCodeIncorrect, type EmailChangeCodePreviouslyUsed, type EmailChangeConfirmed, type EmailChangeNotAvailable, type EmailChangeSent, type EmailChangeTooManyAttempts, type EmailManagedByProvider, type EmailNotAvailable, type EnrollTotpResult, type Exact, type IdentityVerificationExpired, type IdentityVerificationInvalid, type IncorrectPassword, type Incremental, type InputMaybe, type InvalidEmail, type InvalidInvitationExpiry, type InvalidInviteeEmail, type InvalidInviteeRole, type InvalidLocale, type InvitationNotFound, type InvitationNotPending, type InvitationResent, type InvitationRevoked, type InviteUserInput, type InviteUserResult, type InviteeAlreadyAccepted, type InviteeAlreadyInvited, type InviteeAlreadyMember, type ListMetadata, type MakeEmpty, type MakeMaybe, type MakeOptional, type Maybe, type MemberIsManagedByDirectory, type MemberNotFound, type MemberRemoved, type MemberRoleUpdated, type MfaFactorRemoved, type Mutation, type MutationConfirmEmailChangeArgs, type MutationCreatePasswordArgs, type MutationInviteUserArgs, type MutationRemoveMemberArgs, type MutationResendInvitationArgs, type MutationRevokeInvitationArgs, type MutationSendEmailChangeArgs, type MutationUpdateMemberRoleArgs, type MutationUpdatePasswordArgs, type MutationUpdateProfileArgs, type MutationVerifyCurrentEmailArgs, type MutationVerifyTotpArgs, type NoMfaFactorsEnrolled, type NoPendingEmailChange, type OrganizationInvitation, type OrganizationInvitationStatus, type OrganizationMember, type OrganizationMemberList, type OrganizationMemberRole, type OrganizationMemberStatus, type PaginationOrder, type PasswordCreated, type PasswordPolicyViolation, type PasswordUpdated, type ProfileUpdated, type Query, type QueryOrganizationArgs, type QueryOrganizationMembershipsArgs, type QueryUserArgs, type RemoveMemberInput, type RemoveMemberResult, type RemoveMfaFactorResult, type ResendInvitationInput, type ResendInvitationNotFound, type ResendInvitationResult, type RevokeInvitationInput, type RevokeInvitationResult, type RoleNotFound, type Scalars, type Sdk, type SdkFunctionWrapper, type SendEmailChangeInput, type SendEmailChangeResult, type SendVerificationCodeResult, type TotpAlreadyEnrolled, type TotpFactor, type TotpVerificationFailed, type TotpVerified, type UpdateMemberRoleInput, type UpdateMemberRoleResult, type UpdatePasswordInput, type UpdatePasswordResult, type UpdateProfileInput, type UpdateProfileResult, type UserAlreadyHasPassword, type UserInvited, type VerificationCodeExpired, type VerificationCodeIncorrect, type VerificationCodePreviouslyUsed, type VerificationCodeSent, type VerificationTooManyAttempts, type VerifyCurrentEmailInput, type VerifyCurrentEmailResult, type VerifyTotpInput, type VerifyTotpResult, getSdk };
1297
+ export { type AllSessionsRevoked, type AssignPermissionToRoleInput, type AuditEvent, type AuditEventActor, type AuditEventFilterInput, type AuditEventList, type AuditLogExport, type AuditLogExportState, type AuthenticationSettings, ClientApiStatusDocument, type ClientApiStatusQuery, type ClientApiStatusQueryVariables, type ConfirmEmailChangeInput, type ConfirmEmailChangeResult, type ConnectedAccount, type Connection, type ConnectionState, type ConnectionType, type CreateAuditLogExportInput, type CreateAuditLogExportResult, type CreatePasswordInput, type CreatePasswordResult, type CreateRoleInput, type CreateSsoConnectionInput, type CurrentEmailVerified, type DailyEmailQuotaExceeded, type DataProvider, type DataProviderConnection, type DataProviderConnectionList, type DataProviderList, type DeleteRoleInput, type Directory, type DirectoryGroup, type DirectoryGroupList, type DirectoryList, type DirectoryUser, type DirectoryUserList, type DomainVerificationNameServer, type ElevatedAccessTokenExpired, type ElevatedAccessTokenInvalid, type EmailChangeCodeExpired, type EmailChangeCodeIncorrect, type EmailChangeCodePreviouslyUsed, type EmailChangeConfirmed, type EmailChangeNotAvailable, type EmailChangeSent, type EmailChangeTooManyAttempts, type EmailManagedByProvider, type EmailNotAvailable, type EnrollTotpInput, type EnrollTotpResult, type Exact, type Flag, type FlagList, type IdentityVerificationExpired, type IdentityVerificationInvalid, type IncorrectPassword, type Incremental, type InputMaybe, type InvalidAuditLogExportDateRange, type InvalidEmail, type InvalidInvitationExpiry, type InvalidInviteeEmail, type InvalidInviteeRole, type InvalidLocale, type InvitationNotFound, type InvitationNotPending, type InvitationResent, type InvitationRevoked, type InviteUserInput, type InviteUserResult, type InviteeAlreadyAccepted, type InviteeAlreadyInvited, type InviteeAlreadyMember, type InviteeEmailNotDeliverable, type ListMetadata, type MakeEmpty, type MakeMaybe, type MakeOptional, type Maybe, type MemberIsManagedByDirectory, type MemberNotFound, type MemberRemoved, type MemberRoleUpdated, type MfaFactorRemoved, type Mutation, type MutationAssignPermissionToRoleArgs, type MutationConfirmEmailChangeArgs, type MutationCreateAuditLogExportArgs, type MutationCreateOrganizationDomainArgs, type MutationCreatePasswordArgs, type MutationCreateRoleArgs, type MutationCreateSsoConnectionArgs, type MutationDeleteOrganizationDomainArgs, type MutationDeleteRoleArgs, type MutationDeleteSsoConnectionArgs, type MutationEnrollTotpArgs, type MutationInviteUserArgs, type MutationRemoveMemberArgs, type MutationRemoveMfaFactorArgs, type MutationResendInvitationArgs, type MutationReverifyOrganizationDomainArgs, type MutationRevokeInvitationArgs, type MutationRevokeSessionArgs, type MutationSendEmailChangeArgs, type MutationUpdateMemberRoleArgs, type MutationUpdatePasswordArgs, type MutationUpdateProfileArgs, type MutationUpdateRoleArgs, type MutationUpdateSsoConnectionArgs, type MutationVerifyCurrentEmailArgs, type MutationVerifyTotpArgs, type NoAuditEventsFound, type NoMfaFactorsEnrolled, type NoPendingEmailChange, type OAuthProvider, type Organization, type OrganizationBlockedFromSendingInvites, type OrganizationDomain, type OrganizationDomainState, type OrganizationInvitation, type OrganizationInvitationStatus, type OrganizationMember, type OrganizationMemberList, type OrganizationMemberRole, type OrganizationMemberStatus, type PaginationOrder, type Passkey, type PasswordCharacterType, type PasswordCreated, type PasswordPolicy, type PasswordPolicyViolation, type PasswordUpdated, type PasswordViolation, type Permission, type ProfileUpdated, type Query, type QueryAuditEventArgs, type QueryAuditEventsArgs, type QueryDataProviderArgs, type QueryDataProviderConnectionArgs, type QueryDataProviderConnectionsArgs, type QueryDataProvidersArgs, type QueryDirectoryConnectionArgs, type QueryDirectoryConnectionsArgs, type QueryDirectoryGroupsArgs, type QueryDirectoryUsersArgs, type QueryEffectivePermissionsArgs, type QueryEvaluatedFlagsArgs, type QueryFlagArgs, type QueryFlagBySlugArgs, type QueryFlagsArgs, type QueryOrganizationArgs, type QueryOrganizationMembershipsArgs, type QueryRoleArgs, type QuerySsoConnectionArgs, type QueryUserArgs, type RemoveMemberInput, type RemoveMemberResult, type RemoveMfaFactorInput, type RemoveMfaFactorResult, type ResendInvitationInput, type ResendInvitationNotFound, type ResendInvitationResult, type RevokeAllSessionsResult, type RevokeInvitationInput, type RevokeInvitationResult, type RevokeSessionInput, type RevokeSessionResult, type Role, type RoleDeleted, type RoleNotFound, type RolesResult, type Scalars, type Sdk, type SdkFunctionWrapper, type SendEmailChangeInput, type SendEmailChangeResult, type SendVerificationCodeResult, type Session, type SessionLocation, type SessionNotFound, type SessionRevoked, type SessionState, type TotpAlreadyEnrolled, type TotpFactor, type TotpVerificationFailed, type TotpVerified, type UpdateMemberRoleInput, type UpdateMemberRoleResult, type UpdatePasswordInput, type UpdatePasswordResult, type UpdateProfileInput, type UpdateProfileResult, type UpdateRoleInput, type UpdateSsoConnectionInput, type User, type UserAlreadyHasPassword, type UserInvited, type UserOrganization, type VerificationCodeExpired, type VerificationCodeIncorrect, type VerificationCodePreviouslyUsed, type VerificationCodeSent, type VerificationTooManyAttempts, type VerifyCurrentEmailInput, type VerifyCurrentEmailResult, type VerifyTotpInput, type VerifyTotpResult, getSdk };