Get a template
Returns a single shift template by its numeric id.
GET
/v1/templates/{id}
const url = 'https://api.shiftsync.app/v1/templates/1';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://api.shiftsync.app/v1/templates/1 \ --header 'Authorization: Bearer <token>'Authorizations
Section titled “Authorizations”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters”id
required
number
Responses
Section titled “ Responses ”A single template
Media typeapplication/json
object
item
required
object
id
required
integer
title
required
string
shortTitle
required
string
notes
string
colorId
required
integer
icon
userId
required
integer
visibility
required
string
payRateMinor
integer
Any of:
object
allDay
required
boolean
object
isSplit
boolean
startTime
required
string
endTime
required
string
splitStartTime
string
splitEndTime
string
Example
{ "item": { "id": 0, "title": "string", "shortTitle": "string", "notes": "string", "colorId": 0, "icon": { "type": "icon", "name": "moon" }, "userId": 0, "visibility": "public", "payRateMinor": 0, "allDay": true }}