package
0.0.5
Repository: https://github.com/goplugin/plugin.git
Documentation: pkg.go.dev

# Functions

AuthenticateBridgeType returns true if the passed token matches its IncomingToken, or returns false with an error.
AuthenticateExternalInitiator compares an auth against an initiator and returns true if the password hashes match.
AuthenticateUserByToken returns true on successful authentication of the user against the given Authentication Token.
BuildServiceAgreement builds a signed service agreement.
BytesToFunctionSelector converts the given bytes to a FunctionSelector.
BytesToSignature converts an arbitrary length byte array to a Signature.
CoerceInterfaceMapToStringMap converts map[interface{}]interface{} (interface maps) to map[string]interface{} (string maps) and []interface{} with interface maps to string maps.
FilterQueryFactory returns the ethereum FilterQuery for this initiator.
HexToFunctionSelector converts the given string to a FunctionSelector.
IDToHexTopic encodes the string representation of the JobID.
IDToTopic encodes the bytes representation of the JobID padded to fit into a bytes32.
JobSpecIDTopics lists the ways jsID could be represented as a log topic.
No description provided by the author
MakeJobRun returns a new JobRun copy.
No description provided by the author
MarshalToMap converts a struct (typically) to a map[string] so it can be manipulated without repeatedly serializing/deserializing.
Merge returns a new map with all keys merged from left to right On conflicting keys, rightmost inputs will clobber leftmost inputs.
MergeExceptResult does a merge, but will never clobber the field called "result" On conflicting keys, rightmost inputs will clobber leftmost inputs EXCEPT if the field is named "result", in which case the leftmost result wins This is needed to work around idiosyncrasies in the V1 job pipeline where "result" has special meaning.
No description provided by the author
MustNewTaskType instantiates a new TaskType, and panics if a bad input is provided.
No description provided by the author
No description provided by the author
NewAnyTime creates a new Time.
NewBridgeType returns a bridge bridge type authentication (with plaintext password) and a bridge type (with hashed password, for persisting).
NewDatabaseAccessError returns a database access error.
NewExternalInitiator generates an ExternalInitiator from an auth.Token, hashing the password for storage.
NewHead returns a Head instance.
NewInitiatorFromRequest creates an Initiator from the corresponding parameters in a InitiatorRequest.
NewJob initializes a new job by generating a unique ID and setting the CreatedAt field to the time of invokation.
NewJobFromRequest creates a JobSpec from the corresponding parameters in a JobSpecRequest.
NewJobID returns a new JobID.
NewJobIDFromString is a convenience function to return an id from an input string.
NewJobSpecError creates a new JobSpecError struct.
NewJSONAPIErrors creates an instance of JSONAPIErrors, with the intention of managing a collection of them.
NewJSONAPIErrorsWith creates an instance of JSONAPIErrors populated with this single detail.
No description provided by the author
NewRunInput creates a new RunInput with arbitrary data.
NewRunInputWithResult creates a new RunInput with a value in the "result" field.
NewRunOutputComplete returns a new RunOutput that is complete and contains raw data.
NewRunOutputCompleteWithResult returns a new RunOutput that is complete and contains a result and preserves the resultCollection.
NewRunOutputError returns a new RunOutput with an error.
NewRunOutputInProgress returns a new RunOutput that indicates the task is still in progress.
NewRunOutputPendingBridge returns a new RunOutput that indicates the task is still in progress.
NewRunOutputPendingConnection returns a new RunOutput that indicates the task got disconnected.
NewRunOutputPendingConnectionWithData returns a new RunOutput that indicates the task got disconnected but also has some data that needs to be fed in on next invocation.
NewRunOutputPendingOutgoingConfirmationsWithData returns a new RunOutput that indicates the task is pending outgoing confirmations but also has some data that needs to be fed in on next invocation.
NewRunRequest returns a new RunRequest instance.
NewSession returns a session instance with ID set to a random ID and LastUsed to to now.
NewSignature returns a new Signature.
NewTaskType returns a formatted Task type.
NewUnsignedServiceAgreementFromRequest builds the information required to sign a service agreement.
NewUser creates a new user by hashing the passed plainPwd with bcrypt.
NewValidationError returns a validation error.
ParseCBOR attempts to coerce the input byte array into valid CBOR and then coerces it into a JSON object.
ParseJSON attempts to coerce the input byte array into valid JSON and parse it into a JSON object.
ParseRandomnessRequestLog returns the RandomnessRequestLog corresponding to the raw logData.
ParseRunLog decodes the CBOR in the ABI of the log event.
No description provided by the author
ReceiptIndicatesRunLogFulfillment returns true if this tx receipt is the result of a fulfilled run log.
Unconfirmed returns true if the transaction is not confirmed.
No description provided by the author
ValidateBulkDeleteRunRequest returns a task from a request to make a task.
VRFCoordinatorABI returns the ABI for the VRFCoordinator contract.
VRFFulfillMethod returns the golang abstraction of the fulfillRandomnessRequest method.
VRFFulfillSelector returns the signature of the fulfillRandomnessRequest method on the VRFCoordinator contract.
VRFRandomnessRequestLogTopic returns the signature of the RandomnessRequest log emitted by the VRFCoordinator contract.

# Constants

No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
FunctionSelectorLength should always be a length of 4 as a byte.
InitiatorCron for tasks in a job to be ran on a schedule.
InitiatorEthLog for tasks in a job to use the Ethereum blockchain.
InitiatorExternal for tasks in a job to be trigger by an external party.
InitiatorFluxMonitor for tasks in a job to be run on price deviation or request for a new round of prices.
InitiatorRandomnessLog for tasks from a VRF specific contract.
InitiatorRunAt for tasks in a job to be ran once.
InitiatorRunLog for tasks in a job to watch an ethereum address and expect a JSON payload from a log event.
InitiatorServiceAgreementExecutionLog for tasks in a job to watch a Solidity Coordinator contract and expect a payload from a log event.
InitiatorWeb for tasks in a job making a web request.
https://security.stackexchange.com/questions/39849/does-bcrypt-have-a-maximum-password-length.
Descriptive indices of a RunLog's Topic array.
Descriptive indices of a RunLog's Topic array.
Descriptive indices of a RunLog's Topic array.
Descriptive indices of a RunLog's Topic array.
No description provided by the author
No description provided by the author
RunStatusCancelled is used to indicate a run is no longer desired.
RunStatusCompleted is used for when a run has successfully completed execution.
RunStatusErrored is used for when a run has errored and will not complete.
RunStatusInProgress is used for when a run is actively being executed.
RunStatusPendingBridge is used for when a run is waiting on the completion of another event.
RunStatusPendingConnection states that the run is waiting on a connection to the block chain.
RunStatusPendingIncomingConfirmations is used for when a run is awaiting for incoming block confirmations e.g.
RunStatusPendingOutgoingConfirmations is used for when a run is waiting for outgoing block confirmations e.g.
RunStatusPendingSleep is used for when a run is waiting on a sleep function to finish.
RunStatusUnstarted is the default state of any run status.
SignatureLength is the length of the signature in bytes: v = 1, r = 32, s = 32; v + r + s = 65.

# Variables

ChainlinkFulfilledTopic is the signature for the event emitted after calling ChainlinkClient.validateChainlinkCallback(requestId).
CronParser is the global parser for crontabs.
LogBasedChainlinkJobInitiators are initiators which kick off a user-specified chainlink job when an appropriate ethereum log is received.
NilJobID is special form of JobID that is specified to have all 128 bits set to zero.
OracleFulfillmentFunctionID20190128withoutCast is the function selector for fulfilling Ethereum requests, as updated on 2019-01-28, removing the cast to uint256 for the requestId.
No description provided by the author
RandomnessRequestLogTopic is the signature for the event log VRFCoordinator.RandomnessRequest.
RunLogTopic20190207withoutIndexes was the new RunRequest filter topic as of 2019-01-28, after renaming Solidity variables, moving data version, and removing the cast of requestId to uint256.
TopicsForInitiatorsWhichRequireJobSpecIDTopic are the log topics which kick off a user job with the given type of initiator.
WeiPerEth is amount of Wei currency units in one Eth.

# Structs

AnyTime holds a common field for time, and serializes it as a json number.
NOTE: latestAnswer and updatedAt is the only metadata used.
No description provided by the author
BridgeRunResult handles the parsing of RunResults from external adapters.
BridgeType is used for external adapters and has fields for the name of the adapter and its URL.
BridgeTypeAuthentication is the record returned in response to a request to create a BridgeType.
BridgeTypeRequest is the incoming record used to create a BridgeType.
BulkDeleteRunRequest describes the query for deletion of runs.
Changeauth.TokenRequest is sent when updating a User's authentication token.
Configuration stores key value pairs for overriding global configuration.
DatabaseAccessError is an error that occurs during database access.
Duration is a non-negative time duration.
Encumbrance connects job specifications with on-chain encumbrances.
EthLogEvent provides functionality specific to a log event emitted for an eth log initiator.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
ExternalInitiator represents a user that can initiate runs remotely.
ExternalInitiatorRequest is the incoming record used to create an ExternalInitiator.
No description provided by the author
Head represents a BlockNumber, BlockHash.
No description provided by the author
Initiator could be thought of as a trigger, defines how a Job can be started, or rather, how a JobRun can be created from a Job.
InitiatorLogEvent encapsulates all information as a result of a received log from an InitiatorSubscription, and acts as a base struct for other log-initiated events.
InitiatorParams is a collection of the possible parameters that different Initiators may require.
InitiatorRequest represents a schema for incoming initiator requests as used by the API.
JobRun tracks the status of a job by holding its TaskRuns and the Result of each Run.
JobSpec is the definition for all the work to be carried out by the node for a given contract.
JobSpecError represents an asynchronous error caused by a JobSpec.
JobSpecRequest represents a schema for the incoming job spec request as used by the API.
JSON stores the json types string, number, bool, and null.
JSONAPIError is an individual JSONAPI Error.
JSONAPIErrors holds errors conforming to the JSONAPI spec.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
RandomnessLogEvent provides functionality specific to a log event emitted for a run log initiator.
RandomnessRequestLog contains the data for a RandomnessRequest log, represented as compatible golang types.
RunInput represents the input for performing a Task.
RunLogEvent provides functionality specific to a log event emitted for a run log initiator.
RunOutput represents the result of performing a Task.
RunRequest stores the fields used to initiate the parent job run.
RunResult keeps track of the outcome of a TaskRun or JobRun.
SendEtherRequest represents a request to transfer ETH.
ServiceAgreement connects job specifications with on-chain encumbrances.
ServiceAgreementRequest encodes external ServiceAgreement json representation.
Session holds the unique id for the authenticated session.
SessionRequest encapsulates the fields needed to generate a new SessionID, including the hashed password.
SyncEvent represents an event sourcing style event, which is used to sync data upstream with another service.
TaskRun stores the Task and represents the status of the Task to be ran.
TaskSpec is the definition of work to be carried out.
TaskSpecRequest represents a schema for incoming TaskSpec requests as used by the API.
UnsignedServiceAgreement contains the information to sign a service agreement.
User holds the credentials for API user.
ValidationError is an error that occurs during validation.
WithdrawalRequest request to withdraw LINK.

# Interfaces

LogRequest is the interface to allow polymorphic functionality of different types of LogEvents.
Signer is used to produce a HMAC signature from an input digest.

# Type aliases

AddressCollection is an array of common.Address serializable to and from a database.
Cron holds the string that will represent the spec of the cron-job.
No description provided by the author
No description provided by the author
Feeds holds the json of the feeds parameter in the job spec.
FunctionSelector is the first four bytes of the call data for a function call and specifies the function to be called.
Interval represents a time.Duration stored as a Postgres interval type.
ONLY USE FOR JPV1 JOBS JobID is a UUID that has a custom display format.
KV represents a key/value pair to be added to a JSON object.
RawRandomnessRequestLog is used to parse a RandomnessRequest log into types go-ethereum knows about.
RunStatus is a string that represents the run status.
RunStatusCollection is an array of RunStatus.
Explicit type indicating a 32-byte sha256 hash.
Signature is a byte array fixed to the size of a signature.
TaskType defines what Adapter a TaskSpec will use.
Topics handle the serialization of ethereum log topics to and from the data store.
This data can contain anything and is submitted by user on-chain, so we must be extra careful how we interact with it.
WebURL contains the URL of the endpoint.