Skip to content

Commit 1866bf5

Browse files
speakeasybotflemzord
authored andcommitted
ci: regenerated with OpenAPI Doc , Speakeasy CLI 1.441.1
1 parent 7327ec3 commit 1866bf5

File tree

686 files changed

+16422
-779
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

686 files changed

+16422
-779
lines changed

.speakeasy/gen.lock

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
lockVersion: 2.0.0
22
id: 2bb10af9-e48a-4bd7-ae46-a35fa809dc29
33
management:
4-
docChecksum: 44df9207611e89976d823f6df231ee2b
5-
docVersion: v2.1.0
6-
speakeasyVersion: 1.423.2
7-
generationVersion: 2.442.11
8-
releaseVersion: 3.2.0
9-
configChecksum: 575d7b5c8980c281c3fabe5cea2df460
4+
docChecksum: 1cad063828c35998ccfdb3484f3caab0
5+
docVersion: v2.1.1
6+
speakeasyVersion: 1.441.1
7+
generationVersion: 2.461.2
8+
releaseVersion: 3.3.0
9+
configChecksum: d24e401f87ab901cffa5338c63b86c93
1010
repoURL: https://github.com/formancehq/formance-sdk-typescript.git
1111
repoSubDirectory: .
1212
installationURL: https://github.com/formancehq/formance-sdk-typescript
@@ -16,13 +16,13 @@ features:
1616
additionalDependencies: 0.1.0
1717
bigint: 0.0.2
1818
constsAndDefaults: 0.1.11
19-
core: 3.18.2
19+
core: 3.18.6
2020
defaultEnabledRetries: 0.1.0
2121
deprecations: 2.81.1
2222
downloadStreams: 0.1.1
2323
enumUnions: 0.1.0
24-
envVarSecurityUsage: 0.1.1
25-
errors: 2.82.3
24+
envVarSecurityUsage: 0.1.2
25+
errors: 2.84.0
2626
globalSecurity: 2.82.11
2727
globalSecurityCallbacks: 0.1.0
2828
globalServerURLs: 2.82.4
@@ -32,9 +32,9 @@ features:
3232
oauth2ClientCredentials: 0.2.0
3333
responseFormat: 0.2.3
3434
retries: 2.83.0
35-
sdkHooks: 0.1.0
35+
sdkHooks: 0.2.0
3636
tests: 0.7.0
37-
unions: 2.85.7
37+
unions: 2.85.8
3838
generatedFiles:
3939
- .eslintrc.cjs
4040
- .gitattributes

.speakeasy/workflow.lock

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,20 @@
1-
speakeasyVersion: 1.423.2
1+
speakeasyVersion: 1.441.1
22
sources:
33
my-source:
44
sourceNamespace: my-source
5-
sourceRevisionDigest: sha256:f7d12f6c5cf7d4194f89dfd4988c48f12d8c34cf5902bbe96dfb886229b3f1b3
6-
sourceBlobDigest: sha256:27a152e061a648cc77e2c103a656a64e8d4b64a319df8d5af09c5ec798094f3e
5+
sourceRevisionDigest: sha256:25a113054c1e72e39f72b3f651ae9571df6083225130cdf314c099507d9a6d39
6+
sourceBlobDigest: sha256:3e23c263761e5f072ed5b6c1218d39286188d47c0eca9823a5ecb64be3a02d57
77
tags:
88
- latest
9-
- main
9+
- speakeasy-sdk-regen-1732202930
1010
targets:
1111
formance-sdk-typescript:
1212
source: my-source
1313
sourceNamespace: my-source
14-
sourceRevisionDigest: sha256:f7d12f6c5cf7d4194f89dfd4988c48f12d8c34cf5902bbe96dfb886229b3f1b3
15-
sourceBlobDigest: sha256:27a152e061a648cc77e2c103a656a64e8d4b64a319df8d5af09c5ec798094f3e
14+
sourceRevisionDigest: sha256:25a113054c1e72e39f72b3f651ae9571df6083225130cdf314c099507d9a6d39
15+
sourceBlobDigest: sha256:3e23c263761e5f072ed5b6c1218d39286188d47c0eca9823a5ecb64be3a02d57
1616
codeSamplesNamespace: my-source-code-samples
17-
codeSamplesRevisionDigest: sha256:11ba30e10ccf413d0785a74ac758ebee32553f88bf8b3509f26df212a821e84a
17+
codeSamplesRevisionDigest: sha256:742392eb0d92e98b50315d6fddf26dfb71a3add09553a08412d18982efc85d10
1818
workflow:
1919
workflowVersion: 1.0.0
2020
speakeasyVersion: latest

README.md

Lines changed: 17 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -366,10 +366,10 @@ If a HTTP request fails, an operation my also throw an error from the `sdk/model
366366

367367
In addition, when custom error responses are specified for an operation, the SDK may throw their associated Error type. You can refer to respective *Errors* tables in SDK docs for more details on possible error types for each operation. For example, the `createTransactions` method may throw the following errors:
368368

369-
| Error Type | Status Code | Content Type |
370-
| -------------------- | -------------------- | -------------------- |
371-
| errors.ErrorResponse | default | application/json |
372-
| errors.SDKError | 4XX, 5XX | \*/\* |
369+
| Error Type | Status Code | Content Type |
370+
| -------------------- | ----------- | ---------------- |
371+
| errors.ErrorResponse | default | application/json |
372+
| errors.SDKError | 4XX, 5XX | \*/\* |
373373

374374
```typescript
375375
import { SDK } from "@formance/formance-sdk";
@@ -442,12 +442,16 @@ Validation errors can also occur when either method arguments or data returned f
442442

443443
### Select Server by Index
444444

445-
You can override the default server globally by passing a server index to the `serverIdx` optional parameter when initializing the SDK client instance. The selected server will then be used as the default on the operations that use it. This table lists the indexes associated with the available servers:
445+
You can override the default server globally by passing a server index to the `serverIdx: number` optional parameter when initializing the SDK client instance. The selected server will then be used as the default on the operations that use it. This table lists the indexes associated with the available servers:
446446

447-
| # | Server | Variables |
448-
| - | ------ | --------- |
449-
| 0 | `http://localhost` | None |
450-
| 1 | `https://{organization}.{environment}.formance.cloud` | `environment` (default is `sandbox`), `organization` (default is `orgID-stackID`) |
447+
| # | Server | Variables | Default values |
448+
| --- | ----------------------------------------------------- | ------------------------------------------------------------------ | --------------------------------- |
449+
| 0 | `http://localhost` | | |
450+
| 1 | `https://{organization}.{environment}.formance.cloud` | `environment: models.ServerEnvironment`<br/>`organization: string` | `"sandbox"`<br/>`"orgID-stackID"` |
451+
452+
If the selected server has variables, you may override their default values through the additional parameters made available in the SDK constructor.
453+
454+
#### Example
451455

452456
```typescript
453457
import { SDK } from "@formance/formance-sdk";
@@ -471,16 +475,9 @@ run();
471475

472476
```
473477

474-
#### Variables
475-
476-
Some of the server options above contain variables. If you want to set the values of those variables, the following optional parameters are available when initializing the SDK client instance:
477-
* `environment: models.ServerEnvironment`
478-
* `organization: string`
479-
480478
### Override Server URL Per-Client
481479

482-
The default server can also be overridden globally by passing a URL to the `serverURL` optional parameter when initializing the SDK client instance. For example:
483-
480+
The default server can also be overridden globally by passing a URL to the `serverURL: string` optional parameter when initializing the SDK client instance. For example:
484481
```typescript
485482
import { SDK } from "@formance/formance-sdk";
486483

@@ -560,9 +557,9 @@ const sdk = new SDK({ httpClient });
560557

561558
This SDK supports the following security scheme globally:
562559

563-
| Name | Type | Scheme |
564-
| ------------------------------ | ------------------------------ | ------------------------------ |
565-
| `clientID` `clientSecret` | oauth2 | OAuth2 Client Credentials Flow |
560+
| Name | Type | Scheme |
561+
| ----------------------------- | ------ | ------------------------------ |
562+
| `clientID`<br/>`clientSecret` | oauth2 | OAuth2 Client Credentials Flow |
566563

567564
You can set the security parameters through the `security` optional parameter when initializing the SDK client instance. For example:
568565
```typescript

RELEASES.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -226,4 +226,14 @@ Based on:
226226
### Generated
227227
- [typescript v3.2.0] .
228228
### Releases
229-
- [NPM v3.2.0] https://www.npmjs.com/package/@formance/formance-sdk/v/3.2.0 - .
229+
- [NPM v3.2.0] https://www.npmjs.com/package/@formance/formance-sdk/v/3.2.0 - .
230+
231+
## 2024-11-21 15:28:45
232+
### Changes
233+
Based on:
234+
- OpenAPI Doc
235+
- Speakeasy CLI 1.441.1 (2.461.2) https://github.com/speakeasy-api/speakeasy
236+
### Generated
237+
- [typescript v3.3.0] .
238+
### Releases
239+
- [NPM v3.3.0] https://www.npmjs.com/package/@formance/formance-sdk/v/3.3.0 - .

gen.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,19 @@ generation:
99
requestResponseComponentNamesFeb2024: false
1010
auth:
1111
oAuth2ClientCredentialsEnabled: true
12+
oAuth2PasswordEnabled: false
1213
comments: {}
1314
telemetryEnabled: false
1415
typescript:
15-
version: 3.2.0
16+
version: 3.3.0
1617
additionalDependencies:
1718
dependencies: {}
1819
devDependencies: {}
1920
peerDependencies: {}
2021
additionalPackageJSON: {}
2122
author: Formance
2223
clientServerStatusCodesAsErrors: false
24+
defaultErrorName: SDKError
2325
enumFormat: enum
2426
flattenGlobalSecurity: true
2527
flatteningOrder: body-first

jsr.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
{
44
"name": "@formance/formance-sdk",
5-
"version": "3.2.0",
5+
"version": "3.3.0",
66
"exports": {
77
".": "./src/index.ts",
88
"./sdk/models/errors": "./src/sdk/models/errors/index.ts",

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@formance/formance-sdk",
3-
"version": "3.2.0",
3+
"version": "3.3.0",
44
"author": "Formance",
55
"main": "./index.js",
66
"sideEffects": false,

src/funcs/authV1CreateClient.ts

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -63,12 +63,20 @@ export async function authV1CreateClient(
6363
});
6464

6565
const securityInput = await extractSecurity(client._options.security);
66+
const requestSecurity = resolveGlobalSecurity(securityInput);
67+
6668
const context = {
6769
operationID: "createClient",
6870
oAuth2Scopes: ["auth:read", "auth:write"],
71+
72+
resolvedSecurity: requestSecurity,
73+
6974
securitySource: client._options.security,
75+
retryConfig: options?.retries
76+
|| client._options.retryConfig
77+
|| { strategy: "none" },
78+
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
7079
};
71-
const requestSecurity = resolveGlobalSecurity(securityInput);
7280

7381
const requestRes = client._createRequest(context, {
7482
security: requestSecurity,
@@ -86,9 +94,8 @@ export async function authV1CreateClient(
8694
const doResult = await client._do(req, {
8795
context,
8896
errorCodes: ["default"],
89-
retryConfig: options?.retries
90-
|| client._options.retryConfig,
91-
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
97+
retryConfig: context.retryConfig,
98+
retryCodes: context.retryCodes,
9299
});
93100
if (!doResult.ok) {
94101
return doResult;

src/funcs/authV1CreateSecret.ts

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -68,12 +68,20 @@ export async function authV1CreateSecret(
6868
});
6969

7070
const securityInput = await extractSecurity(client._options.security);
71+
const requestSecurity = resolveGlobalSecurity(securityInput);
72+
7173
const context = {
7274
operationID: "createSecret",
7375
oAuth2Scopes: ["auth:read", "auth:write"],
76+
77+
resolvedSecurity: requestSecurity,
78+
7479
securitySource: client._options.security,
80+
retryConfig: options?.retries
81+
|| client._options.retryConfig
82+
|| { strategy: "none" },
83+
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
7584
};
76-
const requestSecurity = resolveGlobalSecurity(securityInput);
7785

7886
const requestRes = client._createRequest(context, {
7987
security: requestSecurity,
@@ -91,9 +99,8 @@ export async function authV1CreateSecret(
9199
const doResult = await client._do(req, {
92100
context,
93101
errorCodes: ["default"],
94-
retryConfig: options?.retries
95-
|| client._options.retryConfig,
96-
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
102+
retryConfig: context.retryConfig,
103+
retryCodes: context.retryCodes,
97104
});
98105
if (!doResult.ok) {
99106
return doResult;

0 commit comments

Comments
 (0)