JavaScript
import Finch from '@tryfinch/finch-api';
const client = new Finch({
accessToken: 'My Access Token',
});
// Automatically fetches more pages as needed.
for await (const ruleListResponse of client.hris.payStatementItem.rules.list()) {
console.log(ruleListResponse.id);
}from finch import Finch
client = Finch(
access_token="My Access Token",
)
page = client.hris.pay_statement_item.rules.list()
page = page.responses[0]
print(page.id)package main
import (
"context"
"fmt"
"github.com/Finch-API/finch-api-go"
"github.com/Finch-API/finch-api-go/option"
)
func main() {
client := finchgo.NewClient(
option.WithAccessToken("My Access Token"),
)
page, err := client.HRIS.PayStatementItem.Rules.List(context.TODO(), finchgo.HRISPayStatementItemRuleListParams{})
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", page)
}package com.tryfinch.api.example;
import com.tryfinch.api.client.FinchClient;
import com.tryfinch.api.client.okhttp.FinchOkHttpClient;
import com.tryfinch.api.models.HrisPayStatementItemRuleListPage;
import com.tryfinch.api.models.HrisPayStatementItemRuleListParams;
public final class Main {
private Main() {}
public static void main(String[] args) {
FinchClient client = FinchOkHttpClient.builder()
.fromEnv()
.accessToken("My Access Token")
.build();
HrisPayStatementItemRuleListPage page = client.hris().payStatementItem().rules().list();
}
}package com.tryfinch.api.example
import com.tryfinch.api.client.FinchClient
import com.tryfinch.api.client.okhttp.FinchOkHttpClient
import com.tryfinch.api.models.HrisPayStatementItemRuleListPage
import com.tryfinch.api.models.HrisPayStatementItemRuleListParams
fun main() {
val client: FinchClient = FinchOkHttpClient.builder()
.fromEnv()
.accessToken("My Access Token")
.build()
val page: HrisPayStatementItemRuleListPage = client.hris().payStatementItem().rules().list()
}require "finch_api"
finch = FinchAPI::Client.new(access_token: "My Access Token")
page = finch.hris.pay_statement_item.rules.list
puts(page)curl --request GET \
--url https://api.tryfinch.com/employer/pay-statement-item/rule \
--header 'Authorization: Bearer <token>' \
--header 'Finch-API-Version: <finch-api-version>'<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.tryfinch.com/employer/pay-statement-item/rule",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Finch-API-Version: <finch-api-version>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}[
{
"id": "5d0b10a1-a09a-430f-81f1-20be735dc5e9",
"priority": 1,
"effective_start_date": "2025-01-01",
"effective_end_date": "2025-12-31",
"conditions": [
{
"field": "name",
"operator": "equals",
"value": "Salary"
}
],
"attributes": {
"metadata": {
"myLabel": "My Value"
}
},
"entity_type": "pay_statement_item",
"created_at": "2025-01-01T10:00:00Z",
"updated_at": "2025-01-01T10:00:00Z"
},
{
"id": "e8b90071-0c11-471c-86e8-e303ef2f6782",
"priority": 1,
"conditions": [
{
"field": "name",
"operator": "equals",
"value": "Medical Insurance"
}
],
"attributes": {
"metadata": {
"myLabel2": "My Value 2"
}
},
"entity_type": "pay_statement_item",
"created_at": "2025-01-10T10:00:00Z",
"updated_at": "2025-02-05T08:45:00Z"
}
]Rules
Get Rules
List all rules of a connection account.
GET
/
employer
/
pay-statement-item
/
rule
JavaScript
import Finch from '@tryfinch/finch-api';
const client = new Finch({
accessToken: 'My Access Token',
});
// Automatically fetches more pages as needed.
for await (const ruleListResponse of client.hris.payStatementItem.rules.list()) {
console.log(ruleListResponse.id);
}from finch import Finch
client = Finch(
access_token="My Access Token",
)
page = client.hris.pay_statement_item.rules.list()
page = page.responses[0]
print(page.id)package main
import (
"context"
"fmt"
"github.com/Finch-API/finch-api-go"
"github.com/Finch-API/finch-api-go/option"
)
func main() {
client := finchgo.NewClient(
option.WithAccessToken("My Access Token"),
)
page, err := client.HRIS.PayStatementItem.Rules.List(context.TODO(), finchgo.HRISPayStatementItemRuleListParams{})
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", page)
}package com.tryfinch.api.example;
import com.tryfinch.api.client.FinchClient;
import com.tryfinch.api.client.okhttp.FinchOkHttpClient;
import com.tryfinch.api.models.HrisPayStatementItemRuleListPage;
import com.tryfinch.api.models.HrisPayStatementItemRuleListParams;
public final class Main {
private Main() {}
public static void main(String[] args) {
FinchClient client = FinchOkHttpClient.builder()
.fromEnv()
.accessToken("My Access Token")
.build();
HrisPayStatementItemRuleListPage page = client.hris().payStatementItem().rules().list();
}
}package com.tryfinch.api.example
import com.tryfinch.api.client.FinchClient
import com.tryfinch.api.client.okhttp.FinchOkHttpClient
import com.tryfinch.api.models.HrisPayStatementItemRuleListPage
import com.tryfinch.api.models.HrisPayStatementItemRuleListParams
fun main() {
val client: FinchClient = FinchOkHttpClient.builder()
.fromEnv()
.accessToken("My Access Token")
.build()
val page: HrisPayStatementItemRuleListPage = client.hris().payStatementItem().rules().list()
}require "finch_api"
finch = FinchAPI::Client.new(access_token: "My Access Token")
page = finch.hris.pay_statement_item.rules.list
puts(page)curl --request GET \
--url https://api.tryfinch.com/employer/pay-statement-item/rule \
--header 'Authorization: Bearer <token>' \
--header 'Finch-API-Version: <finch-api-version>'<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.tryfinch.com/employer/pay-statement-item/rule",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Finch-API-Version: <finch-api-version>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}[
{
"id": "5d0b10a1-a09a-430f-81f1-20be735dc5e9",
"priority": 1,
"effective_start_date": "2025-01-01",
"effective_end_date": "2025-12-31",
"conditions": [
{
"field": "name",
"operator": "equals",
"value": "Salary"
}
],
"attributes": {
"metadata": {
"myLabel": "My Value"
}
},
"entity_type": "pay_statement_item",
"created_at": "2025-01-01T10:00:00Z",
"updated_at": "2025-01-01T10:00:00Z"
},
{
"id": "e8b90071-0c11-471c-86e8-e303ef2f6782",
"priority": 1,
"conditions": [
{
"field": "name",
"operator": "equals",
"value": "Medical Insurance"
}
],
"attributes": {
"metadata": {
"myLabel2": "My Value 2"
}
},
"entity_type": "pay_statement_item",
"created_at": "2025-01-10T10:00:00Z",
"updated_at": "2025-02-05T08:45:00Z"
}
]Authorizations
Please use your Access Token
Headers
Header used to specify the version for a given API request. Current version is 2020-09-17.
Pattern:
([12]\d{3}-(0[1-9]|1[0-2])-(0[1-9]|[12]\d|3[01]))Query Parameters
The entity IDs to retrieve rules for.
Required array length:
1 elementExample:
["550e8400-e29b-41d4-a716-446655440000"]
Response
200 - application/json
OK
Show child attributes
Show child attributes
Was this page helpful?
⌘I