Skip to content
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

feat(api): OpenAPI spec update via Stainless API #1789

Merged
merged 1 commit into from
Apr 15, 2024
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
4 changes: 4 additions & 0 deletions images/v2directupload.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,10 @@ func (r v2DirectUploadNewResponseJSON) RawJSON() string {
type V2DirectUploadNewParams struct {
// Account identifier tag.
AccountID param.Field[string] `path:"account_id,required"`
// Optional Image Custom ID. Up to 1024 chars. Can include any number of subpaths,
// and utf8 characters. Cannot start nor end with a / (forward slash). Cannot be a
// UUID.
ID param.Field[string] `json:"id"`
// The date after which the upload will not be accepted. Minimum: Now + 2 minutes.
// Maximum: Now + 6 hours.
Expiry param.Field[time.Time] `json:"expiry" format:"date-time"`
Expand Down
1 change: 1 addition & 0 deletions images/v2directupload_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ func TestV2DirectUploadNewWithOptionalParams(t *testing.T) {
)
_, err := client.Images.V2.DirectUploads.New(context.TODO(), images.V2DirectUploadNewParams{
AccountID: cloudflare.F("023e105f4ecef8ad9ca31a8372d0c353"),
ID: cloudflare.F("this/is/my-customid"),
Expiry: cloudflare.F(time.Now()),
Metadata: cloudflare.F[any](map[string]interface{}{}),
RequireSignedURLs: cloudflare.F(true),
Expand Down