The QuickBooks Payroll API provides resources for managing payslips. Each time an employer runs payroll in their QuickBooks Online Payroll company, a payslip is generated for each employee that was paid. For details on payslip resources, see the the GraphQL Reference.
Scope: qb.payroll.compensation.read
Request
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 | query EmployeePayslips { payrollPayslips { edges { node { id payPeriod { beginDate endDate } grossPay { currentAmount yearToDateAmount } deductions { employeeDeduction { deductionPolicy { statutoryType { value } name id } active } employeeContributionAccumulationAmount { currentAmount { currency value } toDateAmounts { amount toDateAmountType } } employerContributionAccumulationAmount { currentAmount { value currency } toDateAmounts { amount toDateAmountType } } } compensations { employeeCompensation { active rate { amount { value currency } } } calculatedCompensationAccumulationAmount { toDateAmounts { amount toDateAmountType } currentAmount { currency value } } } } } } } |
Response
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 | { "data": { "payrollPayslips": { "edges": [ { "node": { "id": "13868994", "payPeriod": { "beginDate": "2024-05-23T00:00:00.000Z", "endDate": "2024-06-05T00:00:00.000Z" }, "grossPay": { "currentAmount": "2500", "yearToDateAmount": "30000" }, "deductions": [ { "employeeDeduction": { "deductionPolicy": { "statutoryType": { "value": "TDED_CUS_ERP401KPT" }, "name": "401(k)", "id": "3178878" }, "active": true }, "employeeContributionAccumulationAmount": { "currentAmount": { "currency": "USD", "value": "31" }, "toDateAmounts": [ { "amount": "262", "toDateAmountType": "YEAR" } ] }, "employerContributionAccumulationAmount": { "currentAmount": { "value": "41", "currency": "USD" }, "toDateAmounts": [ { "amount": "382", "toDateAmountType": "YEAR" } ] } } ], "compensations": [ { "employeeCompensation": { "active": true, "rate": null }, "calculatedCompensationAccumulationAmount": { "toDateAmounts": [ { "amount": "30000", "toDateAmountType": "YEAR" } ], "currentAmount": { "currency": "USD", "value": "2500" } } } ] } } ] } } } |