@clerk/backend 3.0.0-snapshot.v20251204175016 → 3.0.0-snapshot.v20251211120550

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (60) hide show
  1. package/dist/api/endpoints/APIKeysApi.d.ts +23 -2
  2. package/dist/api/endpoints/APIKeysApi.d.ts.map +1 -1
  3. package/dist/api/endpoints/InstanceApi.d.ts +3 -3
  4. package/dist/api/endpoints/OrganizationApi.d.ts +2 -2
  5. package/dist/api/endpoints/SamlConnectionApi.d.ts +3 -3
  6. package/dist/api/endpoints/UserApi.d.ts +2 -2
  7. package/dist/api/resources/CommercePlan.d.ts +27 -27
  8. package/dist/api/resources/CommerceSubscriptionItem.d.ts +6 -6
  9. package/dist/api/resources/Feature.d.ts +11 -11
  10. package/dist/api/resources/IdPOAuthAccessToken.d.ts +6 -0
  11. package/dist/api/resources/IdPOAuthAccessToken.d.ts.map +1 -1
  12. package/dist/api/resources/JSON.d.ts +4 -4
  13. package/dist/api/resources/Organization.d.ts +23 -23
  14. package/dist/api/resources/OrganizationInvitation.d.ts +7 -7
  15. package/dist/api/resources/OrganizationMembership.d.ts +7 -7
  16. package/dist/api/resources/SamlConnection.d.ts +4 -4
  17. package/dist/api/resources/Session.d.ts +2 -2
  18. package/dist/api/resources/User.d.ts +4 -4
  19. package/dist/{chunk-777XG3PJ.mjs → chunk-4FN7VCZQ.mjs} +165 -12
  20. package/dist/chunk-4FN7VCZQ.mjs.map +1 -0
  21. package/dist/{chunk-QYKVFAML.mjs → chunk-SNA7AD3D.mjs} +8 -7
  22. package/dist/chunk-SNA7AD3D.mjs.map +1 -0
  23. package/dist/{chunk-HNJNM32R.mjs → chunk-TCIXZLLW.mjs} +11 -4
  24. package/dist/{chunk-HNJNM32R.mjs.map → chunk-TCIXZLLW.mjs.map} +1 -1
  25. package/dist/errors.d.ts +6 -3
  26. package/dist/errors.d.ts.map +1 -1
  27. package/dist/errors.js +10 -3
  28. package/dist/errors.js.map +1 -1
  29. package/dist/errors.mjs +1 -1
  30. package/dist/fixtures/index.d.ts +12 -0
  31. package/dist/fixtures/index.d.ts.map +1 -1
  32. package/dist/fixtures/machine.d.ts +2 -0
  33. package/dist/fixtures/machine.d.ts.map +1 -1
  34. package/dist/index.d.ts +1 -0
  35. package/dist/index.d.ts.map +1 -1
  36. package/dist/index.js +178 -17
  37. package/dist/index.js.map +1 -1
  38. package/dist/index.mjs +3 -3
  39. package/dist/internal.js +178 -17
  40. package/dist/internal.js.map +1 -1
  41. package/dist/internal.mjs +3 -3
  42. package/dist/jwt/assertions.d.ts +1 -1
  43. package/dist/jwt/assertions.d.ts.map +1 -1
  44. package/dist/jwt/index.js +6 -5
  45. package/dist/jwt/index.js.map +1 -1
  46. package/dist/jwt/index.mjs +2 -2
  47. package/dist/jwt/verifyJwt.d.ts +5 -0
  48. package/dist/jwt/verifyJwt.d.ts.map +1 -1
  49. package/dist/tokens/authObjects.d.ts +1 -1
  50. package/dist/tokens/clerkRequest.d.ts.map +1 -1
  51. package/dist/tokens/handshake.d.ts.map +1 -1
  52. package/dist/tokens/machine.d.ts +23 -0
  53. package/dist/tokens/machine.d.ts.map +1 -1
  54. package/dist/tokens/types.d.ts +7 -7
  55. package/dist/tokens/verify.d.ts +1 -1
  56. package/dist/tokens/verify.d.ts.map +1 -1
  57. package/dist/util/shared.d.ts +1 -1
  58. package/package.json +2 -2
  59. package/dist/chunk-777XG3PJ.mjs.map +0 -1
  60. package/dist/chunk-QYKVFAML.mjs.map +0 -1
@@ -1,10 +1,11 @@
1
1
  import type { ClerkPaginationRequest } from '@clerk/shared/types';
2
2
  import type { PaginatedResourceResponse } from '../../api/resources/Deserializer';
3
3
  import type { APIKey } from '../resources/APIKey';
4
+ import type { DeletedObject } from '../resources/DeletedObject';
4
5
  import { AbstractAPI } from './AbstractApi';
5
6
  type GetAPIKeyListParams = ClerkPaginationRequest<{
6
7
  /**
7
- * The user or organization ID to query API keys by
8
+ * The user or Organization ID to query API keys by
8
9
  */
9
10
  subject: string;
10
11
  /**
@@ -20,7 +21,7 @@ type CreateAPIKeyParams = {
20
21
  */
21
22
  name: string;
22
23
  /**
23
- * The user or organization ID to associate the API key with
24
+ * The user or Organization ID to associate the API key with
24
25
  */
25
26
  subject: string;
26
27
  /**
@@ -42,9 +43,29 @@ type RevokeAPIKeyParams = {
42
43
  */
43
44
  revocationReason?: string | null;
44
45
  };
46
+ type UpdateAPIKeyParams = {
47
+ /**
48
+ * API key ID
49
+ */
50
+ apiKeyId: string;
51
+ /**
52
+ * The user or Organization ID to associate the API key with
53
+ */
54
+ subject: string;
55
+ /**
56
+ * API key description
57
+ */
58
+ description?: string | null;
59
+ claims?: Record<string, any> | null;
60
+ scopes?: string[];
61
+ secondsUntilExpiration?: number | null;
62
+ };
45
63
  export declare class APIKeysAPI extends AbstractAPI {
46
64
  list(queryParams: GetAPIKeyListParams): Promise<PaginatedResourceResponse<APIKey[]>>;
47
65
  create(params: CreateAPIKeyParams): Promise<APIKey>;
66
+ get(apiKeyId: string): Promise<APIKey>;
67
+ update(params: UpdateAPIKeyParams): Promise<APIKey>;
68
+ delete(apiKeyId: string): Promise<DeletedObject>;
48
69
  revoke(params: RevokeAPIKeyParams): Promise<APIKey>;
49
70
  getSecret(apiKeyId: string): Promise<{
50
71
  secret: string;
@@ -1 +1 @@
1
- {"version":3,"file":"APIKeysApi.d.ts","sourceRoot":"","sources":["../../../src/api/endpoints/APIKeysApi.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,qBAAqB,CAAC;AAElE,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,kCAAkC,CAAC;AAGlF,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAI5C,KAAK,mBAAmB,GAAG,sBAAsB,CAAC;IAChD;;OAEG;IACH,OAAO,EAAE,MAAM,CAAC;IAChB;;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AAC,QAAQ,EAAE,MAAM;IASpB,MAAM,CAAC,MAAM,EAAE,kBAAkB;IAYjC,MAAM,CAAC,QAAQ,EAAE,MAAM;IASvB,MAAM,CAAC,MAAM,EAAE,kBAAkB;IAYjC,SAAS,CAAC,QAAQ,EAAE,MAAM;gBAGA,MAAM;;IAMhC,MAAM,CAAC,MAAM,EAAE,MAAM;IAQ3B;;OAEG;IACG,YAAY,CAAC,MAAM,EAAE,MAAM;CAIlC"}
@@ -46,17 +46,17 @@ type UpdateOrganizationSettingsParams = {
46
46
  adminDeleteEnabled?: boolean | null | undefined;
47
47
  domainsEnabled?: boolean | null | undefined;
48
48
  /**
49
- * Specifies which [enrollment modes](https://clerk.com/docs/guides/organizations/verified-domains#enable-verified-domains) to enable for your Organization Domains.
49
+ * Specifies which [enrollment modes](https://clerk.com/docs/guides/organizations/add-members/verified-domains#enable-verified-domains) to enable for your Organization Domains.
50
50
  *
51
51
  * @remarks Supported modes are 'automatic_invitation' & 'automatic_suggestion'.
52
52
  */
53
53
  domainsEnrollmentModes?: Array<string> | undefined;
54
54
  /**
55
- * Specifies what the default organization role is for an organization creator.
55
+ * Specifies what the default Organization Role is for an Organization creator.
56
56
  */
57
57
  creatorRoleId?: string | null | undefined;
58
58
  /**
59
- * Specifies what the default organization role is for the organization domains.
59
+ * Specifies what the default Organization Role is for the Organization Domains.
60
60
  */
61
61
  domainsDefaultRoleId?: string | null | undefined;
62
62
  };
@@ -41,7 +41,7 @@ type UpdateMetadataParams = MetadataParams;
41
41
  type GetOrganizationMembershipListParams = ClerkPaginationRequest<{
42
42
  organizationId: string;
43
43
  /**
44
- * Sorts organizations memberships by phone_number, email_address, created_at, first_name, last_name or username.
44
+ * Sorts Organization memberships by phone_number, email_address, created_at, first_name, last_name or username.
45
45
  * By prepending one of those values with + or -, we can choose to sort in ascending (ASC) or descending (DESC) order.
46
46
  */
47
47
  orderBy?: WithSign<'phone_number' | 'email_address' | 'created_at' | 'first_name' | 'last_name' | 'username'>;
@@ -101,7 +101,7 @@ type GetOrganizationMembershipListParams = ClerkPaginationRequest<{
101
101
  }>;
102
102
  type GetInstanceOrganizationMembershipListParams = ClerkPaginationRequest<{
103
103
  /**
104
- * Sorts organizations memberships by phone_number, email_address, created_at, first_name, last_name or username.
104
+ * Sorts Organization memberships by phone_number, email_address, created_at, first_name, last_name or username.
105
105
  * By prepending one of those values with + or -, we can choose to sort in ascending (ASC) or descending (DESC) order.
106
106
  */
107
107
  orderBy?: WithSign<'phone_number' | 'email_address' | 'created_at' | 'first_name' | 'last_name' | 'username'>;
@@ -14,9 +14,9 @@ type SamlConnectionListParams = ClerkPaginationRequest<{
14
14
  */
15
15
  orderBy?: WithSign<'phone_number' | 'email_address' | 'created_at' | 'first_name' | 'last_name' | 'username'>;
16
16
  /**
17
- * Returns SAML connections that have an associated organization ID to the given organizations.
18
- * For each organization id, the + and - can be prepended to the id, which denote whether the
19
- * respective organization should be included or excluded from the result set. Accepts up to 100 organization ids.
17
+ * Returns SAML connections that have an associated Organization ID to the given Organizations.
18
+ * For each Organization ID, the + and - can be prepended to the ID, which denote whether the
19
+ * respective Organization should be included or excluded from the result set. Accepts up to 100 Organization IDs.
20
20
  */
21
21
  organizationId?: WithSign<string>[];
22
22
  }>;
@@ -90,9 +90,9 @@ type UpdateUserParams = {
90
90
  locale?: string;
91
91
  /** If true, the user can delete themselves with the Frontend API. */
92
92
  deleteSelfEnabled?: boolean;
93
- /** If true, the user can create organizations with the Frontend API. */
93
+ /** If true, the user can create Organizations with the Frontend API. */
94
94
  createOrganizationEnabled?: boolean;
95
- /** The maximum number of organizations the user can create. 0 means unlimited. */
95
+ /** The maximum number of Organizations the user can create. 0 means unlimited. */
96
96
  createOrganizationsLimit?: number;
97
97
  } & UserMetadataParams & (UserPasswordHashingParams | object);
98
98
  type GetOrganizationMembershipListParams = ClerkPaginationRequest<{
@@ -2,114 +2,114 @@ import type { BillingMoneyAmount } from '@clerk/shared/types';
2
2
  import { Feature } from './Feature';
3
3
  import type { BillingPlanJSON } from './JSON';
4
4
  /**
5
- * The `BillingPlan` object is similar to the [`BillingPlanResource`](/docs/reference/javascript/types/billing-plan-resource) object as it holds information about a plan, as well as methods for managing it. However, the `BillingPlan` object is different in that it is used in the [Backend API](https://clerk.com/docs/reference/backend-api/tag/commerce/get/commerce/plans) and is not directly accessible from the Frontend API.
5
+ * The `BillingPlan` object is similar to the [`BillingPlanResource`](/docs/reference/javascript/types/billing-plan-resource) object as it holds information about a Plan, as well as methods for managing it. However, the `BillingPlan` object is different in that it is used in the [Backend API](https://clerk.com/docs/reference/backend-api/tag/commerce/get/commerce/plans) and is not directly accessible from the Frontend API.
6
6
  *
7
7
  * @experimental This is an experimental API for the Billing feature that is available under a public beta, and the API is subject to change. It is advised to [pin](https://clerk.com/docs/pinning) the SDK version and the clerk-js version to avoid breaking changes.
8
8
  */
9
9
  export declare class BillingPlan {
10
10
  /**
11
- * The unique identifier for the plan.
11
+ * The unique identifier for the Plan.
12
12
  */
13
13
  readonly id: string;
14
14
  /**
15
- * The name of the plan.
15
+ * The name of the Plan.
16
16
  */
17
17
  readonly name: string;
18
18
  /**
19
- * The URL-friendly identifier of the plan.
19
+ * The URL-friendly identifier of the Plan.
20
20
  */
21
21
  readonly slug: string;
22
22
  /**
23
- * The description of the plan.
23
+ * The description of the Plan.
24
24
  */
25
25
  readonly description: string | null;
26
26
  /**
27
- * Whether the plan is the default plan.
27
+ * Whether the Plan is the default Plan.
28
28
  */
29
29
  readonly isDefault: boolean;
30
30
  /**
31
- * Whether the plan is recurring.
31
+ * Whether the Plan is recurring.
32
32
  */
33
33
  readonly isRecurring: boolean;
34
34
  /**
35
- * Whether the plan has a base fee.
35
+ * Whether the Plan has a base fee.
36
36
  */
37
37
  readonly hasBaseFee: boolean;
38
38
  /**
39
- * Whether the plan is displayed in the `<PriceTable/>` component.
39
+ * Whether the Plan is displayed in the `<PriceTable/>` component.
40
40
  */
41
41
  readonly publiclyVisible: boolean;
42
42
  /**
43
- * The monthly fee of the plan.
43
+ * The monthly fee of the Plan.
44
44
  */
45
45
  readonly fee: BillingMoneyAmount;
46
46
  /**
47
- * The annual fee of the plan.
47
+ * The annual fee of the Plan.
48
48
  */
49
49
  readonly annualFee: BillingMoneyAmount | null;
50
50
  /**
51
- * The annual fee of the plan on a monthly basis.
51
+ * The annual fee of the Plan on a monthly basis.
52
52
  */
53
53
  readonly annualMonthlyFee: BillingMoneyAmount | null;
54
54
  /**
55
- * The type of payer for the plan.
55
+ * The type of payer for the Plan.
56
56
  */
57
57
  readonly forPayerType: 'org' | 'user';
58
58
  /**
59
- * The features the plan offers.
59
+ * The features the Plan offers.
60
60
  */
61
61
  readonly features: Feature[];
62
62
  constructor(
63
63
  /**
64
- * The unique identifier for the plan.
64
+ * The unique identifier for the Plan.
65
65
  */
66
66
  id: string,
67
67
  /**
68
- * The name of the plan.
68
+ * The name of the Plan.
69
69
  */
70
70
  name: string,
71
71
  /**
72
- * The URL-friendly identifier of the plan.
72
+ * The URL-friendly identifier of the Plan.
73
73
  */
74
74
  slug: string,
75
75
  /**
76
- * The description of the plan.
76
+ * The description of the Plan.
77
77
  */
78
78
  description: string | null,
79
79
  /**
80
- * Whether the plan is the default plan.
80
+ * Whether the Plan is the default Plan.
81
81
  */
82
82
  isDefault: boolean,
83
83
  /**
84
- * Whether the plan is recurring.
84
+ * Whether the Plan is recurring.
85
85
  */
86
86
  isRecurring: boolean,
87
87
  /**
88
- * Whether the plan has a base fee.
88
+ * Whether the Plan has a base fee.
89
89
  */
90
90
  hasBaseFee: boolean,
91
91
  /**
92
- * Whether the plan is displayed in the `<PriceTable/>` component.
92
+ * Whether the Plan is displayed in the `<PriceTable/>` component.
93
93
  */
94
94
  publiclyVisible: boolean,
95
95
  /**
96
- * The monthly fee of the plan.
96
+ * The monthly fee of the Plan.
97
97
  */
98
98
  fee: BillingMoneyAmount,
99
99
  /**
100
- * The annual fee of the plan.
100
+ * The annual fee of the Plan.
101
101
  */
102
102
  annualFee: BillingMoneyAmount | null,
103
103
  /**
104
- * The annual fee of the plan on a monthly basis.
104
+ * The annual fee of the Plan on a monthly basis.
105
105
  */
106
106
  annualMonthlyFee: BillingMoneyAmount | null,
107
107
  /**
108
- * The type of payer for the plan.
108
+ * The type of payer for the Plan.
109
109
  */
110
110
  forPayerType: 'org' | 'user',
111
111
  /**
112
- * The features the plan offers.
112
+ * The features the Plan offers.
113
113
  */
114
114
  features: Feature[]);
115
115
  static fromJSON(data: BillingPlanJSON): BillingPlan;
@@ -16,7 +16,7 @@ export declare class BillingSubscriptionItem {
16
16
  */
17
17
  readonly status: BillingSubscriptionItemJSON['status'];
18
18
  /**
19
- * The plan period for the subscription item.
19
+ * The Plan period for the subscription item.
20
20
  */
21
21
  readonly planPeriod: 'month' | 'annual';
22
22
  /**
@@ -41,11 +41,11 @@ export declare class BillingSubscriptionItem {
41
41
  */
42
42
  readonly amount: BillingMoneyAmount | undefined;
43
43
  /**
44
- * The plan associated with this subscription item.
44
+ * The Plan associated with this subscription item.
45
45
  */
46
46
  readonly plan: BillingPlan | null;
47
47
  /**
48
- * The plan ID.
48
+ * The Plan ID.
49
49
  */
50
50
  readonly planId: string | null;
51
51
  /**
@@ -94,7 +94,7 @@ export declare class BillingSubscriptionItem {
94
94
  */
95
95
  status: BillingSubscriptionItemJSON['status'],
96
96
  /**
97
- * The plan period for the subscription item.
97
+ * The Plan period for the subscription item.
98
98
  */
99
99
  planPeriod: 'month' | 'annual',
100
100
  /**
@@ -119,11 +119,11 @@ export declare class BillingSubscriptionItem {
119
119
  */
120
120
  amount: BillingMoneyAmount | undefined,
121
121
  /**
122
- * The plan associated with this subscription item.
122
+ * The Plan associated with this subscription item.
123
123
  */
124
124
  plan: BillingPlan | null,
125
125
  /**
126
- * The plan ID.
126
+ * The Plan ID.
127
127
  */
128
128
  planId: string | null,
129
129
  /**
@@ -1,49 +1,49 @@
1
1
  import type { FeatureJSON } from './JSON';
2
2
  /**
3
- * The `Feature` object represents a feature of a subscription plan.
3
+ * The `Feature` object represents a Feature of a Subscription Plan.
4
4
  *
5
5
  * @experimental This is an experimental API for the Billing feature that is available under a public beta, and the API is subject to change. It is advised to [pin](https://clerk.com/docs/pinning) the SDK version and the clerk-js version to avoid breaking changes.
6
6
  */
7
7
  export declare class Feature {
8
8
  /**
9
- * The unique identifier for the feature.
9
+ * The unique identifier for the Feature.
10
10
  */
11
11
  readonly id: string;
12
12
  /**
13
- * The name of the feature.
13
+ * The name of the Feature.
14
14
  */
15
15
  readonly name: string;
16
16
  /**
17
- * The description of the feature.
17
+ * The description of the Feature.
18
18
  */
19
19
  readonly description: string | null;
20
20
  /**
21
- * The URL-friendly identifier of the feature.
21
+ * The URL-friendly identifier of the Feature.
22
22
  */
23
23
  readonly slug: string;
24
24
  /**
25
- * The URL of the feature's avatar image.
25
+ * The URL of the Feature's avatar image.
26
26
  */
27
27
  readonly avatarUrl: string | null;
28
28
  constructor(
29
29
  /**
30
- * The unique identifier for the feature.
30
+ * The unique identifier for the Feature.
31
31
  */
32
32
  id: string,
33
33
  /**
34
- * The name of the feature.
34
+ * The name of the Feature.
35
35
  */
36
36
  name: string,
37
37
  /**
38
- * The description of the feature.
38
+ * The description of the Feature.
39
39
  */
40
40
  description: string | null,
41
41
  /**
42
- * The URL-friendly identifier of the feature.
42
+ * The URL-friendly identifier of the Feature.
43
43
  */
44
44
  slug: string,
45
45
  /**
46
- * The URL of the feature's avatar image.
46
+ * The URL of the Feature's avatar image.
47
47
  */
48
48
  avatarUrl: string | null);
49
49
  static fromJSON(data: FeatureJSON): Feature;
@@ -1,3 +1,4 @@
1
+ import type { JwtPayload } from '@clerk/shared/types';
1
2
  import type { IdPOAuthAccessTokenJSON } from './JSON';
2
3
  export declare class IdPOAuthAccessToken {
3
4
  readonly id: string;
@@ -13,5 +14,10 @@ export declare class IdPOAuthAccessToken {
13
14
  readonly updatedAt: number;
14
15
  constructor(id: string, clientId: string, type: string, subject: string, scopes: string[], revoked: boolean, revocationReason: string | null, expired: boolean, expiration: number | null, createdAt: number, updatedAt: number);
15
16
  static fromJSON(data: IdPOAuthAccessTokenJSON): IdPOAuthAccessToken;
17
+ /**
18
+ * Creates an IdPOAuthAccessToken from a JWT payload.
19
+ * Maps standard JWT claims and OAuth-specific fields to token properties.
20
+ */
21
+ static fromJwtPayload(payload: JwtPayload, clockSkewInMs?: number): IdPOAuthAccessToken;
16
22
  }
17
23
  //# sourceMappingURL=IdPOAuthAccessToken.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"IdPOAuthAccessToken.d.ts","sourceRoot":"","sources":["../../../src/api/resources/IdPOAuthAccessToken.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,QAAQ,CAAC;AAEtD,qBAAa,mBAAmB;IAE5B,QAAQ,CAAC,EAAE,EAAE,MAAM;IACnB,QAAQ,CAAC,QAAQ,EAAE,MAAM;IACzB,QAAQ,CAAC,IAAI,EAAE,MAAM;IACrB,QAAQ,CAAC,OAAO,EAAE,MAAM;IACxB,QAAQ,CAAC,MAAM,EAAE,MAAM,EAAE;IACzB,QAAQ,CAAC,OAAO,EAAE,OAAO;IACzB,QAAQ,CAAC,gBAAgB,EAAE,MAAM,GAAG,IAAI;IACxC,QAAQ,CAAC,OAAO,EAAE,OAAO;IACzB,QAAQ,CAAC,UAAU,EAAE,MAAM,GAAG,IAAI;IAClC,QAAQ,CAAC,SAAS,EAAE,MAAM;IAC1B,QAAQ,CAAC,SAAS,EAAE,MAAM;gBAVjB,EAAE,EAAE,MAAM,EACV,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE,MAAM,EACf,MAAM,EAAE,MAAM,EAAE,EAChB,OAAO,EAAE,OAAO,EAChB,gBAAgB,EAAE,MAAM,GAAG,IAAI,EAC/B,OAAO,EAAE,OAAO,EAChB,UAAU,EAAE,MAAM,GAAG,IAAI,EACzB,SAAS,EAAE,MAAM,EACjB,SAAS,EAAE,MAAM;IAG5B,MAAM,CAAC,QAAQ,CAAC,IAAI,EAAE,uBAAuB;CAe9C"}
1
+ {"version":3,"file":"IdPOAuthAccessToken.d.ts","sourceRoot":"","sources":["../../../src/api/resources/IdPOAuthAccessToken.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAEtD,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,QAAQ,CAAC;AAStD,qBAAa,mBAAmB;IAE5B,QAAQ,CAAC,EAAE,EAAE,MAAM;IACnB,QAAQ,CAAC,QAAQ,EAAE,MAAM;IACzB,QAAQ,CAAC,IAAI,EAAE,MAAM;IACrB,QAAQ,CAAC,OAAO,EAAE,MAAM;IACxB,QAAQ,CAAC,MAAM,EAAE,MAAM,EAAE;IACzB,QAAQ,CAAC,OAAO,EAAE,OAAO;IACzB,QAAQ,CAAC,gBAAgB,EAAE,MAAM,GAAG,IAAI;IACxC,QAAQ,CAAC,OAAO,EAAE,OAAO;IACzB,QAAQ,CAAC,UAAU,EAAE,MAAM,GAAG,IAAI;IAClC,QAAQ,CAAC,SAAS,EAAE,MAAM;IAC1B,QAAQ,CAAC,SAAS,EAAE,MAAM;gBAVjB,EAAE,EAAE,MAAM,EACV,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE,MAAM,EACf,MAAM,EAAE,MAAM,EAAE,EAChB,OAAO,EAAE,OAAO,EAChB,gBAAgB,EAAE,MAAM,GAAG,IAAI,EAC/B,OAAO,EAAE,OAAO,EAChB,UAAU,EAAE,MAAM,GAAG,IAAI,EACzB,SAAS,EAAE,MAAM,EACjB,SAAS,EAAE,MAAM;IAG5B,MAAM,CAAC,QAAQ,CAAC,IAAI,EAAE,uBAAuB;IAgB7C;;;OAGG;IACH,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,UAAU,EAAE,aAAa,SAAO,GAAG,mBAAmB;CAkBtF"}
@@ -341,19 +341,19 @@ export interface OrganizationInvitationAcceptedJSON extends OrganizationInvitati
341
341
  */
342
342
  export interface PublicOrganizationDataJSON extends ClerkResourceJSON {
343
343
  /**
344
- * The name of the organization.
344
+ * The name of the Organization.
345
345
  */
346
346
  name: string;
347
347
  /**
348
- * The slug of the organization.
348
+ * The slug of the Organization.
349
349
  */
350
350
  slug: string;
351
351
  /**
352
- * Holds the default organization profile image. Compatible with Clerk's [Image Optimization](https://clerk.com/docs/guides/development/image-optimization).
352
+ * Holds the default Organization profile image. Compatible with Clerk's [Image Optimization](https://clerk.com/docs/guides/development/image-optimization).
353
353
  */
354
354
  image_url?: string;
355
355
  /**
356
- * Whether the organization has a profile image.
356
+ * Whether the Organization has a profile image.
357
357
  */
358
358
  has_image: boolean;
359
359
  }
@@ -1,34 +1,34 @@
1
1
  import type { OrganizationJSON } from './JSON';
2
2
  /**
3
- * The Backend `Organization` object is similar to the [`Organization`](https://clerk.com/docs/reference/javascript/organization) object as it holds information about an organization, as well as methods for managing it. However, the Backend `Organization` object is different in that it is used in the [Backend API](https://clerk.com/docs/reference/backend-api/tag/Organizations#operation/ListOrganizations){{ target: '_blank' }} and is not directly accessible from the Frontend API.
3
+ * The Backend `Organization` object is similar to the [`Organization`](https://clerk.com/docs/reference/javascript/organization) object as it holds information about an Organization, as well as methods for managing it. However, the Backend `Organization` object is different in that it is used in the [Backend API](https://clerk.com/docs/reference/backend-api/tag/Organizations#operation/ListOrganizations){{ target: '_blank' }} and is not directly accessible from the Frontend API.
4
4
  */
5
5
  export declare class Organization {
6
6
  /**
7
- * The unique identifier for the organization.
7
+ * The unique identifier for the Organization.
8
8
  */
9
9
  readonly id: string;
10
10
  /**
11
- * The name of the organization.
11
+ * The name of the Organization.
12
12
  */
13
13
  readonly name: string;
14
14
  /**
15
- * The URL-friendly identifier of the user's active organization. If supplied, it must be unique for the instance.
15
+ * The URL-friendly identifier of the user's active Organization. If supplied, it must be unique for the instance.
16
16
  */
17
17
  readonly slug: string;
18
18
  /**
19
- * Holds the organization's logo. Compatible with Clerk's [Image Optimization](https://clerk.com/docs/guides/development/image-optimization).
19
+ * Holds the Organization's logo. Compatible with Clerk's [Image Optimization](https://clerk.com/docs/guides/development/image-optimization).
20
20
  */
21
21
  readonly imageUrl: string;
22
22
  /**
23
- * Whether the organization has an image.
23
+ * Whether the Organization has an image.
24
24
  */
25
25
  readonly hasImage: boolean;
26
26
  /**
27
- * The date when the organization was first created.
27
+ * The date when the Organization was first created.
28
28
  */
29
29
  readonly createdAt: number;
30
30
  /**
31
- * The date when the organization was last updated.
31
+ * The date when the Organization was last updated.
32
32
  */
33
33
  readonly updatedAt: number;
34
34
  /**
@@ -40,50 +40,50 @@ export declare class Organization {
40
40
  */
41
41
  readonly privateMetadata: OrganizationPrivateMetadata;
42
42
  /**
43
- * The maximum number of memberships allowed in the organization.
43
+ * The maximum number of memberships allowed in the Organization.
44
44
  */
45
45
  readonly maxAllowedMemberships: number;
46
46
  /**
47
- * Whether the organization allows admins to delete users.
47
+ * Whether the Organization allows admins to delete users.
48
48
  */
49
49
  readonly adminDeleteEnabled: boolean;
50
50
  /**
51
- * The number of members in the organization.
51
+ * The number of members in the Organization.
52
52
  */
53
53
  readonly membersCount?: number | undefined;
54
54
  /**
55
- * The ID of the user who created the organization.
55
+ * The ID of the user who created the Organization.
56
56
  */
57
57
  readonly createdBy?: string | undefined;
58
58
  private _raw;
59
59
  get raw(): OrganizationJSON | null;
60
60
  constructor(
61
61
  /**
62
- * The unique identifier for the organization.
62
+ * The unique identifier for the Organization.
63
63
  */
64
64
  id: string,
65
65
  /**
66
- * The name of the organization.
66
+ * The name of the Organization.
67
67
  */
68
68
  name: string,
69
69
  /**
70
- * The URL-friendly identifier of the user's active organization. If supplied, it must be unique for the instance.
70
+ * The URL-friendly identifier of the user's active Organization. If supplied, it must be unique for the instance.
71
71
  */
72
72
  slug: string,
73
73
  /**
74
- * Holds the organization's logo. Compatible with Clerk's [Image Optimization](https://clerk.com/docs/guides/development/image-optimization).
74
+ * Holds the Organization's logo. Compatible with Clerk's [Image Optimization](https://clerk.com/docs/guides/development/image-optimization).
75
75
  */
76
76
  imageUrl: string,
77
77
  /**
78
- * Whether the organization has an image.
78
+ * Whether the Organization has an image.
79
79
  */
80
80
  hasImage: boolean,
81
81
  /**
82
- * The date when the organization was first created.
82
+ * The date when the Organization was first created.
83
83
  */
84
84
  createdAt: number,
85
85
  /**
86
- * The date when the organization was last updated.
86
+ * The date when the Organization was last updated.
87
87
  */
88
88
  updatedAt: number,
89
89
  /**
@@ -95,19 +95,19 @@ export declare class Organization {
95
95
  */
96
96
  privateMetadata: OrganizationPrivateMetadata | undefined,
97
97
  /**
98
- * The maximum number of memberships allowed in the organization.
98
+ * The maximum number of memberships allowed in the Organization.
99
99
  */
100
100
  maxAllowedMemberships: number,
101
101
  /**
102
- * Whether the organization allows admins to delete users.
102
+ * Whether the Organization allows admins to delete users.
103
103
  */
104
104
  adminDeleteEnabled: boolean,
105
105
  /**
106
- * The number of members in the organization.
106
+ * The number of members in the Organization.
107
107
  */
108
108
  membersCount?: number | undefined,
109
109
  /**
110
- * The ID of the user who created the organization.
110
+ * The ID of the user who created the Organization.
111
111
  */
112
112
  createdBy?: string | undefined);
113
113
  static fromJSON(data: OrganizationJSON): Organization;
@@ -1,7 +1,7 @@
1
1
  import type { OrganizationInvitationStatus, OrganizationMembershipRole } from './Enums';
2
2
  import type { OrganizationInvitationJSON, PublicOrganizationDataJSON } from './JSON';
3
3
  /**
4
- * The Backend `OrganizationInvitation` object is similar to the [`OrganizationInvitation`](https://clerk.com/docs/reference/javascript/types/organization-invitation) object as it's the model around an organization invitation. However, the Backend `OrganizationInvitation` object is different in that it's used in the [Backend API](https://clerk.com/docs/reference/backend-api/tag/Organization-Invitations#operation/CreateOrganizationInvitation){{ target: '_blank' }} and is not directly accessible from the Frontend API.
4
+ * The Backend `OrganizationInvitation` object is similar to the [`OrganizationInvitation`](https://clerk.com/docs/reference/javascript/types/organization-invitation) object as it's the model around an Organization invitation. However, the Backend `OrganizationInvitation` object is different in that it's used in the [Backend API](https://clerk.com/docs/reference/backend-api/tag/Organization-Invitations#operation/CreateOrganizationInvitation){{ target: '_blank' }} and is not directly accessible from the Frontend API.
5
5
  */
6
6
  export declare class OrganizationInvitation {
7
7
  /**
@@ -13,11 +13,11 @@ export declare class OrganizationInvitation {
13
13
  */
14
14
  readonly emailAddress: string;
15
15
  /**
16
- * The role of the invited user.
16
+ * The Role of the invited user.
17
17
  */
18
18
  readonly role: OrganizationMembershipRole;
19
19
  /**
20
- * The name of the role of the invited user.
20
+ * The name of the Role of the invited user.
21
21
  */
22
22
  readonly roleName: string;
23
23
  /**
@@ -53,7 +53,7 @@ export declare class OrganizationInvitation {
53
53
  */
54
54
  readonly privateMetadata: OrganizationInvitationPrivateMetadata;
55
55
  /**
56
- * Public data about the organization that the user is invited to.
56
+ * Public data about the Organization that the user is invited to.
57
57
  */
58
58
  readonly publicOrganizationData?: (PublicOrganizationDataJSON | null) | undefined;
59
59
  private _raw;
@@ -68,11 +68,11 @@ export declare class OrganizationInvitation {
68
68
  */
69
69
  emailAddress: string,
70
70
  /**
71
- * The role of the invited user.
71
+ * The Role of the invited user.
72
72
  */
73
73
  role: OrganizationMembershipRole,
74
74
  /**
75
- * The name of the role of the invited user.
75
+ * The name of the Role of the invited user.
76
76
  */
77
77
  roleName: string,
78
78
  /**
@@ -108,7 +108,7 @@ export declare class OrganizationInvitation {
108
108
  */
109
109
  privateMetadata?: OrganizationInvitationPrivateMetadata,
110
110
  /**
111
- * Public data about the organization that the user is invited to.
111
+ * Public data about the Organization that the user is invited to.
112
112
  */
113
113
  publicOrganizationData?: (PublicOrganizationDataJSON | null) | undefined);
114
114
  static fromJSON(data: OrganizationInvitationJSON): OrganizationInvitation;