List pay runs
const url = 'https://api.usepayloom.com/api/v1/pay_runs?limit=25&status=draft';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://api.usepayloom.com/api/v1/pay_runs?limit=25&status=draft' \ --header 'Authorization: Bearer <token>'Requires the payruns.read scope.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”The next_cursor from the previous page.
ISO 8601 timestamp; returns only records updated at or after it.
Responses
Section titled “Responses”OK
object
object
Lifecycle is draft → (calculating →) calculated → approved → paid;
volume runs price in the background and read calculating
meanwhile. A paid run is
immutable; later corrections arrive as retro adjustments on the next
open run rather than by rewriting history.
The date whose statutory rules priced this run.
object
object
Integer amount in the currency’s minor unit. 50000 GHS = 500.00.
object
Integer amount in the currency’s minor unit. 50000 GHS = 500.00.
object
Integer amount in the currency’s minor unit. 50000 GHS = 500.00.
Sits ON TOP of gross — do not add it into gross.
object
Integer amount in the currency’s minor unit. 50000 GHS = 500.00.
Example
{ "object": "list", "data": [ { "object": "pay_run", "status": "draft", "totals": { "gross": { "currency": "GHS" }, "net": { "currency": "GHS" }, "employee_deductions": { "currency": "GHS" }, "employer_cost": { "currency": "GHS" } } } ]}Missing, invalid, revoked or expired key.
object
object
object
Example
{ "error": { "code": "missing_token" }}The key is valid but lacks the required scope.
object
object
object
Example
{ "error": { "code": "missing_token" }}