Timeclock
WIP: A summary needs to be written for Timeclock
Search Time Clocks
Search for Time Clock Entries
Body parameters
Consumes
The following content type is required: application/json
- Name
limit
- Type
- number
- Description
- Name
locationIds
- Type
- array
- Description
- Name
orderBy
- Type
- object
- Description
- Name
skip
- Type
- number
- Description
- Name
where
- Type
- object
- Description
Properties for orderBy
object
- Name
number
- Type
- one of: 'asc', 'desc' Required
- Description
Properties for where
object
- Name
inProgress
- Type
- object
- Description
- Name
laborId
- Type
- object
- Description
- Name
orderId
- Type
- object
- Description
- Name
technicianId
- Type
- object
- Description
Properties for inProgress
object
- Name
equals
- Type
- boolean Required
- Description
Properties for laborId
object
- Name
equals
- Type
- string Required
- Description
Properties for orderId
object
- Name
equals
- Type
- string Required
- Description
Properties for technicianId
object
- Name
in
- Type
- array Required
- Description
Produces
The response content type: application/json
200
Response
- Name
data
- Type
- array Required
- Description
- Name
success
- Type
- boolean Required
- Description
4xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
5xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
Example Requestapplication/json
curl https://api.shopmonkey.cloud/v3/timesheet/search \
-H "Authorization: Bearer ${SM_TOKEN}" \
-H 'Content-Type: application/json' \
--data '{}'
Example Responseapplication/json
{
"success": true,
"data": [
{
"id": "id",
"createdDate": "createdDate",
"updatedDate": null,
"locationId": "locationId",
"companyId": "companyId",
"number": 1,
"orderId": null,
"serviceId": null,
"laborId": null,
"technicianId": "technicianId",
"duration": null,
"clockIn": "clockIn",
"clockOut": null,
"clockInPlatform": null,
"clockOutPlatform": null,
"flatRate": true,
"rateCents": null,
"activity": "activity",
"type": "type",
"note": "note",
"inProgress": true,
"clockInLatitude": null,
"clockInLongitude": null,
"clockOutLatitude": null,
"clockOutLongitude": null,
"order": {
"id": "id",
"number": 1,
"name": null,
"coalescedName": null,
"generatedVehicleName": null,
"generatedCustomerName": null
},
"service": {
"id": "id",
"name": "name"
},
"labor": {
"id": "id",
"name": null
},
"technician": {
"firstName": "firstName",
"lastName": "lastName"
}
}
]
}
Find Timesheet
Find one Timesheet by id
URL parameters
- Name
id
- Type
- string Required
- Description
- the id for the object to retrieve
Produces
The response content type: application/json
200
Response
- Name
data
- Type
- object Required
- Description
- Timesheet schema
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
Properties for data
object
- Name
id
- Type
- string Required
- Description
- Name
meta
- Type
- object Required
- Description
- the metadata about the most recent change to the row
- Name
metadata
- Type
- object
- Description
- metadata reserved for customers to control
- Name
createdDate
- Type
- string Required
- Description
- Name
updatedDate
- Type
- string Required
- Description
- Name
locationId
- Type
- string Required
- Description
- Name
companyId
- Type
- string Required
- Description
- Name
number
- Type
- string Required
- Description
- Name
orderId
- Type
- string Required
- Description
- Name
serviceId
- Type
- string Required
- Description
- Name
laborId
- Type
- string Required
- Description
- Name
technicianId
- Type
- string Required
- Description
- Name
duration
- Type
- number Required
- Description
- Name
clockIn
- Type
- string Required
- Description
- Name
clockOut
- Type
- string Required
- Description
- Name
clockInPlatform
- Type
- one of: Web, Mobile Required
- Description
- Name
clockOutPlatform
- Type
- one of: Web, Mobile Required
- Description
- Name
flatRate
- Type
- boolean Required
- Description
- if the technician uses a flat rate
- Name
rateCents
- Type
- integer Required
- Description
- Name
activity
- Type
- one of: General, Order, Service, Labor Required
- Description
- Name
type
- Type
- one of: Timeclock, Manual Required
- Description
- Name
note
- Type
- string Required
- Description
- Name
inProgress
- Type
- boolean Required
- Description
- Name
clockInLatitude
- Type
- number Required
- Description
- the latitude for the clocked in location
- Name
clockInLongitude
- Type
- number Required
- Description
- the longitude for the clocked in location
- Name
clockOutLatitude
- Type
- number Required
- Description
- the latitude for the clocked out location
- Name
clockOutLongitude
- Type
- number Required
- Description
- the longitude for the clocked out location
- Name
clockInGeoLocationId
- Type
- string Required
- Description
- the geolocation id for the clocked in location if provided
- Name
clockOutGeoLocationId
- Type
- string Required
- Description
- the geolocation id for the clocked out location if provided
- Name
clockInAtLocation
- Type
- boolean Required
- Description
- true if the clocked in location was at the store location
- Name
clockOutAtLocation
- Type
- boolean Required
- Description
- true if the clocked out location was at the store location
Properties for meta
object
- Name
userId
- Type
- string
- Description
- the user id that made the most recent change
- Name
sessionId
- Type
- string
- Description
- the session id for the most recent change
- Name
version
- Type
- number
- Description
- a monotonically increasing number for the most recent change
4xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
5xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
Example Request
curl https://api.shopmonkey.cloud/v3/timesheet/:id \
-H "Authorization: Bearer ${SM_TOKEN}"
Example Responseapplication/json
{
"data": {
"id": "id",
"meta": {
"userId": "userId",
"sessionId": "sessionId",
"version": 1
},
"createdDate": "createdDate",
"updatedDate": null,
"locationId": "locationId",
"companyId": "companyId",
"number": "number",
"orderId": null,
"serviceId": null,
"laborId": null,
"technicianId": "technicianId",
"duration": null,
"clockIn": "clockIn",
"clockOut": null,
"clockInPlatform": null,
"clockOutPlatform": null,
"flatRate": true,
"rateCents": null,
"activity": "activity",
"type": "type",
"note": "note",
"inProgress": true,
"clockInLatitude": null,
"clockInLongitude": null,
"clockOutLatitude": null,
"clockOutLongitude": null,
"clockInGeoLocationId": null,
"clockOutGeoLocationId": null,
"clockInAtLocation": true,
"clockOutAtLocation": true
},
"success": true
}
Find Time Clocks
Find all Time Clock Entries
Query String parameters
- Name
ids
- Type
- array
- Description
- Name
limit
- Type
- number
- Description
- the limit on the number of records to return
- Name
orderby
- Type
- string
- Description
- the order instructions for the result
- Name
params
- Type
- string
- Description
- additional request specific params
- Name
skip
- Type
- number
- Description
- the number of records to skip for a paginated result
- Name
where
- Type
- string
- Description
- an object to use for filtering the results
Produces
The response content type: application/json
200
Response
- Name
data
- Type
- array Required
- Description
- Name
meta
- Type
- object
- Description
- Name
success
- Type
- boolean Required
- Description
Properties for meta
object
- Name
avgDurationPerService
- Type
- number Required
- Description
- average duration per service (in milliseconds), ie. the average of all the service or labor scoped time sheet durations
- Name
hasMore
- Type
- boolean Required
- Description
- Name
total
- Type
- number Required
- Description
- Name
totalDuration
- Type
- number Required
- Description
- total duration (in milliseconds) of all time sheet entries that match the filter
4xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
5xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
Example Request
curl https://api.shopmonkey.cloud/v3/timesheet \
-H "Authorization: Bearer ${SM_TOKEN}"
Example Responseapplication/json
{
"success": true,
"data": [
{
"id": "id",
"createdDate": "createdDate",
"updatedDate": null,
"locationId": "locationId",
"companyId": "companyId",
"number": 1,
"orderId": null,
"serviceId": null,
"laborId": null,
"technicianId": "technicianId",
"duration": null,
"clockIn": "clockIn",
"clockOut": null,
"clockInPlatform": null,
"clockOutPlatform": null,
"flatRate": true,
"rateCents": null,
"activity": "activity",
"type": "type",
"note": "note",
"inProgress": true,
"clockInLatitude": null,
"clockInLongitude": null,
"clockOutLatitude": null,
"clockOutLongitude": null,
"order": {
"id": "id",
"number": 1,
"name": null,
"coalescedName": null,
"generatedVehicleName": null,
"generatedCustomerName": null
},
"service": {
"id": "id",
"name": "name"
},
"labor": {
"id": "id",
"name": null
},
"technician": {
"firstName": "firstName",
"lastName": "lastName"
}
}
]
}
Update Time Clock
Update a Time Clock entry by id
URL parameters
- Name
id
- Type
- string Required
- Description
- the id of the time sheet entry
Body parameters
Consumes
The following content type is required: application/json
- Name
orderId
- Type
- string
- Description
- Name
serviceId
- Type
- string
- Description
- Name
laborId
- Type
- string
- Description
- Name
technicianId
- Type
- string
- Description
- Name
clockIn
- Type
- string
- Description
- Name
clockInPlatform
- Type
- one of: Web, Mobile
- Description
- Name
clockOutPlatform
- Type
- one of: Web, Mobile
- Description
- Name
activity
- Type
- one of: General, Order, Service, Labor
- Description
- Name
note
- Type
- string
- Description
- Name
clockInLatitude
- Type
- number
- Description
- the latitude for the clocked in location
- Name
clockInLongitude
- Type
- number
- Description
- the longitude for the clocked in location
- Name
clockOutLatitude
- Type
- number
- Description
- the latitude for the clocked out location
- Name
clockOutLongitude
- Type
- number
- Description
- the longitude for the clocked out location
- Name
clockOut
- Type
- string
- Description
- Name
locationId
- Type
- string
- Description
- the id for the location
Produces
The response content type: application/json
200
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if success = false
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
- Name
data
- Type
- object Required
- Description
- Timesheet schema
Properties for data
object
- Name
id
- Type
- string Required
- Description
- Name
createdDate
- Type
- string Required
- Description
- Name
updatedDate
- Type
- string Required
- Description
- Name
locationId
- Type
- string Required
- Description
- Name
companyId
- Type
- string Required
- Description
- Name
number
- Type
- string Required
- Description
- Name
orderId
- Type
- string Required
- Description
- Name
serviceId
- Type
- string Required
- Description
- Name
laborId
- Type
- string Required
- Description
- Name
technicianId
- Type
- string Required
- Description
- Name
duration
- Type
- number Required
- Description
- Name
clockIn
- Type
- string Required
- Description
- Name
clockOut
- Type
- string Required
- Description
- Name
clockInPlatform
- Type
- one of: Web, Mobile Required
- Description
- Name
clockOutPlatform
- Type
- one of: Web, Mobile Required
- Description
- Name
flatRate
- Type
- boolean Required
- Description
- if the technician uses a flat rate
- Name
rateCents
- Type
- integer Required
- Description
- Name
activity
- Type
- one of: General, Order, Service, Labor Required
- Description
- Name
type
- Type
- one of: Timeclock, Manual Required
- Description
- Name
note
- Type
- string Required
- Description
- Name
inProgress
- Type
- boolean Required
- Description
- Name
clockInLatitude
- Type
- number Required
- Description
- the latitude for the clocked in location
- Name
clockInLongitude
- Type
- number Required
- Description
- the longitude for the clocked in location
- Name
clockOutLatitude
- Type
- number Required
- Description
- the latitude for the clocked out location
- Name
clockOutLongitude
- Type
- number Required
- Description
- the longitude for the clocked out location
- Name
clockInGeoLocationId
- Type
- string Required
- Description
- the geolocation id for the clocked in location if provided
- Name
clockOutGeoLocationId
- Type
- string Required
- Description
- the geolocation id for the clocked out location if provided
- Name
clockInAtLocation
- Type
- boolean Required
- Description
- true if the clocked in location was at the store location
- Name
clockOutAtLocation
- Type
- boolean Required
- Description
- true if the clocked out location was at the store location
4xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
5xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
Example Requestapplication/json
curl https://api.shopmonkey.cloud/v3/timesheet/:id \
-H "Authorization: Bearer ${SM_TOKEN}" \
-X PUT -H 'Content-Type: application/json' \
--data '{}'
Example Responseapplication/json
{
"success": true,
"data": {
"id": "id",
"createdDate": "createdDate",
"updatedDate": null,
"locationId": "locationId",
"companyId": "companyId",
"number": 1,
"orderId": null,
"serviceId": null,
"laborId": null,
"technicianId": "technicianId",
"duration": null,
"clockIn": "clockIn",
"clockOut": null,
"clockInPlatform": null,
"clockOutPlatform": null,
"flatRate": true,
"rateCents": null,
"activity": "activity",
"type": "type",
"note": "note",
"inProgress": true,
"clockInLatitude": null,
"clockInLongitude": null,
"clockOutLatitude": null,
"clockOutLongitude": null
}
}
Update Time Clock Note
Update a Time Clock entry note by id
URL parameters
- Name
id
- Type
- string Required
- Description
- the id of the timesheet entry
Body parameters
Consumes
The following content type is required: application/json
- Name
note
- Type
- string
- Description
Produces
The response content type: application/json
200
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if success = false
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
- Name
data
- Type
- object Required
- Description
- Timesheet schema
Properties for data
object
- Name
id
- Type
- string Required
- Description
- Name
createdDate
- Type
- string Required
- Description
- Name
updatedDate
- Type
- string Required
- Description
- Name
locationId
- Type
- string Required
- Description
- Name
companyId
- Type
- string Required
- Description
- Name
number
- Type
- string Required
- Description
- Name
orderId
- Type
- string Required
- Description
- Name
serviceId
- Type
- string Required
- Description
- Name
laborId
- Type
- string Required
- Description
- Name
technicianId
- Type
- string Required
- Description
- Name
duration
- Type
- number Required
- Description
- Name
clockIn
- Type
- string Required
- Description
- Name
clockOut
- Type
- string Required
- Description
- Name
clockInPlatform
- Type
- one of: Web, Mobile Required
- Description
- Name
clockOutPlatform
- Type
- one of: Web, Mobile Required
- Description
- Name
flatRate
- Type
- boolean Required
- Description
- if the technician uses a flat rate
- Name
rateCents
- Type
- integer Required
- Description
- Name
activity
- Type
- one of: General, Order, Service, Labor Required
- Description
- Name
type
- Type
- one of: Timeclock, Manual Required
- Description
- Name
note
- Type
- string Required
- Description
- Name
inProgress
- Type
- boolean Required
- Description
- Name
clockInLatitude
- Type
- number Required
- Description
- the latitude for the clocked in location
- Name
clockInLongitude
- Type
- number Required
- Description
- the longitude for the clocked in location
- Name
clockOutLatitude
- Type
- number Required
- Description
- the latitude for the clocked out location
- Name
clockOutLongitude
- Type
- number Required
- Description
- the longitude for the clocked out location
- Name
clockInGeoLocationId
- Type
- string Required
- Description
- the geolocation id for the clocked in location if provided
- Name
clockOutGeoLocationId
- Type
- string Required
- Description
- the geolocation id for the clocked out location if provided
- Name
clockInAtLocation
- Type
- boolean Required
- Description
- true if the clocked in location was at the store location
- Name
clockOutAtLocation
- Type
- boolean Required
- Description
- true if the clocked out location was at the store location
4xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
5xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
Example Requestapplication/json
curl https://api.shopmonkey.cloud/v3/timesheet/:id/note \
-H "Authorization: Bearer ${SM_TOKEN}" \
-X PUT -H 'Content-Type: application/json' \
--data '{}'
Example Responseapplication/json
{
"success": true,
"data": {
"id": "id",
"createdDate": "createdDate",
"updatedDate": null,
"locationId": "locationId",
"companyId": "companyId",
"number": 1,
"orderId": null,
"serviceId": null,
"laborId": null,
"technicianId": "technicianId",
"duration": null,
"clockIn": "clockIn",
"clockOut": null,
"clockInPlatform": null,
"clockOutPlatform": null,
"flatRate": true,
"rateCents": null,
"activity": "activity",
"type": "type",
"note": "note",
"inProgress": true,
"clockInLatitude": null,
"clockInLongitude": null,
"clockOutLatitude": null,
"clockOutLongitude": null
}
}
Create Time Clock
Create a new Time Clock entry manually
Body parameters
Consumes
The following content type is required: application/json
- Name
orderId
- Type
- string
- Description
- Name
serviceId
- Type
- string
- Description
- Name
laborId
- Type
- string
- Description
- Name
technicianId
- Type
- string Required
- Description
- Name
clockIn
- Type
- string Required
- Description
- Name
clockInPlatform
- Type
- one of: Web, Mobile
- Description
- Name
clockOutPlatform
- Type
- one of: Web, Mobile
- Description
- Name
activity
- Type
- one of: General, Order, Service, Labor Required
- Description
- Name
note
- Type
- string
- Description
- Name
clockInLatitude
- Type
- number
- Description
- the latitude for the clocked in location
- Name
clockInLongitude
- Type
- number
- Description
- the longitude for the clocked in location
- Name
clockOutLatitude
- Type
- number
- Description
- the latitude for the clocked out location
- Name
clockOutLongitude
- Type
- number
- Description
- the longitude for the clocked out location
- Name
clockOut
- Type
- string Required
- Description
- Name
locationId
- Type
- string
- Description
- the id for the location
Produces
The response content type: application/json
200
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if success = false
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
- Name
data
- Type
- object Required
- Description
- Timesheet schema
Properties for data
object
- Name
id
- Type
- string Required
- Description
- Name
createdDate
- Type
- string Required
- Description
- Name
updatedDate
- Type
- string Required
- Description
- Name
locationId
- Type
- string Required
- Description
- Name
companyId
- Type
- string Required
- Description
- Name
number
- Type
- string Required
- Description
- Name
orderId
- Type
- string Required
- Description
- Name
serviceId
- Type
- string Required
- Description
- Name
laborId
- Type
- string Required
- Description
- Name
technicianId
- Type
- string Required
- Description
- Name
duration
- Type
- number Required
- Description
- Name
clockIn
- Type
- string Required
- Description
- Name
clockOut
- Type
- string Required
- Description
- Name
clockInPlatform
- Type
- one of: Web, Mobile Required
- Description
- Name
clockOutPlatform
- Type
- one of: Web, Mobile Required
- Description
- Name
flatRate
- Type
- boolean Required
- Description
- if the technician uses a flat rate
- Name
rateCents
- Type
- integer Required
- Description
- Name
activity
- Type
- one of: General, Order, Service, Labor Required
- Description
- Name
type
- Type
- one of: Timeclock, Manual Required
- Description
- Name
note
- Type
- string Required
- Description
- Name
inProgress
- Type
- boolean Required
- Description
- Name
clockInLatitude
- Type
- number Required
- Description
- the latitude for the clocked in location
- Name
clockInLongitude
- Type
- number Required
- Description
- the longitude for the clocked in location
- Name
clockOutLatitude
- Type
- number Required
- Description
- the latitude for the clocked out location
- Name
clockOutLongitude
- Type
- number Required
- Description
- the longitude for the clocked out location
- Name
clockInGeoLocationId
- Type
- string Required
- Description
- the geolocation id for the clocked in location if provided
- Name
clockOutGeoLocationId
- Type
- string Required
- Description
- the geolocation id for the clocked out location if provided
- Name
clockInAtLocation
- Type
- boolean Required
- Description
- true if the clocked in location was at the store location
- Name
clockOutAtLocation
- Type
- boolean Required
- Description
- true if the clocked out location was at the store location
4xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
5xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
Example Requestapplication/json
curl https://api.shopmonkey.cloud/v3/timesheet \
-H "Authorization: Bearer ${SM_TOKEN}" \
-H 'Content-Type: application/json' \
--data '{ "technicianId" : "value", "clockIn" : "value", "activity" : "value", "clockOut" : "value" }'
Example Responseapplication/json
{
"success": true,
"data": {
"id": "id",
"createdDate": "createdDate",
"updatedDate": null,
"locationId": "locationId",
"companyId": "companyId",
"number": 1,
"orderId": null,
"serviceId": null,
"laborId": null,
"technicianId": "technicianId",
"duration": null,
"clockIn": "clockIn",
"clockOut": null,
"clockInPlatform": null,
"clockOutPlatform": null,
"flatRate": true,
"rateCents": null,
"activity": "activity",
"type": "type",
"note": "note",
"inProgress": true,
"clockInLatitude": null,
"clockInLongitude": null,
"clockOutLatitude": null,
"clockOutLongitude": null
}
}
Clock In
Create a new "clocked in" Time Clock entry
Body parameters
Consumes
The following content type is required: application/json
- Name
orderId
- Type
- string
- Description
- Name
serviceId
- Type
- string
- Description
- Name
laborId
- Type
- string
- Description
- Name
technicianId
- Type
- string Required
- Description
- Name
activity
- Type
- one of: General, Order, Service, Labor Required
- Description
- Name
note
- Type
- string
- Description
- Name
clockInLatitude
- Type
- number
- Description
- the latitude for the clocked in location
- Name
clockInLongitude
- Type
- number
- Description
- the longitude for the clocked in location
- Name
clockInGeoLocationId
- Type
- string
- Description
- the geolocation id for the clocked in location if provided
- Name
clockOutGeoLocationId
- Type
- string
- Description
- the geolocation id for the clocked out location if provided
- Name
clockInAtLocation
- Type
- boolean
- Description
- true if the clocked in location was at the store location
- Name
clockOutAtLocation
- Type
- boolean
- Description
- true if the clocked out location was at the store location
- Name
clockInPlatform
- Type
- one of: Web, Mobile Required
- Description
- Name
locationId
- Type
- string
- Description
- the id for the location
Produces
The response content type: application/json
200
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if success = false
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
- Name
data
- Type
- object Required
- Description
Properties for data
object
- Name
current
- Type
- object Required
- Description
- Timesheet schema
- Name
previous
- Type
- object
- Description
- Timesheet schema
Properties for current
object
- Name
id
- Type
- string Required
- Description
- Name
createdDate
- Type
- string Required
- Description
- Name
updatedDate
- Type
- string Required
- Description
- Name
locationId
- Type
- string Required
- Description
- Name
companyId
- Type
- string Required
- Description
- Name
number
- Type
- string Required
- Description
- Name
orderId
- Type
- string Required
- Description
- Name
serviceId
- Type
- string Required
- Description
- Name
laborId
- Type
- string Required
- Description
- Name
technicianId
- Type
- string Required
- Description
- Name
duration
- Type
- number Required
- Description
- Name
clockIn
- Type
- string Required
- Description
- Name
clockOut
- Type
- string Required
- Description
- Name
clockInPlatform
- Type
- one of: Web, Mobile Required
- Description
- Name
clockOutPlatform
- Type
- one of: Web, Mobile Required
- Description
- Name
flatRate
- Type
- boolean Required
- Description
- if the technician uses a flat rate
- Name
rateCents
- Type
- integer Required
- Description
- Name
activity
- Type
- one of: General, Order, Service, Labor Required
- Description
- Name
type
- Type
- one of: Timeclock, Manual Required
- Description
- Name
note
- Type
- string Required
- Description
- Name
inProgress
- Type
- boolean Required
- Description
- Name
clockInLatitude
- Type
- number Required
- Description
- the latitude for the clocked in location
- Name
clockInLongitude
- Type
- number Required
- Description
- the longitude for the clocked in location
- Name
clockOutLatitude
- Type
- number Required
- Description
- the latitude for the clocked out location
- Name
clockOutLongitude
- Type
- number Required
- Description
- the longitude for the clocked out location
- Name
clockInGeoLocationId
- Type
- string Required
- Description
- the geolocation id for the clocked in location if provided
- Name
clockOutGeoLocationId
- Type
- string Required
- Description
- the geolocation id for the clocked out location if provided
- Name
clockInAtLocation
- Type
- boolean Required
- Description
- true if the clocked in location was at the store location
- Name
clockOutAtLocation
- Type
- boolean Required
- Description
- true if the clocked out location was at the store location
Properties for previous
object
- Name
id
- Type
- string Required
- Description
- Name
createdDate
- Type
- string Required
- Description
- Name
updatedDate
- Type
- string Required
- Description
- Name
locationId
- Type
- string Required
- Description
- Name
companyId
- Type
- string Required
- Description
- Name
number
- Type
- string Required
- Description
- Name
orderId
- Type
- string Required
- Description
- Name
serviceId
- Type
- string Required
- Description
- Name
laborId
- Type
- string Required
- Description
- Name
technicianId
- Type
- string Required
- Description
- Name
duration
- Type
- number Required
- Description
- Name
clockIn
- Type
- string Required
- Description
- Name
clockOut
- Type
- string Required
- Description
- Name
clockInPlatform
- Type
- one of: Web, Mobile Required
- Description
- Name
clockOutPlatform
- Type
- one of: Web, Mobile Required
- Description
- Name
flatRate
- Type
- boolean Required
- Description
- if the technician uses a flat rate
- Name
rateCents
- Type
- integer Required
- Description
- Name
activity
- Type
- one of: General, Order, Service, Labor Required
- Description
- Name
type
- Type
- one of: Timeclock, Manual Required
- Description
- Name
note
- Type
- string Required
- Description
- Name
inProgress
- Type
- boolean Required
- Description
- Name
clockInLatitude
- Type
- number Required
- Description
- the latitude for the clocked in location
- Name
clockInLongitude
- Type
- number Required
- Description
- the longitude for the clocked in location
- Name
clockOutLatitude
- Type
- number Required
- Description
- the latitude for the clocked out location
- Name
clockOutLongitude
- Type
- number Required
- Description
- the longitude for the clocked out location
- Name
clockInGeoLocationId
- Type
- string Required
- Description
- the geolocation id for the clocked in location if provided
- Name
clockOutGeoLocationId
- Type
- string Required
- Description
- the geolocation id for the clocked out location if provided
- Name
clockInAtLocation
- Type
- boolean Required
- Description
- true if the clocked in location was at the store location
- Name
clockOutAtLocation
- Type
- boolean Required
- Description
- true if the clocked out location was at the store location
4xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
5xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
Example Requestapplication/json
curl https://api.shopmonkey.cloud/v3/timesheet/clock_in \
-H "Authorization: Bearer ${SM_TOKEN}" \
-H 'Content-Type: application/json' \
--data '{ "technicianId" : "value", "activity" : "value", "clockInPlatform" : "value" }'
Example Responseapplication/json
{
"success": true,
"data": {
"current": {
"id": "id",
"createdDate": "createdDate",
"updatedDate": null,
"locationId": "locationId",
"companyId": "companyId",
"number": 1,
"orderId": null,
"serviceId": null,
"laborId": null,
"technicianId": "technicianId",
"duration": null,
"clockIn": "clockIn",
"clockOut": null,
"clockInPlatform": null,
"clockOutPlatform": null,
"flatRate": true,
"rateCents": null,
"activity": "activity",
"type": "type",
"note": "note",
"inProgress": true,
"clockInLatitude": null,
"clockInLongitude": null,
"clockOutLatitude": null,
"clockOutLongitude": null
},
"previous": {
"id": "id",
"createdDate": "createdDate",
"updatedDate": null,
"locationId": "locationId",
"companyId": "companyId",
"number": 1,
"orderId": null,
"serviceId": null,
"laborId": null,
"technicianId": "technicianId",
"duration": null,
"clockIn": "clockIn",
"clockOut": null,
"clockInPlatform": null,
"clockOutPlatform": null,
"flatRate": true,
"rateCents": null,
"activity": "activity",
"type": "type",
"note": "note",
"inProgress": true,
"clockInLatitude": null,
"clockInLongitude": null,
"clockOutLatitude": null,
"clockOutLongitude": null
}
}
}
Clock Out
Clock out of a Time Clock entry
URL parameters
- Name
id
- Type
- string Required
- Description
- the id of the timesheet entry
Body parameters
Consumes
The following content type is required: application/json
- Name
note
- Type
- string
- Description
- Name
clockOutLatitude
- Type
- number
- Description
- the latitude for the clocked out location
- Name
clockOutLongitude
- Type
- number
- Description
- the longitude for the clocked out location
- Name
clockInGeoLocationId
- Type
- string
- Description
- the geolocation id for the clocked in location if provided
- Name
clockOutGeoLocationId
- Type
- string
- Description
- the geolocation id for the clocked out location if provided
- Name
clockInAtLocation
- Type
- boolean
- Description
- true if the clocked in location was at the store location
- Name
clockOutAtLocation
- Type
- boolean
- Description
- true if the clocked out location was at the store location
- Name
clockOutPlatform
- Type
- one of: Web, Mobile Required
- Description
Produces
The response content type: application/json
200
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if success = false
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
- Name
data
- Type
- object Required
- Description
- Timesheet schema
Properties for data
object
- Name
id
- Type
- string Required
- Description
- Name
createdDate
- Type
- string Required
- Description
- Name
updatedDate
- Type
- string Required
- Description
- Name
locationId
- Type
- string Required
- Description
- Name
companyId
- Type
- string Required
- Description
- Name
number
- Type
- string Required
- Description
- Name
orderId
- Type
- string Required
- Description
- Name
serviceId
- Type
- string Required
- Description
- Name
laborId
- Type
- string Required
- Description
- Name
technicianId
- Type
- string Required
- Description
- Name
duration
- Type
- number Required
- Description
- Name
clockIn
- Type
- string Required
- Description
- Name
clockOut
- Type
- string Required
- Description
- Name
clockInPlatform
- Type
- one of: Web, Mobile Required
- Description
- Name
clockOutPlatform
- Type
- one of: Web, Mobile Required
- Description
- Name
flatRate
- Type
- boolean Required
- Description
- if the technician uses a flat rate
- Name
rateCents
- Type
- integer Required
- Description
- Name
activity
- Type
- one of: General, Order, Service, Labor Required
- Description
- Name
type
- Type
- one of: Timeclock, Manual Required
- Description
- Name
note
- Type
- string Required
- Description
- Name
inProgress
- Type
- boolean Required
- Description
- Name
clockInLatitude
- Type
- number Required
- Description
- the latitude for the clocked in location
- Name
clockInLongitude
- Type
- number Required
- Description
- the longitude for the clocked in location
- Name
clockOutLatitude
- Type
- number Required
- Description
- the latitude for the clocked out location
- Name
clockOutLongitude
- Type
- number Required
- Description
- the longitude for the clocked out location
- Name
clockInGeoLocationId
- Type
- string Required
- Description
- the geolocation id for the clocked in location if provided
- Name
clockOutGeoLocationId
- Type
- string Required
- Description
- the geolocation id for the clocked out location if provided
- Name
clockInAtLocation
- Type
- boolean Required
- Description
- true if the clocked in location was at the store location
- Name
clockOutAtLocation
- Type
- boolean Required
- Description
- true if the clocked out location was at the store location
4xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
5xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
Example Requestapplication/json
curl https://api.shopmonkey.cloud/v3/timesheet/:id/clock_out \
-H "Authorization: Bearer ${SM_TOKEN}" \
-X PUT -H 'Content-Type: application/json' \
--data '{ "clockOutPlatform" : "value" }'
Example Responseapplication/json
{
"success": true,
"data": {
"id": "id",
"createdDate": "createdDate",
"updatedDate": null,
"locationId": "locationId",
"companyId": "companyId",
"number": 1,
"orderId": null,
"serviceId": null,
"laborId": null,
"technicianId": "technicianId",
"duration": null,
"clockIn": "clockIn",
"clockOut": null,
"clockInPlatform": null,
"clockOutPlatform": null,
"flatRate": true,
"rateCents": null,
"activity": "activity",
"type": "type",
"note": "note",
"inProgress": true,
"clockInLatitude": null,
"clockInLongitude": null,
"clockOutLatitude": null,
"clockOutLongitude": null
}
}
Delete Timesheet
Permanently delete a Timesheet by id
URL parameters
- Name
id
- Type
- string Required
- Description
- the id of the record to delete
Produces
The response content type: application/json
200
Response
- Name
data
- Type
- object
- Description
- Name
success
- Type
- boolean Required
- Description
Properties for data
object
- Name
id
- Type
- string Required
- Description
- the id for the object
4xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
5xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
Example Requestapplication/json
curl https://api.shopmonkey.cloud/v3/timesheet/:id \
-H "Authorization: Bearer ${SM_TOKEN}" \
-X DELETE -H 'Content-Type: application/json' \
--data '{}'
Example Responseapplication/json
{
"success": true
}
Find Time Tracking Users
Find all users who can track time
Query String parameters
- Name
platform
- Type
- one of: 'Web', 'Mobile'
- Description
- the platform filter for time track permission
Produces
The response content type: application/json
200
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- array Required
- Description
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if success = false
- Name
meta
- Type
- object
- Description
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
Properties for meta
object
- Name
hasMore
- Type
- boolean
- Description
- if there are more records available
- Name
sums
- Type
- object
- Description
- Name
total
- Type
- number
- Description
- the total number of records
4xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
5xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
Example Request
curl https://api.shopmonkey.cloud/v3/timesheet/user \
-H "Authorization: Bearer ${SM_TOKEN}"
Example Responseapplication/json
{
"success": true,
"data": [
{
"id": "id",
"firstName": "firstName",
"lastName": "lastName",
"color": "color"
}
]
}
Find Time Tracking Users with Stats
Find all users who can track time and their stats
Query String parameters
- Name
platform
- Type
- one of: 'Web', 'Mobile'
- Description
- the platform filter for time track permission
Produces
The response content type: application/json
200
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- array Required
- Description
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if success = false
- Name
meta
- Type
- object
- Description
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
Properties for meta
object
- Name
hasMore
- Type
- boolean
- Description
- if there are more records available
- Name
sums
- Type
- object
- Description
- Name
total
- Type
- number
- Description
- the total number of records
4xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
5xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
Example Request
curl https://api.shopmonkey.cloud/v3/timesheet/user/detail \
-H "Authorization: Bearer ${SM_TOKEN}"
Example Responseapplication/json
{
"success": true,
"data": [
{
"id": "id",
"firstName": "firstName",
"lastName": "lastName",
"color": "color",
"durationMonth": 1,
"durationWeek": 1,
"durationDay": 1,
"activeTimesheet": {
"id": "id",
"createdDate": "createdDate",
"updatedDate": null,
"locationId": "locationId",
"companyId": "companyId",
"number": 1,
"orderId": null,
"serviceId": null,
"laborId": null,
"technicianId": "technicianId",
"duration": null,
"clockIn": "clockIn",
"clockOut": null,
"clockInPlatform": null,
"clockOutPlatform": null,
"flatRate": true,
"rateCents": null,
"activity": "activity",
"type": "type",
"note": "note",
"inProgress": true,
"clockInLatitude": null,
"clockInLongitude": null,
"clockOutLatitude": null,
"clockOutLongitude": null,
"order": {
"id": "id",
"number": 1,
"name": null,
"coalescedName": null,
"generatedVehicleName": null,
"generatedCustomerName": null
},
"service": {
"id": "id",
"name": "name"
},
"labor": {
"id": "id",
"name": null
}
},
"recentTimesheets": [
{
"id": "id",
"createdDate": "createdDate",
"updatedDate": null,
"locationId": "locationId",
"companyId": "companyId",
"number": 1,
"orderId": null,
"serviceId": null,
"laborId": null,
"technicianId": "technicianId",
"duration": null,
"clockIn": "clockIn",
"clockOut": null,
"clockInPlatform": null,
"clockOutPlatform": null,
"flatRate": true,
"rateCents": null,
"activity": "activity",
"type": "type",
"note": "note",
"inProgress": true,
"clockInLatitude": null,
"clockInLongitude": null,
"clockOutLatitude": null,
"clockOutLongitude": null,
"order": {
"id": "id",
"number": 1,
"name": null,
"coalescedName": null,
"generatedVehicleName": null,
"generatedCustomerName": null
},
"service": {
"id": "id",
"name": "name"
},
"labor": {
"id": "id",
"name": null
}
}
]
}
]
}
Export Time Clock
Export Time Clock data as Excel spreadsheet
Produces
The response content type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
200
Response
the data in excel format
4xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
5xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
Example Request
curl https://api.shopmonkey.cloud/v3/timesheet/export \
-H "Authorization: Bearer ${SM_TOKEN}"
Export Time Clock
Export Time Clock data as Excel spreadsheet
Produces
The response content type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
200
Response
the data in excel format
4xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
5xx
Response
- Name
code
- Type
- string
- Description
- The error code
- Name
data
- Type
- object
- Description
- An optional object containing relevant error data
- Name
documentation_url
- Type
- string
- Description
- An optional link to the documentation for the error
- Name
message
- Type
- string
- Description
- the error message if not successful
- Name
success
- Type
- boolean Required
- Description
- if successful, will be true. if not successful, will be false and message will contain a human readable error message
Example Requestapplication/json
curl https://api.shopmonkey.cloud/v3/timesheet/export \
-H "Authorization: Bearer ${SM_TOKEN}" \
-H 'Content-Type: application/json' \
--data '{}'