Token payroll
Create Payroll From CSV
Creates or updates a legacy Payroll row keyed by external ID, storing imported CSV employee data.
Not available to API keys.
curl --request POST \
--url 'https://api.toku.com/stablecoin-payroll/create-payroll-from-csv' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"externalPayrollID": "string",
"payPeriodStart": "string",
"payPeriodEnd": "string",
"payrollCutoffDate": "string",
"approvalDeadline": "string",
"payDate": "string",
"payrollEntityId": "string",
"importedData": [
{
"id": "string",
"currency": "string",
"employeeId": "string",
"netPayFiat": 0,
"minimumWage": 0,
"employeeName": "string",
"hasTGAProfile": true,
"hasValidWallet": true,
"totalDeduction": 0,
"hasPayrollError": true,
"netPayStableCoin": 0,
"totalCompensation": 0,
"hasMinimumWageError": true,
"bonusPay": 0,
"email": "user@example.com",
"roleInOrgID": "string"
}
],
"payrollSyncedSource": "string"
}'{
"payroll": {
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"orgID": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"name": "string",
"entity": "string",
"payPeriodStart": "string",
"payPeriodEnd": "string",
"payDate": "string",
"currentStep": "CONFIGURATION",
"state": "DRAFT",
"type": "ON_CYCLE",
"externalPayrollID": "string",
"fiatCurrency": "string",
"stableCoinCurrency": "string",
"tokenTypeID": "string",
"exchangeRate": "string",
"isStablecoinPayrollComplete": true,
"isFiatPayrollComplete": true,
"isSyncedFromHRIS": true,
"selectedEmployeeIds": [
"string"
],
"isCsvUploaded": true,
"createdAt": "string",
"updatedAt": "string",
"createdByID": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"lastModifiedByID": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
}
}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
externalPayrollIDstringrequiredAllowed: 1 to 200 characters
payPeriodStartstringrequiredAllowed: 1 to 50 characters
payPeriodEndstringrequiredAllowed: 1 to 50 characters
payrollCutoffDatestringAllowed: at most 50 characters
approvalDeadlinestringAllowed: at most 50 characters
payDatestringrequiredAllowed: 1 to 50 characters
payrollEntityIdstringAllowed: at most 200 characters
importedDataobject[]requiredAllowed: at most 10000 items
Show child attributes
idstringrequiredAllowed: 1 to 200 characters
currencystringrequiredAllowed: 1 to 20 characters
employeeIdstringrequiredAllowed: 1 to 200 characters
netPayFiatnumberrequiredminimumWagenumberrequiredemployeeNamestringrequiredAllowed: at most 200 characters
hasTGAProfilebooleanrequiredhasValidWalletbooleanrequiredtotalDeductionnumberrequiredhasPayrollErrorbooleanrequirednetPayStableCoinnumberrequiredtotalCompensationnumberrequiredhasMinimumWageErrorbooleanrequiredbonusPaynumberrequiredemailstring<email>roleInOrgIDstringAllowed: at most 200 characters
payrollSyncedSourcestringrequiredAllowed: 1 to 100 characters
Response
200Successful response
payrollobjectrequiredShow child attributes
idstring<uuid>requiredorgIDstring<uuid>requirednamestringrequiredentitystringrequiredpayPeriodStartstringrequiredpayPeriodEndstringrequiredpayDatestringrequiredcurrentStepstringrequiredAvailable options: CONFIGURATION, COMPENSATION_DETAILS, TAX_CALCULATION, APPROVAL_TRANSFER, SETTLED
statestringrequiredAvailable options: DRAFT, PENDING, OVERDUE, LOCKED, IN_PROGRESS, APPROVED, COMPLETED, CANCELLED
typestringrequiredAvailable options: ON_CYCLE, OFF_CYCLE, INVOICE_PAYMENT
externalPayrollIDstring | nullrequiredfiatCurrencystringrequiredstableCoinCurrencystring | nullrequiredtokenTypeIDstring | nullrequiredexchangeRatestring | nullrequiredAllowed: matches ^-?\d+(?:\.\d+)?$
isStablecoinPayrollCompletebooleanrequiredisFiatPayrollCompletebooleanrequiredisSyncedFromHRISbooleanrequiredselectedEmployeeIdsstring[]requiredimportedDataanyrequiredprocessedDataanyrequiredsettlementDataanyrequiredisCsvUploadedboolean | nullrequiredcreatedAtstringrequiredupdatedAtstringrequiredcreatedByIDstring<uuid>requiredlastModifiedByIDstring<uuid>required