Skip to content

Commit 59d5604

Browse files
author
NumaryBot
committed
release(sdk): v2.0.0-beta.5
1 parent ea688eb commit 59d5604

File tree

1,149 files changed

+48541
-16288
lines changed

Some content is hidden

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

1,149 files changed

+48541
-16288
lines changed

.gitattributes

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# This allows generated code to be indexed correctly
2+
*.ts linguist-generated=false

.github/workflows/speakeasy_sdk_publish.yml

Lines changed: 32 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -2,43 +2,46 @@ name: Publish
22
"on":
33
push:
44
branches:
5-
- main
6-
# paths:
7-
# - RELEASES.md
5+
- release/v*.*.*
6+
- release/v*.*.*-alpha.*
7+
- release/v*.*.*-beta.*
8+
- release/v*.*.*-rc.*version
89
jobs:
910
Release:
1011
name: 'Release'
1112
runs-on: ubuntu-latest
1213
steps:
13-
- uses: actions/checkout@v3
14-
- name: Get version from gen.yaml
15-
id: get_version
16-
uses: mikefarah/yq@master
17-
with:
18-
cmd: yq '.typescript.version' gen.yaml
19-
- name: Create Release
20-
id: create_release
21-
uses: actions/create-release@v1
22-
env:
23-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token
24-
with:
25-
tag_name: ${{ steps.get_version.outputs.result }}
26-
release_name: Release ${{ steps.get_version.outputs.result }}
27-
draft: false
28-
prerelease: false
14+
- uses: actions/checkout@v4
15+
- name: Extract branch name
16+
shell: bash
17+
run: echo "branch=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/release/}}" >> $GITHUB_OUTPUT
18+
id: extract_branch
19+
- name: Create Release
20+
id: create_release
21+
uses: actions/create-release@v1
22+
env:
23+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token
24+
with:
25+
tag_name: ${{ steps.extract_branch.outputs.branch }}
26+
release_name: Release ${{ steps.extract_branch.outputs.branch }}
27+
draft: false
28+
prerelease: false
29+
- run: gh repo edit --default-branch=release/${{ steps.extract_branch.outputs.branch }}
30+
env:
31+
GITHUB_TOKEN: ${{ secrets.NUMARY_GITHUB_TOKEN }}
2932

3033
Publish:
3134
name: 'Publish'
32-
needs:
35+
needs:
3336
- Release
3437
runs-on: ubuntu-latest
3538
steps:
36-
- uses: actions/checkout@v3
37-
- uses: actions/setup-node@v3
38-
with:
39-
node-version: '16.x'
40-
registry-url: 'https://registry.npmjs.org'
41-
- run: npm ci
42-
- run: npm publish --access public
43-
env:
44-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
39+
- uses: actions/checkout@v3
40+
- uses: actions/setup-node@v3
41+
with:
42+
node-version: '18.x'
43+
registry-url: 'https://registry.npmjs.org'
44+
- run: npm ci
45+
- run: npm publish --access public
46+
env:
47+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2023 Formance, Inc
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 356 additions & 138 deletions
Large diffs are not rendered by default.

RELEASES.md

Lines changed: 0 additions & 5 deletions
This file was deleted.

USAGE.md

Lines changed: 16 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,22 @@
11
<!-- Start SDK Example Usage -->
2+
3+
24
```typescript
3-
import { Formance } from "@formance/formance-sdk";
4-
import { GetVersionsResponse } from "@formance/formance-sdk/dist/sdk/models/operations";
5+
import { SDK } from "@formance/formance-sdk";
6+
7+
(async () => {
8+
const sdk = new SDK({
9+
security: {
10+
authorization: "",
11+
},
12+
});
13+
14+
const res = await sdk.sdk.getVersions();
515

6-
const sdk = new Formance({
7-
security: {
8-
authorization: "Bearer YOUR_ACCESS_TOKEN_HERE",
9-
},
10-
});
16+
if (res.statusCode == 200) {
17+
// handle response
18+
}
19+
})();
1120

12-
sdk.getVersions().then((res: GetVersionsResponse) => {
13-
if (res.statusCode == 200) {
14-
// handle response
15-
}
16-
});
1721
```
1822
<!-- End SDK Example Usage -->

0 commit comments

Comments
 (0)