// Copyright 2025 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. // Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: // - protoc-gen-go-grpc v1.3.0 // - protoc v4.25.7 // source: google/shopping/merchant/conversions/v1beta/conversionsources.proto package conversionspb import ( context "context" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" emptypb "google.golang.org/protobuf/types/known/emptypb" ) // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. // Requires gRPC-Go v1.32.0 or later. const _ = grpc.SupportPackageIsVersion7 const ( ConversionSourcesService_CreateConversionSource_FullMethodName = "/google.shopping.merchant.conversions.v1beta.ConversionSourcesService/CreateConversionSource" ConversionSourcesService_UpdateConversionSource_FullMethodName = "/google.shopping.merchant.conversions.v1beta.ConversionSourcesService/UpdateConversionSource" ConversionSourcesService_DeleteConversionSource_FullMethodName = "/google.shopping.merchant.conversions.v1beta.ConversionSourcesService/DeleteConversionSource" ConversionSourcesService_UndeleteConversionSource_FullMethodName = "/google.shopping.merchant.conversions.v1beta.ConversionSourcesService/UndeleteConversionSource" ConversionSourcesService_GetConversionSource_FullMethodName = "/google.shopping.merchant.conversions.v1beta.ConversionSourcesService/GetConversionSource" ConversionSourcesService_ListConversionSources_FullMethodName = "/google.shopping.merchant.conversions.v1beta.ConversionSourcesService/ListConversionSources" ) // ConversionSourcesServiceClient is the client API for ConversionSourcesService service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. type ConversionSourcesServiceClient interface { // Creates a new conversion source. CreateConversionSource(ctx context.Context, in *CreateConversionSourceRequest, opts ...grpc.CallOption) (*ConversionSource, error) // Updates information of an existing conversion source. Available only for // Merchant Center Destination conversion sources. UpdateConversionSource(ctx context.Context, in *UpdateConversionSourceRequest, opts ...grpc.CallOption) (*ConversionSource, error) // Archives an existing conversion source. If the conversion source is a // Merchant Center Destination, it will be recoverable for 30 days. If the // conversion source is a Google Analytics Link, it will be deleted // immediately and can be restored by creating a new one. DeleteConversionSource(ctx context.Context, in *DeleteConversionSourceRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) // Re-enables an archived conversion source. Only Available for Merchant // Center Destination conversion sources. UndeleteConversionSource(ctx context.Context, in *UndeleteConversionSourceRequest, opts ...grpc.CallOption) (*ConversionSource, error) // Fetches a conversion source. GetConversionSource(ctx context.Context, in *GetConversionSourceRequest, opts ...grpc.CallOption) (*ConversionSource, error) // Retrieves the list of conversion sources the caller has access to. ListConversionSources(ctx context.Context, in *ListConversionSourcesRequest, opts ...grpc.CallOption) (*ListConversionSourcesResponse, error) } type conversionSourcesServiceClient struct { cc grpc.ClientConnInterface } func NewConversionSourcesServiceClient(cc grpc.ClientConnInterface) ConversionSourcesServiceClient { return &conversionSourcesServiceClient{cc} } func (c *conversionSourcesServiceClient) CreateConversionSource(ctx context.Context, in *CreateConversionSourceRequest, opts ...grpc.CallOption) (*ConversionSource, error) { out := new(ConversionSource) err := c.cc.Invoke(ctx, ConversionSourcesService_CreateConversionSource_FullMethodName, in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *conversionSourcesServiceClient) UpdateConversionSource(ctx context.Context, in *UpdateConversionSourceRequest, opts ...grpc.CallOption) (*ConversionSource, error) { out := new(ConversionSource) err := c.cc.Invoke(ctx, ConversionSourcesService_UpdateConversionSource_FullMethodName, in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *conversionSourcesServiceClient) DeleteConversionSource(ctx context.Context, in *DeleteConversionSourceRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { out := new(emptypb.Empty) err := c.cc.Invoke(ctx, ConversionSourcesService_DeleteConversionSource_FullMethodName, in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *conversionSourcesServiceClient) UndeleteConversionSource(ctx context.Context, in *UndeleteConversionSourceRequest, opts ...grpc.CallOption) (*ConversionSource, error) { out := new(ConversionSource) err := c.cc.Invoke(ctx, ConversionSourcesService_UndeleteConversionSource_FullMethodName, in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *conversionSourcesServiceClient) GetConversionSource(ctx context.Context, in *GetConversionSourceRequest, opts ...grpc.CallOption) (*ConversionSource, error) { out := new(ConversionSource) err := c.cc.Invoke(ctx, ConversionSourcesService_GetConversionSource_FullMethodName, in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *conversionSourcesServiceClient) ListConversionSources(ctx context.Context, in *ListConversionSourcesRequest, opts ...grpc.CallOption) (*ListConversionSourcesResponse, error) { out := new(ListConversionSourcesResponse) err := c.cc.Invoke(ctx, ConversionSourcesService_ListConversionSources_FullMethodName, in, out, opts...) if err != nil { return nil, err } return out, nil } // ConversionSourcesServiceServer is the server API for ConversionSourcesService service. // All implementations should embed UnimplementedConversionSourcesServiceServer // for forward compatibility type ConversionSourcesServiceServer interface { // Creates a new conversion source. CreateConversionSource(context.Context, *CreateConversionSourceRequest) (*ConversionSource, error) // Updates information of an existing conversion source. Available only for // Merchant Center Destination conversion sources. UpdateConversionSource(context.Context, *UpdateConversionSourceRequest) (*ConversionSource, error) // Archives an existing conversion source. If the conversion source is a // Merchant Center Destination, it will be recoverable for 30 days. If the // conversion source is a Google Analytics Link, it will be deleted // immediately and can be restored by creating a new one. DeleteConversionSource(context.Context, *DeleteConversionSourceRequest) (*emptypb.Empty, error) // Re-enables an archived conversion source. Only Available for Merchant // Center Destination conversion sources. UndeleteConversionSource(context.Context, *UndeleteConversionSourceRequest) (*ConversionSource, error) // Fetches a conversion source. GetConversionSource(context.Context, *GetConversionSourceRequest) (*ConversionSource, error) // Retrieves the list of conversion sources the caller has access to. ListConversionSources(context.Context, *ListConversionSourcesRequest) (*ListConversionSourcesResponse, error) } // UnimplementedConversionSourcesServiceServer should be embedded to have forward compatible implementations. type UnimplementedConversionSourcesServiceServer struct { } func (UnimplementedConversionSourcesServiceServer) CreateConversionSource(context.Context, *CreateConversionSourceRequest) (*ConversionSource, error) { return nil, status.Errorf(codes.Unimplemented, "method CreateConversionSource not implemented") } func (UnimplementedConversionSourcesServiceServer) UpdateConversionSource(context.Context, *UpdateConversionSourceRequest) (*ConversionSource, error) { return nil, status.Errorf(codes.Unimplemented, "method UpdateConversionSource not implemented") } func (UnimplementedConversionSourcesServiceServer) DeleteConversionSource(context.Context, *DeleteConversionSourceRequest) (*emptypb.Empty, error) { return nil, status.Errorf(codes.Unimplemented, "method DeleteConversionSource not implemented") } func (UnimplementedConversionSourcesServiceServer) UndeleteConversionSource(context.Context, *UndeleteConversionSourceRequest) (*ConversionSource, error) { return nil, status.Errorf(codes.Unimplemented, "method UndeleteConversionSource not implemented") } func (UnimplementedConversionSourcesServiceServer) GetConversionSource(context.Context, *GetConversionSourceRequest) (*ConversionSource, error) { return nil, status.Errorf(codes.Unimplemented, "method GetConversionSource not implemented") } func (UnimplementedConversionSourcesServiceServer) ListConversionSources(context.Context, *ListConversionSourcesRequest) (*ListConversionSourcesResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ListConversionSources not implemented") } // UnsafeConversionSourcesServiceServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to ConversionSourcesServiceServer will // result in compilation errors. type UnsafeConversionSourcesServiceServer interface { mustEmbedUnimplementedConversionSourcesServiceServer() } func RegisterConversionSourcesServiceServer(s grpc.ServiceRegistrar, srv ConversionSourcesServiceServer) { s.RegisterService(&ConversionSourcesService_ServiceDesc, srv) } func _ConversionSourcesService_CreateConversionSource_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(CreateConversionSourceRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(ConversionSourcesServiceServer).CreateConversionSource(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: ConversionSourcesService_CreateConversionSource_FullMethodName, } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(ConversionSourcesServiceServer).CreateConversionSource(ctx, req.(*CreateConversionSourceRequest)) } return interceptor(ctx, in, info, handler) } func _ConversionSourcesService_UpdateConversionSource_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(UpdateConversionSourceRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(ConversionSourcesServiceServer).UpdateConversionSource(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: ConversionSourcesService_UpdateConversionSource_FullMethodName, } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(ConversionSourcesServiceServer).UpdateConversionSource(ctx, req.(*UpdateConversionSourceRequest)) } return interceptor(ctx, in, info, handler) } func _ConversionSourcesService_DeleteConversionSource_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(DeleteConversionSourceRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(ConversionSourcesServiceServer).DeleteConversionSource(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: ConversionSourcesService_DeleteConversionSource_FullMethodName, } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(ConversionSourcesServiceServer).DeleteConversionSource(ctx, req.(*DeleteConversionSourceRequest)) } return interceptor(ctx, in, info, handler) } func _ConversionSourcesService_UndeleteConversionSource_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(UndeleteConversionSourceRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(ConversionSourcesServiceServer).UndeleteConversionSource(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: ConversionSourcesService_UndeleteConversionSource_FullMethodName, } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(ConversionSourcesServiceServer).UndeleteConversionSource(ctx, req.(*UndeleteConversionSourceRequest)) } return interceptor(ctx, in, info, handler) } func _ConversionSourcesService_GetConversionSource_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(GetConversionSourceRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(ConversionSourcesServiceServer).GetConversionSource(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: ConversionSourcesService_GetConversionSource_FullMethodName, } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(ConversionSourcesServiceServer).GetConversionSource(ctx, req.(*GetConversionSourceRequest)) } return interceptor(ctx, in, info, handler) } func _ConversionSourcesService_ListConversionSources_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(ListConversionSourcesRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(ConversionSourcesServiceServer).ListConversionSources(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: ConversionSourcesService_ListConversionSources_FullMethodName, } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(ConversionSourcesServiceServer).ListConversionSources(ctx, req.(*ListConversionSourcesRequest)) } return interceptor(ctx, in, info, handler) } // ConversionSourcesService_ServiceDesc is the grpc.ServiceDesc for ConversionSourcesService service. // It's only intended for direct use with grpc.RegisterService, // and not to be introspected or modified (even as a copy) var ConversionSourcesService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "google.shopping.merchant.conversions.v1beta.ConversionSourcesService", HandlerType: (*ConversionSourcesServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "CreateConversionSource", Handler: _ConversionSourcesService_CreateConversionSource_Handler, }, { MethodName: "UpdateConversionSource", Handler: _ConversionSourcesService_UpdateConversionSource_Handler, }, { MethodName: "DeleteConversionSource", Handler: _ConversionSourcesService_DeleteConversionSource_Handler, }, { MethodName: "UndeleteConversionSource", Handler: _ConversionSourcesService_UndeleteConversionSource_Handler, }, { MethodName: "GetConversionSource", Handler: _ConversionSourcesService_GetConversionSource_Handler, }, { MethodName: "ListConversionSources", Handler: _ConversionSourcesService_ListConversionSources_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "google/shopping/merchant/conversions/v1beta/conversionsources.proto", }