Add or Update a Resource
Add a new Resource, or update an existing resource.
Query String Parameters
Name | Type | Description | Required |
---|---|---|---|
Action | String | ResourceSave | Required |
ResUpdate | Bool | 1 to set as an update. | Required |
ResId | Int | Id of the resource. | Required |
ResName | String | Resource name, takes precedence over reference and code when updating. | Required for a new resource |
ResReference | String | Resource reference, takes precedence over code when updating. | Optional |
ResCode | String | Resource code. | Optional |
ResGroupName | String | Group name. | Required for a new resource |
ResTachoCard | String | Resource tacho card. | Optional |
ResMobile | String | Resource mobile number. | Optional |
ResOutOfShiftPrivate | Bool | Set Out of Shift Private. 1 or 0 | Optional |
ResTimeZone | String | Set time zone. | Optional |
ResHasTrackingAlert | Bool | Set Has Tracking Alert. 1 or 0 | Optional |
ResKeyWork | String | Set Business Key. | Optional |
ResKeyPrivate | String | Set Private Key. | Optional |
Res4Tracking | Bool | Set if resource is tracked. 1 or 0 | Optional |
ResFuelCard | String | Set Fuel Card. | Optional |
ResMaxTravelDist | Int | Set Maximum Travel Distance for a Job. | Optional |
Resource4Schedule | Int | Set JobWatch Setting. | Optional |
ResDefaultRate | Decimal (6.2) | Set Default Hourly Rate. | Optional |
ResRateCurrency | String | Set Default Hourly Rate Currency. | Optional |
ResPassengerOK | Bool | Set if resource can wet themselves as a passenger. 1 or 0 | Optional |
ResHolidayStart | Date | Set start of holiday year. | Optional |
ResPayroll | String | Set payroll number. | Optional |
ResManagerId | Int | Id of manager. | Optional |
ResDaysHoliday | Int | Set number of days vacation. | Optional |
ResHideParentInfo | Bool | Hide contact’s parent information on the device. 1 or 0 | Optional |
ResLinkedToUser | Bool | Linked to User. 1 or 0 (See notes below) | Optional |
ResUserId | Int | User Id to link to, use with ResLinkedToUser. | Optional |
ResUserEmail | String | User email to create new basic user, use with ResLinkedToUser. | Optional |
ResCanSeeOwnOnly | Bool | 1 or 0. | Optional |
cust_custom field name | String | Pass cust_ followed by the caption of an existing custom field. | Optional |
Notes
To update a resource, set ResUpdate = 1 and supply, in order of precedence, ResId, ResReference or the ResCode.
ResLinkedToUser
- ‘true’ links to existing user, ResUserId must be supplied
- ‘false’ with ResUserEmail creates and links to new Basic User
Response Codes
Example
- Request
- Response
Request URL
https://webservice.bigchange.com/v01/services.ashx?action=ResourceSave&ResUpdate=0&ResName=Joe Bloggs&ResReference=JB1&ResGroupName=Engineers
Response Data
{ "Code": 0, "Result": { "ResourceId": 386632, "ResourceName": "Joe Bloggs", "ResourceReference": "JB1" } }