Skip to content

chore: 🐝 Update SDK - Generate 3.27.0 #47

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
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
2 changes: 1 addition & 1 deletion .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
547 changes: 272 additions & 275 deletions .speakeasy/gen.lock

Large diffs are not rendered by default.

96 changes: 96 additions & 0 deletions .speakeasy/tests.arazzo.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1916,3 +1916,99 @@ workflows:
{}
type: simple
x-speakeasy-test-group: PublishingTokens
- workflowId: generateCodeSamplePreview-default
steps:
- stepId: test
operationId: generateCodeSamplePreview
requestBody:
contentType: multipart/form-data
payload:
language: <value>
schema_file: 'x-file: example.file'
successCriteria:
- condition: $statusCode == 2XX
- condition: $response.header.Content-Type == application/json
- context: $response.body
condition: |
{
"snippets": [
{
"code": "import { Petstore } from \"petstore-sdk\";\n\nconst petstore = new Petstore({\n apiKey: \"\u003cYOUR_API_KEY_HERE\u003e\",\n});\n\nasync function run() {\n const result = await petstore.pet.getById({\n id: 137396,\n });\n\n // Handle the result\n console.log(result);\n}\n\nrun();",
"language": "typescript",
"method": "get",
"operationId": "getPetById",
"path": "/pet/{id}"
}
]
}
type: simple
x-speakeasy-test-group: CodeSamples
x-speakeasy-test-rebuild: true
- workflowId: getCodeSamples-default
steps:
- stepId: test
operationId: getCodeSamples
parameters:
- name: registry_url
in: query
value: https://spec.speakeasy.com/my-org/my-workspace/my-source
- name: operation_ids
in: query
value:
- getPets
- name: method_paths
in: query
value:
- method: get
path: /pets
- name: languages
in: query
value:
- python
- javascript
successCriteria:
- condition: $statusCode == 2XX
- condition: $response.header.Content-Type == application/json
- context: $response.body
condition: |
{
"snippets": [
{
"code": "import { Petstore } from \"petstore-sdk\";\n\nconst petstore = new Petstore({\n apiKey: \"\u003cYOUR_API_KEY_HERE\u003e\",\n});\n\nasync function run() {\n const result = await petstore.pet.getById({\n id: 137396,\n });\n\n // Handle the result\n console.log(result);\n}\n\nrun();",
"language": "typescript",
"method": "get",
"operationId": "getPetById",
"path": "/pet/{id}"
}
]
}
type: simple
x-speakeasy-test-group: CodeSamples
x-speakeasy-test-rebuild: true
- workflowId: getCodeSamplePreviewAsync-default
steps:
- stepId: test
operationId: getCodeSamplePreviewAsync
parameters:
- name: jobID
in: path
value: <id>
successCriteria:
- condition: $statusCode == 2XX
- condition: $response.header.Content-Type == application/json
- context: $response.body
condition: |
{
"snippets": [
{
"code": "import { Petstore } from \"petstore-sdk\";\n\nconst petstore = new Petstore({\n apiKey: \"\u003cYOUR_API_KEY_HERE\u003e\",\n});\n\nasync function run() {\n const result = await petstore.pet.getById({\n id: 137396,\n });\n\n // Handle the result\n console.log(result);\n}\n\nrun();",
"language": "typescript",
"method": "get",
"operationId": "getPetById",
"path": "/pet/{id}"
}
]
}
type: simple
x-speakeasy-test-group: CodeSamples
x-speakeasy-test-rebuild: true
12 changes: 6 additions & 6 deletions .speakeasy/workflow.lock
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
speakeasyVersion: 1.542.3
speakeasyVersion: 1.603.2
sources:
my-source:
sourceNamespace: my-source
sourceRevisionDigest: sha256:402d99fabeef032d62c39870ff2b3f9eb8dd356a76a76f07295ac3b4a94af8e0
sourceBlobDigest: sha256:0442ef7698d8979dd825b3eab0ab868ac86580f4cffcd3e0dff7afdd6191e6d9
sourceRevisionDigest: sha256:9128c3df436950ca04fec9dfc74e769e8b492d434b115b197d68da656ae17d23
sourceBlobDigest: sha256:6eb8a6e215c36d3e11d86fc67d5ce7af499bdb934e0f7fbad17efcdde9bffd73
tags:
- latest
- main
Expand All @@ -12,10 +12,10 @@ targets:
speakeasy-client-sdk-go:
source: my-source
sourceNamespace: my-source
sourceRevisionDigest: sha256:402d99fabeef032d62c39870ff2b3f9eb8dd356a76a76f07295ac3b4a94af8e0
sourceBlobDigest: sha256:0442ef7698d8979dd825b3eab0ab868ac86580f4cffcd3e0dff7afdd6191e6d9
sourceRevisionDigest: sha256:9128c3df436950ca04fec9dfc74e769e8b492d434b115b197d68da656ae17d23
sourceBlobDigest: sha256:6eb8a6e215c36d3e11d86fc67d5ce7af499bdb934e0f7fbad17efcdde9bffd73
codeSamplesNamespace: code-samples-go-speakeasy-client-sdk-go
codeSamplesRevisionDigest: sha256:367336fdd435084f895195faf801e7618cdb3d206b55fab1b1d220870ad39fd6
codeSamplesRevisionDigest: sha256:bd25d834e9c2e37153e63f4f7e5fafba31c0ee604740716000b99747a6191c4b
workflow:
workflowVersion: 1.0.0
speakeasyVersion: latest
Expand Down
75 changes: 39 additions & 36 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ For more information about the API: [The Speakeasy Platform Documentation](/docs

To add the SDK as a dependency to your project:
```bash
go get github.com/speakeasy-api/speakeasy-client-sdk-go
go get github.com/speakeasy-api/speakeasy-client-sdk-go/v3
```
<!-- End SDK Installation [installation] -->

Expand All @@ -54,17 +54,17 @@ package main

import (
"context"
speakeasyclientsdkgo "github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3/pkg/models/shared"
"log"
)

func main() {
ctx := context.Background()

s := speakeasyclientsdkgo.New(
speakeasyclientsdkgo.WithSecurity(shared.Security{
APIKey: speakeasyclientsdkgo.String("<YOUR_API_KEY_HERE>"),
s := v3.New(
v3.WithSecurity(shared.Security{
APIKey: v3.String("<YOUR_API_KEY_HERE>"),
}),
)

Expand Down Expand Up @@ -236,7 +236,7 @@ package main
import (
"context"
"errors"
speakeasyclientsdkgo "github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3/pkg/models/sdkerrors"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3/pkg/models/shared"
"log"
Expand All @@ -245,9 +245,9 @@ import (
func main() {
ctx := context.Background()

s := speakeasyclientsdkgo.New(
speakeasyclientsdkgo.WithSecurity(shared.Security{
APIKey: speakeasyclientsdkgo.String("<YOUR_API_KEY_HERE>"),
s := v3.New(
v3.WithSecurity(shared.Security{
APIKey: v3.String("<YOUR_API_KEY_HERE>"),
}),
)

Expand Down Expand Up @@ -291,18 +291,18 @@ package main

import (
"context"
speakeasyclientsdkgo "github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3/pkg/models/shared"
"log"
)

func main() {
ctx := context.Background()

s := speakeasyclientsdkgo.New(
speakeasyclientsdkgo.WithServer("prod"),
speakeasyclientsdkgo.WithSecurity(shared.Security{
APIKey: speakeasyclientsdkgo.String("<YOUR_API_KEY_HERE>"),
s := v3.New(
v3.WithServer("prod"),
v3.WithSecurity(shared.Security{
APIKey: v3.String("<YOUR_API_KEY_HERE>"),
}),
)

Expand All @@ -325,18 +325,18 @@ package main

import (
"context"
speakeasyclientsdkgo "github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3/pkg/models/shared"
"log"
)

func main() {
ctx := context.Background()

s := speakeasyclientsdkgo.New(
speakeasyclientsdkgo.WithServerURL("https://api.prod.speakeasy.com"),
speakeasyclientsdkgo.WithSecurity(shared.Security{
APIKey: speakeasyclientsdkgo.String("<YOUR_API_KEY_HERE>"),
s := v3.New(
v3.WithServerURL("https://api.prod.speakeasy.com"),
v3.WithSecurity(shared.Security{
APIKey: v3.String("<YOUR_API_KEY_HERE>"),
}),
)

Expand Down Expand Up @@ -371,12 +371,13 @@ The built-in `net/http` client satisfies this interface and a default client bas
import (
"net/http"
"time"
"github.com/myorg/your-go-sdk"

"github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
)

var (
httpClient = &http.Client{Timeout: 30 * time.Second}
sdkClient = sdk.New(sdk.WithClient(httpClient))
sdkClient = v3.New(v3.WithClient(httpClient))
)
```

Expand Down Expand Up @@ -404,17 +405,17 @@ package main

import (
"context"
speakeasyclientsdkgo "github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3/pkg/models/shared"
"log"
)

func main() {
ctx := context.Background()

s := speakeasyclientsdkgo.New(
speakeasyclientsdkgo.WithSecurity(shared.Security{
APIKey: speakeasyclientsdkgo.String("<YOUR_API_KEY_HERE>"),
s := v3.New(
v3.WithSecurity(shared.Security{
APIKey: v3.String("<YOUR_API_KEY_HERE>"),
}),
)

Expand Down Expand Up @@ -453,15 +454,17 @@ package main

import (
"context"
speakeasyclientsdkgo "github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3/pkg/models/operations"
"log"
)

func main() {
ctx := context.Background()

s := speakeasyclientsdkgo.New()
s := v3.New(
v3.WithWorkspaceID("<id>"),
)

res, err := s.Auth.GetAccessToken(ctx, operations.GetAccessTokenRequest{
WorkspaceID: "<id>",
Expand All @@ -488,7 +491,7 @@ package main

import (
"context"
speakeasyclientsdkgo "github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3/pkg/models/shared"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3/pkg/retry"
"log"
Expand All @@ -498,9 +501,9 @@ import (
func main() {
ctx := context.Background()

s := speakeasyclientsdkgo.New(
speakeasyclientsdkgo.WithSecurity(shared.Security{
APIKey: speakeasyclientsdkgo.String("<YOUR_API_KEY_HERE>"),
s := v3.New(
v3.WithSecurity(shared.Security{
APIKey: v3.String("<YOUR_API_KEY_HERE>"),
}),
)

Expand Down Expand Up @@ -531,7 +534,7 @@ package main

import (
"context"
speakeasyclientsdkgo "github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3/pkg/models/shared"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3/pkg/retry"
"log"
Expand All @@ -540,8 +543,8 @@ import (
func main() {
ctx := context.Background()

s := speakeasyclientsdkgo.New(
speakeasyclientsdkgo.WithRetryConfig(
s := v3.New(
v3.WithRetryConfig(
retry.Config{
Strategy: "backoff",
Backoff: &retry.BackoffStrategy{
Expand All @@ -552,8 +555,8 @@ func main() {
},
RetryConnectionErrors: false,
}),
speakeasyclientsdkgo.WithSecurity(shared.Security{
APIKey: speakeasyclientsdkgo.String("<YOUR_API_KEY_HERE>"),
v3.WithSecurity(shared.Security{
APIKey: v3.String("<YOUR_API_KEY_HERE>"),
}),
)

Expand Down
12 changes: 11 additions & 1 deletion RELEASES.md
Original file line number Diff line number Diff line change
Expand Up @@ -1736,4 +1736,14 @@ Based on:
### Generated
- [go v3.26.7] .
### Releases
- [Go v3.26.7] https://github.com/speakeasy-api/speakeasy-client-sdk-go/releases/tag/v3.26.7 - .
- [Go v3.26.7] https://github.com/speakeasy-api/speakeasy-client-sdk-go/releases/tag/v3.26.7 - .

## 2025-08-13 22:08:29
### Changes
Based on:
- OpenAPI Doc
- Speakeasy CLI 1.603.2 (2.681.8) https://github.com/speakeasy-api/speakeasy
### Generated
- [go v3.27.0] .
### Releases
- [Go v3.27.0] https://github.com/speakeasy-api/speakeasy-client-sdk-go/releases/tag/v3.27.0 - .
8 changes: 4 additions & 4 deletions USAGE.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,17 @@ package main

import (
"context"
speakeasyclientsdkgo "github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3"
"github.com/speakeasy-api/speakeasy-client-sdk-go/v3/pkg/models/shared"
"log"
)

func main() {
ctx := context.Background()

s := speakeasyclientsdkgo.New(
speakeasyclientsdkgo.WithSecurity(shared.Security{
APIKey: speakeasyclientsdkgo.String("<YOUR_API_KEY_HERE>"),
s := v3.New(
v3.WithSecurity(shared.Security{
APIKey: v3.String("<YOUR_API_KEY_HERE>"),
}),
)

Expand Down
Loading