Skip to content

chore: upgrade speakeasy version #969

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 13, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -33,18 +33,18 @@
f { pkgs = pkgs; system = system; }
);

speakeasyVersion = "1.517.3";
speakeasyVersion = "1.563.0";
speakeasyPlatforms = {
"x86_64-linux" = "linux_amd64";
"aarch64-linux" = "linux_arm64";
"x86_64-darwin" = "darwin_amd64";
"aarch64-darwin" = "darwin_arm64";
};
speakeasyHashes = {
"x86_64-linux" = "f5b1e296fc03ae6ebb9488009ebe2c5b5c3dd97d1201b12463c706e742dc4eff";
"aarch64-linux" = "fd20b2dfc95f3ee69b7e8c7a589e7cc0a3897671c5e24f4b0d2e7d2eec4ef8f3";
"x86_64-darwin" = "0103f08780b6bc7c4fe9a84e03e197345aba96205da5dd394eb6ac0667431b65";
"aarch64-darwin" = "70a7e3abddb08ec105be2923bc8423d63033a91367ef2f4545965f13e97714b3";
"x86_64-linux" = "632559a6bdc765ef42b81b8404fd0a3e5023919a0bb70ff7e40a8cc259545afd";
"aarch64-linux" = "c74c502df3a05a2d69e6b282886df23354a319d0510d2c1a21fcc124b7ad00efGOROOT";
"x86_64-darwin" = "8814be1fdd4eaf6dcc7fb251ede5693e1d3d4c8e03986f8d37bfd59e049698b9";
"aarch64-darwin" = "12c20fa485de4725c9730cb2e8936cab4b0961d0a956e9f4c45534371f2a6148";
Comment on lines +44 to +47
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Malformed SHA256 for aarch64-linux will cause Nix build failures
c74c502df3a05a2d69e6b282886df23354a319d0510d2c1a21fcc124b7ad00efGOROOT is 71 chars and contains non-hex text (GOROOT). Nix will reject this derivation.

-        "aarch64-linux"  = "c74c502df3a05a2d69e6b282886df23354a319d0510d2c1a21fcc124b7ad00efGOROOT";
+        # TODO: replace with the correct 64-char hex digest for v1.563.0
+        "aarch64-linux"  = "<correct_sha256_here>";

Re-download the artifact and compute the hash:

nix hash file speakeasy_linux_arm64.zip
🤖 Prompt for AI Agents
In flake.nix around lines 44 to 47, the SHA256 hash for "aarch64-linux" is
malformed because it contains non-hex characters and is too long, causing Nix
build failures. Re-download the corresponding artifact for the aarch64-linux
platform and compute the correct SHA256 hash using the command `nix hash file
<filename>`. Replace the incorrect hash string with the newly computed valid
SHA256 hash.

};

in
Expand Down
2 changes: 1 addition & 1 deletion pkg/client/.devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// README at: https://github.com/devcontainers/templates/tree/main/src/go
{
"name": "Go",
"image": "mcr.microsoft.com/devcontainers/go:1-1.20-bullseye",
"image": "mcr.microsoft.com/devcontainers/go:1-1.22-bullseye",
// Features to add to the dev container. More info: https://containers.dev/features.
// "features": {},
// Use 'forwardPorts' to make a list of ports inside the container available locally.
Expand Down
3 changes: 3 additions & 0 deletions pkg/client/.gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
.DS_Store
**/.speakeasy/temp/
**/.speakeasy/logs/
.speakeasy/reports
# .gitignore
158 changes: 66 additions & 92 deletions pkg/client/.speakeasy/gen.lock

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions pkg/client/.speakeasy/gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,20 +7,23 @@ generation:
maintainOpenAPIOrder: true
usageSnippets:
optionalPropertyRendering: withExample
sdkInitStyle: constructor
useClassNamesForArrayFields: true
fixes:
nameResolutionDec2023: true
nameResolutionFeb2025: false
parameterOrderingFeb2024: true
requestResponseComponentNamesFeb2024: true
securityFeb2025: false
sharedErrorComponentsApr2025: false
auth:
oAuth2ClientCredentialsEnabled: true
oAuth2PasswordEnabled: false
go:
version: 0.8.0
additionalDependencies: {}
allowUnknownFieldsInWeakUnions: false
baseErrorName: FormanceError
clientServerStatusCodesAsErrors: true
defaultErrorName: SDKError
envVarPrefix: FORMANCE
Expand Down
4 changes: 2 additions & 2 deletions pkg/client/.speakeasy/workflow.lock
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
speakeasyVersion: 1.517.3
speakeasyVersion: 1.563.0
sources: {}
targets:
formance:
source: Formance-OAS
workflow:
workflowVersion: 1.0.0
speakeasyVersion: v1.517.3
speakeasyVersion: v1.563.0
sources:
Formance-OAS:
inputs:
Expand Down
2 changes: 1 addition & 1 deletion pkg/client/.speakeasy/workflow.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
workflowVersion: 1.0.0
speakeasyVersion: v1.517.3
speakeasyVersion: v1.563.0
sources:
Formance-OAS:
inputs:
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@
| Field | Type | Required | Description |
| ------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------- |
| `HTTPMeta` | [components.HTTPMetadata](../../models/components/httpmetadata.md) | :heavy_check_mark: | N/A |
| `V2RevertTransactionResponse` | [*components.V2RevertTransactionResponse](../../models/components/v2reverttransactionresponse.md) | :heavy_minus_sign: | OK |
| `V2CreateTransactionResponse` | [*components.V2CreateTransactionResponse](../../models/components/v2createtransactionresponse.md) | :heavy_minus_sign: | OK |
42 changes: 4 additions & 38 deletions pkg/client/docs/sdks/v1/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -339,7 +339,6 @@ func main() {
},
Balance: client.Int64(2400),
Cursor: client.String("aHR0cHM6Ly9nLnBhZ2UvTmVrby1SYW1lbj9zaGFyZQ=="),
PaginationToken: client.String("aHR0cHM6Ly9nLnBhZ2UvTmVrby1SYW1lbj9zaGFyZQ=="),
})
if err != nil {
log.Fatal(err)
Expand Down Expand Up @@ -462,6 +461,8 @@ func main() {
Address: "users:001",
RequestBody: map[string]any{
"key": "<value>",
"key1": "<value>",
"key2": "<value>",
},
})
if err != nil {
Expand Down Expand Up @@ -581,18 +582,7 @@ func main() {

res, err := s.Ledger.V1.UpdateMapping(ctx, operations.UpdateMappingRequest{
Ledger: "ledger001",
Mapping: &components.Mapping{
Contracts: []components.Contract{
components.Contract{
Account: client.String("users:001"),
Expr: components.Expr{},
},
components.Contract{
Account: client.String("users:001"),
Expr: components.Expr{},
},
},
},
Mapping: nil,
})
if err != nil {
log.Fatal(err)
Expand Down Expand Up @@ -928,18 +918,6 @@ func main() {
Destination: "users:002",
Source: "users:001",
},
components.Posting{
Amount: big.NewInt(100),
Asset: "COIN",
Destination: "users:002",
Source: "users:001",
},
components.Posting{
Amount: big.NewInt(100),
Asset: "COIN",
Destination: "users:002",
Source: "users:001",
},
},
Script: &components.PostTransactionScript{
Plain: "vars {\n" +
Expand Down Expand Up @@ -1079,7 +1057,7 @@ func main() {
Ledger: "ledger001",
Txid: big.NewInt(1234),
RequestBody: map[string]any{
"key": "<value>",

},
})
if err != nil {
Expand Down Expand Up @@ -1212,18 +1190,6 @@ func main() {
Destination: "users:002",
Source: "users:001",
},
components.Posting{
Amount: big.NewInt(100),
Asset: "COIN",
Destination: "users:002",
Source: "users:001",
},
components.Posting{
Amount: big.NewInt(100),
Asset: "COIN",
Destination: "users:002",
Source: "users:001",
},
},
Reference: client.String("ref:001"),
},
Expand Down
34 changes: 16 additions & 18 deletions pkg/client/docs/sdks/v2/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,8 @@ func main() {
Cursor: client.String("aHR0cHM6Ly9nLnBhZ2UvTmVrby1SYW1lbj9zaGFyZQ=="),
RequestBody: map[string]any{
"key": "<value>",
"key1": "<value>",
"key2": "<value>",
},
})
if err != nil {
Expand Down Expand Up @@ -412,7 +414,6 @@ import(
"os"
"github.com/formancehq/ledger/pkg/client/models/components"
"github.com/formancehq/ledger/pkg/client"
"math/big"
"github.com/formancehq/ledger/pkg/client/models/operations"
"log"
)
Expand All @@ -433,9 +434,9 @@ func main() {
Atomic: client.Bool(true),
Parallel: client.Bool(true),
RequestBody: []components.V2BulkElement{
components.CreateV2BulkElementRevertTransaction(
components.V2BulkElementRevertTransaction{
Action: "<value>",
components.CreateV2BulkElementDeleteMetadata(
components.V2BulkElementDeleteMetadata{
Action: "DELETE_METADATA",
},
),
},
Expand Down Expand Up @@ -500,6 +501,7 @@ func main() {
Ledger: "ledger001",
RequestBody: map[string]any{
"key": "<value>",
"key1": "<value>",
},
})
if err != nil {
Expand Down Expand Up @@ -748,7 +750,7 @@ func main() {

res, err := s.Ledger.V2.DeleteAccountMetadata(ctx, operations.V2DeleteAccountMetadataRequest{
Ledger: "ledger001",
Address: "96609 Cummings Canyon",
Address: "6753 S Washington Street",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Verification agent

🧩 Analysis chain

Verify the address format change is intentional.

The address parameter changed from "users:001" to "6753 S Washington Street". This appears to be changing from an account identifier format to a physical street address, which may not be the intended format for the API's address parameter.


🏁 Script executed:

#!/bin/bash
# Description: Check other examples of address parameter usage in the documentation to verify the expected format

# Search for other DeleteAccountMetadata examples or address parameter usage
rg -A 5 -B 5 'Address.*"users:' pkg/client/docs/

Length of output: 5443


Ensure Address uses the correct account identifier format

The Address field in all other V1 and V2 client examples is treated as an account identifier (e.g. "users:001"), not a postal address. Replacing it with "6753 S Washington Street" is inconsistent and likely incorrect. Please clarify and update:

  • pkg/client/docs/sdks/v2/README.md line 753:
    • If the API still expects an account ID, revert to "users:001".
    • If you’ve intentionally changed Address to accept postal addresses, update all examples and the API docs to reflect this new format.
🤖 Prompt for AI Agents
In pkg/client/docs/sdks/v2/README.md at line 753, the Address parameter was
changed from an account identifier format like "users:001" to a physical street
address "6753 S Washington Street". Verify the intended format for the Address
parameter in the API. If the API expects an account identifier, revert the
Address value back to the original format "users:001". If the change to a postal
address is intentional, update all related examples and API documentation
consistently to reflect this new format.

Key: "foo",
})
if err != nil {
Expand Down Expand Up @@ -871,7 +873,6 @@ func main() {
Ledger: "ledger001",
RequestBody: map[string]any{
"key": "<value>",
"key1": "<value>",
},
})
if err != nil {
Expand Down Expand Up @@ -998,7 +999,6 @@ func main() {
res, err := s.Ledger.V2.CreateTransaction(ctx, operations.V2CreateTransactionRequest{
Ledger: "ledger001",
DryRun: client.Bool(true),
Force: client.Bool(true),
V2PostTransaction: components.V2PostTransaction{
Postings: []components.V2Posting{
components.V2Posting{
Expand All @@ -1007,12 +1007,6 @@ func main() {
Destination: "users:002",
Source: "users:001",
},
components.V2Posting{
Amount: big.NewInt(100),
Asset: "COIN",
Destination: "users:002",
Source: "users:001",
},
},
Script: &components.V2PostTransactionScript{
Plain: "vars {\n" +
Expand All @@ -1038,6 +1032,9 @@ func main() {
"key1": map[string]string{
"admin": "true",
},
"key2": map[string]string{
"admin": "true",
},
},
},
})
Expand Down Expand Up @@ -1294,7 +1291,7 @@ func main() {
if err != nil {
log.Fatal(err)
}
if res.V2RevertTransactionResponse != nil {
if res.V2CreateTransactionResponse != nil {
// handle response
}
}
Expand Down Expand Up @@ -1351,6 +1348,8 @@ func main() {
Ledger: "ledger001",
RequestBody: map[string]any{
"key": "<value>",
"key1": "<value>",
"key2": "<value>",
},
})
if err != nil {
Expand Down Expand Up @@ -1479,7 +1478,7 @@ func main() {
PageSize: client.Int64(100),
Cursor: client.String("aHR0cHM6Ly9nLnBhZ2UvTmVrby1SYW1lbj9zaGFyZQ=="),
RequestBody: map[string]any{
"key": "<value>",

},
})
if err != nil {
Expand Down Expand Up @@ -1536,15 +1535,14 @@ func main() {
}),
)

v2ImportLogsRequest, fileErr := os.Open("example.file")
example, fileErr := os.Open("example.file")
if fileErr != nil {
panic(fileErr)
}


res, err := s.Ledger.V2.ImportLogs(ctx, operations.V2ImportLogsRequest{
Ledger: "ledger001",
V2ImportLogsRequest: v2ImportLogsRequest,
V2ImportLogsRequest: example,
})
if err != nil {
log.Fatal(err)
Expand Down
Loading
Loading