> ## Documentation Index
> Fetch the complete documentation index at: https://docs.toku.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Validate And Calculate Employee Payroll Data

> Validates legacy payroll employee rows, computes the fiat/stablecoin net pay split and stores it on DRAFT payrolls.

Not available to API keys.

## OpenAPI

````yaml api-reference/openapi.json POST /stablecoin-payroll/validate-and-calculate-employee-payroll-data
openapi: 3.1.0
info:
  title: Toku API
  version: 1.0.0
servers:
  - url: https://api.toku.com
security:
  - bearerAuth: []
paths:
  /stablecoin-payroll/validate-and-calculate-employee-payroll-data:
    post:
      operationId: validateAndCalculateEmployeePayrollData
      summary: Validate And Calculate Employee Payroll Data
      description: >-
        Validates legacy payroll employee rows, computes the fiat/stablecoin net
        pay split and stores it on DRAFT payrolls.


        Not available to API keys.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: >-
                #/components/schemas/ValidateAndCalculateEmployeePayrollDataRequest
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/ValidateAndCalculateEmployeePayrollDataResponse
        '400':
          description: Bad request
        '401':
          description: Unauthorized
        '403':
          description: Forbidden
        '404':
          description: Not found
        '409':
          description: Conflict
        '429':
          description: Response 429
components:
  schemas:
    ValidateAndCalculateEmployeePayrollDataRequest:
      type: object
      properties:
        payrollId:
          type: string
          minLength: 1
          maxLength: 200
        employeeData:
          type: array
          items:
            type: object
            properties:
              employeeId:
                type: string
                minLength: 1
                maxLength: 200
              employeeName:
                type: string
                maxLength: 200
              totalCompensation:
                type: number
              totalDeduction:
                type: number
              currency:
                type: string
                minLength: 1
                maxLength: 20
              stableCoinPercentage:
                type: number
                minimum: 0
                maximum: 100
              minimumWage:
                type: number
              id:
                type: string
                minLength: 1
                maxLength: 200
            required:
              - employeeId
              - employeeName
              - totalCompensation
              - totalDeduction
              - currency
              - id
          maxItems: 10000
        isCSVUploaded:
          type: boolean
      required:
        - payrollId
        - employeeData
    ValidateAndCalculateEmployeePayrollDataResponse:
      type: object
      properties:
        validatedEmployeeData:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              employeeId:
                type: string
              employeeName:
                type: string
              totalCompensation:
                type: number
              totalDeduction:
                type: number
              currency:
                type: string
              stableCoinPercentage:
                type: number
              minimumWage:
                type: number
              netPayFiat:
                type: number
              netPayStableCoin:
                type: number
              hasTGAProfile:
                type: boolean
              hasValidWallet:
                type: boolean
              hasPayrollError:
                type: boolean
              hasMinimumWageError:
                type: boolean
            required:
              - id
              - employeeId
              - employeeName
              - totalCompensation
              - totalDeduction
              - currency
              - netPayFiat
              - netPayStableCoin
              - hasTGAProfile
              - hasValidWallet
              - hasPayrollError
              - hasMinimumWageError
        error:
          type: string
      required:
        - validatedEmployeeData
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
````
