import Finch from '@tryfinch/finch-api';
const client = new Finch({
accessToken: 'My Access Token',
});
const automatedAsyncJob = await client.jobs.automated.retrieve('job_id');
console.log(automatedAsyncJob.job_id);from finch import Finch
client = Finch(
access_token="My Access Token",
)
automated_async_job = client.jobs.automated.retrieve(
"job_id",
)
print(automated_async_job.job_id)package main
import (
"context"
"fmt"
"github.com/Finch-API/finch-api-go/v2"
"github.com/Finch-API/finch-api-go/v2/option"
)
func main() {
client := finchgo.NewClient(
option.WithAccessToken("My Access Token"),
)
automatedAsyncJob, err := client.Jobs.Automated.Get(context.TODO(), "job_id")
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", automatedAsyncJob.JobID)
}
package com.tryfinch.api.example;
import com.tryfinch.api.client.FinchClient;
import com.tryfinch.api.client.okhttp.FinchOkHttpClient;
import com.tryfinch.api.models.AutomatedAsyncJob;
import com.tryfinch.api.models.JobAutomatedRetrieveParams;
public final class Main {
private Main() {}
public static void main(String[] args) {
FinchClient client = FinchOkHttpClient.builder()
.fromEnv()
.accessToken("My Access Token")
.build();
AutomatedAsyncJob automatedAsyncJob = client.jobs().automated().retrieve("job_id");
}
}package com.tryfinch.api.example
import com.tryfinch.api.client.FinchClient
import com.tryfinch.api.client.okhttp.FinchOkHttpClient
import com.tryfinch.api.models.AutomatedAsyncJob
import com.tryfinch.api.models.JobAutomatedRetrieveParams
fun main() {
val client: FinchClient = FinchOkHttpClient.builder()
.fromEnv()
.accessToken("My Access Token")
.build()
val automatedAsyncJob: AutomatedAsyncJob = client.jobs().automated().retrieve("job_id")
}require "finch_api"
finch = FinchAPI::Client.new(access_token: "My Access Token")
automated_async_job = finch.jobs.automated.retrieve("job_id")
puts(automated_async_job)curl --request GET \
--url https://api.tryfinch.com/jobs/automated/{job_id} \
--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/jobs/automated/{job_id}",
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;
}{
"job_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"job_url": "<string>",
"type": "data_sync_all",
"status": "pending",
"created_at": "2023-11-07T05:31:56Z",
"scheduled_at": "2023-11-07T05:31:56Z",
"started_at": "2023-11-07T05:31:56Z",
"completed_at": "2023-11-07T05:31:56Z",
"params": {
"individual_id": "<string>"
}
}Retrieve an Automated Job
Get an automated job by job_id.
import Finch from '@tryfinch/finch-api';
const client = new Finch({
accessToken: 'My Access Token',
});
const automatedAsyncJob = await client.jobs.automated.retrieve('job_id');
console.log(automatedAsyncJob.job_id);from finch import Finch
client = Finch(
access_token="My Access Token",
)
automated_async_job = client.jobs.automated.retrieve(
"job_id",
)
print(automated_async_job.job_id)package main
import (
"context"
"fmt"
"github.com/Finch-API/finch-api-go/v2"
"github.com/Finch-API/finch-api-go/v2/option"
)
func main() {
client := finchgo.NewClient(
option.WithAccessToken("My Access Token"),
)
automatedAsyncJob, err := client.Jobs.Automated.Get(context.TODO(), "job_id")
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", automatedAsyncJob.JobID)
}
package com.tryfinch.api.example;
import com.tryfinch.api.client.FinchClient;
import com.tryfinch.api.client.okhttp.FinchOkHttpClient;
import com.tryfinch.api.models.AutomatedAsyncJob;
import com.tryfinch.api.models.JobAutomatedRetrieveParams;
public final class Main {
private Main() {}
public static void main(String[] args) {
FinchClient client = FinchOkHttpClient.builder()
.fromEnv()
.accessToken("My Access Token")
.build();
AutomatedAsyncJob automatedAsyncJob = client.jobs().automated().retrieve("job_id");
}
}package com.tryfinch.api.example
import com.tryfinch.api.client.FinchClient
import com.tryfinch.api.client.okhttp.FinchOkHttpClient
import com.tryfinch.api.models.AutomatedAsyncJob
import com.tryfinch.api.models.JobAutomatedRetrieveParams
fun main() {
val client: FinchClient = FinchOkHttpClient.builder()
.fromEnv()
.accessToken("My Access Token")
.build()
val automatedAsyncJob: AutomatedAsyncJob = client.jobs().automated().retrieve("job_id")
}require "finch_api"
finch = FinchAPI::Client.new(access_token: "My Access Token")
automated_async_job = finch.jobs.automated.retrieve("job_id")
puts(automated_async_job)curl --request GET \
--url https://api.tryfinch.com/jobs/automated/{job_id} \
--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/jobs/automated/{job_id}",
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;
}{
"job_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"job_url": "<string>",
"type": "data_sync_all",
"status": "pending",
"created_at": "2023-11-07T05:31:56Z",
"scheduled_at": "2023-11-07T05:31:56Z",
"started_at": "2023-11-07T05:31:56Z",
"completed_at": "2023-11-07T05:31:56Z",
"params": {
"individual_id": "<string>"
}
}Authorizations
Please use your Access Token
Headers
Header used to specify the version for a given API request. Current version is 2020-09-17.
Path Parameters
Response
OK
The id of the job that has been created.
The url that can be used to retrieve the job status
The type of automated job
data_sync_all, w4_form_employee_sync pending, in_progress, complete, error, reauth_error, permissions_error The datetime when the job was created. for scheduled jobs, this will be the initial connection time. For ad-hoc jobs, this will be the time the creation request was received.
The datetime a job is scheduled to be run. For scheduled jobs, this datetime can be in the future if the job has not yet been enqueued. For ad-hoc jobs, this field will be null.
The datetime a job entered into the job queue.
The datetime the job completed.
The input parameters for the job.
Show child attributes
Show child attributes
Was this page helpful?