put https://api.azuga.com/azuga-ws/v1/timecard.json
Use this API to modify an existing shift. You can edit shift attributes for events such as shift start, shift end, break start, break end. Only one shift can be updated in a single API call.
Sample Request
{
"parentShiftId":"22",
"timeCards":[
{
"eventTime":1460174400000,
"eventType":1,
"id":22,
"location":{
"address":{
"formattedAddress":"1803 Ocean Cape Common, San Jose, CA 95131,USA"
},
"latitude":"37.384973",
"longitude":"-121.896050",
"time":1461217105281
},
"misc":"Shift Start"
},
{
"eventTime":1460175000000,
"eventType":2,
"id":23,
"location":{
"address":{
"formattedAddress":"3101, Mountain View Rd, Santa Clara, CA 95054, USA"
},
"latitude":"37.410857",
"longitude":"-121.985456",
"time":1461218105281
},
"misc":"Break Start"
},
{
"eventTime":1460176200000,
"eventType":3,
"id":24,
"location":{
"address":{
"formattedAddress":"1312 Crossman Ave, Sunnyvale, CA 94089, USA"
},
"latitude":"37.410105",
"longitude":"-122.010499",
"time":1461217185281
},
"misc":"Break End"
},
{
"eventTime":1460260740000,
"eventType":4,
"id":25,
"location":{
"address":{
"formattedAddress":"1399 Charleston Rd, Mountain View, CA 94043, USA"
},
"latitude":"37.420603",
"longitude":"-122.077406",
"time":1461217105281
},
"misc":"Break End"
}
],
"timeZone":"US/Pacific",
"userId":"b5b0e72b-f659-11e5-b1c8-316e9903837a"
}
API Response explanation
Field | Description |
---|---|
error | Error status |
result | API message (Success/Failure) |