March 30, 2021
September 29, 2021

Announcing earning codes

by 
Ian Zapolsky
March 30, 2021
September 29, 2021

Announcing earning codes

by 
Ian Zapolsky

Employers running payroll often want the flexibility to customize labels for certain earnings, in such a way that will flow through to their employees’ paystubs. For example, imagine a restaurant that wants to pay employees for waiting tables and washing dishes. The restaurant might want those paystubs to reflect those details. In fact, ever since Check’s first API users began building on top of our platform, the desire to add custom earning codes has resurfaced again and again. So we're excited to announce the Earning Codes API!

Before Earning Codes, our initial support for custom labels on earnings took a “stateless” approach, meaning users could pass us a description and code field with each earning, which we would use for aggregation on the paystub.

However, there were a couple downsides of this approach. First, it pushed the complexity of maintaining the list of eligible descriptions and codes for a company onto our partners. Second, it prevented Check from actually knowing what earning codes were eligible for a company, which impacted our ability to accurately ingest historical payroll data with a multitude of earning codes, as well as provide high-quality accounting integrations.

With the Earning Code API, partners can create a list of earning codes for each company, which can then be used during the creation of earnings for that company’s employees. The Earning Codes API is now live and ready to be used by all our partners. We plan to deprecate the “code” field on the payroll item earning object in future API versions.

For a glimpse at Earning Codes in action, take our restaurant example. You can now create two earning codes in Check’s API:


curl -XPOST https://api.checkhq.com/earning_codes -d '{
    "company": "com_dsE2Y4wCMg77HGlJB0Mk",
    "type": "hourly",
    "name": "Dishwasher"
}'

curl -XPOST https://api.checkhq.com/earning_codes -d '{
    "company": "com_dsE2Y4wCMg77HGlJB0Mk",
    "type": "hourly",
    "name": "Waiter"
}'

These two requests will return Earning Code objects with IDs. These can then be listed like so:


{
    "next": null,
    "previous": null,
    "results": [
        {
            "id": "erc_ijKMqS3u8MAgQdoGIip6",
            "company": "com_dsE2Y4wCMg77HGlJB0Mk",
            "type": "hourly",
            "name": "Dishwasher"
        },
        {
            "id": "erc_a65eL6JLz5dSBjuddDwL",
            "company": "com_dsE2Y4wCMg77HGlJB0Mk",
            "type": "hourly",
            "name": "Waiter"
        }
    ]
}

These earning codes can now be used within the earnings for employees on a payroll item, instead of a type, code, and description. Whereas before one might have had to send:


{
    "type": "hourly",
    "description": "Dishwasher",
    "code": "dishwasher",
    "amount": "100.00",
    "hours": 10.0
},
{
    "type": "hourly",
    "description": "Waiter",
    "code": "waiter",
    "amount": "100.00",
    "hours": 10.0
},

Now, with earning codes, you can send:


{
    "earning_code": "erc_ijKMqS3u8MAgQdoGIip6",
    "amount": "100.00",
    "hours": 10.0
},
{
    "earning_code": "erc_a65eL6JLz5dSBjuddDwL",
    "amount": "100.00",
    "hours": 10.0
}

More from the check blog

November 18, 2021
November 18, 2021

Preparing for Year-end 2021

Payroll providers spend countless hours behind the scenes preparing for year-end, which unfortunately doesn’t mean wrapping presents. To help, we put together our Year-end Playbook for Partners, which breaks down the year end process and shares best practices and tips.
November 1, 2021
September 29, 2021

October Changelog

October's additions and updates to Check. Changes include Earnings Rate API, defining benefits at the company level, revamping Console's audit flow, and adding bulk employee creation to Console.
October 11, 2021
October 11, 2021

Observing World Mental Health Day at Check

Here at Check, we make paying people simple. With 54% of U.S. consumers living from paycheck to paycheck, getting paid is a source of worry for many people. Beyond the financial aspect, the impact jobs have on people’s lives goes much deeper. In observance of World Mental Health Day, we took time to recognize how intertwined our work life, personal life, and physical and mental well-being through a company-wide event.