Documentation
¶
Index ¶
- type WorkflowClient
- type WorkflowClientOpt
- func WithJWTGenerator(jwtGenerator auth.JWTGenerator) WorkflowClientOpt
- func WithServerName(name string) WorkflowClientOpt
- func WithWorkflowLogger(l logger.Logger) WorkflowClientOpt
- func WithWorkflowTLSCert(cert string) WorkflowClientOpt
- func WithWorkflowTransportCredentials(creds credentials.TransportCredentials) WorkflowClientOpt
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type WorkflowClient ¶
type WorkflowClient interface {
GetOrganizationCreditsByWorkflow(ctx context.Context, req *pb.GetOrganizationCreditsByWorkflowRequest) (*pb.GetOrganizationCreditsByWorkflowResponse, error)
GetRateCard(ctx context.Context, req *pb.GetRateCardRequest) (*pb.GetRateCardResponse, error)
ReserveCredits(ctx context.Context, req *pb.ReserveCreditsRequest) (*pb.ReserveCreditsResponse, error)
SubmitWorkflowReceipt(ctx context.Context, req *pb.SubmitWorkflowReceiptRequest) (*emptypb.Empty, error)
// Closer
Close() error
}
WorkflowClient is a specialized interface for the Workflow node use-case.
func NewWorkflowClient ¶
func NewWorkflowClient(address string, opts ...WorkflowClientOpt) (WorkflowClient, error)
NewWorkflowClient creates a new workflow client with JWT signing enabled.
type WorkflowClientOpt ¶
type WorkflowClientOpt func(*workflowConfig)
func WithJWTGenerator ¶ added in v0.8.0
func WithJWTGenerator(jwtGenerator auth.JWTGenerator) WorkflowClientOpt
WithJWTGenerator sets the JWT generator for authentication.
func WithServerName ¶
func WithServerName(name string) WorkflowClientOpt
WithServerName allows overriding the expected server name in the TLS certificate.
func WithWorkflowLogger ¶
func WithWorkflowLogger(l logger.Logger) WorkflowClientOpt
func WithWorkflowTLSCert ¶
func WithWorkflowTLSCert(cert string) WorkflowClientOpt
func WithWorkflowTransportCredentials ¶
func WithWorkflowTransportCredentials(creds credentials.TransportCredentials) WorkflowClientOpt
Click to show internal directories.
Click to hide internal directories.