Skip to content

Commit 0daa0f6

Browse files
feat(api): api update
1 parent b1e912c commit 0daa0f6

File tree

4 files changed

+31
-1
lines changed

4 files changed

+31
-1
lines changed

.stats.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 22
22
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/opencode%2Fopencode-69b99aaffe10dd5247638b6a34d6c0b3c1cf5300853d12c947151fd946e7fcdb.yml
33
openapi_spec_hash: e2c746cf689d71f04c6e9b1bd92e6356
4-
config_hash: 6d56a7ca0d6ed899ecdb5c053a8278ae
4+
config_hash: e64b350ea4abbb4d56d49b0adebacb02

api.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,3 +117,5 @@ Methods:
117117
- <code title="post /session/{id}/share">client.Session.<a href="https://pkg.go.dev/github.com/sst/opencode-sdk-go#SessionService.Share">Share</a>(ctx <a href="https://pkg.go.dev/context">context</a>.<a href="https://pkg.go.dev/context#Context">Context</a>, id <a href="https://pkg.go.dev/builtin#string">string</a>) (<a href="https://pkg.go.dev/github.com/sst/opencode-sdk-go">opencode</a>.<a href="https://pkg.go.dev/github.com/sst/opencode-sdk-go#Session">Session</a>, <a href="https://pkg.go.dev/builtin#error">error</a>)</code>
118118
- <code title="post /session/{id}/summarize">client.Session.<a href="https://pkg.go.dev/github.com/sst/opencode-sdk-go#SessionService.Summarize">Summarize</a>(ctx <a href="https://pkg.go.dev/context">context</a>.<a href="https://pkg.go.dev/context#Context">Context</a>, id <a href="https://pkg.go.dev/builtin#string">string</a>, body <a href="https://pkg.go.dev/github.com/sst/opencode-sdk-go">opencode</a>.<a href="https://pkg.go.dev/github.com/sst/opencode-sdk-go#SessionSummarizeParams">SessionSummarizeParams</a>) (<a href="https://pkg.go.dev/builtin#bool">bool</a>, <a href="https://pkg.go.dev/builtin#error">error</a>)</code>
119119
- <code title="delete /session/{id}/share">client.Session.<a href="https://pkg.go.dev/github.com/sst/opencode-sdk-go#SessionService.Unshare">Unshare</a>(ctx <a href="https://pkg.go.dev/context">context</a>.<a href="https://pkg.go.dev/context#Context">Context</a>, id <a href="https://pkg.go.dev/builtin#string">string</a>) (<a href="https://pkg.go.dev/github.com/sst/opencode-sdk-go">opencode</a>.<a href="https://pkg.go.dev/github.com/sst/opencode-sdk-go#Session">Session</a>, <a href="https://pkg.go.dev/builtin#error">error</a>)</code>
120+
121+
# Tui

client.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ type Client struct {
2222
File *FileService
2323
Config *ConfigService
2424
Session *SessionService
25+
Tui *TuiService
2526
}
2627

2728
// DefaultClientOptions read from the environment (OPENCODE_BASE_URL). This should
@@ -49,6 +50,7 @@ func NewClient(opts ...option.RequestOption) (r *Client) {
4950
r.File = NewFileService(opts...)
5051
r.Config = NewConfigService(opts...)
5152
r.Session = NewSessionService(opts...)
53+
r.Tui = NewTuiService(opts...)
5254

5355
return
5456
}

tui.go

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2+
3+
package opencode
4+
5+
import (
6+
"github.com/sst/opencode-sdk-go/option"
7+
)
8+
9+
// TuiService contains methods and other services that help with interacting with
10+
// the opencode API.
11+
//
12+
// Note, unlike clients, this service does not read variables from the environment
13+
// automatically. You should not instantiate this service directly, and instead use
14+
// the [NewTuiService] method instead.
15+
type TuiService struct {
16+
Options []option.RequestOption
17+
}
18+
19+
// NewTuiService generates a new service that applies the given options to each
20+
// request. These options are applied after the parent client's options (if there
21+
// is one), and before any request-specific options.
22+
func NewTuiService(opts ...option.RequestOption) (r *TuiService) {
23+
r = &TuiService{}
24+
r.Options = opts
25+
return
26+
}

0 commit comments

Comments
 (0)