Skip to content

Commit

Permalink
feat(api): update via SDK Studio (#1986)
Browse files Browse the repository at this point in the history
  • Loading branch information
stainless-app[bot] authored and stainless-bot committed May 10, 2024
1 parent 9f9cc70 commit d7c0661
Show file tree
Hide file tree
Showing 5 changed files with 79 additions and 79 deletions.
14 changes: 7 additions & 7 deletions api.md
Original file line number Diff line number Diff line change
Expand Up @@ -6795,21 +6795,21 @@ Methods:
- <code title="delete /accounts/{account_id}/calls/apps/{app_id}">client.Calls.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#CallService.Delete">Delete</a>(ctx <a href="https://pkg.go.dev/context">context</a>.<a href="https://pkg.go.dev/context#Context">Context</a>, appID <a href="https://pkg.go.dev/builtin#string">string</a>, body <a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#CallDeleteParams">CallDeleteParams</a>) (<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#CallsApp">CallsApp</a>, <a href="https://pkg.go.dev/builtin#error">error</a>)</code>
- <code title="get /accounts/{account_id}/calls/apps/{app_id}">client.Calls.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#CallService.Get">Get</a>(ctx <a href="https://pkg.go.dev/context">context</a>.<a href="https://pkg.go.dev/context#Context">Context</a>, appID <a href="https://pkg.go.dev/builtin#string">string</a>, query <a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#CallGetParams">CallGetParams</a>) (<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#CallsApp">CallsApp</a>, <a href="https://pkg.go.dev/builtin#error">error</a>)</code>

## Turn
## TURN

### Keys

Response Types:

- <a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TurnKeyNewResponse">TurnKeyNewResponse</a>
- <a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TURNKeyNewResponse">TURNKeyNewResponse</a>

Methods:

- <code title="post /accounts/{account_id}/calls/turn_keys">client.Calls.Turn.Keys.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TurnKeyService.New">New</a>(ctx <a href="https://pkg.go.dev/context">context</a>.<a href="https://pkg.go.dev/context#Context">Context</a>, params <a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TurnKeyNewParams">TurnKeyNewParams</a>) (<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TurnKeyNewResponse">TurnKeyNewResponse</a>, <a href="https://pkg.go.dev/builtin#error">error</a>)</code>
- <code title="put /accounts/{account_id}/calls/turn_keys/{key_id}">client.Calls.Turn.Keys.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TurnKeyService.Update">Update</a>(ctx <a href="https://pkg.go.dev/context">context</a>.<a href="https://pkg.go.dev/context#Context">Context</a>, keyID <a href="https://pkg.go.dev/builtin#string">string</a>, params <a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TurnKeyUpdateParams">TurnKeyUpdateParams</a>) (<a href="https://pkg.go.dev/builtin#string">string</a>, <a href="https://pkg.go.dev/builtin#error">error</a>)</code>
- <code title="get /accounts/{account_id}/calls/turn_keys">client.Calls.Turn.Keys.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TurnKeyService.List">List</a>(ctx <a href="https://pkg.go.dev/context">context</a>.<a href="https://pkg.go.dev/context#Context">Context</a>, query <a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TurnKeyListParams">TurnKeyListParams</a>) (<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/internal/pagination">pagination</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/internal/pagination#SinglePage">SinglePage</a>[<a href="https://pkg.go.dev/builtin#string">string</a>], <a href="https://pkg.go.dev/builtin#error">error</a>)</code>
- <code title="delete /accounts/{account_id}/calls/turn_keys/{key_id}">client.Calls.Turn.Keys.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TurnKeyService.Delete">Delete</a>(ctx <a href="https://pkg.go.dev/context">context</a>.<a href="https://pkg.go.dev/context#Context">Context</a>, keyID <a href="https://pkg.go.dev/builtin#string">string</a>, body <a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TurnKeyDeleteParams">TurnKeyDeleteParams</a>) (<a href="https://pkg.go.dev/builtin#string">string</a>, <a href="https://pkg.go.dev/builtin#error">error</a>)</code>
- <code title="get /accounts/{account_id}/calls/turn_keys/{key_id}">client.Calls.Turn.Keys.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TurnKeyService.Get">Get</a>(ctx <a href="https://pkg.go.dev/context">context</a>.<a href="https://pkg.go.dev/context#Context">Context</a>, keyID <a href="https://pkg.go.dev/builtin#string">string</a>, query <a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TurnKeyGetParams">TurnKeyGetParams</a>) (<a href="https://pkg.go.dev/builtin#string">string</a>, <a href="https://pkg.go.dev/builtin#error">error</a>)</code>
- <code title="post /accounts/{account_id}/calls/turn_keys">client.Calls.TURN.Keys.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TURNKeyService.New">New</a>(ctx <a href="https://pkg.go.dev/context">context</a>.<a href="https://pkg.go.dev/context#Context">Context</a>, params <a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TURNKeyNewParams">TURNKeyNewParams</a>) (<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TURNKeyNewResponse">TURNKeyNewResponse</a>, <a href="https://pkg.go.dev/builtin#error">error</a>)</code>
- <code title="put /accounts/{account_id}/calls/turn_keys/{key_id}">client.Calls.TURN.Keys.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TURNKeyService.Update">Update</a>(ctx <a href="https://pkg.go.dev/context">context</a>.<a href="https://pkg.go.dev/context#Context">Context</a>, keyID <a href="https://pkg.go.dev/builtin#string">string</a>, params <a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TURNKeyUpdateParams">TURNKeyUpdateParams</a>) (<a href="https://pkg.go.dev/builtin#string">string</a>, <a href="https://pkg.go.dev/builtin#error">error</a>)</code>
- <code title="get /accounts/{account_id}/calls/turn_keys">client.Calls.TURN.Keys.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TURNKeyService.List">List</a>(ctx <a href="https://pkg.go.dev/context">context</a>.<a href="https://pkg.go.dev/context#Context">Context</a>, query <a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TURNKeyListParams">TURNKeyListParams</a>) (<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/internal/pagination">pagination</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/internal/pagination#SinglePage">SinglePage</a>[<a href="https://pkg.go.dev/builtin#string">string</a>], <a href="https://pkg.go.dev/builtin#error">error</a>)</code>
- <code title="delete /accounts/{account_id}/calls/turn_keys/{key_id}">client.Calls.TURN.Keys.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TURNKeyService.Delete">Delete</a>(ctx <a href="https://pkg.go.dev/context">context</a>.<a href="https://pkg.go.dev/context#Context">Context</a>, keyID <a href="https://pkg.go.dev/builtin#string">string</a>, body <a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TURNKeyDeleteParams">TURNKeyDeleteParams</a>) (<a href="https://pkg.go.dev/builtin#string">string</a>, <a href="https://pkg.go.dev/builtin#error">error</a>)</code>
- <code title="get /accounts/{account_id}/calls/turn_keys/{key_id}">client.Calls.TURN.Keys.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TURNKeyService.Get">Get</a>(ctx <a href="https://pkg.go.dev/context">context</a>.<a href="https://pkg.go.dev/context#Context">Context</a>, keyID <a href="https://pkg.go.dev/builtin#string">string</a>, query <a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls">calls</a>.<a href="https://pkg.go.dev/github.com/cloudflare/cloudflare-go/v2/calls#TURNKeyGetParams">TURNKeyGetParams</a>) (<a href="https://pkg.go.dev/builtin#string">string</a>, <a href="https://pkg.go.dev/builtin#error">error</a>)</code>

# CloudforceOne

Expand Down
4 changes: 2 additions & 2 deletions calls/call.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import (
// the [NewCallService] method instead.
type CallService struct {
Options []option.RequestOption
Turn *TurnService
TURN *TURNService
}

// NewCallService generates a new service that applies the given options to each
Expand All @@ -33,7 +33,7 @@ type CallService struct {
func NewCallService(opts ...option.RequestOption) (r *CallService) {
r = &CallService{}
r.Options = opts
r.Turn = NewTurnService(opts...)
r.TURN = NewTURNService(opts...)
return
}

Expand Down
16 changes: 8 additions & 8 deletions calls/turn.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,23 +6,23 @@ import (
"github.com/cloudflare/cloudflare-go/v2/option"
)

// TurnService contains methods and other services that help with interacting with
// TURNService contains methods and other services that help with interacting with
// the cloudflare API.
//
// Note, unlike clients, this service does not read variables from the environment
// automatically. You should not instantiate this service directly, and instead use
// the [NewTurnService] method instead.
type TurnService struct {
// the [NewTURNService] method instead.
type TURNService struct {
Options []option.RequestOption
Keys *TurnKeyService
Keys *TURNKeyService
}

// NewTurnService generates a new service that applies the given options to each
// NewTURNService generates a new service that applies the given options to each
// request. These options are applied after the parent client's options (if there
// is one), and before any request-specific options.
func NewTurnService(opts ...option.RequestOption) (r *TurnService) {
r = &TurnService{}
func NewTURNService(opts ...option.RequestOption) (r *TURNService) {
r = &TURNService{}
r.Options = opts
r.Keys = NewTurnKeyService(opts...)
r.Keys = NewTURNKeyService(opts...)
return
}
Loading

0 comments on commit d7c0661

Please sign in to comment.