Pay Stub
Extract earnings, deductions, and net pay information from a payroll stub or pay statement.
curl -X POST $XBERG_ENTERPRISE_URL/v1/extract \ -H "Authorization: Bearer $XBERG_API_KEY" \ -F file=@your-pay_stub.pdf \ -F 'preset=pay_stub'

Structured fields extracted by this preset
employerobjectrequiredInformation about the employer.
namestringrequiredLegal name of the employer.
addressstringMailing address of the employer.
instringEmployer Identification Number (IN) as nine digits without dashes.
contact_phonestringEmployer contact phone number.
employeeobjectrequiredInformation about the employee.
namestringrequiredFull legal name of the employee.
employee_idstringEmployer-assigned employee identification number.
ssn_last_fourstringLast four digits of the employee's Social Security Number.
addressstringMailing address of the employee.
tax_filing_statusstringTax filing status for federal withholding purposes.
pay_period_startstringrequiredStart date of the pay period in ISO-8601 format (YYYY-MM-DD).
pay_period_endstringrequiredEnd date of the pay period in ISO-8601 format (YYYY-MM-DD).
pay_datestringrequiredDate the employee is paid in ISO-8601 format (YYYY-MM-DD).
pay_frequencystringFrequency of pay (weekly, biweekly, semimonthly, monthly, annual, or other).
earningsarrayArray of earnings components.
pre_tax_deductionsarrayArray of pre-tax deduction components.
taxesarrayArray of tax withholdings.
post_tax_deductionsarrayArray of post-tax deduction components.
gross_pay_currentnumberrequiredGross pay (total earnings before deductions) for current pay period as a decimal number without currency symbol.
gross_pay_ytdnumberYear-to-date gross pay as a decimal number without currency symbol.
net_pay_currentnumberrequiredNet pay (take-home pay) for current pay period as a decimal number without currency symbol.
net_pay_ytdnumberYear-to-date net pay as a decimal number without currency symbol.
currencystringrequiredISO 4217 currency code (e.g., 'USD', 'EUR', 'GBP').
Configuration
Call Mode
text_plus_visionCitations
EnabledVersion
v1Tags
+System Prompt
You are extracting payroll data from a pay stub or pay statement. Extract all fields exactly as shown. Record the employer name, employee name, pay period dates (start and end), and pay date in ISO-8601 format (YYYY-MM-DD). For the employee, extract the full legal name, employee ID, and last four digits of the SSN. Preserve the tax filing status if shown. Record all earnings components (regular, overtime, bonus, commission, holiday, vacation, sick, etc.) with hours/units and rates as decimal numbers. Include earnings for both the current pay period and year-to-date. Record all taxes withheld (federal income, state income, local income, social security, medicare, SUI, SDI) with jurisdiction codes for state/local taxes. Include pre-tax deductions (401k, health insurance, FSA, etc.) and post-tax deductions (charitable, union dues, etc.) with current and YTD amounts. All monetary amounts must be decimal numbers without currency symbols. Dates must be ISO-formatted. Currency code must be the three-letter ISO 4217 code. Ensure all required fields are present: employer.name, employee.name, pay_period_start, pay_period_end, pay_date, gross_pay_current, net_pay_current, and currency. Provide citations for all extracted values.