// Code generated by protoc-gen-connect-go. DO NOT EDIT.
//
// Source: xyz/block/ftl/console/v1/console.proto

package consolepbconnect

import (
	connect "connectrpc.com/connect"
	context "context"
	errors "errors"
	v13 "github.com/block/ftl/backend/protos/xyz/block/ftl/buildengine/v1"
	v11 "github.com/block/ftl/backend/protos/xyz/block/ftl/console/v1"
	v12 "github.com/block/ftl/backend/protos/xyz/block/ftl/timeline/v1"
	v1 "github.com/block/ftl/backend/protos/xyz/block/ftl/v1"
	http "net/http"
	strings "strings"
)

// This is a compile-time assertion to ensure that this generated file and the connect package are
// compatible. If you get a compiler error that this constant is not defined, this code was
// generated with a version of connect newer than the one compiled into your binary. You can fix the
// problem by either regenerating this code with an older version of connect or updating the connect
// version compiled into your binary.
const _ = connect.IsAtLeastVersion1_13_0

const (
	// ConsoleServiceName is the fully-qualified name of the ConsoleService service.
	ConsoleServiceName = "xyz.block.ftl.console.v1.ConsoleService"
)

// These constants are the fully-qualified names of the RPCs defined in this package. They're
// exposed at runtime as Spec.Procedure and as the final two segments of the HTTP route.
//
// Note that these are different from the fully-qualified method names used by
// google.golang.org/protobuf/reflect/protoreflect. To convert from these constants to
// reflection-formatted method names, remove the leading slash and convert the remaining slash to a
// period.
const (
	// ConsoleServicePingProcedure is the fully-qualified name of the ConsoleService's Ping RPC.
	ConsoleServicePingProcedure = "/xyz.block.ftl.console.v1.ConsoleService/Ping"
	// ConsoleServiceGetModulesProcedure is the fully-qualified name of the ConsoleService's GetModules
	// RPC.
	ConsoleServiceGetModulesProcedure = "/xyz.block.ftl.console.v1.ConsoleService/GetModules"
	// ConsoleServiceStreamModulesProcedure is the fully-qualified name of the ConsoleService's
	// StreamModules RPC.
	ConsoleServiceStreamModulesProcedure = "/xyz.block.ftl.console.v1.ConsoleService/StreamModules"
	// ConsoleServiceGetTimelineProcedure is the fully-qualified name of the ConsoleService's
	// GetTimeline RPC.
	ConsoleServiceGetTimelineProcedure = "/xyz.block.ftl.console.v1.ConsoleService/GetTimeline"
	// ConsoleServiceStreamTimelineProcedure is the fully-qualified name of the ConsoleService's
	// StreamTimeline RPC.
	ConsoleServiceStreamTimelineProcedure = "/xyz.block.ftl.console.v1.ConsoleService/StreamTimeline"
	// ConsoleServiceGetConfigProcedure is the fully-qualified name of the ConsoleService's GetConfig
	// RPC.
	ConsoleServiceGetConfigProcedure = "/xyz.block.ftl.console.v1.ConsoleService/GetConfig"
	// ConsoleServiceSetConfigProcedure is the fully-qualified name of the ConsoleService's SetConfig
	// RPC.
	ConsoleServiceSetConfigProcedure = "/xyz.block.ftl.console.v1.ConsoleService/SetConfig"
	// ConsoleServiceGetSecretProcedure is the fully-qualified name of the ConsoleService's GetSecret
	// RPC.
	ConsoleServiceGetSecretProcedure = "/xyz.block.ftl.console.v1.ConsoleService/GetSecret"
	// ConsoleServiceSetSecretProcedure is the fully-qualified name of the ConsoleService's SetSecret
	// RPC.
	ConsoleServiceSetSecretProcedure = "/xyz.block.ftl.console.v1.ConsoleService/SetSecret"
	// ConsoleServiceCallProcedure is the fully-qualified name of the ConsoleService's Call RPC.
	ConsoleServiceCallProcedure = "/xyz.block.ftl.console.v1.ConsoleService/Call"
	// ConsoleServiceStreamEngineEventsProcedure is the fully-qualified name of the ConsoleService's
	// StreamEngineEvents RPC.
	ConsoleServiceStreamEngineEventsProcedure = "/xyz.block.ftl.console.v1.ConsoleService/StreamEngineEvents"
	// ConsoleServiceGetInfoProcedure is the fully-qualified name of the ConsoleService's GetInfo RPC.
	ConsoleServiceGetInfoProcedure = "/xyz.block.ftl.console.v1.ConsoleService/GetInfo"
	// ConsoleServiceExecuteGooseProcedure is the fully-qualified name of the ConsoleService's
	// ExecuteGoose RPC.
	ConsoleServiceExecuteGooseProcedure = "/xyz.block.ftl.console.v1.ConsoleService/ExecuteGoose"
	// ConsoleServiceOpenFileInEditorProcedure is the fully-qualified name of the ConsoleService's
	// OpenFileInEditor RPC.
	ConsoleServiceOpenFileInEditorProcedure = "/xyz.block.ftl.console.v1.ConsoleService/OpenFileInEditor"
)

// ConsoleServiceClient is a client for the xyz.block.ftl.console.v1.ConsoleService service.
type ConsoleServiceClient interface {
	// Ping service for readiness.
	Ping(context.Context, *connect.Request[v1.PingRequest]) (*connect.Response[v1.PingResponse], error)
	GetModules(context.Context, *connect.Request[v11.GetModulesRequest]) (*connect.Response[v11.GetModulesResponse], error)
	StreamModules(context.Context, *connect.Request[v11.StreamModulesRequest]) (*connect.ServerStreamForClient[v11.StreamModulesResponse], error)
	GetTimeline(context.Context, *connect.Request[v12.GetTimelineRequest]) (*connect.Response[v12.GetTimelineResponse], error)
	StreamTimeline(context.Context, *connect.Request[v12.StreamTimelineRequest]) (*connect.ServerStreamForClient[v12.StreamTimelineResponse], error)
	GetConfig(context.Context, *connect.Request[v11.GetConfigRequest]) (*connect.Response[v11.GetConfigResponse], error)
	SetConfig(context.Context, *connect.Request[v11.SetConfigRequest]) (*connect.Response[v11.SetConfigResponse], error)
	GetSecret(context.Context, *connect.Request[v11.GetSecretRequest]) (*connect.Response[v11.GetSecretResponse], error)
	SetSecret(context.Context, *connect.Request[v11.SetSecretRequest]) (*connect.Response[v11.SetSecretResponse], error)
	Call(context.Context, *connect.Request[v1.CallRequest]) (*connect.Response[v1.CallResponse], error)
	StreamEngineEvents(context.Context, *connect.Request[v13.StreamEngineEventsRequest]) (*connect.ServerStreamForClient[v13.StreamEngineEventsResponse], error)
	GetInfo(context.Context, *connect.Request[v11.GetInfoRequest]) (*connect.Response[v11.GetInfoResponse], error)
	ExecuteGoose(context.Context, *connect.Request[v11.ExecuteGooseRequest]) (*connect.ServerStreamForClient[v11.ExecuteGooseResponse], error)
	OpenFileInEditor(context.Context, *connect.Request[v11.OpenFileInEditorRequest]) (*connect.Response[v11.OpenFileInEditorResponse], error)
}

// NewConsoleServiceClient constructs a client for the xyz.block.ftl.console.v1.ConsoleService
// service. By default, it uses the Connect protocol with the binary Protobuf Codec, asks for
// gzipped responses, and sends uncompressed requests. To use the gRPC or gRPC-Web protocols, supply
// the connect.WithGRPC() or connect.WithGRPCWeb() options.
//
// The URL supplied here should be the base URL for the Connect or gRPC server (for example,
// http://api.acme.com or https://acme.com/grpc).
func NewConsoleServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) ConsoleServiceClient {
	baseURL = strings.TrimRight(baseURL, "/")
	consoleServiceMethods := v11.File_xyz_block_ftl_console_v1_console_proto.Services().ByName("ConsoleService").Methods()
	return &consoleServiceClient{
		ping: connect.NewClient[v1.PingRequest, v1.PingResponse](
			httpClient,
			baseURL+ConsoleServicePingProcedure,
			connect.WithSchema(consoleServiceMethods.ByName("Ping")),
			connect.WithIdempotency(connect.IdempotencyNoSideEffects),
			connect.WithClientOptions(opts...),
		),
		getModules: connect.NewClient[v11.GetModulesRequest, v11.GetModulesResponse](
			httpClient,
			baseURL+ConsoleServiceGetModulesProcedure,
			connect.WithSchema(consoleServiceMethods.ByName("GetModules")),
			connect.WithClientOptions(opts...),
		),
		streamModules: connect.NewClient[v11.StreamModulesRequest, v11.StreamModulesResponse](
			httpClient,
			baseURL+ConsoleServiceStreamModulesProcedure,
			connect.WithSchema(consoleServiceMethods.ByName("StreamModules")),
			connect.WithClientOptions(opts...),
		),
		getTimeline: connect.NewClient[v12.GetTimelineRequest, v12.GetTimelineResponse](
			httpClient,
			baseURL+ConsoleServiceGetTimelineProcedure,
			connect.WithSchema(consoleServiceMethods.ByName("GetTimeline")),
			connect.WithClientOptions(opts...),
		),
		streamTimeline: connect.NewClient[v12.StreamTimelineRequest, v12.StreamTimelineResponse](
			httpClient,
			baseURL+ConsoleServiceStreamTimelineProcedure,
			connect.WithSchema(consoleServiceMethods.ByName("StreamTimeline")),
			connect.WithClientOptions(opts...),
		),
		getConfig: connect.NewClient[v11.GetConfigRequest, v11.GetConfigResponse](
			httpClient,
			baseURL+ConsoleServiceGetConfigProcedure,
			connect.WithSchema(consoleServiceMethods.ByName("GetConfig")),
			connect.WithClientOptions(opts...),
		),
		setConfig: connect.NewClient[v11.SetConfigRequest, v11.SetConfigResponse](
			httpClient,
			baseURL+ConsoleServiceSetConfigProcedure,
			connect.WithSchema(consoleServiceMethods.ByName("SetConfig")),
			connect.WithClientOptions(opts...),
		),
		getSecret: connect.NewClient[v11.GetSecretRequest, v11.GetSecretResponse](
			httpClient,
			baseURL+ConsoleServiceGetSecretProcedure,
			connect.WithSchema(consoleServiceMethods.ByName("GetSecret")),
			connect.WithClientOptions(opts...),
		),
		setSecret: connect.NewClient[v11.SetSecretRequest, v11.SetSecretResponse](
			httpClient,
			baseURL+ConsoleServiceSetSecretProcedure,
			connect.WithSchema(consoleServiceMethods.ByName("SetSecret")),
			connect.WithClientOptions(opts...),
		),
		call: connect.NewClient[v1.CallRequest, v1.CallResponse](
			httpClient,
			baseURL+ConsoleServiceCallProcedure,
			connect.WithSchema(consoleServiceMethods.ByName("Call")),
			connect.WithClientOptions(opts...),
		),
		streamEngineEvents: connect.NewClient[v13.StreamEngineEventsRequest, v13.StreamEngineEventsResponse](
			httpClient,
			baseURL+ConsoleServiceStreamEngineEventsProcedure,
			connect.WithSchema(consoleServiceMethods.ByName("StreamEngineEvents")),
			connect.WithClientOptions(opts...),
		),
		getInfo: connect.NewClient[v11.GetInfoRequest, v11.GetInfoResponse](
			httpClient,
			baseURL+ConsoleServiceGetInfoProcedure,
			connect.WithSchema(consoleServiceMethods.ByName("GetInfo")),
			connect.WithClientOptions(opts...),
		),
		executeGoose: connect.NewClient[v11.ExecuteGooseRequest, v11.ExecuteGooseResponse](
			httpClient,
			baseURL+ConsoleServiceExecuteGooseProcedure,
			connect.WithSchema(consoleServiceMethods.ByName("ExecuteGoose")),
			connect.WithClientOptions(opts...),
		),
		openFileInEditor: connect.NewClient[v11.OpenFileInEditorRequest, v11.OpenFileInEditorResponse](
			httpClient,
			baseURL+ConsoleServiceOpenFileInEditorProcedure,
			connect.WithSchema(consoleServiceMethods.ByName("OpenFileInEditor")),
			connect.WithClientOptions(opts...),
		),
	}
}

// consoleServiceClient implements ConsoleServiceClient.
type consoleServiceClient struct {
	ping               *connect.Client[v1.PingRequest, v1.PingResponse]
	getModules         *connect.Client[v11.GetModulesRequest, v11.GetModulesResponse]
	streamModules      *connect.Client[v11.StreamModulesRequest, v11.StreamModulesResponse]
	getTimeline        *connect.Client[v12.GetTimelineRequest, v12.GetTimelineResponse]
	streamTimeline     *connect.Client[v12.StreamTimelineRequest, v12.StreamTimelineResponse]
	getConfig          *connect.Client[v11.GetConfigRequest, v11.GetConfigResponse]
	setConfig          *connect.Client[v11.SetConfigRequest, v11.SetConfigResponse]
	getSecret          *connect.Client[v11.GetSecretRequest, v11.GetSecretResponse]
	setSecret          *connect.Client[v11.SetSecretRequest, v11.SetSecretResponse]
	call               *connect.Client[v1.CallRequest, v1.CallResponse]
	streamEngineEvents *connect.Client[v13.StreamEngineEventsRequest, v13.StreamEngineEventsResponse]
	getInfo            *connect.Client[v11.GetInfoRequest, v11.GetInfoResponse]
	executeGoose       *connect.Client[v11.ExecuteGooseRequest, v11.ExecuteGooseResponse]
	openFileInEditor   *connect.Client[v11.OpenFileInEditorRequest, v11.OpenFileInEditorResponse]
}

// Ping calls xyz.block.ftl.console.v1.ConsoleService.Ping.
func (c *consoleServiceClient) Ping(ctx context.Context, req *connect.Request[v1.PingRequest]) (*connect.Response[v1.PingResponse], error) {
	return c.ping.CallUnary(ctx, req)
}

// GetModules calls xyz.block.ftl.console.v1.ConsoleService.GetModules.
func (c *consoleServiceClient) GetModules(ctx context.Context, req *connect.Request[v11.GetModulesRequest]) (*connect.Response[v11.GetModulesResponse], error) {
	return c.getModules.CallUnary(ctx, req)
}

// StreamModules calls xyz.block.ftl.console.v1.ConsoleService.StreamModules.
func (c *consoleServiceClient) StreamModules(ctx context.Context, req *connect.Request[v11.StreamModulesRequest]) (*connect.ServerStreamForClient[v11.StreamModulesResponse], error) {
	return c.streamModules.CallServerStream(ctx, req)
}

// GetTimeline calls xyz.block.ftl.console.v1.ConsoleService.GetTimeline.
func (c *consoleServiceClient) GetTimeline(ctx context.Context, req *connect.Request[v12.GetTimelineRequest]) (*connect.Response[v12.GetTimelineResponse], error) {
	return c.getTimeline.CallUnary(ctx, req)
}

// StreamTimeline calls xyz.block.ftl.console.v1.ConsoleService.StreamTimeline.
func (c *consoleServiceClient) StreamTimeline(ctx context.Context, req *connect.Request[v12.StreamTimelineRequest]) (*connect.ServerStreamForClient[v12.StreamTimelineResponse], error) {
	return c.streamTimeline.CallServerStream(ctx, req)
}

// GetConfig calls xyz.block.ftl.console.v1.ConsoleService.GetConfig.
func (c *consoleServiceClient) GetConfig(ctx context.Context, req *connect.Request[v11.GetConfigRequest]) (*connect.Response[v11.GetConfigResponse], error) {
	return c.getConfig.CallUnary(ctx, req)
}

// SetConfig calls xyz.block.ftl.console.v1.ConsoleService.SetConfig.
func (c *consoleServiceClient) SetConfig(ctx context.Context, req *connect.Request[v11.SetConfigRequest]) (*connect.Response[v11.SetConfigResponse], error) {
	return c.setConfig.CallUnary(ctx, req)
}

// GetSecret calls xyz.block.ftl.console.v1.ConsoleService.GetSecret.
func (c *consoleServiceClient) GetSecret(ctx context.Context, req *connect.Request[v11.GetSecretRequest]) (*connect.Response[v11.GetSecretResponse], error) {
	return c.getSecret.CallUnary(ctx, req)
}

// SetSecret calls xyz.block.ftl.console.v1.ConsoleService.SetSecret.
func (c *consoleServiceClient) SetSecret(ctx context.Context, req *connect.Request[v11.SetSecretRequest]) (*connect.Response[v11.SetSecretResponse], error) {
	return c.setSecret.CallUnary(ctx, req)
}

// Call calls xyz.block.ftl.console.v1.ConsoleService.Call.
func (c *consoleServiceClient) Call(ctx context.Context, req *connect.Request[v1.CallRequest]) (*connect.Response[v1.CallResponse], error) {
	return c.call.CallUnary(ctx, req)
}

// StreamEngineEvents calls xyz.block.ftl.console.v1.ConsoleService.StreamEngineEvents.
func (c *consoleServiceClient) StreamEngineEvents(ctx context.Context, req *connect.Request[v13.StreamEngineEventsRequest]) (*connect.ServerStreamForClient[v13.StreamEngineEventsResponse], error) {
	return c.streamEngineEvents.CallServerStream(ctx, req)
}

// GetInfo calls xyz.block.ftl.console.v1.ConsoleService.GetInfo.
func (c *consoleServiceClient) GetInfo(ctx context.Context, req *connect.Request[v11.GetInfoRequest]) (*connect.Response[v11.GetInfoResponse], error) {
	return c.getInfo.CallUnary(ctx, req)
}

// ExecuteGoose calls xyz.block.ftl.console.v1.ConsoleService.ExecuteGoose.
func (c *consoleServiceClient) ExecuteGoose(ctx context.Context, req *connect.Request[v11.ExecuteGooseRequest]) (*connect.ServerStreamForClient[v11.ExecuteGooseResponse], error) {
	return c.executeGoose.CallServerStream(ctx, req)
}

// OpenFileInEditor calls xyz.block.ftl.console.v1.ConsoleService.OpenFileInEditor.
func (c *consoleServiceClient) OpenFileInEditor(ctx context.Context, req *connect.Request[v11.OpenFileInEditorRequest]) (*connect.Response[v11.OpenFileInEditorResponse], error) {
	return c.openFileInEditor.CallUnary(ctx, req)
}

// ConsoleServiceHandler is an implementation of the xyz.block.ftl.console.v1.ConsoleService
// service.
type ConsoleServiceHandler interface {
	// Ping service for readiness.
	Ping(context.Context, *connect.Request[v1.PingRequest]) (*connect.Response[v1.PingResponse], error)
	GetModules(context.Context, *connect.Request[v11.GetModulesRequest]) (*connect.Response[v11.GetModulesResponse], error)
	StreamModules(context.Context, *connect.Request[v11.StreamModulesRequest], *connect.ServerStream[v11.StreamModulesResponse]) error
	GetTimeline(context.Context, *connect.Request[v12.GetTimelineRequest]) (*connect.Response[v12.GetTimelineResponse], error)
	StreamTimeline(context.Context, *connect.Request[v12.StreamTimelineRequest], *connect.ServerStream[v12.StreamTimelineResponse]) error
	GetConfig(context.Context, *connect.Request[v11.GetConfigRequest]) (*connect.Response[v11.GetConfigResponse], error)
	SetConfig(context.Context, *connect.Request[v11.SetConfigRequest]) (*connect.Response[v11.SetConfigResponse], error)
	GetSecret(context.Context, *connect.Request[v11.GetSecretRequest]) (*connect.Response[v11.GetSecretResponse], error)
	SetSecret(context.Context, *connect.Request[v11.SetSecretRequest]) (*connect.Response[v11.SetSecretResponse], error)
	Call(context.Context, *connect.Request[v1.CallRequest]) (*connect.Response[v1.CallResponse], error)
	StreamEngineEvents(context.Context, *connect.Request[v13.StreamEngineEventsRequest], *connect.ServerStream[v13.StreamEngineEventsResponse]) error
	GetInfo(context.Context, *connect.Request[v11.GetInfoRequest]) (*connect.Response[v11.GetInfoResponse], error)
	ExecuteGoose(context.Context, *connect.Request[v11.ExecuteGooseRequest], *connect.ServerStream[v11.ExecuteGooseResponse]) error
	OpenFileInEditor(context.Context, *connect.Request[v11.OpenFileInEditorRequest]) (*connect.Response[v11.OpenFileInEditorResponse], error)
}

// NewConsoleServiceHandler builds an HTTP handler from the service implementation. It returns the
// path on which to mount the handler and the handler itself.
//
// By default, handlers support the Connect, gRPC, and gRPC-Web protocols with the binary Protobuf
// and JSON codecs. They also support gzip compression.
func NewConsoleServiceHandler(svc ConsoleServiceHandler, opts ...connect.HandlerOption) (string, http.Handler) {
	consoleServiceMethods := v11.File_xyz_block_ftl_console_v1_console_proto.Services().ByName("ConsoleService").Methods()
	consoleServicePingHandler := connect.NewUnaryHandler(
		ConsoleServicePingProcedure,
		svc.Ping,
		connect.WithSchema(consoleServiceMethods.ByName("Ping")),
		connect.WithIdempotency(connect.IdempotencyNoSideEffects),
		connect.WithHandlerOptions(opts...),
	)
	consoleServiceGetModulesHandler := connect.NewUnaryHandler(
		ConsoleServiceGetModulesProcedure,
		svc.GetModules,
		connect.WithSchema(consoleServiceMethods.ByName("GetModules")),
		connect.WithHandlerOptions(opts...),
	)
	consoleServiceStreamModulesHandler := connect.NewServerStreamHandler(
		ConsoleServiceStreamModulesProcedure,
		svc.StreamModules,
		connect.WithSchema(consoleServiceMethods.ByName("StreamModules")),
		connect.WithHandlerOptions(opts...),
	)
	consoleServiceGetTimelineHandler := connect.NewUnaryHandler(
		ConsoleServiceGetTimelineProcedure,
		svc.GetTimeline,
		connect.WithSchema(consoleServiceMethods.ByName("GetTimeline")),
		connect.WithHandlerOptions(opts...),
	)
	consoleServiceStreamTimelineHandler := connect.NewServerStreamHandler(
		ConsoleServiceStreamTimelineProcedure,
		svc.StreamTimeline,
		connect.WithSchema(consoleServiceMethods.ByName("StreamTimeline")),
		connect.WithHandlerOptions(opts...),
	)
	consoleServiceGetConfigHandler := connect.NewUnaryHandler(
		ConsoleServiceGetConfigProcedure,
		svc.GetConfig,
		connect.WithSchema(consoleServiceMethods.ByName("GetConfig")),
		connect.WithHandlerOptions(opts...),
	)
	consoleServiceSetConfigHandler := connect.NewUnaryHandler(
		ConsoleServiceSetConfigProcedure,
		svc.SetConfig,
		connect.WithSchema(consoleServiceMethods.ByName("SetConfig")),
		connect.WithHandlerOptions(opts...),
	)
	consoleServiceGetSecretHandler := connect.NewUnaryHandler(
		ConsoleServiceGetSecretProcedure,
		svc.GetSecret,
		connect.WithSchema(consoleServiceMethods.ByName("GetSecret")),
		connect.WithHandlerOptions(opts...),
	)
	consoleServiceSetSecretHandler := connect.NewUnaryHandler(
		ConsoleServiceSetSecretProcedure,
		svc.SetSecret,
		connect.WithSchema(consoleServiceMethods.ByName("SetSecret")),
		connect.WithHandlerOptions(opts...),
	)
	consoleServiceCallHandler := connect.NewUnaryHandler(
		ConsoleServiceCallProcedure,
		svc.Call,
		connect.WithSchema(consoleServiceMethods.ByName("Call")),
		connect.WithHandlerOptions(opts...),
	)
	consoleServiceStreamEngineEventsHandler := connect.NewServerStreamHandler(
		ConsoleServiceStreamEngineEventsProcedure,
		svc.StreamEngineEvents,
		connect.WithSchema(consoleServiceMethods.ByName("StreamEngineEvents")),
		connect.WithHandlerOptions(opts...),
	)
	consoleServiceGetInfoHandler := connect.NewUnaryHandler(
		ConsoleServiceGetInfoProcedure,
		svc.GetInfo,
		connect.WithSchema(consoleServiceMethods.ByName("GetInfo")),
		connect.WithHandlerOptions(opts...),
	)
	consoleServiceExecuteGooseHandler := connect.NewServerStreamHandler(
		ConsoleServiceExecuteGooseProcedure,
		svc.ExecuteGoose,
		connect.WithSchema(consoleServiceMethods.ByName("ExecuteGoose")),
		connect.WithHandlerOptions(opts...),
	)
	consoleServiceOpenFileInEditorHandler := connect.NewUnaryHandler(
		ConsoleServiceOpenFileInEditorProcedure,
		svc.OpenFileInEditor,
		connect.WithSchema(consoleServiceMethods.ByName("OpenFileInEditor")),
		connect.WithHandlerOptions(opts...),
	)
	return "/xyz.block.ftl.console.v1.ConsoleService/", http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
		switch r.URL.Path {
		case ConsoleServicePingProcedure:
			consoleServicePingHandler.ServeHTTP(w, r)
		case ConsoleServiceGetModulesProcedure:
			consoleServiceGetModulesHandler.ServeHTTP(w, r)
		case ConsoleServiceStreamModulesProcedure:
			consoleServiceStreamModulesHandler.ServeHTTP(w, r)
		case ConsoleServiceGetTimelineProcedure:
			consoleServiceGetTimelineHandler.ServeHTTP(w, r)
		case ConsoleServiceStreamTimelineProcedure:
			consoleServiceStreamTimelineHandler.ServeHTTP(w, r)
		case ConsoleServiceGetConfigProcedure:
			consoleServiceGetConfigHandler.ServeHTTP(w, r)
		case ConsoleServiceSetConfigProcedure:
			consoleServiceSetConfigHandler.ServeHTTP(w, r)
		case ConsoleServiceGetSecretProcedure:
			consoleServiceGetSecretHandler.ServeHTTP(w, r)
		case ConsoleServiceSetSecretProcedure:
			consoleServiceSetSecretHandler.ServeHTTP(w, r)
		case ConsoleServiceCallProcedure:
			consoleServiceCallHandler.ServeHTTP(w, r)
		case ConsoleServiceStreamEngineEventsProcedure:
			consoleServiceStreamEngineEventsHandler.ServeHTTP(w, r)
		case ConsoleServiceGetInfoProcedure:
			consoleServiceGetInfoHandler.ServeHTTP(w, r)
		case ConsoleServiceExecuteGooseProcedure:
			consoleServiceExecuteGooseHandler.ServeHTTP(w, r)
		case ConsoleServiceOpenFileInEditorProcedure:
			consoleServiceOpenFileInEditorHandler.ServeHTTP(w, r)
		default:
			http.NotFound(w, r)
		}
	})
}

// UnimplementedConsoleServiceHandler returns CodeUnimplemented from all methods.
type UnimplementedConsoleServiceHandler struct{}

func (UnimplementedConsoleServiceHandler) Ping(context.Context, *connect.Request[v1.PingRequest]) (*connect.Response[v1.PingResponse], error) {
	return nil, connect.NewError(connect.CodeUnimplemented, errors.New("xyz.block.ftl.console.v1.ConsoleService.Ping is not implemented"))
}

func (UnimplementedConsoleServiceHandler) GetModules(context.Context, *connect.Request[v11.GetModulesRequest]) (*connect.Response[v11.GetModulesResponse], error) {
	return nil, connect.NewError(connect.CodeUnimplemented, errors.New("xyz.block.ftl.console.v1.ConsoleService.GetModules is not implemented"))
}

func (UnimplementedConsoleServiceHandler) StreamModules(context.Context, *connect.Request[v11.StreamModulesRequest], *connect.ServerStream[v11.StreamModulesResponse]) error {
	return connect.NewError(connect.CodeUnimplemented, errors.New("xyz.block.ftl.console.v1.ConsoleService.StreamModules is not implemented"))
}

func (UnimplementedConsoleServiceHandler) GetTimeline(context.Context, *connect.Request[v12.GetTimelineRequest]) (*connect.Response[v12.GetTimelineResponse], error) {
	return nil, connect.NewError(connect.CodeUnimplemented, errors.New("xyz.block.ftl.console.v1.ConsoleService.GetTimeline is not implemented"))
}

func (UnimplementedConsoleServiceHandler) StreamTimeline(context.Context, *connect.Request[v12.StreamTimelineRequest], *connect.ServerStream[v12.StreamTimelineResponse]) error {
	return connect.NewError(connect.CodeUnimplemented, errors.New("xyz.block.ftl.console.v1.ConsoleService.StreamTimeline is not implemented"))
}

func (UnimplementedConsoleServiceHandler) GetConfig(context.Context, *connect.Request[v11.GetConfigRequest]) (*connect.Response[v11.GetConfigResponse], error) {
	return nil, connect.NewError(connect.CodeUnimplemented, errors.New("xyz.block.ftl.console.v1.ConsoleService.GetConfig is not implemented"))
}

func (UnimplementedConsoleServiceHandler) SetConfig(context.Context, *connect.Request[v11.SetConfigRequest]) (*connect.Response[v11.SetConfigResponse], error) {
	return nil, connect.NewError(connect.CodeUnimplemented, errors.New("xyz.block.ftl.console.v1.ConsoleService.SetConfig is not implemented"))
}

func (UnimplementedConsoleServiceHandler) GetSecret(context.Context, *connect.Request[v11.GetSecretRequest]) (*connect.Response[v11.GetSecretResponse], error) {
	return nil, connect.NewError(connect.CodeUnimplemented, errors.New("xyz.block.ftl.console.v1.ConsoleService.GetSecret is not implemented"))
}

func (UnimplementedConsoleServiceHandler) SetSecret(context.Context, *connect.Request[v11.SetSecretRequest]) (*connect.Response[v11.SetSecretResponse], error) {
	return nil, connect.NewError(connect.CodeUnimplemented, errors.New("xyz.block.ftl.console.v1.ConsoleService.SetSecret is not implemented"))
}

func (UnimplementedConsoleServiceHandler) Call(context.Context, *connect.Request[v1.CallRequest]) (*connect.Response[v1.CallResponse], error) {
	return nil, connect.NewError(connect.CodeUnimplemented, errors.New("xyz.block.ftl.console.v1.ConsoleService.Call is not implemented"))
}

func (UnimplementedConsoleServiceHandler) StreamEngineEvents(context.Context, *connect.Request[v13.StreamEngineEventsRequest], *connect.ServerStream[v13.StreamEngineEventsResponse]) error {
	return connect.NewError(connect.CodeUnimplemented, errors.New("xyz.block.ftl.console.v1.ConsoleService.StreamEngineEvents is not implemented"))
}

func (UnimplementedConsoleServiceHandler) GetInfo(context.Context, *connect.Request[v11.GetInfoRequest]) (*connect.Response[v11.GetInfoResponse], error) {
	return nil, connect.NewError(connect.CodeUnimplemented, errors.New("xyz.block.ftl.console.v1.ConsoleService.GetInfo is not implemented"))
}

func (UnimplementedConsoleServiceHandler) ExecuteGoose(context.Context, *connect.Request[v11.ExecuteGooseRequest], *connect.ServerStream[v11.ExecuteGooseResponse]) error {
	return connect.NewError(connect.CodeUnimplemented, errors.New("xyz.block.ftl.console.v1.ConsoleService.ExecuteGoose is not implemented"))
}

func (UnimplementedConsoleServiceHandler) OpenFileInEditor(context.Context, *connect.Request[v11.OpenFileInEditorRequest]) (*connect.Response[v11.OpenFileInEditorResponse], error) {
	return nil, connect.NewError(connect.CodeUnimplemented, errors.New("xyz.block.ftl.console.v1.ConsoleService.OpenFileInEditor is not implemented"))
}
