diff --git a/internal/apiclient/client.gen.go b/internal/apiclient/client.gen.go index 67f66a0..7dea11f 100644 --- a/internal/apiclient/client.gen.go +++ b/internal/apiclient/client.gen.go @@ -28,6 +28,27 @@ const ( UserTokenScopes userTokenContextKey = "UserToken.Scopes" ) +// Defines values for AuthInsightsInterval. +const ( + Day AuthInsightsInterval = "day" + Month AuthInsightsInterval = "month" + Week AuthInsightsInterval = "week" +) + +// Valid indicates whether the value is a known member of the AuthInsightsInterval enum. +func (e AuthInsightsInterval) Valid() bool { + switch e { + case Day: + return true + case Month: + return true + case Week: + return true + default: + return false + } +} + // Defines values for AuthSessionProvider. const ( AuthSessionProviderAnonymous AuthSessionProvider = "anonymous" @@ -2265,25 +2286,25 @@ func (e GetOAuthConfigParamsProvider) Valid() bool { // Defines values for UpdateOAuthConfigParamsProvider. const ( - Apple UpdateOAuthConfigParamsProvider = "apple" - Device UpdateOAuthConfigParamsProvider = "device" - Github UpdateOAuthConfigParamsProvider = "github" - Google UpdateOAuthConfigParamsProvider = "google" - Microsoft UpdateOAuthConfigParamsProvider = "microsoft" + UpdateOAuthConfigParamsProviderApple UpdateOAuthConfigParamsProvider = "apple" + UpdateOAuthConfigParamsProviderDevice UpdateOAuthConfigParamsProvider = "device" + UpdateOAuthConfigParamsProviderGithub UpdateOAuthConfigParamsProvider = "github" + UpdateOAuthConfigParamsProviderGoogle UpdateOAuthConfigParamsProvider = "google" + UpdateOAuthConfigParamsProviderMicrosoft UpdateOAuthConfigParamsProvider = "microsoft" ) // Valid indicates whether the value is a known member of the UpdateOAuthConfigParamsProvider enum. func (e UpdateOAuthConfigParamsProvider) Valid() bool { switch e { - case Apple: + case UpdateOAuthConfigParamsProviderApple: return true - case Device: + case UpdateOAuthConfigParamsProviderDevice: return true - case Github: + case UpdateOAuthConfigParamsProviderGithub: return true - case Google: + case UpdateOAuthConfigParamsProviderGoogle: return true - case Microsoft: + case UpdateOAuthConfigParamsProviderMicrosoft: return true default: return false @@ -2305,6 +2326,21 @@ func (e UploadStorageObjectParamsXUploadComplete) Valid() bool { } } +// Defines values for StartGitConnectParamsProvider. +const ( + StartGitConnectParamsProviderGithub StartGitConnectParamsProvider = "github" +) + +// Valid indicates whether the value is a known member of the StartGitConnectParamsProvider enum. +func (e StartGitConnectParamsProvider) Valid() bool { + switch e { + case StartGitConnectParamsProviderGithub: + return true + default: + return false + } +} + // AnonKey defines model for AnonKey. type AnonKey struct { CreatedAt *time.Time `json:"created_at,omitempty"` @@ -2337,6 +2373,9 @@ type AuthConfig struct { // AllowedRedirectUrls Redirect allowlist used to validate post_auth_redirect_url and post_logout_redirect_url. AllowedRedirectUrls *[]string `json:"allowed_redirect_urls,omitempty"` + // AutoLinkVerifiedOauth Link a verified OAuth identity to an existing confirmed account with the same email instead of returning a conflict. Requires require_email_confirmation to be true. + AutoLinkVerifiedOauth *bool `json:"auto_link_verified_oauth,omitempty"` + // CorsAllowCredentials Allow credentials in CORS requests CorsAllowCredentials *bool `json:"cors_allow_credentials,omitempty"` CorsAllowedOrigins *[]string `json:"cors_allowed_origins,omitempty"` @@ -2353,6 +2392,9 @@ type AuthConfig struct { DeviceVerificationUrl *string `json:"device_verification_url,omitempty"` EmailConfirmationSubject *string `json:"email_confirmation_subject,omitempty"` + // EmailConfirmationTimeout Email confirmation token expiry in seconds. + EmailConfirmationTimeout *int `json:"email_confirmation_timeout,omitempty"` + // EmailEnabled Enable transactional email sending (confirmation, reset, change notifications). Must be true when require_email_confirmation is true. EmailEnabled *bool `json:"email_enabled,omitempty"` EmailFromAddress *string `json:"email_from_address,omitempty"` @@ -2405,18 +2447,21 @@ type AuthConfig struct { RateLimitTokenRefresh *int `json:"rate_limit_token_refresh,omitempty"` // RefreshTokenLifetime Refresh token lifetime in seconds - RefreshTokenLifetime *int `json:"refresh_token_lifetime,omitempty"` - RequireLowercase *bool `json:"require_lowercase,omitempty"` - RequireNumbers *bool `json:"require_numbers,omitempty"` - RequireSpecialChars *bool `json:"require_special_chars,omitempty"` - RequireUppercase *bool `json:"require_uppercase,omitempty"` - SmtpHost *string `json:"smtp_host,omitempty"` - - // SmtpPassword SMTP password. Stored encrypted at rest (AES-256-GCM); returned decrypted only to the authenticated project owner. - SmtpPassword *string `json:"smtp_password,omitempty"` - SmtpPort *int `json:"smtp_port,omitempty"` - SmtpUseTls *bool `json:"smtp_use_tls,omitempty"` - SmtpUsername *string `json:"smtp_username,omitempty"` + RefreshTokenLifetime *int `json:"refresh_token_lifetime,omitempty"` + + // RequireEmailConfirmation Require users to confirm email before sign-in. Can only be true when email_enabled is true. + RequireEmailConfirmation *bool `json:"require_email_confirmation,omitempty"` + RequireLowercase *bool `json:"require_lowercase,omitempty"` + RequireNumbers *bool `json:"require_numbers,omitempty"` + RequireSpecialChars *bool `json:"require_special_chars,omitempty"` + RequireUppercase *bool `json:"require_uppercase,omitempty"` + SmtpHost *string `json:"smtp_host,omitempty"` + + // SmtpPasswordConfigured Whether an SMTP password is configured. The password itself is never returned. + SmtpPasswordConfigured *bool `json:"smtp_password_configured,omitempty"` + SmtpPort *int `json:"smtp_port,omitempty"` + SmtpUseTls *bool `json:"smtp_use_tls,omitempty"` + SmtpUsername *string `json:"smtp_username,omitempty"` } // AuthHostedPage defines model for AuthHostedPage. @@ -2462,6 +2507,48 @@ type AuthIdentity struct { IsPrimary bool `json:"is_primary"` } +// AuthInsightsInterval defines model for AuthInsightsInterval. +type AuthInsightsInterval string + +// AuthInsightsResponse defines model for AuthInsightsResponse. +type AuthInsightsResponse struct { + ObservedAt time.Time `json:"observed_at"` + ProjectId openapi_types.UUID `json:"project_id"` + Series []AuthInsightsSeriesPoint `json:"series"` + Summary AuthInsightsSummary `json:"summary"` + Window AuthInsightsWindow `json:"window"` +} + +// AuthInsightsSeriesPoint defines model for AuthInsightsSeriesPoint. +type AuthInsightsSeriesPoint struct { + BucketStart openapi_types.Date `json:"bucket_start"` + + // IsPartial Whether the requested window or observation time clips this bucket. + IsPartial bool `json:"is_partial"` + + // Signins Successful session creations during the bucket. + Signins int64 `json:"signins"` + + // Signups Accounts created during the bucket. + Signups int64 `json:"signups"` +} + +// AuthInsightsSummary defines model for AuthInsightsSummary. +type AuthInsightsSummary struct { + // ActiveUsers30d Users with a successful session creation or refresh in the trailing 30 days since activity collection was deployed. + ActiveUsers30d int64 `json:"active_users_30d"` + + // TotalUsers Current auth-user count, matching the auth-user list total. + TotalUsers int64 `json:"total_users"` +} + +// AuthInsightsWindow defines model for AuthInsightsWindow. +type AuthInsightsWindow struct { + From openapi_types.Date `json:"from"` + Interval AuthInsightsInterval `json:"interval"` + To openapi_types.Date `json:"to"` +} + // AuthMethodSummary A single sign-in method the account owns (password, an OAuth provider, or an // active anonymous method). `is_primary` reflects the account's primary_method_id. type AuthMethodSummary struct { @@ -2632,6 +2719,27 @@ type CompleteUploadSessionResponse struct { Object *StorageObject `json:"object,omitempty"` } +// ConnectProjectGitRequest defines model for ConnectProjectGitRequest. +type ConnectProjectGitRequest struct { + // ConnectionId The caller's user_git_connections row (see /user/git/connections). + ConnectionId openapi_types.UUID `json:"connection_id"` + InstallationId int64 `json:"installation_id"` + + // ProductionBranch Deprecated. The deployment branch always follows the repository's GitHub default branch; when given it must equal that default branch. New callers omit it. + // Deprecated: this property has been marked as deprecated upstream, but no `x-deprecated-reason` was set + ProductionBranch *string `json:"production_branch,omitempty"` + + // RepoFullName Deprecated selector kept for a compatibility window; prefer repository_id. Either repository_id or repo_full_name is required. + // Deprecated: this property has been marked as deprecated upstream, but no `x-deprecated-reason` was set + RepoFullName *string `json:"repo_full_name,omitempty"` + + // RepositoryId Stable GitHub repository id (repository.id), the preferred selector. Either repository_id or repo_full_name is required; when both are given they must identify the same live repository. + RepositoryId *int64 `json:"repository_id,omitempty"` + + // RootDirectory Monorepo subdirectory the project builds from. Omit for the repo root. + RootDirectory *string `json:"root_directory,omitempty"` +} + // CreateDatabaseRequest Create a new PostgreSQL database. Volcano automatically sets up: // - Auth helpers (auth.uid(), auth.email(), auth.role()) // - Database roles (anon for unauthenticated, authenticated for signed-in users) @@ -2944,7 +3052,9 @@ type EmailTemplateTemplateType string // Error defines model for Error. type Error struct { - Error string `json:"error"` + // Code Stable machine-readable error code when a specific recovery path is available. + Code *string `json:"code,omitempty"` + Error string `json:"error"` } // Frontend defines model for Frontend. @@ -3031,7 +3141,6 @@ type FrontendDeployment struct { ArtifactVersion *string `json:"artifact_version,omitempty"` CloudformationStackId *string `json:"cloudformation_stack_id,omitempty"` CloudformationStackUrl *string `json:"cloudformation_stack_url,omitempty"` - CloudwatchLogGroup *string `json:"cloudwatch_log_group,omitempty"` // CodebuildBuildCount Number of completed CodeBuild builds included in codebuild_duration_seconds. CodebuildBuildCount *int `json:"codebuild_build_count,omitempty"` @@ -3161,8 +3270,6 @@ type FunctionDeployment struct { // CodebuildDurationSeconds Total CodeBuild build duration recorded for this deployment, in seconds. CodebuildDurationSeconds *int64 `json:"codebuild_duration_seconds,omitempty"` - CompileLogGroup *string `json:"compile_log_group,omitempty"` - CompileLogStream *string `json:"compile_log_stream,omitempty"` CompletedAt *time.Time `json:"completed_at,omitempty"` CreatedAt time.Time `json:"created_at"` ErrorMessage *string `json:"error_message,omitempty"` @@ -3170,8 +3277,6 @@ type FunctionDeployment struct { Id openapi_types.UUID `json:"id"` Operation FunctionDeploymentOperation `json:"operation"` ProjectId openapi_types.UUID `json:"project_id"` - PublishLogGroup *string `json:"publish_log_group,omitempty"` - PublishLogStream *string `json:"publish_log_stream,omitempty"` Status FunctionDeploymentStatus `json:"status"` UpdatedAt time.Time `json:"updated_at"` } @@ -3277,8 +3382,64 @@ type FunctionSchedulerListResponse struct { Data []FunctionScheduler `json:"data"` HasMore bool `json:"has_more"` Limit int `json:"limit"` - Page int `json:"page"` - Total int `json:"total"` + + // NextCursor Opaque cursor for the next page (cursor pagination only; present if has_more is true) + NextCursor *string `json:"next_cursor,omitempty"` + Page int `json:"page"` + + // PrevCursor Opaque cursor for the previous page (cursor pagination only; present when a previous page exists). Send as `ending_before`. + PrevCursor *string `json:"prev_cursor,omitempty"` + Total int `json:"total"` +} + +// GitConnectStartResponse defines model for GitConnectStartResponse. +type GitConnectStartResponse struct { + AuthorizationUrl string `json:"authorization_url"` +} + +// GitConnection defines model for GitConnection. +type GitConnection struct { + CreatedAt time.Time `json:"created_at"` + Id openapi_types.UUID `json:"id"` + LastAuthenticatedAt time.Time `json:"last_authenticated_at"` + Provider string `json:"provider"` + ProviderLogin string `json:"provider_login"` + ProviderUserId string `json:"provider_user_id"` + Status string `json:"status"` + UpdatedAt time.Time `json:"updated_at"` +} + +// GitConnectionsResponse defines model for GitConnectionsResponse. +type GitConnectionsResponse struct { + Connections []GitConnection `json:"connections"` +} + +// GitInstallation defines model for GitInstallation. +type GitInstallation struct { + AccountLogin string `json:"account_login"` + AccountType string `json:"account_type"` + Id int64 `json:"id"` + RepositorySelection string `json:"repository_selection"` +} + +// GitInstallationsResponse defines model for GitInstallationsResponse. +type GitInstallationsResponse struct { + Installations []GitInstallation `json:"installations"` +} + +// GitRepositoriesResponse defines model for GitRepositoriesResponse. +type GitRepositoriesResponse struct { + Repositories []GitRepository `json:"repositories"` +} + +// GitRepository defines model for GitRepository. +type GitRepository struct { + DefaultBranch string `json:"default_branch"` + FullName string `json:"full_name"` + + // Id Stable GitHub repository id (repository.id), unchanged by renames. + Id int64 `json:"id"` + Private bool `json:"private"` } // HostedAuthPageType defines model for HostedAuthPageType. @@ -3341,15 +3502,9 @@ type LogActivityRequest struct { // EndTime End time. EndTime *time.Time `json:"end_time,omitempty"` - // Levels Canonical lowercase log levels to filter by. If omitted, empty, or all levels are selected, no level filter is applied. - Levels *[]LiveLogLevel `json:"levels,omitempty"` - - // Q Optional free-text search query for log messages. + // Q Optional activity query. Supports quoted text, implicit AND, AND/OR/NOT, parentheses, and fields such as `level`, `region`, `invocation.id`, `resource.id`, `resource.name`, `function`, `frontend`, `database`, and `body`. Q *string `json:"q,omitempty"` - // Regions Regions to filter by, for example `["us-east-1", "eu-west-1"]`. If omitted or empty, aggregate all deployed regions. - Regions *[]string `json:"regions,omitempty"` - // Resource Resource selectors for project log reads. Resource LogRequestResource `json:"resource"` @@ -3395,8 +3550,11 @@ type LogDeploymentRequestSelector struct { Ids *[]openapi_types.UUID `json:"ids,omitempty"` } -// LogEvent Normalized historical log event returned by paginated log APIs. +// LogEvent Historical log event returned by log APIs. type LogEvent struct { + // Body Application log value. JSON arguments retain their JSON type. Strings containing a serialized JSON object or array are normalized to that object or array; all other strings remain strings. + Body *LogEvent_Body `json:"body"` + // Deployment Deployment context associated with a historical deployment log event. Deployment *LogDeployment `json:"deployment,omitempty"` @@ -3409,15 +3567,6 @@ type LogEvent struct { // Level Canonical lowercase function runtime log level. Level *LiveLogLevel `json:"level,omitempty"` - // Message Display log message. - Message string `json:"message"` - - // Metadata Parsed JSON fields and other indexed metadata, when available. - Metadata *map[string]interface{} `json:"metadata,omitempty"` - - // RawMessage Original log line/message after platform sanitization. - RawMessage *string `json:"raw_message,omitempty"` - // Region Region where this log event originated. Region *string `json:"region,omitempty"` @@ -3428,6 +3577,26 @@ type LogEvent struct { Timestamp time.Time `json:"timestamp"` } +// LogEventBody0 defines model for . +type LogEventBody0 = string + +// LogEventBody1 defines model for . +type LogEventBody1 map[string]interface{} + +// LogEventBody2 defines model for . +type LogEventBody2 = []interface{} + +// LogEventBody3 defines model for . +type LogEventBody3 = float64 + +// LogEventBody4 defines model for . +type LogEventBody4 = bool + +// LogEvent_Body Application log value. JSON arguments retain their JSON type. Strings containing a serialized JSON object or array are normalized to that object or array; all other strings remain strings. +type LogEvent_Body struct { + union json.RawMessage +} + // LogFrontendRequestResource Frontend log resource selector. type LogFrontendRequestResource struct { // Deployments Deployment log selector for deployable resources. @@ -3480,6 +3649,9 @@ type LogResourceType string // LogSearchEvent defines model for LogSearchEvent. type LogSearchEvent struct { + // Body Application log value. JSON arguments retain their JSON type. Strings containing a serialized JSON object or array are normalized to that object or array; all other strings remain strings. + Body *LogSearchEvent_Body `json:"body"` + // Deployment Deployment context associated with a historical deployment log event. Deployment *LogDeployment `json:"deployment,omitempty"` @@ -3492,15 +3664,6 @@ type LogSearchEvent struct { // Level Canonical lowercase function runtime log level. Level *LiveLogLevel `json:"level,omitempty"` - // Message Display log message. - Message string `json:"message"` - - // Metadata Parsed JSON fields and other indexed metadata, when available. - Metadata *map[string]interface{} `json:"metadata,omitempty"` - - // RawMessage Original log line/message after platform sanitization. - RawMessage *string `json:"raw_message,omitempty"` - // Region Region where this log event originated. Region *string `json:"region,omitempty"` @@ -3511,6 +3674,26 @@ type LogSearchEvent struct { Timestamp time.Time `json:"timestamp"` } +// LogSearchEventBody0 defines model for . +type LogSearchEventBody0 = string + +// LogSearchEventBody1 defines model for . +type LogSearchEventBody1 map[string]interface{} + +// LogSearchEventBody2 defines model for . +type LogSearchEventBody2 = []interface{} + +// LogSearchEventBody3 defines model for . +type LogSearchEventBody3 = float64 + +// LogSearchEventBody4 defines model for . +type LogSearchEventBody4 = bool + +// LogSearchEvent_Body Application log value. JSON arguments retain their JSON type. Strings containing a serialized JSON object or array are normalized to that object or array; all other strings remain strings. +type LogSearchEvent_Body struct { + union json.RawMessage +} + // LogSearchRequest Search request for project logs. type LogSearchRequest struct { // Cursor Opaque pagination cursor from the previous response's `next_cursor`. @@ -3519,18 +3702,12 @@ type LogSearchRequest struct { // EndTime End time. EndTime *time.Time `json:"end_time,omitempty"` - // Levels Canonical lowercase log levels to filter by. If omitted, empty, or all levels are selected, no level filter is applied. - Levels *[]LiveLogLevel `json:"levels,omitempty"` - // Limit Maximum number of records to return. Limit *int `json:"limit,omitempty"` - // Q Optional free-text search query for log messages. + // Q Optional log query. Supports quoted text, implicit AND, AND/OR/NOT, parentheses, and fields such as `level`, `region`, `invocation.id`, `resource.id`, `resource.name`, `function`, `frontend`, `database`, and `body`. Q *string `json:"q,omitempty"` - // Regions Regions to filter by, for example `["us-east-1", "eu-west-1"]`. If omitted or empty, search all deployed regions. - Regions *[]string `json:"regions,omitempty"` - // Resource Resource selectors for project log reads. Resource LogRequestResource `json:"resource"` @@ -3553,16 +3730,13 @@ type LogSearchResponse struct { NextCursor *string `json:"next_cursor,omitempty"` } -// LogStreamRequest Stream request for live project logs. Text search, pagination cursors, and fixed end times are not supported. +// LogStreamRequest Stream request for live project logs. Pagination cursors and fixed end times are not supported. type LogStreamRequest struct { - // Levels Canonical lowercase log levels to filter by. If omitted, empty, or all levels are selected, no level filter is applied. - Levels *[]LiveLogLevel `json:"levels,omitempty"` - // Limit Maximum number of records to deliver on connect or reconnect before following new events. Limit *int `json:"limit,omitempty"` - // Regions Regions to filter by, for example `["us-east-1", "eu-west-1"]`. If omitted or empty, stream all deployed regions. - Regions *[]string `json:"regions,omitempty"` + // Q Optional log query using the same syntax as search and activity requests. + Q *string `json:"q,omitempty"` // Resource Resource selectors for project log reads. Resource LogRequestResource `json:"resource"` @@ -3651,9 +3825,15 @@ type PaginatedDatabases struct { // Next URL path to next page (only present if has_more is true) Next *string `json:"next,omitempty"` + // NextCursor Opaque cursor for the next page (cursor pagination only; present if has_more is true) + NextCursor *string `json:"next_cursor,omitempty"` + // Page Current page number (1-indexed) Page int `json:"page"` + // PrevCursor Opaque cursor for the previous page (cursor pagination only; present when a previous page exists). Send as `ending_before`. + PrevCursor *string `json:"prev_cursor,omitempty"` + // Total Total number of items across all pages Total int `json:"total"` } @@ -3688,12 +3868,18 @@ type PaginatedFrontends struct { // Limit Number of items per page Limit int `json:"limit"` - // Next URL path to next page (only present if has_more is true) + // Next URL path to next page (offset pagination only; present if has_more is true) Next *string `json:"next,omitempty"` + // NextCursor Opaque cursor for the next page (cursor pagination only; present if has_more is true) + NextCursor *string `json:"next_cursor,omitempty"` + // Page Current page number (1-indexed) Page int `json:"page"` + // PrevCursor Opaque cursor for the previous page (cursor pagination only; present when a previous page exists). Send as `ending_before`. + PrevCursor *string `json:"prev_cursor,omitempty"` + // Total Total number of items across all pages Total int `json:"total"` } @@ -3731,9 +3917,15 @@ type PaginatedFunctions struct { // Next URL path to next page (only present if has_more is true) Next *string `json:"next,omitempty"` + // NextCursor Opaque cursor for the next page (cursor pagination only; present if has_more is true) + NextCursor *string `json:"next_cursor,omitempty"` + // Page Current page number (1-indexed) Page int `json:"page"` + // PrevCursor Opaque cursor for the previous page (cursor pagination only; present when a previous page exists). Send as `ending_before`. + PrevCursor *string `json:"prev_cursor,omitempty"` + // Total Total number of items across all pages Total int `json:"total"` } @@ -3819,16 +4011,42 @@ type PaginatedServiceKeys struct { // Limit Number of items per page Limit int `json:"limit"` - // Next URL path to next page (only present if has_more is true) + // Next URL path to next page (offset pagination only; present if has_more is true) Next *string `json:"next,omitempty"` + // NextCursor Opaque cursor for the next page (cursor pagination only; present if has_more is true) + NextCursor *string `json:"next_cursor,omitempty"` + // Page Current page number (1-indexed) Page int `json:"page"` + // PrevCursor Opaque cursor for the previous page (cursor pagination only; present when a previous page exists). Send as `ending_before`. + PrevCursor *string `json:"prev_cursor,omitempty"` + // Total Total number of items across all pages Total int `json:"total"` } +// PaginatedStorageBuckets Cursor-paginated storage buckets (returned only when cursor pagination is requested). +type PaginatedStorageBuckets struct { + Data []StorageBucket `json:"data"` + + // HasMore Whether a next page exists + HasMore bool `json:"has_more"` + + // Limit Number of items per page + Limit int `json:"limit"` + + // NextCursor Opaque cursor for the next page (present if has_more is true) + NextCursor *string `json:"next_cursor,omitempty"` + + // PrevCursor Opaque cursor for the previous page (present when a previous page exists). Send as `ending_before`. + PrevCursor *string `json:"prev_cursor,omitempty"` + + // Total Total number of items matching the query + Total *int `json:"total,omitempty"` +} + // PaginatedVariables defines model for PaginatedVariables. type PaginatedVariables struct { Data []Variable `json:"data"` @@ -3842,9 +4060,15 @@ type PaginatedVariables struct { // Next URL path to next page (only present if has_more is true) Next *string `json:"next,omitempty"` + // NextCursor Opaque cursor for the next page (cursor pagination only; present if has_more is true) + NextCursor *string `json:"next_cursor,omitempty"` + // Page Current page number (1-indexed) Page int `json:"page"` + // PrevCursor Opaque cursor for the previous page (cursor pagination only; present when a previous page exists). Send as `ending_before`. + PrevCursor *string `json:"prev_cursor,omitempty"` + // Total Total number of items across all pages Total int `json:"total"` } @@ -4402,6 +4626,19 @@ type ProjectFrontendCustomDomainTlsMode string // ProjectFrontendCustomDomainVerificationStatus defines model for ProjectFrontendCustomDomain.VerificationStatus. type ProjectFrontendCustomDomainVerificationStatus string +// ProjectGitConnection defines model for ProjectGitConnection. +type ProjectGitConnection struct { + // ProductionBranch The repository's GitHub default branch, cached at connect time and used as the deployment target. + ProductionBranch string `json:"production_branch"` + RepoFullName string `json:"repo_full_name"` + + // RepoId Stable GitHub repository id (repository.id), the authoritative binding. + RepoId int64 `json:"repo_id"` + RepoInstallationId int64 `json:"repo_installation_id"` + RootDirectory string `json:"root_directory"` + UpdatedAt time.Time `json:"updated_at"` +} + // ProjectHealthCategory defines model for ProjectHealthCategory. type ProjectHealthCategory string @@ -4847,9 +5084,12 @@ type UpdateAuthConfigRequest struct { AllowPasswordReset *bool `json:"allow_password_reset,omitempty"` // AllowedRedirectUrls Redirect allowlist. Every entry must be a valid http/https URL. - AllowedRedirectUrls *[]string `json:"allowed_redirect_urls,omitempty"` - CorsAllowCredentials *bool `json:"cors_allow_credentials,omitempty"` - CorsMaxAge *int `json:"cors_max_age,omitempty"` + AllowedRedirectUrls *[]string `json:"allowed_redirect_urls,omitempty"` + + // AutoLinkVerifiedOauth Link a verified OAuth identity to an existing confirmed account with the same email instead of returning a conflict. Requires require_email_confirmation to be true. + AutoLinkVerifiedOauth *bool `json:"auto_link_verified_oauth,omitempty"` + CorsAllowCredentials *bool `json:"cors_allow_credentials,omitempty"` + CorsMaxAge *int `json:"cors_max_age,omitempty"` // DeviceVerificationUrl Optional custom device-authorization verification page. Must be a // valid http/https URL (not tied to allowed_redirect_urls). When set, @@ -4901,7 +5141,7 @@ type UpdateAuthConfigRequest struct { RequireUppercase *bool `json:"require_uppercase,omitempty"` SmtpHost *string `json:"smtp_host,omitempty"` - // SmtpPassword SMTP password (sensitive). Encrypted at rest (AES-256-GCM) when stored. + // SmtpPassword Replacement SMTP password. Omit this field to preserve the configured password. The value is encrypted at rest and never returned. SmtpPassword *string `json:"smtp_password,omitempty"` SmtpPort *int `json:"smtp_port,omitempty"` SmtpUseTls *bool `json:"smtp_use_tls,omitempty"` @@ -5089,12 +5329,18 @@ type VariableStatus string // BucketName defines model for BucketName. type BucketName = string +// Cursor defines model for Cursor. +type Cursor = string + // DatabaseName defines model for DatabaseName. type DatabaseName = string // DeploymentId defines model for DeploymentId. type DeploymentId = openapi_types.UUID +// EndingBefore defines model for EndingBefore. +type EndingBefore = string + // FrontendId defines model for FrontendId. type FrontendId = openapi_types.UUID @@ -5104,6 +5350,9 @@ type FunctionId = openapi_types.UUID // Limit defines model for Limit. type Limit = int +// Offset defines model for Offset. +type Offset = int + // Page defines model for Page. type Page = int @@ -5113,6 +5362,9 @@ type ProjectId = openapi_types.UUID // SchedulerId defines model for SchedulerId. type SchedulerId = openapi_types.UUID +// Search defines model for Search. +type Search = string + // VariableName defines model for VariableName. type VariableName = string @@ -5468,6 +5720,18 @@ type ResolveFunctionForInvocationParams struct { Name string `form:"name" json:"name"` } +// GitConnectCallbackParams defines parameters for GitConnectCallback. +type GitConnectCallbackParams struct { + // Code GitHub user authorization code. + Code *string `form:"code,omitempty" json:"code,omitempty"` + + // State Signed connect state generated by startGitConnect. + State string `form:"state" json:"state"` + + // Error Provider error returned by GitHub. + Error *string `form:"error,omitempty" json:"error,omitempty"` +} + // ListProjectsParams defines parameters for ListProjects. type ListProjectsParams struct { // Page Page number (1-indexed) @@ -5477,6 +5741,39 @@ type ListProjectsParams struct { Limit *Limit `form:"limit,omitempty" json:"limit,omitempty"` } +// ListAnonKeysParams defines parameters for ListAnonKeys. +type ListAnonKeysParams struct { + // Page Page number (1-indexed) + Page *Page `form:"page,omitempty" json:"page,omitempty"` + + // Limit Number of items per page (max 100) + Limit *Limit `form:"limit,omitempty" json:"limit,omitempty"` + + // Cursor Opaque keyset pagination cursor from a previous response's `next_cursor` + // — pages forward. Mutually exclusive with `page` and `ending_before`; + // combining them returns 400. When supplied, the request's `search` and + // `limit` must match the values bound to the cursor or the request returns 400. + Cursor *Cursor `form:"cursor,omitempty" json:"cursor,omitempty"` + + // EndingBefore Opaque keyset pagination cursor from a previous response's `prev_cursor` + // — pages backward (the page immediately preceding this cursor). Mutually + // exclusive with `page` and `cursor`; combining them returns 400. `search` + // and `limit` must match the values bound to the cursor or the request + // returns 400. + EndingBefore *EndingBefore `form:"ending_before,omitempty" json:"ending_before,omitempty"` + + // Offset Bounded row offset past the keyset anchor named by `cursor` (forward) or + // `ending_before` (backward) — the hybrid jump. Seek to the anchor, then + // skip this many rows within. Used for numbered jump-to-page: from the + // current page, seek to its next/prev cursor and offset the remaining + // pages. Only honored on the cursor pagination path; ignored otherwise. + Offset *Offset `form:"offset,omitempty" json:"offset,omitempty"` + + // Search Case-insensitive substring match on the resource `name`. Only honored on + // the cursor pagination path. + Search *Search `form:"search,omitempty" json:"search,omitempty"` +} + // CreateAnonKeyJSONBody defines parameters for CreateAnonKey. type CreateAnonKeyJSONBody struct { // Name Key name for identification. @@ -5528,6 +5825,18 @@ type GetHostedLoginOptionsParams struct { AnonKey string `form:"anon_key" json:"anon_key"` } +// GetAuthInsightsParams defines parameters for GetAuthInsights. +type GetAuthInsightsParams struct { + // From Inclusive UTC start date. Defaults to 29 days before `to`. + From *openapi_types.Date `form:"from,omitempty" json:"from,omitempty"` + + // To Inclusive UTC end date. Defaults to today. + To *openapi_types.Date `form:"to,omitempty" json:"to,omitempty"` + + // Interval Chart bucket size. Defaults to `day`. + Interval *AuthInsightsInterval `form:"interval,omitempty" json:"interval,omitempty"` +} + // ConfigureAuthMethodsJSONBody defines parameters for ConfigureAuthMethods. type ConfigureAuthMethodsJSONBody struct { EnableAnonymous *bool `json:"enable_anonymous,omitempty"` @@ -5584,6 +5893,30 @@ type ListDatabasesParams struct { // Limit Number of items per page (max 100) Limit *Limit `form:"limit,omitempty" json:"limit,omitempty"` + + // Cursor Opaque keyset pagination cursor from a previous response's `next_cursor` + // — pages forward. Mutually exclusive with `page` and `ending_before`; + // combining them returns 400. When supplied, the request's `search` and + // `limit` must match the values bound to the cursor or the request returns 400. + Cursor *Cursor `form:"cursor,omitempty" json:"cursor,omitempty"` + + // EndingBefore Opaque keyset pagination cursor from a previous response's `prev_cursor` + // — pages backward (the page immediately preceding this cursor). Mutually + // exclusive with `page` and `cursor`; combining them returns 400. `search` + // and `limit` must match the values bound to the cursor or the request + // returns 400. + EndingBefore *EndingBefore `form:"ending_before,omitempty" json:"ending_before,omitempty"` + + // Offset Bounded row offset past the keyset anchor named by `cursor` (forward) or + // `ending_before` (backward) — the hybrid jump. Seek to the anchor, then + // skip this many rows within. Used for numbered jump-to-page: from the + // current page, seek to its next/prev cursor and offset the remaining + // pages. Only honored on the cursor pagination path; ignored otherwise. + Offset *Offset `form:"offset,omitempty" json:"offset,omitempty"` + + // Search Case-insensitive substring match on the resource `name`. Only honored on + // the cursor pagination path. + Search *Search `form:"search,omitempty" json:"search,omitempty"` } // GetProjectDatabaseQueriesParams defines parameters for GetProjectDatabaseQueries. @@ -5641,6 +5974,30 @@ type ListFrontendsParams struct { // Limit Number of items per page (max 100) Limit *Limit `form:"limit,omitempty" json:"limit,omitempty"` + + // Cursor Opaque keyset pagination cursor from a previous response's `next_cursor` + // — pages forward. Mutually exclusive with `page` and `ending_before`; + // combining them returns 400. When supplied, the request's `search` and + // `limit` must match the values bound to the cursor or the request returns 400. + Cursor *Cursor `form:"cursor,omitempty" json:"cursor,omitempty"` + + // EndingBefore Opaque keyset pagination cursor from a previous response's `prev_cursor` + // — pages backward (the page immediately preceding this cursor). Mutually + // exclusive with `page` and `cursor`; combining them returns 400. `search` + // and `limit` must match the values bound to the cursor or the request + // returns 400. + EndingBefore *EndingBefore `form:"ending_before,omitempty" json:"ending_before,omitempty"` + + // Offset Bounded row offset past the keyset anchor named by `cursor` (forward) or + // `ending_before` (backward) — the hybrid jump. Seek to the anchor, then + // skip this many rows within. Used for numbered jump-to-page: from the + // current page, seek to its next/prev cursor and offset the remaining + // pages. Only honored on the cursor pagination path; ignored otherwise. + Offset *Offset `form:"offset,omitempty" json:"offset,omitempty"` + + // Search Case-insensitive substring match on the resource `name`. Only honored on + // the cursor pagination path. + Search *Search `form:"search,omitempty" json:"search,omitempty"` } // CreateFrontendMultipartBody defines parameters for CreateFrontend. @@ -5683,6 +6040,30 @@ type ListFunctionsParams struct { // Limit Number of items per page (max 100) Limit *Limit `form:"limit,omitempty" json:"limit,omitempty"` + + // Cursor Opaque keyset pagination cursor from a previous response's `next_cursor` + // — pages forward. Mutually exclusive with `page` and `ending_before`; + // combining them returns 400. When supplied, the request's `search` and + // `limit` must match the values bound to the cursor or the request returns 400. + Cursor *Cursor `form:"cursor,omitempty" json:"cursor,omitempty"` + + // EndingBefore Opaque keyset pagination cursor from a previous response's `prev_cursor` + // — pages backward (the page immediately preceding this cursor). Mutually + // exclusive with `page` and `cursor`; combining them returns 400. `search` + // and `limit` must match the values bound to the cursor or the request + // returns 400. + EndingBefore *EndingBefore `form:"ending_before,omitempty" json:"ending_before,omitempty"` + + // Offset Bounded row offset past the keyset anchor named by `cursor` (forward) or + // `ending_before` (backward) — the hybrid jump. Seek to the anchor, then + // skip this many rows within. Used for numbered jump-to-page: from the + // current page, seek to its next/prev cursor and offset the remaining + // pages. Only honored on the cursor pagination path; ignored otherwise. + Offset *Offset `form:"offset,omitempty" json:"offset,omitempty"` + + // Search Case-insensitive substring match on the resource `name`. Only honored on + // the cursor pagination path. + Search *Search `form:"search,omitempty" json:"search,omitempty"` } // CreateFunctionMultipartBody defines parameters for CreateFunction. @@ -5777,6 +6158,30 @@ type ListProjectSchedulersParams struct { // Limit Number of items per page (max 100) Limit *Limit `form:"limit,omitempty" json:"limit,omitempty"` + + // Cursor Opaque keyset pagination cursor from a previous response's `next_cursor` + // — pages forward. Mutually exclusive with `page` and `ending_before`; + // combining them returns 400. When supplied, the request's `search` and + // `limit` must match the values bound to the cursor or the request returns 400. + Cursor *Cursor `form:"cursor,omitempty" json:"cursor,omitempty"` + + // EndingBefore Opaque keyset pagination cursor from a previous response's `prev_cursor` + // — pages backward (the page immediately preceding this cursor). Mutually + // exclusive with `page` and `cursor`; combining them returns 400. `search` + // and `limit` must match the values bound to the cursor or the request + // returns 400. + EndingBefore *EndingBefore `form:"ending_before,omitempty" json:"ending_before,omitempty"` + + // Offset Bounded row offset past the keyset anchor named by `cursor` (forward) or + // `ending_before` (backward) — the hybrid jump. Seek to the anchor, then + // skip this many rows within. Used for numbered jump-to-page: from the + // current page, seek to its next/prev cursor and offset the remaining + // pages. Only honored on the cursor pagination path; ignored otherwise. + Offset *Offset `form:"offset,omitempty" json:"offset,omitempty"` + + // Search Case-insensitive substring match on the resource `name`. Only honored on + // the cursor pagination path. + Search *Search `form:"search,omitempty" json:"search,omitempty"` } // ListServiceKeysParams defines parameters for ListServiceKeys. @@ -5786,6 +6191,30 @@ type ListServiceKeysParams struct { // Limit Number of items per page (max 100) Limit *Limit `form:"limit,omitempty" json:"limit,omitempty"` + + // Cursor Opaque keyset pagination cursor from a previous response's `next_cursor` + // — pages forward. Mutually exclusive with `page` and `ending_before`; + // combining them returns 400. When supplied, the request's `search` and + // `limit` must match the values bound to the cursor or the request returns 400. + Cursor *Cursor `form:"cursor,omitempty" json:"cursor,omitempty"` + + // EndingBefore Opaque keyset pagination cursor from a previous response's `prev_cursor` + // — pages backward (the page immediately preceding this cursor). Mutually + // exclusive with `page` and `cursor`; combining them returns 400. `search` + // and `limit` must match the values bound to the cursor or the request + // returns 400. + EndingBefore *EndingBefore `form:"ending_before,omitempty" json:"ending_before,omitempty"` + + // Offset Bounded row offset past the keyset anchor named by `cursor` (forward) or + // `ending_before` (backward) — the hybrid jump. Seek to the anchor, then + // skip this many rows within. Used for numbered jump-to-page: from the + // current page, seek to its next/prev cursor and offset the remaining + // pages. Only honored on the cursor pagination path; ignored otherwise. + Offset *Offset `form:"offset,omitempty" json:"offset,omitempty"` + + // Search Case-insensitive substring match on the resource `name`. Only honored on + // the cursor pagination path. + Search *Search `form:"search,omitempty" json:"search,omitempty"` } // CreateServiceKeyJSONBody defines parameters for CreateServiceKey. @@ -5804,6 +6233,44 @@ type CreateServiceKeyJSONBody struct { Permissions *[]string `json:"permissions,omitempty"` } +// ListStorageBucketsParams defines parameters for ListStorageBuckets. +type ListStorageBucketsParams struct { + // Limit Number of items per page (max 100) + Limit *Limit `form:"limit,omitempty" json:"limit,omitempty"` + + // Cursor Opaque keyset pagination cursor from a previous response's `next_cursor` + // — pages forward. Mutually exclusive with `page` and `ending_before`; + // combining them returns 400. When supplied, the request's `search` and + // `limit` must match the values bound to the cursor or the request returns 400. + Cursor *Cursor `form:"cursor,omitempty" json:"cursor,omitempty"` + + // EndingBefore Opaque keyset pagination cursor from a previous response's `prev_cursor` + // — pages backward (the page immediately preceding this cursor). Mutually + // exclusive with `page` and `cursor`; combining them returns 400. `search` + // and `limit` must match the values bound to the cursor or the request + // returns 400. + EndingBefore *EndingBefore `form:"ending_before,omitempty" json:"ending_before,omitempty"` + + // Offset Bounded row offset past the keyset anchor named by `cursor` (forward) or + // `ending_before` (backward) — the hybrid jump. Seek to the anchor, then + // skip this many rows within. Used for numbered jump-to-page: from the + // current page, seek to its next/prev cursor and offset the remaining + // pages. Only honored on the cursor pagination path; ignored otherwise. + Offset *Offset `form:"offset,omitempty" json:"offset,omitempty"` + + // Search Case-insensitive substring match on the resource `name`. Only honored on + // the cursor pagination path. + Search *Search `form:"search,omitempty" json:"search,omitempty"` +} + +// ListStorageBuckets200JSONResponseBody0 defines parameters for ListStorageBuckets. +type ListStorageBuckets200JSONResponseBody0 = []StorageBucket + +// ListStorageBuckets200JSONResponseBody defines parameters for ListStorageBuckets. +type ListStorageBuckets200JSONResponseBody struct { + union json.RawMessage +} + // ListStorageObjectsAdminParams defines parameters for ListStorageObjectsAdmin. type ListStorageObjectsAdminParams struct { // OwnerId Filter by owner user ID @@ -5814,6 +6281,30 @@ type ListStorageObjectsAdminParams struct { // Limit Items per page Limit *int `form:"limit,omitempty" json:"limit,omitempty"` + + // Cursor Opaque keyset pagination cursor from a previous response's `next_cursor` + // — pages forward. Mutually exclusive with `page` and `ending_before`; + // combining them returns 400. When supplied, the request's `search` and + // `limit` must match the values bound to the cursor or the request returns 400. + Cursor *Cursor `form:"cursor,omitempty" json:"cursor,omitempty"` + + // EndingBefore Opaque keyset pagination cursor from a previous response's `prev_cursor` + // — pages backward (the page immediately preceding this cursor). Mutually + // exclusive with `page` and `cursor`; combining them returns 400. `search` + // and `limit` must match the values bound to the cursor or the request + // returns 400. + EndingBefore *EndingBefore `form:"ending_before,omitempty" json:"ending_before,omitempty"` + + // Offset Bounded row offset past the keyset anchor named by `cursor` (forward) or + // `ending_before` (backward) — the hybrid jump. Seek to the anchor, then + // skip this many rows within. Used for numbered jump-to-page: from the + // current page, seek to its next/prev cursor and offset the remaining + // pages. Only honored on the cursor pagination path; ignored otherwise. + Offset *Offset `form:"offset,omitempty" json:"offset,omitempty"` + + // Search Case-insensitive substring match on the resource `name`. Only honored on + // the cursor pagination path. + Search *Search `form:"search,omitempty" json:"search,omitempty"` } // ListVariablesParams defines parameters for ListVariables. @@ -5823,6 +6314,30 @@ type ListVariablesParams struct { // Limit Number of items per page (max 100) Limit *Limit `form:"limit,omitempty" json:"limit,omitempty"` + + // Cursor Opaque keyset pagination cursor from a previous response's `next_cursor` + // — pages forward. Mutually exclusive with `page` and `ending_before`; + // combining them returns 400. When supplied, the request's `search` and + // `limit` must match the values bound to the cursor or the request returns 400. + Cursor *Cursor `form:"cursor,omitempty" json:"cursor,omitempty"` + + // EndingBefore Opaque keyset pagination cursor from a previous response's `prev_cursor` + // — pages backward (the page immediately preceding this cursor). Mutually + // exclusive with `page` and `cursor`; combining them returns 400. `search` + // and `limit` must match the values bound to the cursor or the request + // returns 400. + EndingBefore *EndingBefore `form:"ending_before,omitempty" json:"ending_before,omitempty"` + + // Offset Bounded row offset past the keyset anchor named by `cursor` (forward) or + // `ending_before` (backward) — the hybrid jump. Seek to the anchor, then + // skip this many rows within. Used for numbered jump-to-page: from the + // current page, seek to its next/prev cursor and offset the remaining + // pages. Only honored on the cursor pagination path; ignored otherwise. + Offset *Offset `form:"offset,omitempty" json:"offset,omitempty"` + + // Search Case-insensitive substring match on the resource `name`. Only honored on + // the cursor pagination path. + Search *Search `form:"search,omitempty" json:"search,omitempty"` } // ListStorageObjectsParams defines parameters for ListStorageObjects. @@ -5886,6 +6401,18 @@ type UploadPartParams struct { XPartNumber int `json:"X-Part-Number"` } +// StartGitConnectParams defines parameters for StartGitConnect. +type StartGitConnectParams struct { + // Provider Git provider to connect. Defaults to github. + Provider *StartGitConnectParamsProvider `form:"provider,omitempty" json:"provider,omitempty"` + + // Redirect URL to redirect the browser to after the provider callback completes. + Redirect *string `form:"redirect,omitempty" json:"redirect,omitempty"` +} + +// StartGitConnectParamsProvider defines parameters for StartGitConnect. +type StartGitConnectParamsProvider string + // AuthConfirmEmailJSONRequestBody defines body for AuthConfirmEmail for application/json ContentType. type AuthConfirmEmailJSONRequestBody AuthConfirmEmailJSONBody @@ -6018,6 +6545,9 @@ type CreateFunctionSchedulerJSONRequestBody = CreateFunctionSchedulerRequest // UpdateFunctionSchedulerJSONRequestBody defines body for UpdateFunctionScheduler for application/json ContentType. type UpdateFunctionSchedulerJSONRequestBody = UpdateFunctionSchedulerRequest +// ConnectProjectGitJSONRequestBody defines body for ConnectProjectGit for application/json ContentType. +type ConnectProjectGitJSONRequestBody = ConnectProjectGitRequest + // UploadProjectLogoMultipartRequestBody defines body for UploadProjectLogo for multipart/form-data ContentType. type UploadProjectLogoMultipartRequestBody UploadProjectLogoMultipartBody @@ -6075,6 +6605,146 @@ type UploadStorageObjectMultipartRequestBody UploadStorageObjectMultipartBody // UpdateStorageObjectVisibilityJSONRequestBody defines body for UpdateStorageObjectVisibility for application/json ContentType. type UpdateStorageObjectVisibilityJSONRequestBody = StorageVisibilityRequest +// AsLogEventBody0 returns the union data inside the LogEvent_Body as a LogEventBody0 +func (t LogEvent_Body) AsLogEventBody0() (LogEventBody0, error) { + var body LogEventBody0 + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromLogEventBody0 overwrites any union data inside the LogEvent_Body as the provided LogEventBody0 +func (t *LogEvent_Body) FromLogEventBody0(v LogEventBody0) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeLogEventBody0 performs a merge with any union data inside the LogEvent_Body, using the provided LogEventBody0 +func (t *LogEvent_Body) MergeLogEventBody0(v LogEventBody0) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JSONMerge(t.union, b) + t.union = merged + return err +} + +// AsLogEventBody1 returns the union data inside the LogEvent_Body as a LogEventBody1 +func (t LogEvent_Body) AsLogEventBody1() (LogEventBody1, error) { + var body LogEventBody1 + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromLogEventBody1 overwrites any union data inside the LogEvent_Body as the provided LogEventBody1 +func (t *LogEvent_Body) FromLogEventBody1(v LogEventBody1) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeLogEventBody1 performs a merge with any union data inside the LogEvent_Body, using the provided LogEventBody1 +func (t *LogEvent_Body) MergeLogEventBody1(v LogEventBody1) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JSONMerge(t.union, b) + t.union = merged + return err +} + +// AsLogEventBody2 returns the union data inside the LogEvent_Body as a LogEventBody2 +func (t LogEvent_Body) AsLogEventBody2() (LogEventBody2, error) { + var body LogEventBody2 + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromLogEventBody2 overwrites any union data inside the LogEvent_Body as the provided LogEventBody2 +func (t *LogEvent_Body) FromLogEventBody2(v LogEventBody2) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeLogEventBody2 performs a merge with any union data inside the LogEvent_Body, using the provided LogEventBody2 +func (t *LogEvent_Body) MergeLogEventBody2(v LogEventBody2) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JSONMerge(t.union, b) + t.union = merged + return err +} + +// AsLogEventBody3 returns the union data inside the LogEvent_Body as a LogEventBody3 +func (t LogEvent_Body) AsLogEventBody3() (LogEventBody3, error) { + var body LogEventBody3 + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromLogEventBody3 overwrites any union data inside the LogEvent_Body as the provided LogEventBody3 +func (t *LogEvent_Body) FromLogEventBody3(v LogEventBody3) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeLogEventBody3 performs a merge with any union data inside the LogEvent_Body, using the provided LogEventBody3 +func (t *LogEvent_Body) MergeLogEventBody3(v LogEventBody3) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JSONMerge(t.union, b) + t.union = merged + return err +} + +// AsLogEventBody4 returns the union data inside the LogEvent_Body as a LogEventBody4 +func (t LogEvent_Body) AsLogEventBody4() (LogEventBody4, error) { + var body LogEventBody4 + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromLogEventBody4 overwrites any union data inside the LogEvent_Body as the provided LogEventBody4 +func (t *LogEvent_Body) FromLogEventBody4(v LogEventBody4) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeLogEventBody4 performs a merge with any union data inside the LogEvent_Body, using the provided LogEventBody4 +func (t *LogEvent_Body) MergeLogEventBody4(v LogEventBody4) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JSONMerge(t.union, b) + t.union = merged + return err +} + +func (t LogEvent_Body) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *LogEvent_Body) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + // AsLogFunctionRequestResource returns the union data inside the LogRequestResource as a LogFunctionRequestResource func (t LogRequestResource) AsLogFunctionRequestResource() (LogFunctionRequestResource, error) { var body LogFunctionRequestResource @@ -6194,6 +6864,146 @@ func (t *LogRequestResource) UnmarshalJSON(b []byte) error { return err } +// AsLogSearchEventBody0 returns the union data inside the LogSearchEvent_Body as a LogSearchEventBody0 +func (t LogSearchEvent_Body) AsLogSearchEventBody0() (LogSearchEventBody0, error) { + var body LogSearchEventBody0 + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromLogSearchEventBody0 overwrites any union data inside the LogSearchEvent_Body as the provided LogSearchEventBody0 +func (t *LogSearchEvent_Body) FromLogSearchEventBody0(v LogSearchEventBody0) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeLogSearchEventBody0 performs a merge with any union data inside the LogSearchEvent_Body, using the provided LogSearchEventBody0 +func (t *LogSearchEvent_Body) MergeLogSearchEventBody0(v LogSearchEventBody0) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JSONMerge(t.union, b) + t.union = merged + return err +} + +// AsLogSearchEventBody1 returns the union data inside the LogSearchEvent_Body as a LogSearchEventBody1 +func (t LogSearchEvent_Body) AsLogSearchEventBody1() (LogSearchEventBody1, error) { + var body LogSearchEventBody1 + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromLogSearchEventBody1 overwrites any union data inside the LogSearchEvent_Body as the provided LogSearchEventBody1 +func (t *LogSearchEvent_Body) FromLogSearchEventBody1(v LogSearchEventBody1) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeLogSearchEventBody1 performs a merge with any union data inside the LogSearchEvent_Body, using the provided LogSearchEventBody1 +func (t *LogSearchEvent_Body) MergeLogSearchEventBody1(v LogSearchEventBody1) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JSONMerge(t.union, b) + t.union = merged + return err +} + +// AsLogSearchEventBody2 returns the union data inside the LogSearchEvent_Body as a LogSearchEventBody2 +func (t LogSearchEvent_Body) AsLogSearchEventBody2() (LogSearchEventBody2, error) { + var body LogSearchEventBody2 + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromLogSearchEventBody2 overwrites any union data inside the LogSearchEvent_Body as the provided LogSearchEventBody2 +func (t *LogSearchEvent_Body) FromLogSearchEventBody2(v LogSearchEventBody2) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeLogSearchEventBody2 performs a merge with any union data inside the LogSearchEvent_Body, using the provided LogSearchEventBody2 +func (t *LogSearchEvent_Body) MergeLogSearchEventBody2(v LogSearchEventBody2) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JSONMerge(t.union, b) + t.union = merged + return err +} + +// AsLogSearchEventBody3 returns the union data inside the LogSearchEvent_Body as a LogSearchEventBody3 +func (t LogSearchEvent_Body) AsLogSearchEventBody3() (LogSearchEventBody3, error) { + var body LogSearchEventBody3 + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromLogSearchEventBody3 overwrites any union data inside the LogSearchEvent_Body as the provided LogSearchEventBody3 +func (t *LogSearchEvent_Body) FromLogSearchEventBody3(v LogSearchEventBody3) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeLogSearchEventBody3 performs a merge with any union data inside the LogSearchEvent_Body, using the provided LogSearchEventBody3 +func (t *LogSearchEvent_Body) MergeLogSearchEventBody3(v LogSearchEventBody3) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JSONMerge(t.union, b) + t.union = merged + return err +} + +// AsLogSearchEventBody4 returns the union data inside the LogSearchEvent_Body as a LogSearchEventBody4 +func (t LogSearchEvent_Body) AsLogSearchEventBody4() (LogSearchEventBody4, error) { + var body LogSearchEventBody4 + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromLogSearchEventBody4 overwrites any union data inside the LogSearchEvent_Body as the provided LogSearchEventBody4 +func (t *LogSearchEvent_Body) FromLogSearchEventBody4(v LogSearchEventBody4) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeLogSearchEventBody4 performs a merge with any union data inside the LogSearchEvent_Body, using the provided LogSearchEventBody4 +func (t *LogSearchEvent_Body) MergeLogSearchEventBody4(v LogSearchEventBody4) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JSONMerge(t.union, b) + t.union = merged + return err +} + +func (t LogSearchEvent_Body) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *LogSearchEvent_Body) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + // AsQueryDatabaseDeleteJSONBodyFiltersValue0 returns the union data inside the QueryDatabaseDeleteJSONBody_Filters_Value as a QueryDatabaseDeleteJSONBodyFiltersValue0 func (t QueryDatabaseDeleteJSONBody_Filters_Value) AsQueryDatabaseDeleteJSONBodyFiltersValue0() (QueryDatabaseDeleteJSONBodyFiltersValue0, error) { var body QueryDatabaseDeleteJSONBodyFiltersValue0 @@ -6572,6 +7382,68 @@ func (t *QueryDatabaseUpdateJSONBody_Filters_Value) UnmarshalJSON(b []byte) erro return err } +// AsListStorageBuckets200JSONResponseBody0 returns the union data inside the ListStorageBuckets200JSONResponseBody as a ListStorageBuckets200JSONResponseBody0 +func (t ListStorageBuckets200JSONResponseBody) AsListStorageBuckets200JSONResponseBody0() (ListStorageBuckets200JSONResponseBody0, error) { + var body ListStorageBuckets200JSONResponseBody0 + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromListStorageBuckets200JSONResponseBody0 overwrites any union data inside the ListStorageBuckets200JSONResponseBody as the provided ListStorageBuckets200JSONResponseBody0 +func (t *ListStorageBuckets200JSONResponseBody) FromListStorageBuckets200JSONResponseBody0(v ListStorageBuckets200JSONResponseBody0) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeListStorageBuckets200JSONResponseBody0 performs a merge with any union data inside the ListStorageBuckets200JSONResponseBody, using the provided ListStorageBuckets200JSONResponseBody0 +func (t *ListStorageBuckets200JSONResponseBody) MergeListStorageBuckets200JSONResponseBody0(v ListStorageBuckets200JSONResponseBody0) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JSONMerge(t.union, b) + t.union = merged + return err +} + +// AsPaginatedStorageBuckets returns the union data inside the ListStorageBuckets200JSONResponseBody as a PaginatedStorageBuckets +func (t ListStorageBuckets200JSONResponseBody) AsPaginatedStorageBuckets() (PaginatedStorageBuckets, error) { + var body PaginatedStorageBuckets + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromPaginatedStorageBuckets overwrites any union data inside the ListStorageBuckets200JSONResponseBody as the provided PaginatedStorageBuckets +func (t *ListStorageBuckets200JSONResponseBody) FromPaginatedStorageBuckets(v PaginatedStorageBuckets) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergePaginatedStorageBuckets performs a merge with any union data inside the ListStorageBuckets200JSONResponseBody, using the provided PaginatedStorageBuckets +func (t *ListStorageBuckets200JSONResponseBody) MergePaginatedStorageBuckets(v PaginatedStorageBuckets) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JSONMerge(t.union, b) + t.union = merged + return err +} + +func (t ListStorageBuckets200JSONResponseBody) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *ListStorageBuckets200JSONResponseBody) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + // AsStorageObject returns the union data inside the UploadStorageObject201JSONResponseBody as a StorageObject func (t UploadStorageObject201JSONResponseBody) AsStorageObject() (StorageObject, error) { var body StorageObject @@ -6894,6 +7766,9 @@ type ClientInterface interface { InvokeFunction(ctx context.Context, functionId FunctionId, body InvokeFunctionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // GitConnectCallback request + GitConnectCallback(ctx context.Context, params *GitConnectCallbackParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // HealthCheck request HealthCheck(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) @@ -6917,7 +7792,7 @@ type ClientInterface interface { UpdateProject(ctx context.Context, id ProjectId, body UpdateProjectJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // ListAnonKeys request - ListAnonKeys(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*http.Response, error) + ListAnonKeys(ctx context.Context, id ProjectId, params *ListAnonKeysParams, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateAnonKeyWithBody request with any body CreateAnonKeyWithBody(ctx context.Context, id ProjectId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) @@ -6971,6 +7846,9 @@ type ClientInterface interface { // RenderManagedAuthPage request RenderManagedAuthPage(ctx context.Context, id ProjectId, pageType HostedRenderablePageType, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetAuthInsights request + GetAuthInsights(ctx context.Context, id ProjectId, params *GetAuthInsightsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetAuthMethods request GetAuthMethods(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*http.Response, error) @@ -7140,6 +8018,17 @@ type ClientInterface interface { UpdateFunctionScheduler(ctx context.Context, id ProjectId, functionId FunctionId, schedulerId SchedulerId, body UpdateFunctionSchedulerJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // DisconnectProjectGit request + DisconnectProjectGit(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetProjectGitConnection request + GetProjectGitConnection(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*http.Response, error) + + // ConnectProjectGitWithBody request with any body + ConnectProjectGitWithBody(ctx context.Context, id ProjectId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + ConnectProjectGit(ctx context.Context, id ProjectId, body ConnectProjectGitJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetProjectHealth request GetProjectHealth(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*http.Response, error) @@ -7226,7 +8115,7 @@ type ClientInterface interface { RegenerateServiceKey(ctx context.Context, id ProjectId, keyId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) // ListStorageBuckets request - ListStorageBuckets(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*http.Response, error) + ListStorageBuckets(ctx context.Context, id ProjectId, params *ListStorageBucketsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateStorageBucketWithBody request with any body CreateStorageBucketWithBody(ctx context.Context, id ProjectId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) @@ -7317,6 +8206,21 @@ type ClientInterface interface { UpdateStorageObjectVisibilityWithBody(ctx context.Context, bucketName BucketName, path string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) UpdateStorageObjectVisibility(ctx context.Context, bucketName BucketName, path string, body UpdateStorageObjectVisibilityJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // StartGitConnect request + StartGitConnect(ctx context.Context, params *StartGitConnectParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // ListGitConnections request + ListGitConnections(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteGitConnection request + DeleteGitConnection(ctx context.Context, connectionId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) + + // ListGitInstallations request + ListGitInstallations(ctx context.Context, connectionId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) + + // ListGitInstallationRepositories request + ListGitInstallationRepositories(ctx context.Context, connectionId openapi_types.UUID, installationId int64, reqEditors ...RequestEditorFn) (*http.Response, error) } func (c *Client) AuthConfirmEmailWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { @@ -8159,6 +9063,18 @@ func (c *Client) InvokeFunction(ctx context.Context, functionId FunctionId, body return c.Client.Do(req) } +func (c *Client) GitConnectCallback(ctx context.Context, params *GitConnectCallbackParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGitConnectCallbackRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + func (c *Client) HealthCheck(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { req, err := NewHealthCheckRequest(c.Server) if err != nil { @@ -8255,8 +9171,8 @@ func (c *Client) UpdateProject(ctx context.Context, id ProjectId, body UpdatePro return c.Client.Do(req) } -func (c *Client) ListAnonKeys(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListAnonKeysRequest(c.Server, id) +func (c *Client) ListAnonKeys(ctx context.Context, id ProjectId, params *ListAnonKeysParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListAnonKeysRequest(c.Server, id, params) if err != nil { return nil, err } @@ -8495,6 +9411,18 @@ func (c *Client) RenderManagedAuthPage(ctx context.Context, id ProjectId, pageTy return c.Client.Do(req) } +func (c *Client) GetAuthInsights(ctx context.Context, id ProjectId, params *GetAuthInsightsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetAuthInsightsRequest(c.Server, id, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + func (c *Client) GetAuthMethods(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*http.Response, error) { req, err := NewGetAuthMethodsRequest(c.Server, id) if err != nil { @@ -9215,6 +10143,54 @@ func (c *Client) UpdateFunctionScheduler(ctx context.Context, id ProjectId, func return c.Client.Do(req) } +func (c *Client) DisconnectProjectGit(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDisconnectProjectGitRequest(c.Server, id) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetProjectGitConnection(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetProjectGitConnectionRequest(c.Server, id) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) ConnectProjectGitWithBody(ctx context.Context, id ProjectId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewConnectProjectGitRequestWithBody(c.Server, id, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) ConnectProjectGit(ctx context.Context, id ProjectId, body ConnectProjectGitJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewConnectProjectGitRequest(c.Server, id, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + func (c *Client) GetProjectHealth(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*http.Response, error) { req, err := NewGetProjectHealthRequest(c.Server, id) if err != nil { @@ -9587,8 +10563,8 @@ func (c *Client) RegenerateServiceKey(ctx context.Context, id ProjectId, keyId o return c.Client.Do(req) } -func (c *Client) ListStorageBuckets(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListStorageBucketsRequest(c.Server, id) +func (c *Client) ListStorageBuckets(ctx context.Context, id ProjectId, params *ListStorageBucketsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListStorageBucketsRequest(c.Server, id, params) if err != nil { return nil, err } @@ -9995,6 +10971,66 @@ func (c *Client) UpdateStorageObjectVisibility(ctx context.Context, bucketName B return c.Client.Do(req) } +func (c *Client) StartGitConnect(ctx context.Context, params *StartGitConnectParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewStartGitConnectRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) ListGitConnections(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListGitConnectionsRequest(c.Server) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteGitConnection(ctx context.Context, connectionId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteGitConnectionRequest(c.Server, connectionId) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) ListGitInstallations(ctx context.Context, connectionId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListGitInstallationsRequest(c.Server, connectionId) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) ListGitInstallationRepositories(ctx context.Context, connectionId openapi_types.UUID, installationId int64, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListGitInstallationRepositoriesRequest(c.Server, connectionId, installationId) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + // NewAuthConfirmEmailRequest calls the generic AuthConfirmEmail builder with application/json body func NewAuthConfirmEmailRequest(server string, body AuthConfirmEmailJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader @@ -11822,6 +12858,80 @@ func NewInvokeFunctionRequestWithBody(server string, functionId FunctionId, cont return req, nil } +// NewGitConnectCallbackRequest generates requests for GitConnectCallback +func NewGitConnectCallbackRequest(server string, params *GitConnectCallbackParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/github/callback") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + // queryValues collects non-styled parameters (passthrough, JSON) + // that are safe to round-trip through url.Values.Encode(). + queryValues := queryURL.Query() + // rawQueryFragments collects pre-encoded query fragments from + // styled parameters, preserving literal commas as delimiters + // per the OpenAPI spec (e.g. "color=blue,black,brown"). + var rawQueryFragments []string + + if params.Code != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "code", *params.Code, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "state", params.State, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + if params.Error != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "error", *params.Error, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if encoded := queryValues.Encode(); encoded != "" { + rawQueryFragments = append(rawQueryFragments, encoded) + } + queryURL.RawQuery = strings.Join(rawQueryFragments, "&") + } + + req, err := http.NewRequest(http.MethodGet, queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + // NewHealthCheckRequest generates requests for HealthCheck func NewHealthCheckRequest(server string) (*http.Request, error) { var err error @@ -12071,7 +13181,7 @@ func NewUpdateProjectRequestWithBody(server string, id ProjectId, contentType st } // NewListAnonKeysRequest generates requests for ListAnonKeys -func NewListAnonKeysRequest(server string, id ProjectId) (*http.Request, error) { +func NewListAnonKeysRequest(server string, id ProjectId, params *ListAnonKeysParams) (*http.Request, error) { var err error var pathParam0 string @@ -12096,6 +13206,93 @@ func NewListAnonKeysRequest(server string, id ProjectId) (*http.Request, error) return nil, err } + if params != nil { + // queryValues collects non-styled parameters (passthrough, JSON) + // that are safe to round-trip through url.Values.Encode(). + queryValues := queryURL.Query() + // rawQueryFragments collects pre-encoded query fragments from + // styled parameters, preserving literal commas as delimiters + // per the OpenAPI spec (e.g. "color=blue,black,brown"). + var rawQueryFragments []string + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "page", *params.Page, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "integer", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Limit != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "limit", *params.Limit, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "integer", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Cursor != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "cursor", *params.Cursor, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.EndingBefore != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "ending_before", *params.EndingBefore, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Offset != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "offset", *params.Offset, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "integer", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Search != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "search", *params.Search, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if encoded := queryValues.Encode(); encoded != "" { + rawQueryFragments = append(rawQueryFragments, encoded) + } + queryURL.RawQuery = strings.Join(rawQueryFragments, "&") + } + req, err := http.NewRequest(http.MethodGet, queryURL.String(), nil) if err != nil { return nil, err @@ -12793,6 +13990,91 @@ func NewRenderManagedAuthPageRequest(server string, id ProjectId, pageType Hoste return req, nil } +// NewGetAuthInsightsRequest generates requests for GetAuthInsights +func NewGetAuthInsightsRequest(server string, id ProjectId, params *GetAuthInsightsParams) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithOptions("simple", false, "id", id, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: "uuid"}) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/projects/%s/auth/insights", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + // queryValues collects non-styled parameters (passthrough, JSON) + // that are safe to round-trip through url.Values.Encode(). + queryValues := queryURL.Query() + // rawQueryFragments collects pre-encoded query fragments from + // styled parameters, preserving literal commas as delimiters + // per the OpenAPI spec (e.g. "color=blue,black,brown"). + var rawQueryFragments []string + + if params.From != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "from", *params.From, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: "date"}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.To != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "to", *params.To, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: "date"}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Interval != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "interval", *params.Interval, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if encoded := queryValues.Encode(); encoded != "" { + rawQueryFragments = append(rawQueryFragments, encoded) + } + queryURL.RawQuery = strings.Join(rawQueryFragments, "&") + } + + req, err := http.NewRequest(http.MethodGet, queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + // NewGetAuthMethodsRequest generates requests for GetAuthMethods func NewGetAuthMethodsRequest(server string, id ProjectId) (*http.Request, error) { var err error @@ -13487,6 +14769,54 @@ func NewListDatabasesRequest(server string, id ProjectId, params *ListDatabasesP } + if params.Cursor != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "cursor", *params.Cursor, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.EndingBefore != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "ending_before", *params.EndingBefore, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Offset != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "offset", *params.Offset, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "integer", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Search != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "search", *params.Search, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + if encoded := queryValues.Encode(); encoded != "" { rawQueryFragments = append(rawQueryFragments, encoded) } @@ -14307,6 +15637,54 @@ func NewListFrontendsRequest(server string, id ProjectId, params *ListFrontendsP } + if params.Cursor != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "cursor", *params.Cursor, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.EndingBefore != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "ending_before", *params.EndingBefore, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Offset != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "offset", *params.Offset, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "integer", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Search != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "search", *params.Search, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + if encoded := queryValues.Encode(); encoded != "" { rawQueryFragments = append(rawQueryFragments, encoded) } @@ -14823,6 +16201,54 @@ func NewListFunctionsRequest(server string, id ProjectId, params *ListFunctionsP } + if params.Cursor != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "cursor", *params.Cursor, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.EndingBefore != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "ending_before", *params.EndingBefore, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Offset != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "offset", *params.Offset, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "integer", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Search != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "search", *params.Search, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + if encoded := queryValues.Encode(); encoded != "" { rawQueryFragments = append(rawQueryFragments, encoded) } @@ -15377,6 +16803,121 @@ func NewUpdateFunctionSchedulerRequestWithBody(server string, id ProjectId, func return req, nil } +// NewDisconnectProjectGitRequest generates requests for DisconnectProjectGit +func NewDisconnectProjectGitRequest(server string, id ProjectId) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithOptions("simple", false, "id", id, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: "uuid"}) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/projects/%s/git-connection", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest(http.MethodDelete, queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetProjectGitConnectionRequest generates requests for GetProjectGitConnection +func NewGetProjectGitConnectionRequest(server string, id ProjectId) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithOptions("simple", false, "id", id, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: "uuid"}) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/projects/%s/git-connection", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest(http.MethodGet, queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewConnectProjectGitRequest calls the generic ConnectProjectGit builder with application/json body +func NewConnectProjectGitRequest(server string, id ProjectId, body ConnectProjectGitJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewConnectProjectGitRequestWithBody(server, id, "application/json", bodyReader) +} + +// NewConnectProjectGitRequestWithBody generates requests for ConnectProjectGit with any type of body +func NewConnectProjectGitRequestWithBody(server string, id ProjectId, contentType string, body io.Reader) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithOptions("simple", false, "id", id, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: "uuid"}) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/projects/%s/git-connection", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest(http.MethodPut, queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + // NewGetProjectHealthRequest generates requests for GetProjectHealth func NewGetProjectHealthRequest(server string, id ProjectId) (*http.Request, error) { var err error @@ -16251,58 +17792,33 @@ func NewListProjectSchedulersRequest(server string, id ProjectId, params *ListPr } - if encoded := queryValues.Encode(); encoded != "" { - rawQueryFragments = append(rawQueryFragments, encoded) - } - queryURL.RawQuery = strings.Join(rawQueryFragments, "&") - } - - req, err := http.NewRequest(http.MethodGet, queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewListServiceKeysRequest generates requests for ListServiceKeys -func NewListServiceKeysRequest(server string, id ProjectId, params *ListServiceKeysParams) (*http.Request, error) { - var err error - - var pathParam0 string + if params.Cursor != nil { - pathParam0, err = runtime.StyleParamWithOptions("simple", false, "id", id, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: "uuid"}) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "cursor", *params.Cursor, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + } - operationPath := fmt.Sprintf("/projects/%s/service-keys", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if params.EndingBefore != nil { - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "ending_before", *params.EndingBefore, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } - if params != nil { - // queryValues collects non-styled parameters (passthrough, JSON) - // that are safe to round-trip through url.Values.Encode(). - queryValues := queryURL.Query() - // rawQueryFragments collects pre-encoded query fragments from - // styled parameters, preserving literal commas as delimiters - // per the OpenAPI spec (e.g. "color=blue,black,brown"). - var rawQueryFragments []string + } - if params.Page != nil { + if params.Offset != nil { - if queryFrag, err := runtime.StyleParamWithOptions("form", true, "page", *params.Page, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "integer", Format: ""}); err != nil { + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "offset", *params.Offset, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "integer", Format: ""}); err != nil { return nil, err } else { for _, qp := range strings.Split(queryFrag, "&") { @@ -16312,9 +17828,9 @@ func NewListServiceKeysRequest(server string, id ProjectId, params *ListServiceK } - if params.Limit != nil { + if params.Search != nil { - if queryFrag, err := runtime.StyleParamWithOptions("form", true, "limit", *params.Limit, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "integer", Format: ""}); err != nil { + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "search", *params.Search, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { return nil, err } else { for _, qp := range strings.Split(queryFrag, "&") { @@ -16338,19 +17854,140 @@ func NewListServiceKeysRequest(server string, id ProjectId, params *ListServiceK return req, nil } -// NewCreateServiceKeyRequest calls the generic CreateServiceKey builder with application/json body -func NewCreateServiceKeyRequest(server string, id ProjectId, body CreateServiceKeyJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreateServiceKeyRequestWithBody(server, id, "application/json", bodyReader) -} - -// NewCreateServiceKeyRequestWithBody generates requests for CreateServiceKey with any type of body -func NewCreateServiceKeyRequestWithBody(server string, id ProjectId, contentType string, body io.Reader) (*http.Request, error) { +// NewListServiceKeysRequest generates requests for ListServiceKeys +func NewListServiceKeysRequest(server string, id ProjectId, params *ListServiceKeysParams) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithOptions("simple", false, "id", id, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: "uuid"}) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/projects/%s/service-keys", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + // queryValues collects non-styled parameters (passthrough, JSON) + // that are safe to round-trip through url.Values.Encode(). + queryValues := queryURL.Query() + // rawQueryFragments collects pre-encoded query fragments from + // styled parameters, preserving literal commas as delimiters + // per the OpenAPI spec (e.g. "color=blue,black,brown"). + var rawQueryFragments []string + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "page", *params.Page, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "integer", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Limit != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "limit", *params.Limit, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "integer", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Cursor != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "cursor", *params.Cursor, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.EndingBefore != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "ending_before", *params.EndingBefore, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Offset != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "offset", *params.Offset, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "integer", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Search != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "search", *params.Search, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if encoded := queryValues.Encode(); encoded != "" { + rawQueryFragments = append(rawQueryFragments, encoded) + } + queryURL.RawQuery = strings.Join(rawQueryFragments, "&") + } + + req, err := http.NewRequest(http.MethodGet, queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewCreateServiceKeyRequest calls the generic CreateServiceKey builder with application/json body +func NewCreateServiceKeyRequest(server string, id ProjectId, body CreateServiceKeyJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewCreateServiceKeyRequestWithBody(server, id, "application/json", bodyReader) +} + +// NewCreateServiceKeyRequestWithBody generates requests for CreateServiceKey with any type of body +func NewCreateServiceKeyRequestWithBody(server string, id ProjectId, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string @@ -16509,7 +18146,7 @@ func NewRegenerateServiceKeyRequest(server string, id ProjectId, keyId openapi_t } // NewListStorageBucketsRequest generates requests for ListStorageBuckets -func NewListStorageBucketsRequest(server string, id ProjectId) (*http.Request, error) { +func NewListStorageBucketsRequest(server string, id ProjectId, params *ListStorageBucketsParams) (*http.Request, error) { var err error var pathParam0 string @@ -16534,6 +18171,81 @@ func NewListStorageBucketsRequest(server string, id ProjectId) (*http.Request, e return nil, err } + if params != nil { + // queryValues collects non-styled parameters (passthrough, JSON) + // that are safe to round-trip through url.Values.Encode(). + queryValues := queryURL.Query() + // rawQueryFragments collects pre-encoded query fragments from + // styled parameters, preserving literal commas as delimiters + // per the OpenAPI spec (e.g. "color=blue,black,brown"). + var rawQueryFragments []string + + if params.Limit != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "limit", *params.Limit, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "integer", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Cursor != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "cursor", *params.Cursor, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.EndingBefore != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "ending_before", *params.EndingBefore, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Offset != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "offset", *params.Offset, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "integer", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Search != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "search", *params.Search, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if encoded := queryValues.Encode(); encoded != "" { + rawQueryFragments = append(rawQueryFragments, encoded) + } + queryURL.RawQuery = strings.Join(rawQueryFragments, "&") + } + req, err := http.NewRequest(http.MethodGet, queryURL.String(), nil) if err != nil { return nil, err @@ -16939,6 +18651,54 @@ func NewListStorageObjectsAdminRequest(server string, id ProjectId, params *List } + if params.Cursor != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "cursor", *params.Cursor, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.EndingBefore != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "ending_before", *params.EndingBefore, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Offset != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "offset", *params.Offset, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "integer", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Search != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "search", *params.Search, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + if encoded := queryValues.Encode(); encoded != "" { rawQueryFragments = append(rawQueryFragments, encoded) } @@ -17080,6 +18840,54 @@ func NewListVariablesRequest(server string, id ProjectId, params *ListVariablesP } + if params.Cursor != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "cursor", *params.Cursor, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.EndingBefore != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "ending_before", *params.EndingBefore, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Offset != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "offset", *params.Offset, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "integer", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + + if params.Search != nil { + + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "search", *params.Search, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { + return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } + } + + } + if encoded := queryValues.Encode(); encoded != "" { rawQueryFragments = append(rawQueryFragments, encoded) } @@ -17527,7 +19335,286 @@ func NewDeleteStorageObjectRequest(server string, bucketName BucketName, path st return nil, err } - operationPath := fmt.Sprintf("/storage/%s/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/storage/%s/%s", pathParam0, pathParam1) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest(http.MethodDelete, queryURL.String(), nil) + if err != nil { + return nil, err + } + + if params != nil { + + if params.XUploadSession != nil { + var headerParam0 string + + headerParam0, err = runtime.StyleParamWithOptions("simple", false, "X-Upload-Session", *params.XUploadSession, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationHeader, Type: "string", Format: ""}) + if err != nil { + return nil, err + } + + req.Header.Set("X-Upload-Session", headerParam0) + } + + } + + return req, nil +} + +// NewDownloadStorageObjectRequest generates requests for DownloadStorageObject +func NewDownloadStorageObjectRequest(server string, bucketName BucketName, path string, params *DownloadStorageObjectParams) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithOptions("simple", false, "bucketName", bucketName, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) + if err != nil { + return nil, err + } + + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithOptions("simple", false, "path", path, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/storage/%s/%s", pathParam0, pathParam1) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest(http.MethodGet, queryURL.String(), nil) + if err != nil { + return nil, err + } + + if params != nil { + + if params.Range != nil { + var headerParam0 string + + headerParam0, err = runtime.StyleParamWithOptions("simple", false, "Range", *params.Range, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationHeader, Type: "string", Format: ""}) + if err != nil { + return nil, err + } + + req.Header.Set("Range", headerParam0) + } + + if params.XUploadSession != nil { + var headerParam1 string + + headerParam1, err = runtime.StyleParamWithOptions("simple", false, "X-Upload-Session", *params.XUploadSession, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationHeader, Type: "string", Format: ""}) + if err != nil { + return nil, err + } + + req.Header.Set("X-Upload-Session", headerParam1) + } + + } + + return req, nil +} + +// NewUploadStorageObjectRequest calls the generic UploadStorageObject builder with application/json body +func NewUploadStorageObjectRequest(server string, bucketName BucketName, path string, params *UploadStorageObjectParams, body UploadStorageObjectJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewUploadStorageObjectRequestWithBody(server, bucketName, path, params, "application/json", bodyReader) +} + +// NewUploadStorageObjectRequestWithBody generates requests for UploadStorageObject with any type of body +func NewUploadStorageObjectRequestWithBody(server string, bucketName BucketName, path string, params *UploadStorageObjectParams, contentType string, body io.Reader) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithOptions("simple", false, "bucketName", bucketName, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) + if err != nil { + return nil, err + } + + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithOptions("simple", false, "path", path, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/storage/%s/%s", pathParam0, pathParam1) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest(http.MethodPost, queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + if params != nil { + + if params.XUploadSession != nil { + var headerParam0 string + + headerParam0, err = runtime.StyleParamWithOptions("simple", false, "X-Upload-Session", *params.XUploadSession, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationHeader, Type: "string", Format: ""}) + if err != nil { + return nil, err + } + + req.Header.Set("X-Upload-Session", headerParam0) + } + + if params.XUploadComplete != nil { + var headerParam1 string + + headerParam1, err = runtime.StyleParamWithOptions("simple", false, "X-Upload-Complete", *params.XUploadComplete, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationHeader, Type: "string", Format: ""}) + if err != nil { + return nil, err + } + + req.Header.Set("X-Upload-Complete", headerParam1) + } + + } + + return req, nil +} + +// NewUploadPartRequestWithBody generates requests for UploadPart with any type of body +func NewUploadPartRequestWithBody(server string, bucketName BucketName, path string, params *UploadPartParams, contentType string, body io.Reader) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithOptions("simple", false, "bucketName", bucketName, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) + if err != nil { + return nil, err + } + + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithOptions("simple", false, "path", path, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/storage/%s/%s", pathParam0, pathParam1) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest(http.MethodPut, queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + if params != nil { + + var headerParam0 string + + headerParam0, err = runtime.StyleParamWithOptions("simple", false, "X-Upload-Session", params.XUploadSession, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationHeader, Type: "string", Format: ""}) + if err != nil { + return nil, err + } + + req.Header.Set("X-Upload-Session", headerParam0) + + var headerParam1 string + + headerParam1, err = runtime.StyleParamWithOptions("simple", false, "X-Part-Number", params.XPartNumber, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationHeader, Type: "integer", Format: ""}) + if err != nil { + return nil, err + } + + req.Header.Set("X-Part-Number", headerParam1) + + } + + return req, nil +} + +// NewUpdateStorageObjectVisibilityRequest calls the generic UpdateStorageObjectVisibility builder with application/json body +func NewUpdateStorageObjectVisibilityRequest(server string, bucketName BucketName, path string, body UpdateStorageObjectVisibilityJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewUpdateStorageObjectVisibilityRequestWithBody(server, bucketName, path, "application/json", bodyReader) +} + +// NewUpdateStorageObjectVisibilityRequestWithBody generates requests for UpdateStorageObjectVisibility with any type of body +func NewUpdateStorageObjectVisibilityRequestWithBody(server string, bucketName BucketName, path string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithOptions("simple", false, "bucketName", bucketName, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) + if err != nil { + return nil, err + } + + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithOptions("simple", false, "path", path, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/storage/%s/%s/visibility", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17537,53 +19624,26 @@ func NewDeleteStorageObjectRequest(server string, bucketName BucketName, path st return nil, err } - req, err := http.NewRequest(http.MethodDelete, queryURL.String(), nil) + req, err := http.NewRequest(http.MethodPatch, queryURL.String(), body) if err != nil { return nil, err } - if params != nil { - - if params.XUploadSession != nil { - var headerParam0 string - - headerParam0, err = runtime.StyleParamWithOptions("simple", false, "X-Upload-Session", *params.XUploadSession, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationHeader, Type: "string", Format: ""}) - if err != nil { - return nil, err - } - - req.Header.Set("X-Upload-Session", headerParam0) - } - - } + req.Header.Add("Content-Type", contentType) return req, nil } -// NewDownloadStorageObjectRequest generates requests for DownloadStorageObject -func NewDownloadStorageObjectRequest(server string, bucketName BucketName, path string, params *DownloadStorageObjectParams) (*http.Request, error) { +// NewStartGitConnectRequest generates requests for StartGitConnect +func NewStartGitConnectRequest(server string, params *StartGitConnectParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithOptions("simple", false, "bucketName", bucketName, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithOptions("simple", false, "path", path, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/storage/%s/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/user/git/connect") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17593,65 +19653,87 @@ func NewDownloadStorageObjectRequest(server string, bucketName BucketName, path return nil, err } - req, err := http.NewRequest(http.MethodGet, queryURL.String(), nil) - if err != nil { - return nil, err - } - if params != nil { + // queryValues collects non-styled parameters (passthrough, JSON) + // that are safe to round-trip through url.Values.Encode(). + queryValues := queryURL.Query() + // rawQueryFragments collects pre-encoded query fragments from + // styled parameters, preserving literal commas as delimiters + // per the OpenAPI spec (e.g. "color=blue,black,brown"). + var rawQueryFragments []string - if params.Range != nil { - var headerParam0 string + if params.Provider != nil { - headerParam0, err = runtime.StyleParamWithOptions("simple", false, "Range", *params.Range, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationHeader, Type: "string", Format: ""}) - if err != nil { + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "provider", *params.Provider, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } } - req.Header.Set("Range", headerParam0) } - if params.XUploadSession != nil { - var headerParam1 string + if params.Redirect != nil { - headerParam1, err = runtime.StyleParamWithOptions("simple", false, "X-Upload-Session", *params.XUploadSession, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationHeader, Type: "string", Format: ""}) - if err != nil { + if queryFrag, err := runtime.StyleParamWithOptions("form", true, "redirect", *params.Redirect, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationQuery, Type: "string", Format: ""}); err != nil { return nil, err + } else { + for _, qp := range strings.Split(queryFrag, "&") { + rawQueryFragments = append(rawQueryFragments, qp) + } } - req.Header.Set("X-Upload-Session", headerParam1) } + if encoded := queryValues.Encode(); encoded != "" { + rawQueryFragments = append(rawQueryFragments, encoded) + } + queryURL.RawQuery = strings.Join(rawQueryFragments, "&") + } + + req, err := http.NewRequest(http.MethodPost, queryURL.String(), nil) + if err != nil { + return nil, err } return req, nil } -// NewUploadStorageObjectRequest calls the generic UploadStorageObject builder with application/json body -func NewUploadStorageObjectRequest(server string, bucketName BucketName, path string, params *UploadStorageObjectParams, body UploadStorageObjectJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) +// NewListGitConnectionsRequest generates requests for ListGitConnections +func NewListGitConnectionsRequest(server string) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewUploadStorageObjectRequestWithBody(server, bucketName, path, params, "application/json", bodyReader) -} -// NewUploadStorageObjectRequestWithBody generates requests for UploadStorageObject with any type of body -func NewUploadStorageObjectRequestWithBody(server string, bucketName BucketName, path string, params *UploadStorageObjectParams, contentType string, body io.Reader) (*http.Request, error) { - var err error + operationPath := fmt.Sprintf("/user/git/connections") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - var pathParam0 string + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - pathParam0, err = runtime.StyleParamWithOptions("simple", false, "bucketName", bucketName, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) + req, err := http.NewRequest(http.MethodGet, queryURL.String(), nil) if err != nil { return nil, err } - var pathParam1 string + return req, nil +} - pathParam1, err = runtime.StyleParamWithOptions("simple", false, "path", path, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) +// NewDeleteGitConnectionRequest generates requests for DeleteGitConnection +func NewDeleteGitConnectionRequest(server string, connectionId openapi_types.UUID) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithOptions("simple", false, "connectionId", connectionId, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: "uuid"}) if err != nil { return nil, err } @@ -17661,7 +19743,7 @@ func NewUploadStorageObjectRequestWithBody(server string, bucketName BucketName, return nil, err } - operationPath := fmt.Sprintf("/storage/%s/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/user/git/connections/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17671,56 +19753,21 @@ func NewUploadStorageObjectRequestWithBody(server string, bucketName BucketName, return nil, err } - req, err := http.NewRequest(http.MethodPost, queryURL.String(), body) + req, err := http.NewRequest(http.MethodDelete, queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - - if params != nil { - - if params.XUploadSession != nil { - var headerParam0 string - - headerParam0, err = runtime.StyleParamWithOptions("simple", false, "X-Upload-Session", *params.XUploadSession, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationHeader, Type: "string", Format: ""}) - if err != nil { - return nil, err - } - - req.Header.Set("X-Upload-Session", headerParam0) - } - - if params.XUploadComplete != nil { - var headerParam1 string - - headerParam1, err = runtime.StyleParamWithOptions("simple", false, "X-Upload-Complete", *params.XUploadComplete, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationHeader, Type: "string", Format: ""}) - if err != nil { - return nil, err - } - - req.Header.Set("X-Upload-Complete", headerParam1) - } - - } - return req, nil } -// NewUploadPartRequestWithBody generates requests for UploadPart with any type of body -func NewUploadPartRequestWithBody(server string, bucketName BucketName, path string, params *UploadPartParams, contentType string, body io.Reader) (*http.Request, error) { +// NewListGitInstallationsRequest generates requests for ListGitInstallations +func NewListGitInstallationsRequest(server string, connectionId openapi_types.UUID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithOptions("simple", false, "bucketName", bucketName, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithOptions("simple", false, "path", path, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) + pathParam0, err = runtime.StyleParamWithOptions("simple", false, "connectionId", connectionId, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: "uuid"}) if err != nil { return nil, err } @@ -17730,7 +19777,7 @@ func NewUploadPartRequestWithBody(server string, bucketName BucketName, path str return nil, err } - operationPath := fmt.Sprintf("/storage/%s/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/user/git/connections/%s/installations", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17740,63 +19787,28 @@ func NewUploadPartRequestWithBody(server string, bucketName BucketName, path str return nil, err } - req, err := http.NewRequest(http.MethodPut, queryURL.String(), body) + req, err := http.NewRequest(http.MethodGet, queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - - if params != nil { - - var headerParam0 string - - headerParam0, err = runtime.StyleParamWithOptions("simple", false, "X-Upload-Session", params.XUploadSession, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationHeader, Type: "string", Format: ""}) - if err != nil { - return nil, err - } - - req.Header.Set("X-Upload-Session", headerParam0) - - var headerParam1 string - - headerParam1, err = runtime.StyleParamWithOptions("simple", false, "X-Part-Number", params.XPartNumber, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationHeader, Type: "integer", Format: ""}) - if err != nil { - return nil, err - } - - req.Header.Set("X-Part-Number", headerParam1) - - } - return req, nil } -// NewUpdateStorageObjectVisibilityRequest calls the generic UpdateStorageObjectVisibility builder with application/json body -func NewUpdateStorageObjectVisibilityRequest(server string, bucketName BucketName, path string, body UpdateStorageObjectVisibilityJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateStorageObjectVisibilityRequestWithBody(server, bucketName, path, "application/json", bodyReader) -} - -// NewUpdateStorageObjectVisibilityRequestWithBody generates requests for UpdateStorageObjectVisibility with any type of body -func NewUpdateStorageObjectVisibilityRequestWithBody(server string, bucketName BucketName, path string, contentType string, body io.Reader) (*http.Request, error) { +// NewListGitInstallationRepositoriesRequest generates requests for ListGitInstallationRepositories +func NewListGitInstallationRepositoriesRequest(server string, connectionId openapi_types.UUID, installationId int64) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithOptions("simple", false, "bucketName", bucketName, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) + pathParam0, err = runtime.StyleParamWithOptions("simple", false, "connectionId", connectionId, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: "uuid"}) if err != nil { return nil, err } var pathParam1 string - pathParam1, err = runtime.StyleParamWithOptions("simple", false, "path", path, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "string", Format: ""}) + pathParam1, err = runtime.StyleParamWithOptions("simple", false, "installationId", installationId, runtime.StyleParamOptions{ParamLocation: runtime.ParamLocationPath, Type: "integer", Format: "int64"}) if err != nil { return nil, err } @@ -17806,7 +19818,7 @@ func NewUpdateStorageObjectVisibilityRequestWithBody(server string, bucketName B return nil, err } - operationPath := fmt.Sprintf("/storage/%s/%s/visibility", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/user/git/connections/%s/installations/%s/repositories", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17816,13 +19828,11 @@ func NewUpdateStorageObjectVisibilityRequestWithBody(server string, bucketName B return nil, err } - req, err := http.NewRequest(http.MethodPatch, queryURL.String(), body) + req, err := http.NewRequest(http.MethodGet, queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } @@ -18056,6 +20066,9 @@ type ClientWithResponsesInterface interface { InvokeFunctionWithResponse(ctx context.Context, functionId FunctionId, body InvokeFunctionJSONRequestBody, reqEditors ...RequestEditorFn) (*InvokeFunctionClientResponse, error) + // GitConnectCallbackWithResponse request + GitConnectCallbackWithResponse(ctx context.Context, params *GitConnectCallbackParams, reqEditors ...RequestEditorFn) (*GitConnectCallbackClientResponse, error) + // HealthCheckWithResponse request HealthCheckWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*HealthCheckClientResponse, error) @@ -18079,7 +20092,7 @@ type ClientWithResponsesInterface interface { UpdateProjectWithResponse(ctx context.Context, id ProjectId, body UpdateProjectJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateProjectClientResponse, error) // ListAnonKeysWithResponse request - ListAnonKeysWithResponse(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*ListAnonKeysClientResponse, error) + ListAnonKeysWithResponse(ctx context.Context, id ProjectId, params *ListAnonKeysParams, reqEditors ...RequestEditorFn) (*ListAnonKeysClientResponse, error) // CreateAnonKeyWithBodyWithResponse request with any body CreateAnonKeyWithBodyWithResponse(ctx context.Context, id ProjectId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateAnonKeyClientResponse, error) @@ -18133,6 +20146,9 @@ type ClientWithResponsesInterface interface { // RenderManagedAuthPageWithResponse request RenderManagedAuthPageWithResponse(ctx context.Context, id ProjectId, pageType HostedRenderablePageType, reqEditors ...RequestEditorFn) (*RenderManagedAuthPageClientResponse, error) + // GetAuthInsightsWithResponse request + GetAuthInsightsWithResponse(ctx context.Context, id ProjectId, params *GetAuthInsightsParams, reqEditors ...RequestEditorFn) (*GetAuthInsightsClientResponse, error) + // GetAuthMethodsWithResponse request GetAuthMethodsWithResponse(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*GetAuthMethodsClientResponse, error) @@ -18302,6 +20318,17 @@ type ClientWithResponsesInterface interface { UpdateFunctionSchedulerWithResponse(ctx context.Context, id ProjectId, functionId FunctionId, schedulerId SchedulerId, body UpdateFunctionSchedulerJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateFunctionSchedulerClientResponse, error) + // DisconnectProjectGitWithResponse request + DisconnectProjectGitWithResponse(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*DisconnectProjectGitClientResponse, error) + + // GetProjectGitConnectionWithResponse request + GetProjectGitConnectionWithResponse(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*GetProjectGitConnectionClientResponse, error) + + // ConnectProjectGitWithBodyWithResponse request with any body + ConnectProjectGitWithBodyWithResponse(ctx context.Context, id ProjectId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ConnectProjectGitClientResponse, error) + + ConnectProjectGitWithResponse(ctx context.Context, id ProjectId, body ConnectProjectGitJSONRequestBody, reqEditors ...RequestEditorFn) (*ConnectProjectGitClientResponse, error) + // GetProjectHealthWithResponse request GetProjectHealthWithResponse(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*GetProjectHealthClientResponse, error) @@ -18388,7 +20415,7 @@ type ClientWithResponsesInterface interface { RegenerateServiceKeyWithResponse(ctx context.Context, id ProjectId, keyId openapi_types.UUID, reqEditors ...RequestEditorFn) (*RegenerateServiceKeyClientResponse, error) // ListStorageBucketsWithResponse request - ListStorageBucketsWithResponse(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*ListStorageBucketsClientResponse, error) + ListStorageBucketsWithResponse(ctx context.Context, id ProjectId, params *ListStorageBucketsParams, reqEditors ...RequestEditorFn) (*ListStorageBucketsClientResponse, error) // CreateStorageBucketWithBodyWithResponse request with any body CreateStorageBucketWithBodyWithResponse(ctx context.Context, id ProjectId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateStorageBucketClientResponse, error) @@ -18479,6 +20506,21 @@ type ClientWithResponsesInterface interface { UpdateStorageObjectVisibilityWithBodyWithResponse(ctx context.Context, bucketName BucketName, path string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateStorageObjectVisibilityClientResponse, error) UpdateStorageObjectVisibilityWithResponse(ctx context.Context, bucketName BucketName, path string, body UpdateStorageObjectVisibilityJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateStorageObjectVisibilityClientResponse, error) + + // StartGitConnectWithResponse request + StartGitConnectWithResponse(ctx context.Context, params *StartGitConnectParams, reqEditors ...RequestEditorFn) (*StartGitConnectClientResponse, error) + + // ListGitConnectionsWithResponse request + ListGitConnectionsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ListGitConnectionsClientResponse, error) + + // DeleteGitConnectionWithResponse request + DeleteGitConnectionWithResponse(ctx context.Context, connectionId openapi_types.UUID, reqEditors ...RequestEditorFn) (*DeleteGitConnectionClientResponse, error) + + // ListGitInstallationsWithResponse request + ListGitInstallationsWithResponse(ctx context.Context, connectionId openapi_types.UUID, reqEditors ...RequestEditorFn) (*ListGitInstallationsClientResponse, error) + + // ListGitInstallationRepositoriesWithResponse request + ListGitInstallationRepositoriesWithResponse(ctx context.Context, connectionId openapi_types.UUID, installationId int64, reqEditors ...RequestEditorFn) (*ListGitInstallationRepositoriesClientResponse, error) } type AuthConfirmEmailClientResponse struct { @@ -20069,6 +22111,39 @@ func (r InvokeFunctionClientResponse) ContentType() string { return "" } +type GitConnectCallbackClientResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *Error + JSON429 *Error + JSON500 *Error + JSON503 *Error +} + +// Status returns HTTPResponse.Status +func (r GitConnectCallbackClientResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GitConnectCallbackClientResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +// ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers +func (r GitConnectCallbackClientResponse) ContentType() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Header.Get("Content-Type") + } + return "" +} + type HealthCheckClientResponse struct { Body []byte HTTPResponse *http.Response @@ -20260,6 +22335,18 @@ type ListAnonKeysClientResponse struct { HTTPResponse *http.Response JSON200 *struct { Data *[]AnonKey `json:"data,omitempty"` + + // HasMore Whether a next page exists. + HasMore *bool `json:"has_more,omitempty"` + + // NextCursor Opaque cursor for the next page (cursor pagination only) + NextCursor *string `json:"next_cursor,omitempty"` + + // PrevCursor Opaque cursor for the previous page (cursor pagination only). Send as `ending_before`. + PrevCursor *string `json:"prev_cursor,omitempty"` + + // Total Total number of items matching the query (so the UI can render numbered pages). + Total *int `json:"total,omitempty"` } } @@ -20707,6 +22794,41 @@ func (r RenderManagedAuthPageClientResponse) ContentType() string { return "" } +type GetAuthInsightsClientResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *AuthInsightsResponse + JSON400 *Error + JSON401 *Error + JSON403 *Error + JSON404 *Error + JSON500 *Error +} + +// Status returns HTTPResponse.Status +func (r GetAuthInsightsClientResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetAuthInsightsClientResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +// ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers +func (r GetAuthInsightsClientResponse) ContentType() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Header.Get("Content-Type") + } + return "" +} + type GetAuthMethodsClientResponse struct { Body []byte HTTPResponse *http.Response @@ -22319,6 +24441,109 @@ func (r UpdateFunctionSchedulerClientResponse) ContentType() string { return "" } +type DisconnectProjectGitClientResponse struct { + Body []byte + HTTPResponse *http.Response + JSON401 *Error + JSON403 *Error + JSON404 *Error + JSON500 *Error +} + +// Status returns HTTPResponse.Status +func (r DisconnectProjectGitClientResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DisconnectProjectGitClientResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +// ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers +func (r DisconnectProjectGitClientResponse) ContentType() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Header.Get("Content-Type") + } + return "" +} + +type GetProjectGitConnectionClientResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *ProjectGitConnection + JSON401 *Error + JSON403 *Error + JSON404 *Error + JSON500 *Error +} + +// Status returns HTTPResponse.Status +func (r GetProjectGitConnectionClientResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetProjectGitConnectionClientResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +// ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers +func (r GetProjectGitConnectionClientResponse) ContentType() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Header.Get("Content-Type") + } + return "" +} + +type ConnectProjectGitClientResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *ProjectGitConnection + JSON400 *Error + JSON401 *Error + JSON403 *Error + JSON404 *Error + JSON500 *Error + JSON503 *Error +} + +// Status returns HTTPResponse.Status +func (r ConnectProjectGitClientResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r ConnectProjectGitClientResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +// ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers +func (r ConnectProjectGitClientResponse) ContentType() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Header.Get("Content-Type") + } + return "" +} + type GetProjectHealthClientResponse struct { Body []byte HTTPResponse *http.Response @@ -23054,7 +25279,7 @@ func (r RegenerateServiceKeyClientResponse) ContentType() string { type ListStorageBucketsClientResponse struct { Body []byte HTTPResponse *http.Response - JSON200 *[]StorageBucket + JSON200 *ListStorageBuckets200JSONResponseBody } // Status returns HTTPResponse.Status @@ -23296,8 +25521,14 @@ type ListStorageObjectsAdminClientResponse struct { Data *[]StorageObjectWithBucket `json:"data,omitempty"` HasMore *bool `json:"has_more,omitempty"` Limit *int `json:"limit,omitempty"` - Page *int `json:"page,omitempty"` - Total *int `json:"total,omitempty"` + + // NextCursor Opaque cursor for the next page (cursor pagination only) + NextCursor *string `json:"next_cursor,omitempty"` + Page *int `json:"page,omitempty"` + + // PrevCursor Opaque cursor for the previous page (cursor pagination only). Send as `ending_before`. + PrevCursor *string `json:"prev_cursor,omitempty"` + Total *int `json:"total,omitempty"` } } @@ -23817,6 +26048,177 @@ func (r UpdateStorageObjectVisibilityClientResponse) ContentType() string { return "" } +type StartGitConnectClientResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *GitConnectStartResponse + JSON400 *Error + JSON401 *Error + JSON500 *Error + JSON503 *Error +} + +// Status returns HTTPResponse.Status +func (r StartGitConnectClientResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r StartGitConnectClientResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +// ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers +func (r StartGitConnectClientResponse) ContentType() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Header.Get("Content-Type") + } + return "" +} + +type ListGitConnectionsClientResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *GitConnectionsResponse + JSON401 *Error + JSON500 *Error + JSON503 *Error +} + +// Status returns HTTPResponse.Status +func (r ListGitConnectionsClientResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r ListGitConnectionsClientResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +// ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers +func (r ListGitConnectionsClientResponse) ContentType() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Header.Get("Content-Type") + } + return "" +} + +type DeleteGitConnectionClientResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *Error + JSON401 *Error + JSON404 *Error + JSON500 *Error + JSON503 *Error +} + +// Status returns HTTPResponse.Status +func (r DeleteGitConnectionClientResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteGitConnectionClientResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +// ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers +func (r DeleteGitConnectionClientResponse) ContentType() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Header.Get("Content-Type") + } + return "" +} + +type ListGitInstallationsClientResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *GitInstallationsResponse + JSON400 *Error + JSON401 *Error + JSON404 *Error + JSON500 *Error + JSON503 *Error +} + +// Status returns HTTPResponse.Status +func (r ListGitInstallationsClientResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r ListGitInstallationsClientResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +// ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers +func (r ListGitInstallationsClientResponse) ContentType() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Header.Get("Content-Type") + } + return "" +} + +type ListGitInstallationRepositoriesClientResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *GitRepositoriesResponse + JSON400 *Error + JSON401 *Error + JSON404 *Error + JSON500 *Error + JSON503 *Error +} + +// Status returns HTTPResponse.Status +func (r ListGitInstallationRepositoriesClientResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r ListGitInstallationRepositoriesClientResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +// ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers +func (r ListGitInstallationRepositoriesClientResponse) ContentType() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Header.Get("Content-Type") + } + return "" +} + // AuthConfirmEmailWithBodyWithResponse request with arbitrary body returning *AuthConfirmEmailClientResponse func (c *ClientWithResponses) AuthConfirmEmailWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthConfirmEmailClientResponse, error) { rsp, err := c.AuthConfirmEmailWithBody(ctx, contentType, body, reqEditors...) @@ -24424,6 +26826,15 @@ func (c *ClientWithResponses) InvokeFunctionWithResponse(ctx context.Context, fu return ParseInvokeFunctionClientResponse(rsp) } +// GitConnectCallbackWithResponse request returning *GitConnectCallbackClientResponse +func (c *ClientWithResponses) GitConnectCallbackWithResponse(ctx context.Context, params *GitConnectCallbackParams, reqEditors ...RequestEditorFn) (*GitConnectCallbackClientResponse, error) { + rsp, err := c.GitConnectCallback(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGitConnectCallbackClientResponse(rsp) +} + // HealthCheckWithResponse request returning *HealthCheckClientResponse func (c *ClientWithResponses) HealthCheckWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*HealthCheckClientResponse, error) { rsp, err := c.HealthCheck(ctx, reqEditors...) @@ -24495,8 +26906,8 @@ func (c *ClientWithResponses) UpdateProjectWithResponse(ctx context.Context, id } // ListAnonKeysWithResponse request returning *ListAnonKeysClientResponse -func (c *ClientWithResponses) ListAnonKeysWithResponse(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*ListAnonKeysClientResponse, error) { - rsp, err := c.ListAnonKeys(ctx, id, reqEditors...) +func (c *ClientWithResponses) ListAnonKeysWithResponse(ctx context.Context, id ProjectId, params *ListAnonKeysParams, reqEditors ...RequestEditorFn) (*ListAnonKeysClientResponse, error) { + rsp, err := c.ListAnonKeys(ctx, id, params, reqEditors...) if err != nil { return nil, err } @@ -24669,6 +27080,15 @@ func (c *ClientWithResponses) RenderManagedAuthPageWithResponse(ctx context.Cont return ParseRenderManagedAuthPageClientResponse(rsp) } +// GetAuthInsightsWithResponse request returning *GetAuthInsightsClientResponse +func (c *ClientWithResponses) GetAuthInsightsWithResponse(ctx context.Context, id ProjectId, params *GetAuthInsightsParams, reqEditors ...RequestEditorFn) (*GetAuthInsightsClientResponse, error) { + rsp, err := c.GetAuthInsights(ctx, id, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetAuthInsightsClientResponse(rsp) +} + // GetAuthMethodsWithResponse request returning *GetAuthMethodsClientResponse func (c *ClientWithResponses) GetAuthMethodsWithResponse(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*GetAuthMethodsClientResponse, error) { rsp, err := c.GetAuthMethods(ctx, id, reqEditors...) @@ -25198,6 +27618,41 @@ func (c *ClientWithResponses) UpdateFunctionSchedulerWithResponse(ctx context.Co return ParseUpdateFunctionSchedulerClientResponse(rsp) } +// DisconnectProjectGitWithResponse request returning *DisconnectProjectGitClientResponse +func (c *ClientWithResponses) DisconnectProjectGitWithResponse(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*DisconnectProjectGitClientResponse, error) { + rsp, err := c.DisconnectProjectGit(ctx, id, reqEditors...) + if err != nil { + return nil, err + } + return ParseDisconnectProjectGitClientResponse(rsp) +} + +// GetProjectGitConnectionWithResponse request returning *GetProjectGitConnectionClientResponse +func (c *ClientWithResponses) GetProjectGitConnectionWithResponse(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*GetProjectGitConnectionClientResponse, error) { + rsp, err := c.GetProjectGitConnection(ctx, id, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetProjectGitConnectionClientResponse(rsp) +} + +// ConnectProjectGitWithBodyWithResponse request with arbitrary body returning *ConnectProjectGitClientResponse +func (c *ClientWithResponses) ConnectProjectGitWithBodyWithResponse(ctx context.Context, id ProjectId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ConnectProjectGitClientResponse, error) { + rsp, err := c.ConnectProjectGitWithBody(ctx, id, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseConnectProjectGitClientResponse(rsp) +} + +func (c *ClientWithResponses) ConnectProjectGitWithResponse(ctx context.Context, id ProjectId, body ConnectProjectGitJSONRequestBody, reqEditors ...RequestEditorFn) (*ConnectProjectGitClientResponse, error) { + rsp, err := c.ConnectProjectGit(ctx, id, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseConnectProjectGitClientResponse(rsp) +} + // GetProjectHealthWithResponse request returning *GetProjectHealthClientResponse func (c *ClientWithResponses) GetProjectHealthWithResponse(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*GetProjectHealthClientResponse, error) { rsp, err := c.GetProjectHealth(ctx, id, reqEditors...) @@ -25470,8 +27925,8 @@ func (c *ClientWithResponses) RegenerateServiceKeyWithResponse(ctx context.Conte } // ListStorageBucketsWithResponse request returning *ListStorageBucketsClientResponse -func (c *ClientWithResponses) ListStorageBucketsWithResponse(ctx context.Context, id ProjectId, reqEditors ...RequestEditorFn) (*ListStorageBucketsClientResponse, error) { - rsp, err := c.ListStorageBuckets(ctx, id, reqEditors...) +func (c *ClientWithResponses) ListStorageBucketsWithResponse(ctx context.Context, id ProjectId, params *ListStorageBucketsParams, reqEditors ...RequestEditorFn) (*ListStorageBucketsClientResponse, error) { + rsp, err := c.ListStorageBuckets(ctx, id, params, reqEditors...) if err != nil { return nil, err } @@ -25766,6 +28221,51 @@ func (c *ClientWithResponses) UpdateStorageObjectVisibilityWithResponse(ctx cont return ParseUpdateStorageObjectVisibilityClientResponse(rsp) } +// StartGitConnectWithResponse request returning *StartGitConnectClientResponse +func (c *ClientWithResponses) StartGitConnectWithResponse(ctx context.Context, params *StartGitConnectParams, reqEditors ...RequestEditorFn) (*StartGitConnectClientResponse, error) { + rsp, err := c.StartGitConnect(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseStartGitConnectClientResponse(rsp) +} + +// ListGitConnectionsWithResponse request returning *ListGitConnectionsClientResponse +func (c *ClientWithResponses) ListGitConnectionsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ListGitConnectionsClientResponse, error) { + rsp, err := c.ListGitConnections(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseListGitConnectionsClientResponse(rsp) +} + +// DeleteGitConnectionWithResponse request returning *DeleteGitConnectionClientResponse +func (c *ClientWithResponses) DeleteGitConnectionWithResponse(ctx context.Context, connectionId openapi_types.UUID, reqEditors ...RequestEditorFn) (*DeleteGitConnectionClientResponse, error) { + rsp, err := c.DeleteGitConnection(ctx, connectionId, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteGitConnectionClientResponse(rsp) +} + +// ListGitInstallationsWithResponse request returning *ListGitInstallationsClientResponse +func (c *ClientWithResponses) ListGitInstallationsWithResponse(ctx context.Context, connectionId openapi_types.UUID, reqEditors ...RequestEditorFn) (*ListGitInstallationsClientResponse, error) { + rsp, err := c.ListGitInstallations(ctx, connectionId, reqEditors...) + if err != nil { + return nil, err + } + return ParseListGitInstallationsClientResponse(rsp) +} + +// ListGitInstallationRepositoriesWithResponse request returning *ListGitInstallationRepositoriesClientResponse +func (c *ClientWithResponses) ListGitInstallationRepositoriesWithResponse(ctx context.Context, connectionId openapi_types.UUID, installationId int64, reqEditors ...RequestEditorFn) (*ListGitInstallationRepositoriesClientResponse, error) { + rsp, err := c.ListGitInstallationRepositories(ctx, connectionId, installationId, reqEditors...) + if err != nil { + return nil, err + } + return ParseListGitInstallationRepositoriesClientResponse(rsp) +} + // ParseAuthConfirmEmailClientResponse parses an HTTP response from a AuthConfirmEmailWithResponse call func ParseAuthConfirmEmailClientResponse(rsp *http.Response) (*AuthConfirmEmailClientResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) @@ -27622,6 +30122,53 @@ func ParseInvokeFunctionClientResponse(rsp *http.Response) (*InvokeFunctionClien return response, nil } +// ParseGitConnectCallbackClientResponse parses an HTTP response from a GitConnectCallbackWithResponse call +func ParseGitConnectCallbackClientResponse(rsp *http.Response) (*GitConnectCallbackClientResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GitConnectCallbackClientResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON503 = &dest + + } + + return response, nil +} + // ParseHealthCheckClientResponse parses an HTTP response from a HealthCheckWithResponse call func ParseHealthCheckClientResponse(rsp *http.Response) (*HealthCheckClientResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) @@ -27834,6 +30381,18 @@ func ParseListAnonKeysClientResponse(rsp *http.Response) (*ListAnonKeysClientRes case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { Data *[]AnonKey `json:"data,omitempty"` + + // HasMore Whether a next page exists. + HasMore *bool `json:"has_more,omitempty"` + + // NextCursor Opaque cursor for the next page (cursor pagination only) + NextCursor *string `json:"next_cursor,omitempty"` + + // PrevCursor Opaque cursor for the previous page (cursor pagination only). Send as `ending_before`. + PrevCursor *string `json:"prev_cursor,omitempty"` + + // Total Total number of items matching the query (so the UI can render numbered pages). + Total *int `json:"total,omitempty"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err @@ -28203,6 +30762,67 @@ func ParseRenderManagedAuthPageClientResponse(rsp *http.Response) (*RenderManage return response, nil } +// ParseGetAuthInsightsClientResponse parses an HTTP response from a GetAuthInsightsWithResponse call +func ParseGetAuthInsightsClientResponse(rsp *http.Response) (*GetAuthInsightsClientResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetAuthInsightsClientResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest AuthInsightsResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil +} + // ParseGetAuthMethodsClientResponse parses an HTTP response from a GetAuthMethodsWithResponse call func ParseGetAuthMethodsClientResponse(rsp *http.Response) (*GetAuthMethodsClientResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) @@ -30168,6 +32788,175 @@ func ParseUpdateFunctionSchedulerClientResponse(rsp *http.Response) (*UpdateFunc return response, nil } +// ParseDisconnectProjectGitClientResponse parses an HTTP response from a DisconnectProjectGitWithResponse call +func ParseDisconnectProjectGitClientResponse(rsp *http.Response) (*DisconnectProjectGitClientResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DisconnectProjectGitClientResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil +} + +// ParseGetProjectGitConnectionClientResponse parses an HTTP response from a GetProjectGitConnectionWithResponse call +func ParseGetProjectGitConnectionClientResponse(rsp *http.Response) (*GetProjectGitConnectionClientResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetProjectGitConnectionClientResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest ProjectGitConnection + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil +} + +// ParseConnectProjectGitClientResponse parses an HTTP response from a ConnectProjectGitWithResponse call +func ParseConnectProjectGitClientResponse(rsp *http.Response) (*ConnectProjectGitClientResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &ConnectProjectGitClientResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest ProjectGitConnection + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON503 = &dest + + } + + return response, nil +} + // ParseGetProjectHealthClientResponse parses an HTTP response from a GetProjectHealthWithResponse call func ParseGetProjectHealthClientResponse(rsp *http.Response) (*GetProjectHealthClientResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) @@ -31021,7 +33810,7 @@ func ParseListStorageBucketsClientResponse(rsp *http.Response) (*ListStorageBuck switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest []StorageBucket + var dest ListStorageBuckets200JSONResponseBody if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -31213,8 +34002,14 @@ func ParseListStorageObjectsAdminClientResponse(rsp *http.Response) (*ListStorag Data *[]StorageObjectWithBucket `json:"data,omitempty"` HasMore *bool `json:"has_more,omitempty"` Limit *int `json:"limit,omitempty"` - Page *int `json:"page,omitempty"` - Total *int `json:"total,omitempty"` + + // NextCursor Opaque cursor for the next page (cursor pagination only) + NextCursor *string `json:"next_cursor,omitempty"` + Page *int `json:"page,omitempty"` + + // PrevCursor Opaque cursor for the previous page (cursor pagination only). Send as `ending_before`. + PrevCursor *string `json:"prev_cursor,omitempty"` + Total *int `json:"total,omitempty"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err @@ -31728,3 +34523,280 @@ func ParseUpdateStorageObjectVisibilityClientResponse(rsp *http.Response) (*Upda return response, nil } + +// ParseStartGitConnectClientResponse parses an HTTP response from a StartGitConnectWithResponse call +func ParseStartGitConnectClientResponse(rsp *http.Response) (*StartGitConnectClientResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &StartGitConnectClientResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest GitConnectStartResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON503 = &dest + + } + + return response, nil +} + +// ParseListGitConnectionsClientResponse parses an HTTP response from a ListGitConnectionsWithResponse call +func ParseListGitConnectionsClientResponse(rsp *http.Response) (*ListGitConnectionsClientResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &ListGitConnectionsClientResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest GitConnectionsResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON503 = &dest + + } + + return response, nil +} + +// ParseDeleteGitConnectionClientResponse parses an HTTP response from a DeleteGitConnectionWithResponse call +func ParseDeleteGitConnectionClientResponse(rsp *http.Response) (*DeleteGitConnectionClientResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteGitConnectionClientResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON503 = &dest + + } + + return response, nil +} + +// ParseListGitInstallationsClientResponse parses an HTTP response from a ListGitInstallationsWithResponse call +func ParseListGitInstallationsClientResponse(rsp *http.Response) (*ListGitInstallationsClientResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &ListGitInstallationsClientResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest GitInstallationsResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON503 = &dest + + } + + return response, nil +} + +// ParseListGitInstallationRepositoriesClientResponse parses an HTTP response from a ListGitInstallationRepositoriesWithResponse call +func ParseListGitInstallationRepositoriesClientResponse(rsp *http.Response) (*ListGitInstallationRepositoriesClientResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &ListGitInstallationRepositoriesClientResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest GitRepositoriesResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: + var dest Error + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON503 = &dest + + } + + return response, nil +} diff --git a/openapi/openapi.yaml b/openapi/openapi.yaml index faac0d9..b57794a 100644 --- a/openapi/openapi.yaml +++ b/openapi/openapi.yaml @@ -45,6 +45,8 @@ tags: description: OAuth provider configuration (Google, GitHub, Microsoft, Apple) - name: OAuth Authentication description: OAuth login flows and provider management for end users + - name: Git Connections + description: Platform-user git provider connections for deployment source integrations - name: Storage Buckets description: Storage bucket management (platform admin) - name: Storage Policies @@ -64,6 +66,335 @@ tags: and polls for completion. Session completion is handled by volcano.dev via the Management API. paths: + /user/git/connect: + post: + tags: + - Git Connections + summary: Start a git provider connection + description: | + Starts a first-party dashboard user's git provider connection flow and + returns the provider authorization URL. The response also sets a + short-lived HttpOnly callback binding cookie tied to the authenticated + user through the signed provider state. + operationId: startGitConnect + security: + - UserToken: [] + - AuthUserAccessToken: [] + parameters: + - name: provider + in: query + required: false + description: Git provider to connect. Defaults to github. + schema: + type: string + enum: + - github + default: github + - name: redirect + in: query + required: false + description: URL to redirect the browser to after the provider callback completes. + schema: + type: string + responses: + '200': + description: Provider authorization URL + content: + application/json: + schema: + $ref: '#/components/schemas/GitConnectStartResponse' + '400': + description: Unsupported provider or invalid redirect + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '401': + description: Not authenticated + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '500': + description: Failed to start the connection + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '503': + description: Git provider integration is not configured + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + /user/git/connections: + get: + tags: + - Git Connections + summary: List git provider connections + operationId: listGitConnections + security: + - UserToken: [] + - AuthUserAccessToken: [] + responses: + '200': + description: Stored git provider connections + content: + application/json: + schema: + $ref: '#/components/schemas/GitConnectionsResponse' + '401': + description: Not authenticated + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '500': + description: Failed to list connections + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '503': + description: Git provider integration is not configured + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + /user/git/connections/{connectionId}: + delete: + tags: + - Git Connections + summary: Delete a git provider connection + operationId: deleteGitConnection + security: + - UserToken: [] + - AuthUserAccessToken: [] + parameters: + - name: connectionId + in: path + required: true + description: Connection ID to delete + schema: + type: string + format: uuid + responses: + '204': + description: Connection deleted + '400': + description: Malformed connection ID + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '401': + description: Not authenticated + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '404': + description: Connection not found + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '500': + description: Failed to delete connection + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '503': + description: Git provider integration is not configured + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + /user/git/connections/{connectionId}/installations: + get: + tags: + - Git Connections + summary: List GitHub App installations accessible to a connection + description: | + Live proxy to GitHub: lists the platform GitHub App installations the + connection's stored user token can access. Nothing is persisted by + this call. + operationId: listGitInstallations + security: + - UserToken: [] + - AuthUserAccessToken: [] + parameters: + - name: connectionId + in: path + required: true + description: Connection ID to browse installations for. + schema: + type: string + format: uuid + responses: + '200': + description: Installations accessible to the connection + content: + application/json: + schema: + $ref: '#/components/schemas/GitInstallationsResponse' + '400': + description: Malformed connection ID + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '401': + description: Not authenticated + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '404': + description: Connection not found + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '500': + description: Failed to list installations + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '503': + description: Git provider integration is not configured + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + /user/git/connections/{connectionId}/installations/{installationId}/repositories: + get: + tags: + - Git Connections + summary: List repos accessible to a connection through an installation + description: | + Live proxy to GitHub: lists the repos the connection's stored user + token can access through installationId. Nothing is persisted by this + call. + operationId: listGitInstallationRepositories + security: + - UserToken: [] + - AuthUserAccessToken: [] + parameters: + - name: connectionId + in: path + required: true + description: Connection ID to browse repositories for. + schema: + type: string + format: uuid + - name: installationId + in: path + required: true + description: GitHub App installation ID. + schema: + type: integer + format: int64 + responses: + '200': + description: Repositories accessible through the installation + content: + application/json: + schema: + $ref: '#/components/schemas/GitRepositoriesResponse' + '400': + description: Malformed connection or installation ID + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '401': + description: Not authenticated + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '404': + description: Connection not found + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '500': + description: Failed to list repositories + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '503': + description: Git provider integration is not configured + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + /github/callback: + get: + tags: + - Git Connections + summary: Complete a GitHub App connection callback + description: | + Public GitHub App callback. The signed state and callback binding cookie + bind the provider authorization to the browser that started the flow. + operationId: gitConnectCallback + security: [] + parameters: + - name: code + in: query + required: false + description: GitHub user authorization code. + schema: + type: string + - name: state + in: query + required: true + description: Signed connect state generated by startGitConnect. + schema: + type: string + - name: error + in: query + required: false + description: Provider error returned by GitHub. + schema: + type: string + responses: + '303': + description: Redirect back to the app after a successful or failed connect attempt + headers: + Location: + description: Redirect target + schema: + type: string + '400': + description: Invalid callback request or state + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '429': + description: Too many callback attempts from this client + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '500': + description: Failed to complete the connection + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '503': + description: Git provider integration is not configured + content: + application/json: + schema: + $ref: '#/components/schemas/Error' /projects: get: tags: @@ -633,6 +964,155 @@ paths: application/json: schema: $ref: '#/components/schemas/ProjectConfigValidationErrorResponse' + /projects/{id}/git-connection: + get: + tags: + - Projects + - Git Connections + summary: Get a project's repo connection + operationId: getProjectGitConnection + security: + - UserToken: [] + parameters: + - $ref: '#/components/parameters/ProjectId' + responses: + '200': + description: The project's current repo connection + content: + application/json: + schema: + $ref: '#/components/schemas/ProjectGitConnection' + '401': + description: Unauthorized - invalid or missing token + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '403': + description: Project not owned by the caller + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '404': + description: Project not found, or has no repo connection + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '500': + description: Failed to get project git connection + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + put: + tags: + - Projects + - Git Connections + summary: Connect or update a project's repo connection + description: | + Full replace, following Vercel's model: many projects may point at the + same repo, so this only binds the project — it never creates or + deletes git-provider state. Used for both the initial connect and + later edits (repo change, root directory, production branch). + Resolves the repository_id or repo_full_name selector against the repos + accessible through installation_id via connection_id's stored GitHub + user token, then persists repository metadata only from that validated + GitHub response. + operationId: connectProjectGit + security: + - UserToken: [] + parameters: + - $ref: '#/components/parameters/ProjectId' + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/ConnectProjectGitRequest' + responses: + '200': + description: The project's repo connection + content: + application/json: + schema: + $ref: '#/components/schemas/ProjectGitConnection' + '400': + description: Malformed request body + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '401': + description: Unauthorized - invalid or missing token + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '403': + description: | + Project not owned by the caller, or the selected repository is not + accessible through installation_id + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '404': + description: Project or connection not found + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '500': + description: Failed to connect project git + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '503': + description: Git provider integration is not configured + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + delete: + tags: + - Projects + - Git Connections + summary: Disconnect a project's repo connection + operationId: disconnectProjectGit + security: + - UserToken: [] + parameters: + - $ref: '#/components/parameters/ProjectId' + responses: + '204': + description: Connection removed + '401': + description: Unauthorized - invalid or missing token + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '403': + description: Project not owned by the caller + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '404': + description: Project not found, or has no repo connection + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '500': + description: Failed to disconnect project git + content: + application/json: + schema: + $ref: '#/components/schemas/Error' /projects/{id}/databases/{databaseName}/queries: get: tags: @@ -796,6 +1276,12 @@ paths: tags: - Functions summary: List all functions in a project + description: | + Supports two mutually exclusive pagination modes. Offset mode uses `page` + and `limit` and returns `next` (URL). Cursor mode uses `cursor` and + `limit`, supports `search` (case-insensitive name match), and returns + `next_cursor`/`prev_cursor`. Sending both `page` and `cursor` (or `page` + and `search`) returns 400. operationId: listFunctions security: - UserToken: [] @@ -803,6 +1289,10 @@ paths: - $ref: '#/components/parameters/ProjectId' - $ref: '#/components/parameters/Page' - $ref: '#/components/parameters/Limit' + - $ref: '#/components/parameters/Cursor' + - $ref: '#/components/parameters/EndingBefore' + - $ref: '#/components/parameters/Offset' + - $ref: '#/components/parameters/Search' responses: '200': description: Successful response @@ -1337,12 +1827,13 @@ paths: summary: Stream project logs description: | Live-tail project logs as Server-Sent Events. The request body uses the - resource selector plus `levels`, `regions`, `start_time`, and `limit`, + resource selector plus `q`, `start_time`, and `limit`, including runtime logs and function/frontend deployment logs selected with `resource.deployments`. Deployment logs are not supported for databases. Database logs are a PRO-plan feature; `resource.type=database` - from a FREE-plan project owner returns 403. Do not send `q`, `cursor`, or - `end_time`; use `/logs/search` for text search and range backfills. + from a FREE-plan project owner returns 403. The `q` field uses the same + syntax as search and activity requests. Do not send `cursor` or + `end_time`; use `/logs/search` for range backfills. Explicit historical `start_time` values are limited to the plan's retention window (FREE: 1 day, PRO: 30 days). Resume with `Last-Event-ID` or the `last_event_id` query parameter. The cursor is @@ -1497,6 +1988,10 @@ paths: - $ref: '#/components/parameters/ProjectId' - $ref: '#/components/parameters/Page' - $ref: '#/components/parameters/Limit' + - $ref: '#/components/parameters/Cursor' + - $ref: '#/components/parameters/EndingBefore' + - $ref: '#/components/parameters/Offset' + - $ref: '#/components/parameters/Search' responses: '200': description: Project schedulers @@ -1640,6 +2135,12 @@ paths: tags: - Frontends summary: List all frontends in a project + description: | + Supports two mutually exclusive pagination modes. Offset mode uses `page` + and `limit` and returns `next` (URL). Cursor mode uses `cursor` and + `limit`, supports `search` (case-insensitive name match), and returns + `next_cursor`. Sending both `page` and `cursor` (or `page` and `search`) + returns 400. operationId: listFrontends security: - UserToken: [] @@ -1647,6 +2148,10 @@ paths: - $ref: '#/components/parameters/ProjectId' - $ref: '#/components/parameters/Page' - $ref: '#/components/parameters/Limit' + - $ref: '#/components/parameters/Cursor' + - $ref: '#/components/parameters/EndingBefore' + - $ref: '#/components/parameters/Offset' + - $ref: '#/components/parameters/Search' responses: '200': description: Successful response @@ -1700,7 +2205,7 @@ paths: 22.x or 24.x. The Node.js runtime is inferred from `package.json` `engines.node`; if omitted, Volcano uses Node.js 22.x. The selected Node.js family must also satisfy the installed Next.js package's - `engines.node` constraint. Volcano tests Next 15.5.20 (`^18.18.0 || ^19.8.0 || >=20.0.0`) and Next 16.2.10 (`>=20.9.0`). + `engines.node` constraint. Volcano tests Next 15.5.21 (`^18.18.0 || ^19.8.0 || >=20.0.0`) and Next 16.2.11 (`>=20.9.0`). Source archive size is enforced by the API with `SOURCE_ARCHIVE_SIZE_LIMIT_MB`; the CLI does not apply its own source archive size limit. After the final Lambda container images are built, the publish build enforces `LAMBDA_TARGET_CONTAINER_SIZE_LIMIT_MB` before pushing. @@ -2256,6 +2761,10 @@ paths: - $ref: '#/components/parameters/ProjectId' - $ref: '#/components/parameters/Page' - $ref: '#/components/parameters/Limit' + - $ref: '#/components/parameters/Cursor' + - $ref: '#/components/parameters/EndingBefore' + - $ref: '#/components/parameters/Offset' + - $ref: '#/components/parameters/Search' responses: '200': description: Successful response @@ -2305,6 +2814,12 @@ paths: tags: - Databases summary: List all databases for a project + description: | + Supports two mutually exclusive pagination modes. Offset mode uses `page` + and `limit`. Cursor mode uses `cursor` and `limit`, supports `search` + (case-insensitive name match), and returns `next_cursor`/`prev_cursor`. + The optional `status` filter applies in both modes and is bound to the + cursor. Sending both `page` and `cursor` (or `page` and `search`) returns 400. operationId: listDatabases security: - UserToken: [] @@ -2312,6 +2827,10 @@ paths: - $ref: '#/components/parameters/ProjectId' - $ref: '#/components/parameters/Page' - $ref: '#/components/parameters/Limit' + - $ref: '#/components/parameters/Cursor' + - $ref: '#/components/parameters/EndingBefore' + - $ref: '#/components/parameters/Offset' + - $ref: '#/components/parameters/Search' responses: '200': description: Successful response @@ -2439,11 +2958,9 @@ paths: new_password: type: string description: New Volcano-managed client password. Always starts with `vpg_`. - example: vpg_qv3Y4GQwHcklV4G76ZcKhZW-rmZLQktEORHnGqU0Bpk connection_string: type: string description: Updated pgproxy connection string using Volcano-managed credentials. - example: postgresql://volcano_client_11111111-1111-1111-1111-111111111111:vpg_qv3Y4GQwHcklV4G76ZcKhZW-rmZLQktEORHnGqU0Bpk@database.volcano.dev:5432/mydb?sslmode=require&application_name=volcano_full_access /projects/{id}/databases/{databaseName}/type: patch: tags: @@ -4184,6 +4701,92 @@ paths: application/json: schema: $ref: '#/components/schemas/Error' + /projects/{id}/auth/insights: + get: + tags: + - Auth Admin + summary: Get auth user insights + description: | + Returns current auth-user totals, rolling 30-day active users, and + zero-filled signup and successful sign-in counts for an inclusive UTC + date range. Weeks start on Monday. Sign-in counts and active-user + activity begin when collection is deployed. Historical signup counts + are backfilled from users present at deployment. Token refreshes affect + active users but not the sign-in series. + operationId: getAuthInsights + security: + - UserToken: [] + parameters: + - $ref: '#/components/parameters/ProjectId' + - name: from + in: query + description: Inclusive UTC start date. Defaults to 29 days before `to`. + schema: + type: string + format: date + - name: to + in: query + description: Inclusive UTC end date. Defaults to today. + schema: + type: string + format: date + - name: interval + in: query + description: Chart bucket size. Defaults to `day`. + schema: + $ref: '#/components/schemas/AuthInsightsInterval' + responses: + '200': + description: Auth insights retrieved + content: + application/json: + schema: + $ref: '#/components/schemas/AuthInsightsResponse' + example: + project_id: 4f165080-a931-4e03-b3bd-41c45c3f0058 + observed_at: '2026-07-20T18:00:00Z' + window: + from: '2026-06-21' + to: '2026-07-20' + interval: day + summary: + total_users: 1234 + active_users_30d: 418 + series: + - bucket_start: '2026-07-20' + signups: 12 + signins: 97 + is_partial: true + '400': + description: Invalid date range or interval + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '401': + description: Unauthorized - invalid or missing token + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '403': + description: Access denied + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '404': + description: Project not found + content: + application/json: + schema: + $ref: '#/components/schemas/Error' + '500': + description: Internal server error + content: + application/json: + schema: + $ref: '#/components/schemas/Error' /projects/{id}/auth/users: get: tags: @@ -5839,11 +6442,24 @@ paths: tags: - Anon Keys summary: List anon keys + description: | + Supports two mutually exclusive pagination modes. Offset mode uses `page` + and `limit` and is the default when neither `cursor` nor `search` is + supplied (first page, default `limit`). Cursor mode uses `cursor` and + `limit`, supports `search` (case-insensitive name match), and returns + `next_cursor`. Sending both `page` and `cursor` (or `page` and `search`) + returns 400. operationId: listAnonKeys security: - UserToken: [] parameters: - $ref: '#/components/parameters/ProjectId' + - $ref: '#/components/parameters/Page' + - $ref: '#/components/parameters/Limit' + - $ref: '#/components/parameters/Cursor' + - $ref: '#/components/parameters/EndingBefore' + - $ref: '#/components/parameters/Offset' + - $ref: '#/components/parameters/Search' responses: '200': description: List of anon keys @@ -5856,6 +6472,18 @@ paths: type: array items: $ref: '#/components/schemas/AnonKey' + total: + type: integer + description: Total number of items matching the query (so the UI can render numbered pages). + has_more: + type: boolean + description: Whether a next page exists. + next_cursor: + type: string + description: Opaque cursor for the next page (cursor pagination only) + prev_cursor: + type: string + description: Opaque cursor for the previous page (cursor pagination only). Send as `ending_before`. post: tags: - Anon Keys @@ -6058,6 +6686,10 @@ paths: - $ref: '#/components/parameters/ProjectId' - $ref: '#/components/parameters/Page' - $ref: '#/components/parameters/Limit' + - $ref: '#/components/parameters/Cursor' + - $ref: '#/components/parameters/EndingBefore' + - $ref: '#/components/parameters/Offset' + - $ref: '#/components/parameters/Search' responses: '200': description: Paginated list of service keys @@ -6203,20 +6835,34 @@ paths: tags: - Storage Buckets summary: List all storage buckets in a project + description: | + With no pagination params, returns the full bucket list as a bare array + (legacy). Supplying `cursor`, `ending_before`, `search`, or `limit` + switches to keyset (cursor) pagination and returns a paginated envelope + with `next_cursor`/`prev_cursor` and a filtered `total`. operationId: listStorageBuckets security: - UserToken: [] parameters: - $ref: '#/components/parameters/ProjectId' + - $ref: '#/components/parameters/Limit' + - $ref: '#/components/parameters/Cursor' + - $ref: '#/components/parameters/EndingBefore' + - $ref: '#/components/parameters/Offset' + - $ref: '#/components/parameters/Search' responses: '200': - description: List of storage buckets + description: | + Either the full bucket list (bare array, legacy) or a paginated + envelope when cursor pagination is requested. content: application/json: schema: - type: array - items: - $ref: '#/components/schemas/StorageBucket' + oneOf: + - type: array + items: + $ref: '#/components/schemas/StorageBucket' + - $ref: '#/components/schemas/PaginatedStorageBuckets' post: tags: - Storage Buckets @@ -6394,6 +7040,10 @@ paths: default: 50 minimum: 1 maximum: 100 + - $ref: '#/components/parameters/Cursor' + - $ref: '#/components/parameters/EndingBefore' + - $ref: '#/components/parameters/Offset' + - $ref: '#/components/parameters/Search' responses: '200': description: Paginated list of storage objects @@ -6414,6 +7064,12 @@ paths: type: integer has_more: type: boolean + next_cursor: + type: string + description: Opaque cursor for the next page (cursor pagination only) + prev_cursor: + type: string + description: Opaque cursor for the previous page (cursor pagination only). Send as `ending_before`. /projects/{id}/storage/stats: get: tags: @@ -7042,6 +7698,29 @@ components: minLength: 1 maxLength: 64 description: Storage bucket name + Cursor: + name: cursor + in: query + required: false + schema: + type: string + description: | + Opaque keyset pagination cursor from a previous response's `next_cursor` + — pages forward. Mutually exclusive with `page` and `ending_before`; + combining them returns 400. When supplied, the request's `search` and + `limit` must match the values bound to the cursor or the request returns 400. + EndingBefore: + name: ending_before + in: query + required: false + schema: + type: string + description: | + Opaque keyset pagination cursor from a previous response's `prev_cursor` + — pages backward (the page immediately preceding this cursor). Mutually + exclusive with `page` and `cursor`; combining them returns 400. `search` + and `limit` must match the values bound to the cursor or the request + returns 400. DatabaseName: name: databaseName in: path @@ -7085,6 +7764,20 @@ components: maximum: 100 default: 10 description: Number of items per page (max 100) + Offset: + name: offset + in: query + required: false + schema: + type: integer + minimum: 0 + default: 0 + description: | + Bounded row offset past the keyset anchor named by `cursor` (forward) or + `ending_before` (backward) — the hybrid jump. Seek to the anchor, then + skip this many rows within. Used for numbered jump-to-page: from the + current page, seek to its next/prev cursor and offset the remaining + pages. Only honored on the cursor pagination path; ignored otherwise. Page: name: page in: query @@ -7102,6 +7795,16 @@ components: type: string format: uuid description: Project ID + Search: + name: search + in: query + required: false + schema: + type: string + maxLength: 256 + description: | + Case-insensitive substring match on the resource `name`. Only honored on + the cursor pagination path. SchedulerId: name: schedulerId in: path @@ -7277,6 +7980,18 @@ components: type: integer description: CORS preflight cache duration (seconds) default: 86400 + require_email_confirmation: + type: boolean + description: Require users to confirm email before sign-in. Can only be true when email_enabled is true. + default: false + email_confirmation_timeout: + type: integer + description: Email confirmation token expiry in seconds. + default: 86400 + auto_link_verified_oauth: + type: boolean + description: Link a verified OAuth identity to an existing confirmed account with the same email instead of returning a conflict. Requires require_email_confirmation to be true. + default: false email_enabled: type: boolean description: Enable transactional email sending (confirmation, reset, change notifications). Must be true when require_email_confirmation is true. @@ -7292,10 +8007,10 @@ components: default: 587 smtp_username: type: string - smtp_password: - type: string - format: password - description: SMTP password. Stored encrypted at rest (AES-256-GCM); returned decrypted only to the authenticated project owner. + smtp_password_configured: + type: boolean + description: Whether an SMTP password is configured. The password itself is never returned. + default: false smtp_use_tls: type: boolean default: true @@ -7329,6 +8044,94 @@ components: the built-in managed device page. Lets a CLI surface the project's own RFC 8628 approval page. Empty falls back to the managed page. example: https://app.acme.com/device + AuthInsightsInterval: + type: string + enum: + - day + - week + - month + AuthInsightsResponse: + type: object + additionalProperties: false + properties: + project_id: + type: string + format: uuid + observed_at: + type: string + format: date-time + window: + $ref: '#/components/schemas/AuthInsightsWindow' + summary: + $ref: '#/components/schemas/AuthInsightsSummary' + series: + type: array + items: + $ref: '#/components/schemas/AuthInsightsSeriesPoint' + required: + - project_id + - observed_at + - window + - summary + - series + AuthInsightsSeriesPoint: + type: object + additionalProperties: false + properties: + bucket_start: + type: string + format: date + signups: + type: integer + format: int64 + minimum: 0 + description: Accounts created during the bucket. + signins: + type: integer + format: int64 + minimum: 0 + description: Successful session creations during the bucket. + is_partial: + type: boolean + description: Whether the requested window or observation time clips this bucket. + required: + - bucket_start + - signups + - signins + - is_partial + AuthInsightsSummary: + type: object + additionalProperties: false + properties: + total_users: + type: integer + format: int64 + minimum: 0 + description: Current auth-user count, matching the auth-user list total. + active_users_30d: + type: integer + format: int64 + minimum: 0 + description: Users with a successful session creation or refresh in the trailing 30 days since activity collection was deployed. + required: + - total_users + - active_users_30d + AuthInsightsWindow: + type: object + additionalProperties: false + properties: + from: + type: string + format: date + to: + type: string + format: date + interval: + $ref: '#/components/schemas/AuthInsightsInterval' + required: + - from + - to + - interval AuthHostedPage: type: object properties: @@ -7785,6 +8588,7 @@ components: properties: name: type: string + maxLength: 200 enabled: type: boolean default: true @@ -8012,7 +8816,6 @@ components: - `volcano_full_access` — Full admin access (DDL, migrations) - `volcano_user_access:{user_id}` — User impersonation (RLS enforced) - `volcano_user_access` — Anonymous access (anon role, RLS enforced) - example: postgres://volcano_client_11111111-1111-1111-1111-111111111111:vpg_secret@database.volcano.dev:5432/my_app_db?sslmode=require&application_name=volcano_full_access region: type: string description: AWS region where database is hosted @@ -8172,8 +8975,167 @@ components: properties: error: type: string + code: + type: string + description: Stable machine-readable error code when a specific recovery path is available. required: - error + GitConnection: + type: object + properties: + id: + type: string + format: uuid + provider: + type: string + provider_user_id: + type: string + provider_login: + type: string + status: + type: string + last_authenticated_at: + type: string + format: date-time + created_at: + type: string + format: date-time + updated_at: + type: string + format: date-time + required: + - id + - provider + - provider_user_id + - provider_login + - status + - last_authenticated_at + - created_at + - updated_at + GitConnectStartResponse: + type: object + properties: + authorization_url: + type: string + required: + - authorization_url + GitConnectionsResponse: + type: object + properties: + connections: + type: array + items: + $ref: '#/components/schemas/GitConnection' + required: + - connections + GitInstallation: + type: object + properties: + id: + type: integer + format: int64 + account_login: + type: string + account_type: + type: string + repository_selection: + type: string + required: + - id + - account_login + - account_type + - repository_selection + GitInstallationsResponse: + type: object + properties: + installations: + type: array + items: + $ref: '#/components/schemas/GitInstallation' + required: + - installations + GitRepository: + type: object + properties: + id: + type: integer + format: int64 + description: Stable GitHub repository id (repository.id), unchanged by renames. + full_name: + type: string + default_branch: + type: string + private: + type: boolean + required: + - id + - full_name + - default_branch + - private + GitRepositoriesResponse: + type: object + properties: + repositories: + type: array + items: + $ref: '#/components/schemas/GitRepository' + required: + - repositories + ProjectGitConnection: + type: object + properties: + repo_installation_id: + type: integer + format: int64 + repo_id: + type: integer + format: int64 + description: Stable GitHub repository id (repository.id), the authoritative binding. + repo_full_name: + type: string + root_directory: + type: string + production_branch: + type: string + description: The repository's GitHub default branch, cached at connect time and used as the deployment target. + updated_at: + type: string + format: date-time + required: + - repo_installation_id + - repo_id + - repo_full_name + - root_directory + - production_branch + - updated_at + ConnectProjectGitRequest: + type: object + properties: + connection_id: + type: string + format: uuid + description: The caller's user_git_connections row (see /user/git/connections). + installation_id: + type: integer + format: int64 + repository_id: + type: integer + format: int64 + description: Stable GitHub repository id (repository.id), the preferred selector. Either repository_id or repo_full_name is required; when both are given they must identify the same live repository. + repo_full_name: + type: string + deprecated: true + description: Deprecated selector kept for a compatibility window; prefer repository_id. Either repository_id or repo_full_name is required. + root_directory: + type: string + description: Monorepo subdirectory the project builds from. Omit for the repo root. + production_branch: + type: string + deprecated: true + description: Deprecated. The deployment branch always follows the repository's GitHub default branch; when given it must equal that default branch. New callers omit it. + required: + - connection_id + - installation_id Frontend: type: object properties: @@ -8349,8 +9311,6 @@ components: type: string artifact_version: type: string - cloudwatch_log_group: - type: string site_url: type: string cloudformation_stack_id: @@ -8587,14 +9547,6 @@ components: type: string artifact_version: type: string - compile_log_group: - type: string - compile_log_stream: - type: string - publish_log_group: - type: string - publish_log_stream: - type: string codebuild_duration_seconds: type: integer format: int64 @@ -8701,18 +9653,8 @@ components: $ref: '#/components/schemas/LogRequestResource' q: type: string - description: Optional free-text search query for log messages. - levels: - type: array - description: Canonical lowercase log levels to filter by. If omitted, empty, or all levels are selected, no level filter is applied. - items: - $ref: '#/components/schemas/LiveLogLevel' - regions: - type: array - maxItems: 25 - description: Regions to filter by, for example `["us-east-1", "eu-west-1"]`. If omitted or empty, aggregate all deployed regions. - items: - type: string + maxLength: 512 + description: Optional activity query. Supports quoted text, implicit AND, AND/OR/NOT, parentheses, and fields such as `level`, `region`, `invocation.id`, `resource.id`, `resource.name`, `function`, `frontend`, `database`, and `body`. start_time: type: string format: date-time @@ -8751,18 +9693,8 @@ components: $ref: '#/components/schemas/LogRequestResource' q: type: string - description: Optional free-text search query for log messages. - levels: - type: array - description: Canonical lowercase log levels to filter by. If omitted, empty, or all levels are selected, no level filter is applied. - items: - $ref: '#/components/schemas/LiveLogLevel' - regions: - type: array - maxItems: 25 - description: Regions to filter by, for example `["us-east-1", "eu-west-1"]`. If omitted or empty, search all deployed regions. - items: - type: string + maxLength: 512 + description: Optional log query. Supports quoted text, implicit AND, AND/OR/NOT, parentheses, and fields such as `level`, `region`, `invocation.id`, `resource.id`, `resource.name`, `function`, `frontend`, `database`, and `body`. start_time: type: string format: date-time @@ -8784,22 +9716,15 @@ components: - resource LogStreamRequest: type: object - description: Stream request for live project logs. Text search, pagination cursors, and fixed end times are not supported. + description: Stream request for live project logs. Pagination cursors and fixed end times are not supported. additionalProperties: false properties: resource: $ref: '#/components/schemas/LogRequestResource' - levels: - type: array - description: Canonical lowercase log levels to filter by. If omitted, empty, or all levels are selected, no level filter is applied. - items: - $ref: '#/components/schemas/LiveLogLevel' - regions: - type: array - maxItems: 25 - description: Regions to filter by, for example `["us-east-1", "eu-west-1"]`. If omitted or empty, stream all deployed regions. - items: - type: string + q: + type: string + maxLength: 512 + description: Optional log query using the same syntax as search and activity requests. start_time: type: string format: date-time @@ -8960,6 +9885,12 @@ components: type: integer has_more: type: boolean + next_cursor: + type: string + description: Opaque cursor for the next page (cursor pagination only; present if has_more is true) + prev_cursor: + type: string + description: Opaque cursor for the previous page (cursor pagination only; present when a previous page exists). Send as `ending_before`. required: - data - page @@ -9005,7 +9936,7 @@ components: - reset-password LogEvent: type: object - description: Normalized historical log event returned by paginated log APIs. + description: Historical log event returned by log APIs. properties: id: type: string @@ -9016,9 +9947,18 @@ components: description: Event timestamp. level: $ref: '#/components/schemas/LiveLogLevel' - message: - type: string - description: Display log message. + body: + description: Application log value. JSON arguments retain their JSON type. Strings containing a serialized JSON object or array are normalized to that object or array; all other strings remain strings. + nullable: true + oneOf: + - type: string + - type: object + additionalProperties: true + - type: array + items: {} + - type: number + format: double + - type: boolean region: type: string description: Region where this log event originated. @@ -9029,17 +9969,9 @@ components: invocation_id: type: string description: Function invocation ID associated with this log event, when available. - raw_message: - type: string - description: Original log line/message after platform sanitization. - metadata: - type: object - nullable: true - additionalProperties: true - description: Parsed JSON fields and other indexed metadata, when available. required: - timestamp - - message + - body LiveLogLevel: type: string enum: @@ -9187,6 +10119,12 @@ components: next: type: string description: URL path to next page (only present if has_more is true) + next_cursor: + type: string + description: Opaque cursor for the next page (cursor pagination only; present if has_more is true) + prev_cursor: + type: string + description: Opaque cursor for the previous page (cursor pagination only; present when a previous page exists). Send as `ending_before`. required: - data - page @@ -9242,7 +10180,13 @@ components: description: Whether there are more pages available next: type: string - description: URL path to next page (only present if has_more is true) + description: URL path to next page (offset pagination only; present if has_more is true) + next_cursor: + type: string + description: Opaque cursor for the next page (cursor pagination only; present if has_more is true) + prev_cursor: + type: string + description: Opaque cursor for the previous page (cursor pagination only; present when a previous page exists). Send as `ending_before`. required: - data - page @@ -9299,6 +10243,12 @@ components: next: type: string description: URL path to next page (only present if has_more is true) + next_cursor: + type: string + description: Opaque cursor for the next page (cursor pagination only; present if has_more is true) + prev_cursor: + type: string + description: Opaque cursor for the previous page (cursor pagination only; present when a previous page exists). Send as `ending_before`. required: - data - page @@ -9425,13 +10375,46 @@ components: description: Whether there are more pages available next: type: string - description: URL path to next page (only present if has_more is true) + description: URL path to next page (offset pagination only; present if has_more is true) + next_cursor: + type: string + description: Opaque cursor for the next page (cursor pagination only; present if has_more is true) + prev_cursor: + type: string + description: Opaque cursor for the previous page (cursor pagination only; present when a previous page exists). Send as `ending_before`. required: - data - page - limit - total - has_more + PaginatedStorageBuckets: + type: object + description: Cursor-paginated storage buckets (returned only when cursor pagination is requested). + properties: + data: + type: array + items: + $ref: '#/components/schemas/StorageBucket' + limit: + type: integer + description: Number of items per page + total: + type: integer + description: Total number of items matching the query + has_more: + type: boolean + description: Whether a next page exists + next_cursor: + type: string + description: Opaque cursor for the next page (present if has_more is true) + prev_cursor: + type: string + description: Opaque cursor for the previous page (present when a previous page exists). Send as `ending_before`. + required: + - data + - limit + - has_more PaginatedVariables: type: object properties: @@ -9454,6 +10437,12 @@ components: next: type: string description: URL path to next page (only present if has_more is true) + next_cursor: + type: string + description: Opaque cursor for the next page (cursor pagination only; present if has_more is true) + prev_cursor: + type: string + description: Opaque cursor for the previous page (cursor pagination only; present when a previous page exists). Send as `ending_before`. required: - data - page @@ -10157,6 +11146,7 @@ components: name: type: string minLength: 1 + maxLength: 200 cron: type: string description: 5-field UTC cron expression @@ -11128,6 +12118,9 @@ components: email_confirmation_timeout: type: integer description: Email confirmation token expiry in seconds. + auto_link_verified_oauth: + type: boolean + description: Link a verified OAuth identity to an existing confirmed account with the same email instead of returning a conflict. Requires require_email_confirmation to be true. email_enabled: type: boolean description: Enable transactional email sending. Cannot be false while require_email_confirmation is true. @@ -11144,7 +12137,9 @@ components: smtp_password: type: string format: password - description: SMTP password (sensitive). Encrypted at rest (AES-256-GCM) when stored. + writeOnly: true + minLength: 1 + description: Replacement SMTP password. Omit this field to preserve the configured password. The value is encrypted at rest and never returned. smtp_use_tls: type: boolean email_confirmation_subject: @@ -11227,6 +12222,7 @@ components: properties: name: type: string + maxLength: 200 enabled: type: boolean schedule: