Token payroll
Update Token Payroll State
Sets a token payroll's state under a dispatch lock, refusing to reopen a COMPLETED payroll.
POSThttps://api.toku.com/stablecoin-payroll/update-token-payroll-state
Not available to API keys yet. It will need payroll:write.
curl --request POST \
--url 'https://api.toku.com/stablecoin-payroll/update-token-payroll-state' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"tokenPayrollId": "string",
"state": "DRAFT"
}'200 response
{
"tokenPayroll": {
"tokenPayrollID": "string",
"orgID": "string",
"payPeriodStart": "string",
"payPeriodEnd": "string",
"payDate": "string",
"externalPayrollID": "string",
"fiatCurrency": "string",
"payrollEntityId": "string",
"state": "string",
"type": "string",
"createdAt": "string",
"updatedAt": "string"
}
}Authorizations
AuthorizationstringheaderrequiredBearer authentication header of the form Bearer <token>, where <token> is an access token from a Toku sign-in. See Authentication in the API reference.
Body
application/json
tokenPayrollIdstringrequiredAllowed: 1 to 200 characters
statestringrequiredAvailable options: DRAFT, PENDING, OVERDUE, LOCKED, IN_PROGRESS, APPROVED, COMPLETED, CANCELLED
Response
200Successful response
tokenPayrollobjectrequiredShow child attributes
tokenPayrollIDstringrequiredorgIDstringrequiredpayPeriodStartstringrequiredpayPeriodEndstringrequiredpayDatestringrequiredexternalPayrollIDstring | nullrequiredfiatCurrencystringrequiredpayrollEntityIdstring | nullrequiredstatestringrequiredtypestringrequiredcreatedAtstringrequiredupdatedAtstringrequired400Bad request
401Unauthorized
403Forbidden
404Not found
409Conflict
429Response 429
Was this page helpful? Suggest edits