@dynamic-labs/sdk-api 0.0.982 → 0.0.983

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 (133) hide show
  1. package/package.json +1 -1
  2. package/src/apis/AdminActionsApi.cjs +3 -0
  3. package/src/apis/AdminActionsApi.js +3 -0
  4. package/src/apis/AllowlistsApi.cjs +3 -0
  5. package/src/apis/AllowlistsApi.js +3 -0
  6. package/src/apis/AnalyticsApi.cjs +3 -0
  7. package/src/apis/AnalyticsApi.js +3 -0
  8. package/src/apis/AuthorizedClientsApi.cjs +217 -0
  9. package/src/apis/AuthorizedClientsApi.d.ts +55 -0
  10. package/src/apis/AuthorizedClientsApi.js +213 -0
  11. package/src/apis/ChainalysisApi.cjs +3 -0
  12. package/src/apis/ChainalysisApi.js +3 -0
  13. package/src/apis/ChainsApi.cjs +3 -0
  14. package/src/apis/ChainsApi.js +3 -0
  15. package/src/apis/CheckoutApi.cjs +3 -0
  16. package/src/apis/CheckoutApi.js +3 -0
  17. package/src/apis/ClientGrantApi.cjs +250 -0
  18. package/src/apis/ClientGrantApi.d.ts +70 -0
  19. package/src/apis/ClientGrantApi.js +246 -0
  20. package/src/apis/CustomFieldsApi.cjs +3 -0
  21. package/src/apis/CustomFieldsApi.js +3 -0
  22. package/src/apis/CustomHostnamesApi.cjs +3 -0
  23. package/src/apis/CustomHostnamesApi.js +3 -0
  24. package/src/apis/CustomNetworksApi.cjs +3 -0
  25. package/src/apis/CustomNetworksApi.js +3 -0
  26. package/src/apis/DeeplinkUrlsApi.cjs +3 -0
  27. package/src/apis/DeeplinkUrlsApi.js +3 -0
  28. package/src/apis/EnvironmentsApi.cjs +3 -0
  29. package/src/apis/EnvironmentsApi.js +3 -0
  30. package/src/apis/EventsApi.cjs +3 -0
  31. package/src/apis/EventsApi.js +3 -0
  32. package/src/apis/ExchangesApi.cjs +3 -0
  33. package/src/apis/ExchangesApi.js +3 -0
  34. package/src/apis/ExportsApi.cjs +3 -0
  35. package/src/apis/ExportsApi.js +3 -0
  36. package/src/apis/ExternalJwtApi.cjs +3 -0
  37. package/src/apis/ExternalJwtApi.js +3 -0
  38. package/src/apis/GatesApi.cjs +3 -0
  39. package/src/apis/GatesApi.js +3 -0
  40. package/src/apis/GlobalWalletAccessControlApi.cjs +3 -0
  41. package/src/apis/GlobalWalletAccessControlApi.js +3 -0
  42. package/src/apis/GlobalWalletConnectionsApi.cjs +3 -0
  43. package/src/apis/GlobalWalletConnectionsApi.js +3 -0
  44. package/src/apis/GlobalWalletsApi.cjs +3 -0
  45. package/src/apis/GlobalWalletsApi.js +3 -0
  46. package/src/apis/InvitesApi.cjs +3 -0
  47. package/src/apis/InvitesApi.js +3 -0
  48. package/src/apis/MembersApi.cjs +3 -0
  49. package/src/apis/MembersApi.js +3 -0
  50. package/src/apis/MfaSettingsApi.cjs +3 -0
  51. package/src/apis/MfaSettingsApi.js +3 -0
  52. package/src/apis/NameServicesApi.cjs +3 -0
  53. package/src/apis/NameServicesApi.js +3 -0
  54. package/src/apis/OrganizationSettingsApi.cjs +3 -0
  55. package/src/apis/OrganizationSettingsApi.js +3 -0
  56. package/src/apis/OrganizationsApi.cjs +3 -0
  57. package/src/apis/OrganizationsApi.js +3 -0
  58. package/src/apis/OriginsApi.cjs +3 -0
  59. package/src/apis/OriginsApi.js +3 -0
  60. package/src/apis/ProjectsApi.cjs +3 -0
  61. package/src/apis/ProjectsApi.js +3 -0
  62. package/src/apis/ProvidersApi.cjs +3 -0
  63. package/src/apis/ProvidersApi.js +3 -0
  64. package/src/apis/SDKApi.cjs +3 -0
  65. package/src/apis/SDKApi.js +3 -0
  66. package/src/apis/SDKViewsApi.cjs +3 -0
  67. package/src/apis/SDKViewsApi.js +3 -0
  68. package/src/apis/SessionsApi.cjs +3 -0
  69. package/src/apis/SessionsApi.js +3 -0
  70. package/src/apis/TestAccountApi.cjs +3 -0
  71. package/src/apis/TestAccountApi.js +3 -0
  72. package/src/apis/TokensApi.cjs +3 -0
  73. package/src/apis/TokensApi.js +3 -0
  74. package/src/apis/UserApiTokensApi.cjs +3 -0
  75. package/src/apis/UserApiTokensApi.js +3 -0
  76. package/src/apis/UsersApi.cjs +3 -0
  77. package/src/apis/UsersApi.js +3 -0
  78. package/src/apis/VisitsApi.cjs +3 -0
  79. package/src/apis/VisitsApi.js +3 -0
  80. package/src/apis/WaasApi.cjs +3 -0
  81. package/src/apis/WaasApi.js +3 -0
  82. package/src/apis/WalletConnectApi.cjs +3 -0
  83. package/src/apis/WalletConnectApi.js +3 -0
  84. package/src/apis/WalletsApi.cjs +3 -0
  85. package/src/apis/WalletsApi.js +3 -0
  86. package/src/apis/WebhooksApi.cjs +3 -0
  87. package/src/apis/WebhooksApi.js +3 -0
  88. package/src/apis/index.d.ts +2 -0
  89. package/src/index.cjs +68 -0
  90. package/src/index.js +15 -0
  91. package/src/models/AuthorizedClient.cjs +54 -0
  92. package/src/models/AuthorizedClient.d.ts +94 -0
  93. package/src/models/AuthorizedClient.js +48 -0
  94. package/src/models/AuthorizedClientList.cjs +33 -0
  95. package/src/models/AuthorizedClientList.d.ts +28 -0
  96. package/src/models/AuthorizedClientList.js +27 -0
  97. package/src/models/ClientMetadata.cjs +39 -0
  98. package/src/models/ClientMetadata.d.ts +48 -0
  99. package/src/models/ClientMetadata.js +33 -0
  100. package/src/models/ClientTypeEnum.cjs +45 -0
  101. package/src/models/ClientTypeEnum.d.ts +28 -0
  102. package/src/models/ClientTypeEnum.js +39 -0
  103. package/src/models/GetEVMSponsoredTransactionStatusResponse.cjs +4 -8
  104. package/src/models/GetEVMSponsoredTransactionStatusResponse.d.ts +7 -11
  105. package/src/models/GetEVMSponsoredTransactionStatusResponse.js +4 -8
  106. package/src/models/GrantActionEnum.cjs +42 -0
  107. package/src/models/GrantActionEnum.d.ts +25 -0
  108. package/src/models/GrantActionEnum.js +36 -0
  109. package/src/models/GrantApproveRequest.cjs +35 -0
  110. package/src/models/GrantApproveRequest.d.ts +34 -0
  111. package/src/models/GrantApproveRequest.js +29 -0
  112. package/src/models/GrantApproveResponse.cjs +33 -0
  113. package/src/models/GrantApproveResponse.d.ts +28 -0
  114. package/src/models/GrantApproveResponse.js +27 -0
  115. package/src/models/GrantCodeRequest.cjs +37 -0
  116. package/src/models/GrantCodeRequest.d.ts +37 -0
  117. package/src/models/GrantCodeRequest.js +31 -0
  118. package/src/models/GrantCodeResponse.cjs +53 -0
  119. package/src/models/GrantCodeResponse.d.ts +59 -0
  120. package/src/models/GrantCodeResponse.js +47 -0
  121. package/src/models/GrantPeekResponse.cjs +37 -0
  122. package/src/models/GrantPeekResponse.d.ts +37 -0
  123. package/src/models/GrantPeekResponse.js +31 -0
  124. package/src/models/GrantTokenRequest.cjs +43 -0
  125. package/src/models/GrantTokenRequest.d.ts +27 -0
  126. package/src/models/GrantTokenRequest.js +37 -0
  127. package/src/models/GrantTokenResponse.cjs +49 -0
  128. package/src/models/GrantTokenResponse.d.ts +52 -0
  129. package/src/models/GrantTokenResponse.js +43 -0
  130. package/src/models/UpdateAuthorizedClientRequest.cjs +33 -0
  131. package/src/models/UpdateAuthorizedClientRequest.d.ts +27 -0
  132. package/src/models/UpdateAuthorizedClientRequest.js +27 -0
  133. package/src/models/index.d.ts +13 -0
@@ -20,6 +20,7 @@ require('../models/AuthenticatorAttachment.cjs');
20
20
  require('../models/ResidentKeyRequirement.cjs');
21
21
  require('../models/UserVerificationRequirement.cjs');
22
22
  require('../models/AuthenticatorTransportProtocol.cjs');
23
+ require('../models/ClientTypeEnum.cjs');
23
24
  require('../models/WaasBackupOptionsEnum.cjs');
24
25
  require('../models/BackupKeySharesToLocationsPendingResponse.cjs');
25
26
  require('../models/ThresholdSignatureScheme.cjs');
@@ -93,6 +94,8 @@ require('../models/PasskeyCredentialType.cjs');
93
94
  require('../models/PublicKeyCredentialType.cjs');
94
95
  require('../models/GlobalWalletAccessControlTypeEnum.cjs');
95
96
  require('../models/GlobalWalletConnectionStatusEnum.cjs');
97
+ require('../models/GrantActionEnum.cjs');
98
+ require('../models/GrantTokenResponse.cjs');
96
99
  require('../models/HealthcheckStatus.cjs');
97
100
  require('../models/SdkEnvironmentIdWaasWalletIdAdditionalAddressesAdditionalAddresses.cjs');
98
101
  require('../models/InlineObject2.cjs');
@@ -16,6 +16,7 @@ import '../models/AuthenticatorAttachment.js';
16
16
  import '../models/ResidentKeyRequirement.js';
17
17
  import '../models/UserVerificationRequirement.js';
18
18
  import '../models/AuthenticatorTransportProtocol.js';
19
+ import '../models/ClientTypeEnum.js';
19
20
  import '../models/WaasBackupOptionsEnum.js';
20
21
  import '../models/BackupKeySharesToLocationsPendingResponse.js';
21
22
  import '../models/ThresholdSignatureScheme.js';
@@ -89,6 +90,8 @@ import '../models/PasskeyCredentialType.js';
89
90
  import '../models/PublicKeyCredentialType.js';
90
91
  import '../models/GlobalWalletAccessControlTypeEnum.js';
91
92
  import '../models/GlobalWalletConnectionStatusEnum.js';
93
+ import '../models/GrantActionEnum.js';
94
+ import '../models/GrantTokenResponse.js';
92
95
  import '../models/HealthcheckStatus.js';
93
96
  import '../models/SdkEnvironmentIdWaasWalletIdAdditionalAddressesAdditionalAddresses.js';
94
97
  import '../models/InlineObject2.js';
@@ -20,6 +20,7 @@ require('../models/AuthenticatorAttachment.cjs');
20
20
  require('../models/ResidentKeyRequirement.cjs');
21
21
  require('../models/UserVerificationRequirement.cjs');
22
22
  require('../models/AuthenticatorTransportProtocol.cjs');
23
+ require('../models/ClientTypeEnum.cjs');
23
24
  require('../models/WaasBackupOptionsEnum.cjs');
24
25
  require('../models/BackupKeySharesToLocationsPendingResponse.cjs');
25
26
  require('../models/ThresholdSignatureScheme.cjs');
@@ -94,6 +95,8 @@ require('../models/PasskeyCredentialType.cjs');
94
95
  require('../models/PublicKeyCredentialType.cjs');
95
96
  require('../models/GlobalWalletAccessControlTypeEnum.cjs');
96
97
  require('../models/GlobalWalletConnectionStatusEnum.cjs');
98
+ require('../models/GrantActionEnum.cjs');
99
+ require('../models/GrantTokenResponse.cjs');
97
100
  require('../models/HealthcheckStatus.cjs');
98
101
  require('../models/SdkEnvironmentIdWaasWalletIdAdditionalAddressesAdditionalAddresses.cjs');
99
102
  require('../models/InlineObject2.cjs');
@@ -16,6 +16,7 @@ import '../models/AuthenticatorAttachment.js';
16
16
  import '../models/ResidentKeyRequirement.js';
17
17
  import '../models/UserVerificationRequirement.js';
18
18
  import '../models/AuthenticatorTransportProtocol.js';
19
+ import '../models/ClientTypeEnum.js';
19
20
  import '../models/WaasBackupOptionsEnum.js';
20
21
  import '../models/BackupKeySharesToLocationsPendingResponse.js';
21
22
  import '../models/ThresholdSignatureScheme.js';
@@ -90,6 +91,8 @@ import '../models/PasskeyCredentialType.js';
90
91
  import '../models/PublicKeyCredentialType.js';
91
92
  import '../models/GlobalWalletAccessControlTypeEnum.js';
92
93
  import '../models/GlobalWalletConnectionStatusEnum.js';
94
+ import '../models/GrantActionEnum.js';
95
+ import '../models/GrantTokenResponse.js';
93
96
  import '../models/HealthcheckStatus.js';
94
97
  import '../models/SdkEnvironmentIdWaasWalletIdAdditionalAddressesAdditionalAddresses.js';
95
98
  import '../models/InlineObject2.js';
@@ -0,0 +1,250 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var runtime = require('../runtime.cjs');
6
+ require('../models/AccessOutcomeEnum.cjs');
7
+ require('../models/ExchangeKeyEnum.cjs');
8
+ require('../models/AdminActionRequestStatus.cjs');
9
+ require('../models/AdminActionResponseDecision.cjs');
10
+ require('../models/AdminActionType.cjs');
11
+ require('../models/AuthStorageEnum.cjs');
12
+ require('../models/MFADeviceType.cjs');
13
+ require('../models/MFASettingsActions.cjs');
14
+ require('../models/TimeUnitEnum.cjs');
15
+ require('../models/ChainEnum.cjs');
16
+ require('../models/CheckoutSourceTypeEnum.cjs');
17
+ require('../models/AttestationConveyancePreference.cjs');
18
+ require('../models/AuthModeEnum.cjs');
19
+ require('../models/AuthenticatorAttachment.cjs');
20
+ require('../models/ResidentKeyRequirement.cjs');
21
+ require('../models/UserVerificationRequirement.cjs');
22
+ require('../models/AuthenticatorTransportProtocol.cjs');
23
+ require('../models/ClientTypeEnum.cjs');
24
+ require('../models/WaasBackupOptionsEnum.cjs');
25
+ require('../models/BackupKeySharesToLocationsPendingResponse.cjs');
26
+ require('../models/ThresholdSignatureScheme.cjs');
27
+ require('../models/BackupKeySharesToLocationsResponse.cjs');
28
+ require('../models/JwtVerifiedCredentialFormatEnum.cjs');
29
+ require('../models/ProviderEnum.cjs');
30
+ require('../models/WalletAddressType.cjs');
31
+ require('../models/EcdsaValidatorOptions.cjs');
32
+ require('../models/EmbeddedWalletVersionEnum.cjs');
33
+ require('../models/HardwareWalletEnum.cjs');
34
+ require('../models/PasswordSourceTypeEnum.cjs');
35
+ require('../models/ProviderEntryPointVersionEnum.cjs');
36
+ require('../models/ProviderKernelVersionEnum.cjs');
37
+ require('../models/WaasWalletShareSetType.cjs');
38
+ require('../models/WalletProviderEnum.cjs');
39
+ require('../models/MfaBackupCodeAcknowledgement.cjs');
40
+ require('../models/CustomFieldType.cjs');
41
+ require('../models/KycFieldType.cjs');
42
+ require('../models/BillingSubscriptionPlanTypeEnum.cjs');
43
+ require('../models/UnprocessableEntityErrorCode.cjs');
44
+ require('../models/ChainalysisCheckResultEnum.cjs');
45
+ require('../models/DestinationTypeEnum.cjs');
46
+ require('../models/CheckoutModeEnum.cjs');
47
+ require('../models/SettlementStrategyEnum.cjs');
48
+ require('../models/CheckoutExecutionStateEnum.cjs');
49
+ require('../models/CheckoutRiskStateEnum.cjs');
50
+ require('../models/CheckoutSettlementStateEnum.cjs');
51
+ require('../models/CoinbaseOnrampBuyUrlExperience.cjs');
52
+ require('../models/CoinbaseOnrampFeeType.cjs');
53
+ require('../models/CoinbaseOnrampOrderPaymentMethod.cjs');
54
+ require('../models/CoinbaseOnrampOrderStatus.cjs');
55
+ require('../models/CoinbaseOnrampOrderPaymentLinkType.cjs');
56
+ require('../models/EmbeddedWalletChainEnum.cjs');
57
+ require('../models/EmbeddedWalletProviderEnum.cjs');
58
+ require('../models/RoomTypeEnum.cjs');
59
+ require('../models/TokenScopes.cjs');
60
+ require('../models/UserIdentifierTypeEnum.cjs');
61
+ require('../models/WaasChainEnum.cjs');
62
+ require('../models/CurrencyType.cjs');
63
+ require('../models/CustomHostnameStatusEnum.cjs');
64
+ require('../models/CustomHostnameUsageEnum.cjs');
65
+ require('../models/CustomHostnameVerificationType.cjs');
66
+ require('../models/DnsRecordType.cjs');
67
+ require('../models/DelegatedAccessEncryptionPublicKey.cjs');
68
+ require('../models/DelegatedShareDeliveryResponse.cjs');
69
+ require('../models/TokenScope.cjs');
70
+ require('../models/EmbeddedWalletAuthType.cjs');
71
+ require('../models/EmbeddedWalletSecurityMethod.cjs');
72
+ require('../models/EnvironmentEnum.cjs');
73
+ require('../models/Network.cjs');
74
+ require('../models/ExternalWalletFundingTokenRule.cjs');
75
+ require('../models/OnrampProviders.cjs');
76
+ require('../models/MinApiVersionEnum.cjs');
77
+ require('../models/SignInProviderEnum.cjs');
78
+ require('../models/SocialSignInProviderEnum.cjs');
79
+ require('../models/ProjectSettingsSdkWaasICloud.cjs');
80
+ require('../models/SdkViewSectionAlignment.cjs');
81
+ require('../models/SdkViewSectionType.cjs');
82
+ require('../models/SdkViewType.cjs');
83
+ require('../models/ZerodevBundlerProvider.cjs');
84
+ require('../models/ExportFormatEnum.cjs');
85
+ require('../models/ExportModelEnum.cjs');
86
+ require('../models/ExportStatusEnum.cjs');
87
+ require('../models/ExternalWalletFundingDefaultChain.cjs');
88
+ require('../models/GateRuleType.cjs');
89
+ require('../models/GetEVMSponsoredTransactionStatusResponse.cjs');
90
+ require('../models/PasskeyTransport.cjs');
91
+ require('../models/PasskeyCredentialHint.cjs');
92
+ require('../models/PasskeyCredentialType.cjs');
93
+ require('../models/PublicKeyCredentialType.cjs');
94
+ require('../models/GlobalWalletAccessControlTypeEnum.cjs');
95
+ require('../models/GlobalWalletConnectionStatusEnum.cjs');
96
+ require('../models/GrantActionEnum.cjs');
97
+ var GrantApproveRequest = require('../models/GrantApproveRequest.cjs');
98
+ var GrantApproveResponse = require('../models/GrantApproveResponse.cjs');
99
+ var GrantCodeRequest = require('../models/GrantCodeRequest.cjs');
100
+ var GrantCodeResponse = require('../models/GrantCodeResponse.cjs');
101
+ var GrantPeekResponse = require('../models/GrantPeekResponse.cjs');
102
+ var GrantTokenRequest = require('../models/GrantTokenRequest.cjs');
103
+ var GrantTokenResponse = require('../models/GrantTokenResponse.cjs');
104
+ require('../models/HealthcheckStatus.cjs');
105
+ require('../models/SdkEnvironmentIdWaasWalletIdAdditionalAddressesAdditionalAddresses.cjs');
106
+ require('../models/InlineObject2.cjs');
107
+ require('../models/InlineObject3.cjs');
108
+ require('../models/InlineObject4.cjs');
109
+ require('../models/InlineObject5.cjs');
110
+ require('../models/InviteStatusEnum.cjs');
111
+ require('../models/RoleEnum.cjs');
112
+ require('../models/JwtScope.cjs');
113
+ require('../models/MFAAction.cjs');
114
+ require('../models/NextViewEnum.cjs');
115
+ require('../models/OauthResultStatus.cjs');
116
+ require('../models/WhenToImplementEnum.cjs');
117
+ require('../models/PublishEventsEvents.cjs');
118
+ require('../models/SsoProviderEnum.cjs');
119
+ require('../models/SsoProviderCheckResponse.cjs');
120
+ require('../models/SubscriptionAdvancedScopeEnum.cjs');
121
+ require('../models/SubscriptionFreeScopeEnum.cjs');
122
+ require('../models/SwapQuoteRequest.cjs');
123
+ require('../models/SwapStatusResponse.cjs');
124
+ require('../models/UserFieldsCheckEnum.cjs');
125
+ require('../models/UserFilterableFieldsEnum.cjs');
126
+ require('../models/VisitorFilterableFieldsEnum.cjs');
127
+ require('../models/WaasDelegatedAccessEncryptionPublicKeyType.cjs');
128
+ require('../models/WaasDelegationCredentialsResponse.cjs');
129
+ require('../models/WaasPolicyConstraintCondition.cjs');
130
+ require('../models/WaasPolicyRuleType.cjs');
131
+ require('../models/WalletTransactionType.cjs');
132
+
133
+ /* tslint:disable */
134
+ /**
135
+ *
136
+ */
137
+ class ClientGrantApi extends runtime.BaseAPI {
138
+ /**
139
+ * Called by the dashboard authorize page on behalf of the authenticated user. Resolves a pending grant identified by `user_code`. Idempotent against the same user_code only while the grant is still pending.
140
+ * Approve or deny a pending client grant
141
+ */
142
+ async approveGrantRaw(requestParameters, initOverrides) {
143
+ if (requestParameters.grantApproveRequest === null || requestParameters.grantApproveRequest === undefined) {
144
+ throw new runtime.RequiredError('grantApproveRequest', 'Required parameter requestParameters.grantApproveRequest was null or undefined when calling approveGrant.');
145
+ }
146
+ const queryParameters = {};
147
+ const headerParameters = {};
148
+ headerParameters['Content-Type'] = 'application/json';
149
+ const response = await this.request({
150
+ path: `/auth/grant/approve`,
151
+ method: 'POST',
152
+ headers: headerParameters,
153
+ query: queryParameters,
154
+ body: GrantApproveRequest.GrantApproveRequestToJSON(requestParameters.grantApproveRequest),
155
+ }, initOverrides);
156
+ return new runtime.JSONApiResponse(response, (jsonValue) => GrantApproveResponse.GrantApproveResponseFromJSON(jsonValue));
157
+ }
158
+ /**
159
+ * Called by the dashboard authorize page on behalf of the authenticated user. Resolves a pending grant identified by `user_code`. Idempotent against the same user_code only while the grant is still pending.
160
+ * Approve or deny a pending client grant
161
+ */
162
+ async approveGrant(requestParameters, initOverrides) {
163
+ const response = await this.approveGrantRaw(requestParameters, initOverrides);
164
+ return await response.value();
165
+ }
166
+ /**
167
+ * Used by the dashboard authorize page to render `Authorize {clientName}?` before the user clicks Approve. Requires the dashboard user to be authenticated. Does NOT return the `grant_code` — only the metadata that\'s safe to display in a logged-in browser.
168
+ * Read public-safe metadata about a pending grant
169
+ */
170
+ async peekGrantRaw(requestParameters, initOverrides) {
171
+ if (requestParameters.userCode === null || requestParameters.userCode === undefined) {
172
+ throw new runtime.RequiredError('userCode', 'Required parameter requestParameters.userCode was null or undefined when calling peekGrant.');
173
+ }
174
+ const queryParameters = {};
175
+ if (requestParameters.userCode !== undefined) {
176
+ queryParameters['user_code'] = requestParameters.userCode;
177
+ }
178
+ const headerParameters = {};
179
+ const response = await this.request({
180
+ path: `/auth/grant/peek`,
181
+ method: 'GET',
182
+ headers: headerParameters,
183
+ query: queryParameters,
184
+ }, initOverrides);
185
+ return new runtime.JSONApiResponse(response, (jsonValue) => GrantPeekResponse.GrantPeekResponseFromJSON(jsonValue));
186
+ }
187
+ /**
188
+ * Used by the dashboard authorize page to render `Authorize {clientName}?` before the user clicks Approve. Requires the dashboard user to be authenticated. Does NOT return the `grant_code` — only the metadata that\'s safe to display in a logged-in browser.
189
+ * Read public-safe metadata about a pending grant
190
+ */
191
+ async peekGrant(requestParameters, initOverrides) {
192
+ const response = await this.peekGrantRaw(requestParameters, initOverrides);
193
+ return await response.value();
194
+ }
195
+ /**
196
+ * Polled by the client to check whether the grant has been approved or denied. Public — the `grant_code` itself is the proof of identity. Status follows RFC 8628 conventions: `authorization_pending`, `slow_down`, `approved`, `access_denied`, `expired_token`. On `approved`, the response includes the minted client JWT.
197
+ * Poll for the result of a client grant
198
+ */
199
+ async pollGrantTokenRaw(requestParameters, initOverrides) {
200
+ if (requestParameters.grantTokenRequest === null || requestParameters.grantTokenRequest === undefined) {
201
+ throw new runtime.RequiredError('grantTokenRequest', 'Required parameter requestParameters.grantTokenRequest was null or undefined when calling pollGrantToken.');
202
+ }
203
+ const queryParameters = {};
204
+ const headerParameters = {};
205
+ headerParameters['Content-Type'] = 'application/json';
206
+ const response = await this.request({
207
+ path: `/auth/grant/token`,
208
+ method: 'POST',
209
+ headers: headerParameters,
210
+ query: queryParameters,
211
+ body: GrantTokenRequest.GrantTokenRequestToJSON(requestParameters.grantTokenRequest),
212
+ }, initOverrides);
213
+ return new runtime.JSONApiResponse(response, (jsonValue) => GrantTokenResponse.GrantTokenResponseFromJSON(jsonValue));
214
+ }
215
+ /**
216
+ * Polled by the client to check whether the grant has been approved or denied. Public — the `grant_code` itself is the proof of identity. Status follows RFC 8628 conventions: `authorization_pending`, `slow_down`, `approved`, `access_denied`, `expired_token`. On `approved`, the response includes the minted client JWT.
217
+ * Poll for the result of a client grant
218
+ */
219
+ async pollGrantToken(requestParameters, initOverrides) {
220
+ const response = await this.pollGrantTokenRaw(requestParameters, initOverrides);
221
+ return await response.value();
222
+ }
223
+ /**
224
+ * Public — the caller has no credentials yet. Generates a `grant_code` (long secret used by the polling client) and a `user_code` (short code shown to the user for visual verification). Both are stored in Redis with a 15-minute TTL.
225
+ * Initiate a client grant request
226
+ */
227
+ async requestGrantCodeRaw(requestParameters, initOverrides) {
228
+ const queryParameters = {};
229
+ const headerParameters = {};
230
+ headerParameters['Content-Type'] = 'application/json';
231
+ const response = await this.request({
232
+ path: `/auth/grant/code`,
233
+ method: 'POST',
234
+ headers: headerParameters,
235
+ query: queryParameters,
236
+ body: GrantCodeRequest.GrantCodeRequestToJSON(requestParameters.grantCodeRequest),
237
+ }, initOverrides);
238
+ return new runtime.JSONApiResponse(response, (jsonValue) => GrantCodeResponse.GrantCodeResponseFromJSON(jsonValue));
239
+ }
240
+ /**
241
+ * Public — the caller has no credentials yet. Generates a `grant_code` (long secret used by the polling client) and a `user_code` (short code shown to the user for visual verification). Both are stored in Redis with a 15-minute TTL.
242
+ * Initiate a client grant request
243
+ */
244
+ async requestGrantCode(requestParameters = {}, initOverrides) {
245
+ const response = await this.requestGrantCodeRaw(requestParameters, initOverrides);
246
+ return await response.value();
247
+ }
248
+ }
249
+
250
+ exports.ClientGrantApi = ClientGrantApi;
@@ -0,0 +1,70 @@
1
+ /**
2
+ * Dashboard API
3
+ * Dashboard API documentation
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import * as runtime from '../runtime';
13
+ import { GrantApproveRequest, GrantApproveResponse, GrantCodeRequest, GrantCodeResponse, GrantPeekResponse, GrantTokenRequest, GrantTokenResponse } from '../models';
14
+ export interface ApproveGrantRequest {
15
+ grantApproveRequest: GrantApproveRequest;
16
+ }
17
+ export interface PeekGrantRequest {
18
+ userCode: string;
19
+ }
20
+ export interface PollGrantTokenRequest {
21
+ grantTokenRequest: GrantTokenRequest;
22
+ }
23
+ export interface RequestGrantCodeRequest {
24
+ grantCodeRequest?: GrantCodeRequest;
25
+ }
26
+ /**
27
+ *
28
+ */
29
+ export declare class ClientGrantApi extends runtime.BaseAPI {
30
+ /**
31
+ * Called by the dashboard authorize page on behalf of the authenticated user. Resolves a pending grant identified by `user_code`. Idempotent against the same user_code only while the grant is still pending.
32
+ * Approve or deny a pending client grant
33
+ */
34
+ approveGrantRaw(requestParameters: ApproveGrantRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<GrantApproveResponse>>;
35
+ /**
36
+ * Called by the dashboard authorize page on behalf of the authenticated user. Resolves a pending grant identified by `user_code`. Idempotent against the same user_code only while the grant is still pending.
37
+ * Approve or deny a pending client grant
38
+ */
39
+ approveGrant(requestParameters: ApproveGrantRequest, initOverrides?: RequestInit): Promise<GrantApproveResponse>;
40
+ /**
41
+ * Used by the dashboard authorize page to render `Authorize {clientName}?` before the user clicks Approve. Requires the dashboard user to be authenticated. Does NOT return the `grant_code` — only the metadata that\'s safe to display in a logged-in browser.
42
+ * Read public-safe metadata about a pending grant
43
+ */
44
+ peekGrantRaw(requestParameters: PeekGrantRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<GrantPeekResponse>>;
45
+ /**
46
+ * Used by the dashboard authorize page to render `Authorize {clientName}?` before the user clicks Approve. Requires the dashboard user to be authenticated. Does NOT return the `grant_code` — only the metadata that\'s safe to display in a logged-in browser.
47
+ * Read public-safe metadata about a pending grant
48
+ */
49
+ peekGrant(requestParameters: PeekGrantRequest, initOverrides?: RequestInit): Promise<GrantPeekResponse>;
50
+ /**
51
+ * Polled by the client to check whether the grant has been approved or denied. Public — the `grant_code` itself is the proof of identity. Status follows RFC 8628 conventions: `authorization_pending`, `slow_down`, `approved`, `access_denied`, `expired_token`. On `approved`, the response includes the minted client JWT.
52
+ * Poll for the result of a client grant
53
+ */
54
+ pollGrantTokenRaw(requestParameters: PollGrantTokenRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<GrantTokenResponse>>;
55
+ /**
56
+ * Polled by the client to check whether the grant has been approved or denied. Public — the `grant_code` itself is the proof of identity. Status follows RFC 8628 conventions: `authorization_pending`, `slow_down`, `approved`, `access_denied`, `expired_token`. On `approved`, the response includes the minted client JWT.
57
+ * Poll for the result of a client grant
58
+ */
59
+ pollGrantToken(requestParameters: PollGrantTokenRequest, initOverrides?: RequestInit): Promise<GrantTokenResponse>;
60
+ /**
61
+ * Public — the caller has no credentials yet. Generates a `grant_code` (long secret used by the polling client) and a `user_code` (short code shown to the user for visual verification). Both are stored in Redis with a 15-minute TTL.
62
+ * Initiate a client grant request
63
+ */
64
+ requestGrantCodeRaw(requestParameters: RequestGrantCodeRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<GrantCodeResponse>>;
65
+ /**
66
+ * Public — the caller has no credentials yet. Generates a `grant_code` (long secret used by the polling client) and a `user_code` (short code shown to the user for visual verification). Both are stored in Redis with a 15-minute TTL.
67
+ * Initiate a client grant request
68
+ */
69
+ requestGrantCode(requestParameters?: RequestGrantCodeRequest, initOverrides?: RequestInit): Promise<GrantCodeResponse>;
70
+ }
@@ -0,0 +1,246 @@
1
+ import { BaseAPI, RequiredError, JSONApiResponse } from '../runtime.js';
2
+ import '../models/AccessOutcomeEnum.js';
3
+ import '../models/ExchangeKeyEnum.js';
4
+ import '../models/AdminActionRequestStatus.js';
5
+ import '../models/AdminActionResponseDecision.js';
6
+ import '../models/AdminActionType.js';
7
+ import '../models/AuthStorageEnum.js';
8
+ import '../models/MFADeviceType.js';
9
+ import '../models/MFASettingsActions.js';
10
+ import '../models/TimeUnitEnum.js';
11
+ import '../models/ChainEnum.js';
12
+ import '../models/CheckoutSourceTypeEnum.js';
13
+ import '../models/AttestationConveyancePreference.js';
14
+ import '../models/AuthModeEnum.js';
15
+ import '../models/AuthenticatorAttachment.js';
16
+ import '../models/ResidentKeyRequirement.js';
17
+ import '../models/UserVerificationRequirement.js';
18
+ import '../models/AuthenticatorTransportProtocol.js';
19
+ import '../models/ClientTypeEnum.js';
20
+ import '../models/WaasBackupOptionsEnum.js';
21
+ import '../models/BackupKeySharesToLocationsPendingResponse.js';
22
+ import '../models/ThresholdSignatureScheme.js';
23
+ import '../models/BackupKeySharesToLocationsResponse.js';
24
+ import '../models/JwtVerifiedCredentialFormatEnum.js';
25
+ import '../models/ProviderEnum.js';
26
+ import '../models/WalletAddressType.js';
27
+ import '../models/EcdsaValidatorOptions.js';
28
+ import '../models/EmbeddedWalletVersionEnum.js';
29
+ import '../models/HardwareWalletEnum.js';
30
+ import '../models/PasswordSourceTypeEnum.js';
31
+ import '../models/ProviderEntryPointVersionEnum.js';
32
+ import '../models/ProviderKernelVersionEnum.js';
33
+ import '../models/WaasWalletShareSetType.js';
34
+ import '../models/WalletProviderEnum.js';
35
+ import '../models/MfaBackupCodeAcknowledgement.js';
36
+ import '../models/CustomFieldType.js';
37
+ import '../models/KycFieldType.js';
38
+ import '../models/BillingSubscriptionPlanTypeEnum.js';
39
+ import '../models/UnprocessableEntityErrorCode.js';
40
+ import '../models/ChainalysisCheckResultEnum.js';
41
+ import '../models/DestinationTypeEnum.js';
42
+ import '../models/CheckoutModeEnum.js';
43
+ import '../models/SettlementStrategyEnum.js';
44
+ import '../models/CheckoutExecutionStateEnum.js';
45
+ import '../models/CheckoutRiskStateEnum.js';
46
+ import '../models/CheckoutSettlementStateEnum.js';
47
+ import '../models/CoinbaseOnrampBuyUrlExperience.js';
48
+ import '../models/CoinbaseOnrampFeeType.js';
49
+ import '../models/CoinbaseOnrampOrderPaymentMethod.js';
50
+ import '../models/CoinbaseOnrampOrderStatus.js';
51
+ import '../models/CoinbaseOnrampOrderPaymentLinkType.js';
52
+ import '../models/EmbeddedWalletChainEnum.js';
53
+ import '../models/EmbeddedWalletProviderEnum.js';
54
+ import '../models/RoomTypeEnum.js';
55
+ import '../models/TokenScopes.js';
56
+ import '../models/UserIdentifierTypeEnum.js';
57
+ import '../models/WaasChainEnum.js';
58
+ import '../models/CurrencyType.js';
59
+ import '../models/CustomHostnameStatusEnum.js';
60
+ import '../models/CustomHostnameUsageEnum.js';
61
+ import '../models/CustomHostnameVerificationType.js';
62
+ import '../models/DnsRecordType.js';
63
+ import '../models/DelegatedAccessEncryptionPublicKey.js';
64
+ import '../models/DelegatedShareDeliveryResponse.js';
65
+ import '../models/TokenScope.js';
66
+ import '../models/EmbeddedWalletAuthType.js';
67
+ import '../models/EmbeddedWalletSecurityMethod.js';
68
+ import '../models/EnvironmentEnum.js';
69
+ import '../models/Network.js';
70
+ import '../models/ExternalWalletFundingTokenRule.js';
71
+ import '../models/OnrampProviders.js';
72
+ import '../models/MinApiVersionEnum.js';
73
+ import '../models/SignInProviderEnum.js';
74
+ import '../models/SocialSignInProviderEnum.js';
75
+ import '../models/ProjectSettingsSdkWaasICloud.js';
76
+ import '../models/SdkViewSectionAlignment.js';
77
+ import '../models/SdkViewSectionType.js';
78
+ import '../models/SdkViewType.js';
79
+ import '../models/ZerodevBundlerProvider.js';
80
+ import '../models/ExportFormatEnum.js';
81
+ import '../models/ExportModelEnum.js';
82
+ import '../models/ExportStatusEnum.js';
83
+ import '../models/ExternalWalletFundingDefaultChain.js';
84
+ import '../models/GateRuleType.js';
85
+ import '../models/GetEVMSponsoredTransactionStatusResponse.js';
86
+ import '../models/PasskeyTransport.js';
87
+ import '../models/PasskeyCredentialHint.js';
88
+ import '../models/PasskeyCredentialType.js';
89
+ import '../models/PublicKeyCredentialType.js';
90
+ import '../models/GlobalWalletAccessControlTypeEnum.js';
91
+ import '../models/GlobalWalletConnectionStatusEnum.js';
92
+ import '../models/GrantActionEnum.js';
93
+ import { GrantApproveRequestToJSON } from '../models/GrantApproveRequest.js';
94
+ import { GrantApproveResponseFromJSON } from '../models/GrantApproveResponse.js';
95
+ import { GrantCodeRequestToJSON } from '../models/GrantCodeRequest.js';
96
+ import { GrantCodeResponseFromJSON } from '../models/GrantCodeResponse.js';
97
+ import { GrantPeekResponseFromJSON } from '../models/GrantPeekResponse.js';
98
+ import { GrantTokenRequestToJSON } from '../models/GrantTokenRequest.js';
99
+ import { GrantTokenResponseFromJSON } from '../models/GrantTokenResponse.js';
100
+ import '../models/HealthcheckStatus.js';
101
+ import '../models/SdkEnvironmentIdWaasWalletIdAdditionalAddressesAdditionalAddresses.js';
102
+ import '../models/InlineObject2.js';
103
+ import '../models/InlineObject3.js';
104
+ import '../models/InlineObject4.js';
105
+ import '../models/InlineObject5.js';
106
+ import '../models/InviteStatusEnum.js';
107
+ import '../models/RoleEnum.js';
108
+ import '../models/JwtScope.js';
109
+ import '../models/MFAAction.js';
110
+ import '../models/NextViewEnum.js';
111
+ import '../models/OauthResultStatus.js';
112
+ import '../models/WhenToImplementEnum.js';
113
+ import '../models/PublishEventsEvents.js';
114
+ import '../models/SsoProviderEnum.js';
115
+ import '../models/SsoProviderCheckResponse.js';
116
+ import '../models/SubscriptionAdvancedScopeEnum.js';
117
+ import '../models/SubscriptionFreeScopeEnum.js';
118
+ import '../models/SwapQuoteRequest.js';
119
+ import '../models/SwapStatusResponse.js';
120
+ import '../models/UserFieldsCheckEnum.js';
121
+ import '../models/UserFilterableFieldsEnum.js';
122
+ import '../models/VisitorFilterableFieldsEnum.js';
123
+ import '../models/WaasDelegatedAccessEncryptionPublicKeyType.js';
124
+ import '../models/WaasDelegationCredentialsResponse.js';
125
+ import '../models/WaasPolicyConstraintCondition.js';
126
+ import '../models/WaasPolicyRuleType.js';
127
+ import '../models/WalletTransactionType.js';
128
+
129
+ /* tslint:disable */
130
+ /**
131
+ *
132
+ */
133
+ class ClientGrantApi extends BaseAPI {
134
+ /**
135
+ * Called by the dashboard authorize page on behalf of the authenticated user. Resolves a pending grant identified by `user_code`. Idempotent against the same user_code only while the grant is still pending.
136
+ * Approve or deny a pending client grant
137
+ */
138
+ async approveGrantRaw(requestParameters, initOverrides) {
139
+ if (requestParameters.grantApproveRequest === null || requestParameters.grantApproveRequest === undefined) {
140
+ throw new RequiredError('grantApproveRequest', 'Required parameter requestParameters.grantApproveRequest was null or undefined when calling approveGrant.');
141
+ }
142
+ const queryParameters = {};
143
+ const headerParameters = {};
144
+ headerParameters['Content-Type'] = 'application/json';
145
+ const response = await this.request({
146
+ path: `/auth/grant/approve`,
147
+ method: 'POST',
148
+ headers: headerParameters,
149
+ query: queryParameters,
150
+ body: GrantApproveRequestToJSON(requestParameters.grantApproveRequest),
151
+ }, initOverrides);
152
+ return new JSONApiResponse(response, (jsonValue) => GrantApproveResponseFromJSON(jsonValue));
153
+ }
154
+ /**
155
+ * Called by the dashboard authorize page on behalf of the authenticated user. Resolves a pending grant identified by `user_code`. Idempotent against the same user_code only while the grant is still pending.
156
+ * Approve or deny a pending client grant
157
+ */
158
+ async approveGrant(requestParameters, initOverrides) {
159
+ const response = await this.approveGrantRaw(requestParameters, initOverrides);
160
+ return await response.value();
161
+ }
162
+ /**
163
+ * Used by the dashboard authorize page to render `Authorize {clientName}?` before the user clicks Approve. Requires the dashboard user to be authenticated. Does NOT return the `grant_code` — only the metadata that\'s safe to display in a logged-in browser.
164
+ * Read public-safe metadata about a pending grant
165
+ */
166
+ async peekGrantRaw(requestParameters, initOverrides) {
167
+ if (requestParameters.userCode === null || requestParameters.userCode === undefined) {
168
+ throw new RequiredError('userCode', 'Required parameter requestParameters.userCode was null or undefined when calling peekGrant.');
169
+ }
170
+ const queryParameters = {};
171
+ if (requestParameters.userCode !== undefined) {
172
+ queryParameters['user_code'] = requestParameters.userCode;
173
+ }
174
+ const headerParameters = {};
175
+ const response = await this.request({
176
+ path: `/auth/grant/peek`,
177
+ method: 'GET',
178
+ headers: headerParameters,
179
+ query: queryParameters,
180
+ }, initOverrides);
181
+ return new JSONApiResponse(response, (jsonValue) => GrantPeekResponseFromJSON(jsonValue));
182
+ }
183
+ /**
184
+ * Used by the dashboard authorize page to render `Authorize {clientName}?` before the user clicks Approve. Requires the dashboard user to be authenticated. Does NOT return the `grant_code` — only the metadata that\'s safe to display in a logged-in browser.
185
+ * Read public-safe metadata about a pending grant
186
+ */
187
+ async peekGrant(requestParameters, initOverrides) {
188
+ const response = await this.peekGrantRaw(requestParameters, initOverrides);
189
+ return await response.value();
190
+ }
191
+ /**
192
+ * Polled by the client to check whether the grant has been approved or denied. Public — the `grant_code` itself is the proof of identity. Status follows RFC 8628 conventions: `authorization_pending`, `slow_down`, `approved`, `access_denied`, `expired_token`. On `approved`, the response includes the minted client JWT.
193
+ * Poll for the result of a client grant
194
+ */
195
+ async pollGrantTokenRaw(requestParameters, initOverrides) {
196
+ if (requestParameters.grantTokenRequest === null || requestParameters.grantTokenRequest === undefined) {
197
+ throw new RequiredError('grantTokenRequest', 'Required parameter requestParameters.grantTokenRequest was null or undefined when calling pollGrantToken.');
198
+ }
199
+ const queryParameters = {};
200
+ const headerParameters = {};
201
+ headerParameters['Content-Type'] = 'application/json';
202
+ const response = await this.request({
203
+ path: `/auth/grant/token`,
204
+ method: 'POST',
205
+ headers: headerParameters,
206
+ query: queryParameters,
207
+ body: GrantTokenRequestToJSON(requestParameters.grantTokenRequest),
208
+ }, initOverrides);
209
+ return new JSONApiResponse(response, (jsonValue) => GrantTokenResponseFromJSON(jsonValue));
210
+ }
211
+ /**
212
+ * Polled by the client to check whether the grant has been approved or denied. Public — the `grant_code` itself is the proof of identity. Status follows RFC 8628 conventions: `authorization_pending`, `slow_down`, `approved`, `access_denied`, `expired_token`. On `approved`, the response includes the minted client JWT.
213
+ * Poll for the result of a client grant
214
+ */
215
+ async pollGrantToken(requestParameters, initOverrides) {
216
+ const response = await this.pollGrantTokenRaw(requestParameters, initOverrides);
217
+ return await response.value();
218
+ }
219
+ /**
220
+ * Public — the caller has no credentials yet. Generates a `grant_code` (long secret used by the polling client) and a `user_code` (short code shown to the user for visual verification). Both are stored in Redis with a 15-minute TTL.
221
+ * Initiate a client grant request
222
+ */
223
+ async requestGrantCodeRaw(requestParameters, initOverrides) {
224
+ const queryParameters = {};
225
+ const headerParameters = {};
226
+ headerParameters['Content-Type'] = 'application/json';
227
+ const response = await this.request({
228
+ path: `/auth/grant/code`,
229
+ method: 'POST',
230
+ headers: headerParameters,
231
+ query: queryParameters,
232
+ body: GrantCodeRequestToJSON(requestParameters.grantCodeRequest),
233
+ }, initOverrides);
234
+ return new JSONApiResponse(response, (jsonValue) => GrantCodeResponseFromJSON(jsonValue));
235
+ }
236
+ /**
237
+ * Public — the caller has no credentials yet. Generates a `grant_code` (long secret used by the polling client) and a `user_code` (short code shown to the user for visual verification). Both are stored in Redis with a 15-minute TTL.
238
+ * Initiate a client grant request
239
+ */
240
+ async requestGrantCode(requestParameters = {}, initOverrides) {
241
+ const response = await this.requestGrantCodeRaw(requestParameters, initOverrides);
242
+ return await response.value();
243
+ }
244
+ }
245
+
246
+ export { ClientGrantApi };