Skip to content

Employee hour entries

Allows you to upload worked hours for specific time. This is interesting when combined with number of visitors or receipts - are the sales people working during the busiest times?

This endpoint is intended to be used when you have aggregate level information per minute/hour/day. If your data is consists of workshifts, you should use Workshifts endpoint.

Upload list of employee hour entries

Request

POST https://api.zoined.com/employeeHours?dryRun=false&separator=%3B&encoding=utf-8

Security
bearerAuth
Query
dryRunbooleanrequired

Only validate the request without storing the data

Example:dryRun=false
separatorstringrequired

Column separator used when loading CSV data

Example:separator=;
encodingstringrequired

Character encoding used in the CSV data (default is utf-8)

Example:encoding=utf-8
Body
Any of:
organisation_idstringrequired

Organisation / Store ID

Example:"540"
department_idstring

Store department ID

Example:"54021"
salesperson_idstring

Sales person ID

Example:"5402101"
employee_typestring

Employee Type

Example:"Permie"
employeehours_idstring

Optional identifier for the entry

Example:"4244"
absence_codestring

Code for the absense if this entry describes absence.

Example:"BREAK"
datestringrequired

Date of entry (yyyy-mm-dd)

Example:"2016-01-01"
timestringrequired

Time of entry (HH:mm:ss)

Example:"15:00:00"
scheduledboolean

Whether this is scheduled or punched shift, default is false

Example:false
productiveboolean

Whether this is productive or administrative work, default is true

Example:true
hoursnumberrequired

Number of hours to record for this specific time

Example:8
staff_costnumber

Salary cost associated with this hour

Example:500
breaksnumber

Total hours of breaks

Example:0.5
breaks_costnumber

Total salary cost associated for paid breaks

Example:40
currencystring

Currency for the purchase price as ISO 4217 currency code. Required if multiple currencies are used.

Example:"EUR"
custom_field_1string

Field that can be used for custom dimensions

Example:"XYZ"
custom_field_2string

Field that can be used for custom dimensions

Example:"XYZ"
custom_field_3string

Field that can be used for custom dimensions

Example:"XYZ"
custom_field_4string

Field that can be used for custom dimensions

Example:"XYZ"
custom_field_5string

Field that can be used for custom dimensions

Example:"XYZ"
source_systemstring

Identifier of the source system this data is from. Needed when mapping between source system identifiers and master identifiers are used.

Example:"ABCDEF"
curl -i -X POST \
  'https://zapi-api.zoined.com/_mock/employeeHours?dryRun=false&separator=%3B&encoding=utf-8' \
  -H 'Authorization: Bearer <YOUR_token_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "organisation_id": "540",
    "department_id": "54021",
    "salesperson_id": "5402101",
    "employee_type": "Permie",
    "employeehours_id": "4244",
    "absence_code": "BREAK",
    "date": "2016-01-01",
    "time": "15:00:00",
    "scheduled": false,
    "productive": true,
    "hours": 8,
    "staff_cost": 500,
    "breaks": 0.5,
    "breaks_cost": 40,
    "currency": "EUR",
    "custom_field_1": "XYZ",
    "custom_field_2": "XYZ",
    "custom_field_3": "XYZ",
    "custom_field_4": "XYZ",
    "custom_field_5": "XYZ",
    "source_system": "ABCDEF"
  }'

Responses

Request has been processed successfully.

Headers

  • Content-Type: application/json
Bodyapplication/json
statusstringrequired

Status of the operation OK / Not OK

Example:"OK"
msgstringrequired

Message describing result of operation

Example:"1 entity added"
Response
{ "status": "OK", "msg": "1 entity added" }