Skip to main content
POST
Create a pay schedule

Authorizations

Authorization
string
header
required

Your secret API key, sent as Authorization: Bearer hmk_test_....

Headers

Hammock-Version
string

The API version to use for this request. Defaults to the version pinned to your API key.

Idempotency-Key
string

A unique value, up to 255 characters, that makes the request safe to retry for 24 hours.

Maximum string length: 255

Body

application/json
employer
string
required
frequency
enum<string>
required
Available options:
weekly,
biweekly,
semimonthly,
monthly
external_id
string
anchor_period_end_date
string<date>

Required for weekly and biweekly.

pay_date_offset_days
integer
default:0
Required range: 0 <= x <= 14
holiday_rule
enum<string>
default:previous_business_day
Available options:
previous_business_day,
next_business_day
lock_offset_business_days
integer
default:2
Required range: 0 <= x <= 10

Response

The created pay schedule.

id
string
required
Example:

"ps_7Hn3Kd9sLq2W"

object
string
required
Allowed value: "pay_schedule"
employer
string
required
Example:

"empr_1Qx8Zt2eZvKYlo2C"

frequency
enum<string>
required
Available options:
weekly,
biweekly,
semimonthly,
monthly
pay_date_offset_days
integer
required

Calendar days from the end of a pay period to its payday.

Example:

4

holiday_rule
enum<string>
required

Where a payday moves when it lands on a weekend or bank holiday.

Available options:
previous_business_day,
next_business_day
lock_offset_business_days
integer
default:2
required

Business days before payday that a pay period locks.

livemode
boolean
required
created
string<date-time>
required
external_id
string | null
Example:

"schedule_semimonthly"

anchor_period_end_date
string<date> | null

The last day of any one real pay period. Required for weekly and biweekly, which repeat from it. null for semimonthly and monthly, which follow the calendar.

next_pay_period
object | null

The first pay period that hasn't locked yet.