@workos/openapi-spec 0.137.0 → 0.139.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.
package/dist/services.mjs CHANGED
@@ -600,6 +600,11 @@ const serviceEndpoints = {
600
600
  "path": "/organizations/{organizationId}/groups/{groupId}/organization-memberships",
601
601
  "name": "create_group_organization_membership"
602
602
  },
603
+ {
604
+ "method": "PUT",
605
+ "path": "/organizations/{organizationId}/groups/{groupId}/organization-memberships",
606
+ "name": "set_group_organization_memberships"
607
+ },
603
608
  {
604
609
  "method": "DELETE",
605
610
  "path": "/organizations/{organizationId}/groups/{groupId}/organization-memberships/{omId}",
package/dist/types.d.ts CHANGED
@@ -2215,7 +2215,11 @@ export interface paths {
2215
2215
  * @description Get a list of organization memberships in a group.
2216
2216
  */
2217
2217
  get: operations["GroupMembershipsController_listMembers"];
2218
- put?: never;
2218
+ /**
2219
+ * Replace Group members
2220
+ * @description Replace the members of a group with the given organization memberships. Members not in the list are removed. An empty list removes every member.
2221
+ */
2222
+ put: operations["GroupMembershipsController_replaceMembers"];
2219
2223
  /**
2220
2224
  * Add a member to a Group
2221
2225
  * @description Add an organization membership to a group.
@@ -5225,6 +5229,15 @@ export interface components {
5225
5229
  */
5226
5230
  organization_membership_id: string;
5227
5231
  };
5232
+ ReplaceGroupMembershipsDto: {
5233
+ /**
5234
+ * @description The complete list of organization membership IDs the group should contain, up to 500. Any current members not included are removed from the group.
5235
+ * @example [
5236
+ * "om_01HXYZ123456789ABCDEFGHIJ"
5237
+ * ]
5238
+ */
5239
+ organization_membership_ids: string[];
5240
+ };
5228
5241
  CreateGroupDto: {
5229
5242
  /**
5230
5243
  * @description The name of the Group.
@@ -30873,86 +30886,17 @@ export interface operations {
30873
30886
  * @example sk-1234567890abcdef
30874
30887
  */
30875
30888
  secret: string;
30876
- } | {
30877
- /**
30878
- * @description A mutable, non-unique label. Omit to preserve an existing label; null clears it. Labels are never account identifiers.
30879
- * @example Acme production
30880
- */
30881
- account_display_name?: string | null;
30882
30889
  /**
30883
- * @description A developer-attested provider account identifier, never inferred from a label or credential. Omit to preserve an existing identifier; null clears it.
30884
- * @example workspace_123
30885
- */
30886
- account_identifier?: string | null;
30887
- /**
30888
- * @description A [User](/reference/authkit/user) identifier.
30889
- * @example user_01EHZNVPK3SFK441A1RGBFSHRT
30890
- */
30891
- user_id: string;
30892
- /**
30893
- * @description An [Organization](/reference/organization) identifier. Optional parameter to scope the connection to a specific organization. Required when `connection_owner` is `organization`.
30894
- * @example org_01EHZNVPK3SFK441A1RGBFSHRT
30895
- */
30896
- organization_id?: string;
30897
- /**
30898
- * @description Whose connection to create or rotate. `user` (the default) addresses the connection owned by `user_id`. `organization` addresses the connection shared by every member of `organization_id`; `user_id` then identifies the member performing the request and must be an active member of the organization.
30899
- * @example user
30900
- * @enum {string}
30901
- */
30902
- connection_owner?: "user" | "organization";
30903
- /**
30904
- * @description The API key secret to store for this integration.
30905
- * @example sk-1234567890abcdef
30906
- */
30907
- secret: string;
30908
- /**
30909
- * @description Reauthorize exactly the connection named by `connected_account_id`.
30890
+ * @description Send `reauthorize` with `connected_account_id` to reauthorize one exact connection. Omit it to use the compatibility connection; creating another connection lives on the POST route.
30910
30891
  * @example reauthorize
30911
30892
  * @constant
30912
30893
  */
30913
- connection_intent: "reauthorize";
30914
- /**
30915
- * @description The exact connected account to reauthorize. Required with `connection_intent: reauthorize`.
30916
- * @example data_installation_01EHZNVPK3SFK441A1RGBFSHRT
30917
- */
30918
- connected_account_id: string;
30919
- } | {
30920
- /**
30921
- * @description A mutable, non-unique label. Omit to preserve an existing label; null clears it. Labels are never account identifiers.
30922
- * @example Acme production
30923
- */
30924
- account_display_name?: string | null;
30925
- /**
30926
- * @description A developer-attested provider account identifier, never inferred from a label or credential. Omit to preserve an existing identifier; null clears it.
30927
- * @example workspace_123
30928
- */
30929
- account_identifier?: string | null;
30894
+ connection_intent?: "reauthorize";
30930
30895
  /**
30931
- * @description A [User](/reference/authkit/user) identifier.
30932
- * @example user_01EHZNVPK3SFK441A1RGBFSHRT
30933
- */
30934
- user_id: string;
30935
- /**
30936
- * @description An [Organization](/reference/organization) identifier. Optional parameter to scope the connection to a specific organization. Required when `connection_owner` is `organization`.
30937
- * @example org_01EHZNVPK3SFK441A1RGBFSHRT
30938
- */
30939
- organization_id?: string;
30940
- /**
30941
- * @description Whose connection to create or rotate. `user` (the default) addresses the connection owned by `user_id`. `organization` addresses the connection shared by every member of `organization_id`; `user_id` then identifies the member performing the request and must be an active member of the organization.
30942
- * @example user
30943
- * @enum {string}
30944
- */
30945
- connection_owner?: "user" | "organization";
30946
- /**
30947
- * @description The API key secret to store for this integration.
30948
- * @example sk-1234567890abcdef
30949
- */
30950
- secret: string;
30951
- /**
30952
- * @description The exact connected account to reauthorize. The reauthorize intent may be omitted for compatibility.
30896
+ * @description The exact connected account to reauthorize. Required with `connection_intent: reauthorize`; it may also be sent on its own to reauthorize that connection.
30953
30897
  * @example data_installation_01EHZNVPK3SFK441A1RGBFSHRT
30954
30898
  */
30955
- connected_account_id: string;
30899
+ connected_account_id?: string;
30956
30900
  };
30957
30901
  };
30958
30902
  };
@@ -31305,97 +31249,17 @@ export interface operations {
31305
31249
  config?: {
31306
31250
  [key: string]: string;
31307
31251
  };
31308
- } | {
31309
- /**
31310
- * @description A mutable, non-unique label. Omit to preserve an existing label; null clears it. Labels are never account identifiers.
31311
- * @example Acme production
31312
- */
31313
- account_display_name?: string | null;
31314
- /**
31315
- * @description The ID of the user to authorize. When `connection_owner` is `organization`, this is the user authorizing on behalf of the organization; they must be an active member of the organization and do not become the owner of the resulting connected account.
31316
- * @example user_01EHZNVPK3SFK441A1RGBFSHRT
31317
- */
31318
- user_id: string;
31319
- /**
31320
- * @description An organization ID to scope the authorization to a specific organization. Required when `connection_owner` is `organization`.
31321
- * @example org_01EHZNVPK3SFK441A1RGBFSHRT
31322
- */
31323
- organization_id?: string;
31324
- /**
31325
- * @description Who will own the connected account. `user` (the default) connects the user's own account. `organization` connects the organization's shared account and requires `organization_id`.
31326
- * @example user
31327
- * @enum {string}
31328
- */
31329
- connection_owner?: "user" | "organization";
31330
- /**
31331
- * Format: uri
31332
- * @description The URL to redirect the user to after authorization.
31333
- * @example https://example.com/callback
31334
- */
31335
- return_to?: string;
31336
- /**
31337
- * @description Connect-time config values for the provider-declared `installation`-scope fields (e.g. a Zendesk `subdomain`), keyed by the config field. Only fields the provider declares may be supplied, and required fields must be provided unless already pinned on the integration.
31338
- * @example {
31339
- * "subdomain": "acme"
31340
- * }
31341
- */
31342
- config?: {
31343
- [key: string]: string;
31344
- };
31345
31252
  /**
31346
- * @description Create another connection. The first connection for an owner shape fills the compatibility slot; later connections are standard. Omit `connection_intent` to use the compatibility connection, or send `reauthorize` with `connected_account_id` to reauthorize one exact connection.
31253
+ * @description Which connection the request targets. Omit it to use the compatibility connection. Send `add` to create another connection: the first connection for an owner shape fills the compatibility slot, and later connections are standard. Send `reauthorize` with `connected_account_id` to reauthorize one exact connection.
31347
31254
  * @example add
31348
- * @constant
31349
- */
31350
- connection_intent: "add";
31351
- } | {
31352
- /**
31353
- * @description A mutable, non-unique label. Omit to preserve an existing label; null clears it. Labels are never account identifiers.
31354
- * @example Acme production
31355
- */
31356
- account_display_name?: string | null;
31357
- /**
31358
- * @description The ID of the user to authorize. When `connection_owner` is `organization`, this is the user authorizing on behalf of the organization; they must be an active member of the organization and do not become the owner of the resulting connected account.
31359
- * @example user_01EHZNVPK3SFK441A1RGBFSHRT
31360
- */
31361
- user_id: string;
31362
- /**
31363
- * @description An organization ID to scope the authorization to a specific organization. Required when `connection_owner` is `organization`.
31364
- * @example org_01EHZNVPK3SFK441A1RGBFSHRT
31365
- */
31366
- organization_id?: string;
31367
- /**
31368
- * @description Who will own the connected account. `user` (the default) connects the user's own account. `organization` connects the organization's shared account and requires `organization_id`.
31369
- * @example user
31370
31255
  * @enum {string}
31371
31256
  */
31372
- connection_owner?: "user" | "organization";
31373
- /**
31374
- * Format: uri
31375
- * @description The URL to redirect the user to after authorization.
31376
- * @example https://example.com/callback
31377
- */
31378
- return_to?: string;
31379
- /**
31380
- * @description Connect-time config values for the provider-declared `installation`-scope fields (e.g. a Zendesk `subdomain`), keyed by the config field. Only fields the provider declares may be supplied, and required fields must be provided unless already pinned on the integration.
31381
- * @example {
31382
- * "subdomain": "acme"
31383
- * }
31384
- */
31385
- config?: {
31386
- [key: string]: string;
31387
- };
31257
+ connection_intent?: "add" | "reauthorize";
31388
31258
  /**
31389
- * @description Reauthorize exactly the connection named by `connected_account_id`.
31390
- * @example reauthorize
31391
- * @constant
31392
- */
31393
- connection_intent: "reauthorize";
31394
- /**
31395
- * @description The exact connected account to reauthorize. Required with `connection_intent: reauthorize`.
31259
+ * @description The exact connected account to reauthorize. Required with `connection_intent: reauthorize` and not accepted otherwise.
31396
31260
  * @example data_installation_01EHZNVPK3SFK441A1RGBFSHRT
31397
31261
  */
31398
- connected_account_id: string;
31262
+ connected_account_id?: string;
31399
31263
  };
31400
31264
  };
31401
31265
  };
@@ -31565,114 +31429,17 @@ export interface operations {
31565
31429
  config?: {
31566
31430
  [key: string]: string;
31567
31431
  };
31568
- } | {
31569
- /**
31570
- * @description A mutable, non-unique label. Omit to preserve an existing label; null clears it. Labels are never account identifiers.
31571
- * @example Acme production
31572
- */
31573
- account_display_name?: string | null;
31574
- /**
31575
- * @description A developer-attested provider account identifier, never inferred from a label or credential. Omit to preserve an existing identifier; null clears it.
31576
- * @example workspace_123
31577
- */
31578
- account_identifier?: string | null;
31579
- /**
31580
- * @description A [User](/reference/authkit/user) identifier.
31581
- * @example user_01EHZNVPK3SFK441A1RGBFSHRT
31582
- */
31583
- user_id: string;
31584
31432
  /**
31585
- * @description An [Organization](/reference/organization) identifier. Optional parameter to scope the connection to a specific organization. Required when `connection_owner` is `organization`.
31586
- * @example org_01EHZNVPK3SFK441A1RGBFSHRT
31587
- */
31588
- organization_id?: string;
31589
- /**
31590
- * @description Whose connection to create or rotate. `user` (the default) addresses the connection owned by `user_id`. `organization` addresses the connection shared by every member of `organization_id`; `user_id` then identifies the member performing the request and must be an active member of the organization.
31591
- * @example user
31592
- * @enum {string}
31593
- */
31594
- connection_owner?: "user" | "organization";
31595
- /**
31596
- * @description The OAuth client ID to store for this integration.
31597
- * @example 3MVG9...
31598
- */
31599
- client_id: string;
31600
- /**
31601
- * @description The OAuth client secret to store for this integration.
31602
- * @example shhh-secret
31603
- */
31604
- client_secret: string;
31605
- /**
31606
- * @description Provider-specific configuration values collected for this installation, keyed by the provider's config field descriptors.
31607
- * @example {
31608
- * "salesforce_host": "acme.my.salesforce.com"
31609
- * }
31610
- */
31611
- config?: {
31612
- [key: string]: string;
31613
- };
31614
- /**
31615
- * @description Reauthorize exactly the connection named by `connected_account_id`.
31433
+ * @description Send `reauthorize` with `connected_account_id` to reauthorize one exact connection. Omit it to use the compatibility connection; creating another connection lives on the POST route.
31616
31434
  * @example reauthorize
31617
31435
  * @constant
31618
31436
  */
31619
- connection_intent: "reauthorize";
31620
- /**
31621
- * @description The exact connected account to reauthorize. Required with `connection_intent: reauthorize`.
31622
- * @example data_installation_01EHZNVPK3SFK441A1RGBFSHRT
31623
- */
31624
- connected_account_id: string;
31625
- } | {
31626
- /**
31627
- * @description A mutable, non-unique label. Omit to preserve an existing label; null clears it. Labels are never account identifiers.
31628
- * @example Acme production
31629
- */
31630
- account_display_name?: string | null;
31631
- /**
31632
- * @description A developer-attested provider account identifier, never inferred from a label or credential. Omit to preserve an existing identifier; null clears it.
31633
- * @example workspace_123
31634
- */
31635
- account_identifier?: string | null;
31636
- /**
31637
- * @description A [User](/reference/authkit/user) identifier.
31638
- * @example user_01EHZNVPK3SFK441A1RGBFSHRT
31639
- */
31640
- user_id: string;
31641
- /**
31642
- * @description An [Organization](/reference/organization) identifier. Optional parameter to scope the connection to a specific organization. Required when `connection_owner` is `organization`.
31643
- * @example org_01EHZNVPK3SFK441A1RGBFSHRT
31644
- */
31645
- organization_id?: string;
31646
- /**
31647
- * @description Whose connection to create or rotate. `user` (the default) addresses the connection owned by `user_id`. `organization` addresses the connection shared by every member of `organization_id`; `user_id` then identifies the member performing the request and must be an active member of the organization.
31648
- * @example user
31649
- * @enum {string}
31650
- */
31651
- connection_owner?: "user" | "organization";
31652
- /**
31653
- * @description The OAuth client ID to store for this integration.
31654
- * @example 3MVG9...
31655
- */
31656
- client_id: string;
31437
+ connection_intent?: "reauthorize";
31657
31438
  /**
31658
- * @description The OAuth client secret to store for this integration.
31659
- * @example shhh-secret
31660
- */
31661
- client_secret: string;
31662
- /**
31663
- * @description Provider-specific configuration values collected for this installation, keyed by the provider's config field descriptors.
31664
- * @example {
31665
- * "salesforce_host": "acme.my.salesforce.com"
31666
- * }
31667
- */
31668
- config?: {
31669
- [key: string]: string;
31670
- };
31671
- /**
31672
- * @description The exact connected account to reauthorize. The reauthorize intent may be omitted for compatibility.
31439
+ * @description The exact connected account to reauthorize. Required with `connection_intent: reauthorize`; it may also be sent on its own to reauthorize that connection.
31673
31440
  * @example data_installation_01EHZNVPK3SFK441A1RGBFSHRT
31674
31441
  */
31675
- connected_account_id: string;
31442
+ connected_account_id?: string;
31676
31443
  };
31677
31444
  };
31678
31445
  };
@@ -35271,6 +35038,99 @@ export interface operations {
35271
35038
  };
35272
35039
  };
35273
35040
  };
35041
+ GroupMembershipsController_replaceMembers: {
35042
+ parameters: {
35043
+ query?: never;
35044
+ header?: never;
35045
+ path: {
35046
+ /** @description Unique identifier of the Organization. */
35047
+ organizationId: string;
35048
+ /** @description Unique identifier of the Group. */
35049
+ groupId: string;
35050
+ };
35051
+ cookie?: never;
35052
+ };
35053
+ requestBody: {
35054
+ content: {
35055
+ "application/json": components["schemas"]["ReplaceGroupMembershipsDto"];
35056
+ };
35057
+ };
35058
+ responses: {
35059
+ /** @description No Content */
35060
+ 204: {
35061
+ headers: {
35062
+ [name: string]: unknown;
35063
+ };
35064
+ content?: never;
35065
+ };
35066
+ /** @description Bad Request */
35067
+ 400: {
35068
+ headers: {
35069
+ [name: string]: unknown;
35070
+ };
35071
+ content: {
35072
+ "application/json": {
35073
+ /**
35074
+ * @description The error code identifying the type of error.
35075
+ * @example group_membership_limit_exceeded
35076
+ * @constant
35077
+ */
35078
+ code: "group_membership_limit_exceeded";
35079
+ /**
35080
+ * @description A human-readable description of the error.
35081
+ * @example Request could not be processed.
35082
+ */
35083
+ message: string;
35084
+ };
35085
+ };
35086
+ };
35087
+ /** @description Forbidden */
35088
+ 403: {
35089
+ headers: {
35090
+ [name: string]: unknown;
35091
+ };
35092
+ content: {
35093
+ "application/json": {
35094
+ /**
35095
+ * @description A human-readable description of the error.
35096
+ * @example Organization not found: 'org_01EHQMYV6MBK39QC5PZXHY59C3'.
35097
+ */
35098
+ message: string;
35099
+ };
35100
+ };
35101
+ };
35102
+ /** @description Not Found */
35103
+ 404: {
35104
+ headers: {
35105
+ [name: string]: unknown;
35106
+ };
35107
+ content: {
35108
+ "application/json": {
35109
+ /**
35110
+ * @description A human-readable description of the error.
35111
+ * @example Organization not found: 'org_01EHQMYV6MBK39QC5PZXHY59C3'.
35112
+ */
35113
+ message: string;
35114
+ };
35115
+ };
35116
+ };
35117
+ /** @description Unprocessable Entity */
35118
+ 422: {
35119
+ headers: {
35120
+ [name: string]: unknown;
35121
+ };
35122
+ content: {
35123
+ "application/json": {
35124
+ /**
35125
+ * @description A human-readable description of the error.
35126
+ * @example Organization not found: 'org_01EHQMYV6MBK39QC5PZXHY59C3'.
35127
+ */
35128
+ message: string;
35129
+ };
35130
+ };
35131
+ };
35132
+ };
35133
+ };
35274
35134
  GroupMembershipsController_addMember: {
35275
35135
  parameters: {
35276
35136
  query?: never;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@workos/openapi-spec",
3
- "version": "0.137.0",
3
+ "version": "0.139.0",
4
4
  "type": "module",
5
5
  "description": "WorkOS OpenAPI specification, TypeScript types, and SDK resolution policy",
6
6
  "license": "MIT",