PayFit Trigger

PayFit Trigger

Certified

Poll PayFit absences

Polls GET /companies/{companyId}/absences and starts an execution when absences are created or change status. The first poll records the current set unless fireOnInitial is true. Requires the time: read scope.

yaml
type: io.kestra.plugin.payfit.absences.Trigger

Run a flow when an absence is approved

yaml
id: payfit_new_absence
namespace: company.team

tasks:
  - id: log
    type: io.kestra.plugin.core.log.Log
    message: "Absences {{ trigger.absences | length }}"

triggers:
  - id: absences
    type: io.kestra.plugin.payfit.absences.Trigger
    apiKey: "{{ secret('PAYFIT_API_KEY') }}"
    interval: PT10M
    status: approved
    on: CREATE_OR_UPDATE
Properties

API key

PayFit API key or OAuth access token, sent as a bearer token. Store this value in a Kestra secret.

Defaultfalse

Specifies whether a trigger is allowed to start a new execution even if a previous run is still in progress.

Defaulthttps://partner-api.payfit.com

Partner API base URL

Base URL of the PayFit Partner API. Defaults to https://partner-api.payfit.com.

Include absences that end on or after this date (YYYY-MM-DD)

Company ID

PayFit company identifier. When omitted, the trigger resolves it through token introspection.

Restrict polling to one contract

Include absences that start on or before this date (YYYY-MM-DD)

Defaultfalse

Fire on the initial snapshot

When false (the default), the first poll records the current PayFit resources and does not start an execution. Later polls fire only for resources that match on.

DefaultPT5M
Formatduration

Polling interval

Interval between PayFit polls. Minimum PT30S. Defaults to PT5M.

Default100

Maximum pages to read on each poll. Defaults to 100

Defaulthttps://oauth.payfit.com

OAuth base URL

Base URL used for token introspection. Defaults to https://oauth.payfit.com.

DefaultCREATE
Possible Values
CREATEUPDATECREATE_OR_UPDATE

Trigger event type

When to fire. CREATE starts new executions for resources that were not in the previous snapshot. Defaults to CREATE.

HTTP client options

Optional HTTP client configuration applied to PayFit requests.

Definitions
allowFailedbooleanstring
Defaultfalse

If true, allow a failed response code (response code >= 400)

allowedResponseCodesarray
SubTypeinteger

List of response code allowed for this request

auth

The authentication to use.

type*object
passwordstring

The password for HTTP basic authentication.

usernamestring

The username for HTTP basic authentication.

type*object
tokenstring

The token for bearer token authentication.

type*object
passwordstring

The password for HTTP Digest authentication.

usernamestring

The username for HTTP Digest authentication.

defaultCharsetstring
DefaultUTF-8

The default charset for the request.

enabledTcpExtendedKeepAlivebooleanstring
Defaulttrue

Whether to enable TCP Keep-Alive extended socket options (TCP_KEEPIDLE, TCP_KEEPINTERVAL, TCP_KEEPCOUNT).

Set to false when running on Windows workers, as these extended socket options are not supported by the Windows JDK and will cause connection failures.

followRedirectsbooleanstring
Defaulttrue

Whether redirects should be followed automatically.

logsarray
SubTypestring
Possible Values
REQUEST_HEADERSREQUEST_BODYRESPONSE_HEADERSRESPONSE_BODY

The enabled log.

proxy

The proxy configuration.

addressstring

The address of the proxy server.

passwordstring

The password for proxy authentication.

portintegerstring

The port of the proxy server.

typestring
DefaultDIRECT
Possible Values
DIRECTHTTPSOCKS

The type of proxy to use.

usernamestring

The username for proxy authentication.

ssl

The SSL request options

insecureTrustAllCertificatesbooleanstring

Whether to disable checking of the remote SSL certificate.

Only applies if no trust store is configured. Note: This makes the SSL connection insecure and should only be used for testing. If you are using a self-signed certificate, set up a trust store instead.

timeout

The timeout configuration.

connectTimeoutstring

The time allowed to establish a connection to the server before failing.

readIdleTimeoutstring
DefaultPT5M

The time allowed for a read connection to remain idle before closing it.

State key

KV key used to store the resources already seen. Defaults to <namespace>_<flowId>_<triggerId>.

State TTL

Age of an individual resource version after which it is treated as new again. The snapshot key itself is kept, so an expired watermark still fires

Absence status filter. Omit it to use PayFit's default of approved absences

SubTypestring
Possible Values
CREATEDSUBMITTEDRUNNINGPAUSEDRESTARTEDKILLINGSUCCESSWARNINGFAILEDKILLEDCANCELLEDQUEUEDRETRYINGRETRIEDSKIPPEDBREAKPOINTRESUBMITTED

List of execution states after which a trigger should be stopped (a.k.a. disabled).

Defaulttrue

A condition that determines whether the trigger should run.

A Pebble expression evaluated at trigger time. The trigger fires only when the expression evaluates to a truthy value (true, a non-empty string, a non-zero number). Use this to gate trigger execution on dynamic runtime values such as execution labels, flow variables, or environment conditions.

SubTypeobject

Absences that matched on, not the full company list

Default0

Number of absences that matched on