Quickstart Guide
Get started with Settler. Follow these steps to create a deterministic reconciliation run.
Note: Settler surfaces variances and evidence. Your team reviews and resolves outcomes.
1
Create a Workspace
Create a workspace to organize reconciliation runs
# Using the SDK
import { Settler } from '@settler/sdk';
const client = new Settler({
apiKey: process.env.SETTLER_API_KEY,
});
# Or use the App
# Visit /app to create a workspace via UI2
Create a Reconciliation Run
Define deterministic rules for matching
const job = await client.jobs.create({
name: "My First Reconciliation",
source: {
adapter: "stripe",
config: {
apiKey: process.env.STRIPE_SECRET_KEY,
},
},
target: {
adapter: "shopify",
config: {
apiKey: process.env.SHOPIFY_API_KEY,
},
},
rules: {
matching: [
{ field: "order_id", type: "exact" },
{ field: "amount", type: "exact", tolerance: 0.01 },
],
},
});
// eslint-disable-next-line no-console
console.log("Job created:", job.id);3
Upload Receipt/Data
Upload transactions or normalized data
# Parse a receipt
const receipt = await client.receipts.parse({
file: "https://example.com/receipt.jpg",
});
// eslint-disable-next-line no-console
console.log("Receipt parsed:", receipt.total, receipt.merchant);
# Or upload CSV/JSON
const upload = await client.data.upload({
file: fileBuffer,
format: "csv",
});4
View Results
Review variances and evidence
# Get job status
const status = await client.jobs.get(job.id);
// eslint-disable-next-line no-console
console.log("Status:", status.status);
# Get report
const report = await client.reports.get(job.id);
// eslint-disable-next-line no-console
console.log("Matched:", report.summary.matched);
// eslint-disable-next-line no-console
console.log("Unmatched:", report.summary.unmatched);