workflows

package
v0.0.0-...-6a23013 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 17, 2023 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AcceptSubmissionSignalName = "accept-submission"
	AcceptGracePeriod          = time.Hour * 24 * 7
)
View Source
const (
	EmploymentVerificationDetailsQuery         = "employment-verification-details"
	EmploymentVerificationSubmissionSignalName = "employment-verification-submission"
	ResearchDeadline                           = time.Hour * 24 * 7
)
View Source
const (
	BackgroundCheckStatusQuery = "background-check-status"
)

Variables

This section is empty.

Functions

func AcceptWorkflowID

func AcceptWorkflowID(email string) string

func BackgroundCheckWorkflowID

func BackgroundCheckWorkflowID(email string) string

func EmploymentVerificationWorkflowID

func EmploymentVerificationWorkflowID(email string) string

func SearchWorkflowID

func SearchWorkflowID(email string, name string) string

func TokenForWorkflow

func TokenForWorkflow(ctx workflow.Context) string

func WorkflowFromToken

func WorkflowFromToken(token string) (string, string, error)

Types

type AcceptSubmission

type AcceptSubmission struct {
	Accepted         bool
	CandidateDetails CandidateDetails
}

type AcceptSubmissionSignal

type AcceptSubmissionSignal struct {
	Accepted         bool
	CandidateDetails CandidateDetails
}

type AcceptWorkflowInput

type AcceptWorkflowInput struct {
	Email string
}

type AcceptWorkflowResult

type AcceptWorkflowResult struct {
	Accepted         bool
	CandidateDetails CandidateDetails
}

func Accept

@@@SNIPSTART background-checks-accept-workflow-definition

type BackgroundCheckState

type BackgroundCheckState struct {
	Email            string
	Tier             string
	Accepted         bool
	CandidateDetails CandidateDetails
	SSNTrace         *SSNTraceWorkflowResult
	SearchResults    map[string]interface{}
	SearchErrors     map[string]string
}

type BackgroundCheckWorkflowInput

type BackgroundCheckWorkflowInput struct {
	Email string
	Tier  string
}

type BackgroundCheckWorkflowResult

type BackgroundCheckWorkflowResult = BackgroundCheckState

func BackgroundCheck

BackgroundCheck is a Workflow Definition that calls for the execution of a variable set of Activities and Child Workflows. This is the main entry point of the application. It accepts an email address as the input. All other personal information for the Candidate is provided when they accept the Background Check.

type CandidateDetails

type CandidateDetails struct {
	FullName string
	Address  string
	SSN      string
	DOB      string
	Employer string
}

type EmploymentVerificationSubmission

type EmploymentVerificationSubmission struct {
	EmploymentVerificationComplete bool
	EmployerVerified               bool
}

type EmploymentVerificationSubmissionSignal

type EmploymentVerificationSubmissionSignal struct {
	EmploymentVerificationComplete bool
	EmployerVerified               bool
}

type EmploymentVerificationWorkflowInput

type EmploymentVerificationWorkflowInput struct {
	CandidateDetails CandidateDetails
}

type EmploymentVerificationWorkflowResult

type EmploymentVerificationWorkflowResult struct {
	EmploymentVerificationComplete bool
	EmployerVerified               bool
}

func EmploymentVerification

EmploymentVerification is a Workflow Definition that calls for the execution of a Side Effect, and an Activity, but then waits on and handles a Signal. It is also capable of handling a Query to get Candidate Details. This is executed as a Child Workflow by the main Background Check.

type FederalCriminalSearchWorkflowInput

type FederalCriminalSearchWorkflowInput struct {
	FullName       string
	KnownAddresses []string
}

type FederalCriminalSearchWorkflowResult

type FederalCriminalSearchWorkflowResult struct {
	Crimes []string
}

func FederalCriminalSearch

@@@SNIPSTART background-checks-federal-criminal-workflow-definition

type KnownAddress

type KnownAddress struct {
	Address string
	City    string
	State   string
	ZipCode string
}

type MotorVehicleIncidentSearchWorkflowInput

type MotorVehicleIncidentSearchWorkflowInput struct {
	FullName string
	Address  string
}

type MotorVehicleIncidentSearchWorkflowResult

type MotorVehicleIncidentSearchWorkflowResult struct {
	LicenseValid          bool
	MotorVehicleIncidents []string
}

func MotorVehicleIncidentSearch

@@@SNIPSTART background-checks-motor-vehicle-workflow-definition

type SSNTraceWorkflowInput

type SSNTraceWorkflowInput struct {
	FullName string
	SSN      string
}

type SSNTraceWorkflowResult

type SSNTraceWorkflowResult struct {
	SSNIsValid     bool
	KnownAddresses []string
}

func SSNTrace

SSNTrace is a Workflow Definition that calls for the execution of a single Activity. This is executed as a Child Workflow by the main Background Check.

type StateCriminalSearchWorkflowInput

type StateCriminalSearchWorkflowInput struct {
	FullName       string
	KnownAddresses []string
}

type StateCriminalSearchWorkflowResult

type StateCriminalSearchWorkflowResult struct {
	Crimes []string
}

func StateCriminalSearch

StateCriminalSearch is a Workflow Definition that calls for the execution an Activity for each address associated with the Candidate. This is executed as a Child Workflow by the main Background Check.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL