import Finch from '@tryfinch/finch-api';
const client = new Finch({
accessToken: 'My Access Token',
});
const company = await client.hris.company.retrieve();
console.log(company.id);from finch import Finch
client = Finch(
access_token="My Access Token",
)
company = client.hris.company.retrieve()
print(company.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"),
)
company, err := client.HRIS.Company.Get(context.TODO(), finchgo.HRISCompanyGetParams{})
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", company.ID)
}
package com.tryfinch.api.example;
import com.tryfinch.api.client.FinchClient;
import com.tryfinch.api.client.okhttp.FinchOkHttpClient;
import com.tryfinch.api.models.Company;
import com.tryfinch.api.models.HrisCompanyRetrieveParams;
public final class Main {
private Main() {}
public static void main(String[] args) {
FinchClient client = FinchOkHttpClient.builder()
.fromEnv()
.accessToken("My Access Token")
.build();
Company company = client.hris().company().retrieve();
}
}package com.tryfinch.api.example
import com.tryfinch.api.client.FinchClient
import com.tryfinch.api.client.okhttp.FinchOkHttpClient
import com.tryfinch.api.models.Company
import com.tryfinch.api.models.HrisCompanyRetrieveParams
fun main() {
val client: FinchClient = FinchOkHttpClient.builder()
.fromEnv()
.accessToken("My Access Token")
.build()
val company: Company = client.hris().company().retrieve()
}require "finch_api"
finch = FinchAPI::Client.new(access_token: "My Access Token")
company = finch.hris.company.retrieve
puts(company)curl --request GET \
--url https://api.tryfinch.com/employer/company \
--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/company",
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": "514aa2b7-898f-4ce7-bc05-c2fe993713e8",
"legal_name": "Acme, Inc.",
"entity": {
"type": "corporation",
"subtype": "s_corporation"
},
"ein": "12-3456789",
"primary_email": "founders@acme.com",
"primary_phone_number": "+14475678901",
"departments": [
{
"name": "Engineering",
"parent": null
},
{
"name": "Platform",
"parent": {
"name": "Engineering"
}
}
],
"locations": [
{
"line1": "628 Bear Ave",
"line2": "Apt A",
"city": "Schenectady",
"state": "NY",
"postal_code": "94301",
"country": "US"
}
],
"accounts": [
{
"routing_number": "123456789",
"account_name": "CHECKING ACCOUNT",
"institution_name": "BANK OF AMERICA, N.A.",
"account_type": "checking",
"account_number": "98765432"
}
]
}Company
Read basic company data
import Finch from '@tryfinch/finch-api';
const client = new Finch({
accessToken: 'My Access Token',
});
const company = await client.hris.company.retrieve();
console.log(company.id);from finch import Finch
client = Finch(
access_token="My Access Token",
)
company = client.hris.company.retrieve()
print(company.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"),
)
company, err := client.HRIS.Company.Get(context.TODO(), finchgo.HRISCompanyGetParams{})
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", company.ID)
}
package com.tryfinch.api.example;
import com.tryfinch.api.client.FinchClient;
import com.tryfinch.api.client.okhttp.FinchOkHttpClient;
import com.tryfinch.api.models.Company;
import com.tryfinch.api.models.HrisCompanyRetrieveParams;
public final class Main {
private Main() {}
public static void main(String[] args) {
FinchClient client = FinchOkHttpClient.builder()
.fromEnv()
.accessToken("My Access Token")
.build();
Company company = client.hris().company().retrieve();
}
}package com.tryfinch.api.example
import com.tryfinch.api.client.FinchClient
import com.tryfinch.api.client.okhttp.FinchOkHttpClient
import com.tryfinch.api.models.Company
import com.tryfinch.api.models.HrisCompanyRetrieveParams
fun main() {
val client: FinchClient = FinchOkHttpClient.builder()
.fromEnv()
.accessToken("My Access Token")
.build()
val company: Company = client.hris().company().retrieve()
}require "finch_api"
finch = FinchAPI::Client.new(access_token: "My Access Token")
company = finch.hris.company.retrieve
puts(company)curl --request GET \
--url https://api.tryfinch.com/employer/company \
--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/company",
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": "514aa2b7-898f-4ce7-bc05-c2fe993713e8",
"legal_name": "Acme, Inc.",
"entity": {
"type": "corporation",
"subtype": "s_corporation"
},
"ein": "12-3456789",
"primary_email": "founders@acme.com",
"primary_phone_number": "+14475678901",
"departments": [
{
"name": "Engineering",
"parent": null
},
{
"name": "Platform",
"parent": {
"name": "Engineering"
}
}
],
"locations": [
{
"line1": "628 Bear Ave",
"line2": "Apt A",
"city": "Schenectady",
"state": "NY",
"postal_code": "94301",
"country": "US"
}
],
"accounts": [
{
"routing_number": "123456789",
"account_name": "CHECKING ACCOUNT",
"institution_name": "BANK OF AMERICA, N.A.",
"account_type": "checking",
"account_number": "98765432"
}
]
}Authorizations
Please use your Access Token
Headers
Header used to specify the version for a given API request. Current version is 2020-09-17.
([12]\d{3}-(0[1-9]|1[0-2])-(0[1-9]|[12]\d|3[01]))Query Parameters
The entity IDs to specify which entities' data to access. Provide exactly one entity ID per request; a maximum of one is accepted.
1 element["550e8400-e29b-41d4-a716-446655440000"]
Response
Basic company data
A stable Finch id (UUID v4) for the company.
The legal name of the company.
The entity type object.
Show child attributes
Show child attributes
The email of the main administrator on the account.
The phone number of the main administrator on the account. Format: E.164, with extension where applicable, e.g. +NNNNNNNNNNN xExtension
The array of company departments.
Show child attributes
Show child attributes
The employer identification number.
Show child attributes
Show child attributes
An array of bank account objects associated with the payroll/HRIS system.
Show child attributes
Show child attributes
Was this page helpful?