VismaBouwsoftAPICalls.v1_GET_WorkCodes Method
v1_GET_WorkCodes() as String

This API call is used to get fields of a(n) WorkCode(s)

HTTP method API version
GET v1

Don’t forget to put the Authorization field in the header

API Path: /WorkCodes/
or
API Path: /WorkCodes/{id}
or
API Path: /WorkCodes/FieldInfo/

You can make this API call:
* without the key field id to get a list of WorkCodes
* with the key field id as the path parameter (the specific id of the WorkCode you want to get)
* to request the FieldInfo for this call

Fields

The following fields are available:

Field Name Type Name Length Required Writeable Force Write Link
workcode tpString 4 No No No
worktext tpString 250 No No No
worked tpBool 0 No No No
actualcostitem_id tpLong 0 No No No
absence_actualcostitem_name tpString 100 No No No
vacation tpBool 0 No No No
paid tpBool 0 No No No

/WorkCodes/

API Path: /WorkCodes/

If everything succeeds the HTTP response status is 200
(200 OK)

If there is something wrong with the request, the response status and code is 400
(400 Bad Request)

If you forget to send the Authorization, the response status is 401
(401 Unauthorized)

If what you sent can’t be processed, the response status is 500
(500 Internal Server Error)

For an explanation of all possible errors, please consult our section on possible answers to API calls here

Examples:

https://ra.bouwsoft.be/api/v1/WorkCodes

with the following parameters :

Header Parameters :
ParameterName: Clientnr, ParameterValue: 115
ParameterName: AccessToken, ParameterValue: PtGfWxfOrPzSftOfffzRqmrDffrrfGrVffAkzmDDmlGGPVPVrt

Query Parameters :
ParameterName: limit, ParameterValue: 5

Success gives statuscode 200 And the following result

{ “Content-Range”:“0–4/19”, “Records”: [
  {
    "id": 1,
    "workcode": "01",
    "worktext": "Gepresteerde dagen",
    "worked": true,
    "actualcostitem_id": 0,
    "absence_actualcostitem_name": "",
    "vacation": false,
    "paid": true
  },
  {
    "id": 2,
    "workcode": "AO",
    "worktext": "AO",
    "worked": false,
    "actualcostitem_id": 0,
    "absence_actualcostitem_name": "",
    "vacation": false,
    "paid": true
  }
,

]
}

/WorkCodes/{id}

If everything succeeds the HTTP response status is 200
(200 OK)

If there is something wrong with the request, the response status and code is 400
(400 Bad Request)

If there is no record that has the requested id the HTTP response status and code is 404
(404 Not found)

If you forget to send the Authorization, the response status is 401
(401 Unauthorized)

If what you sent can’t be processed, the response status is 500
(500 Internal Server Error)

For an explanation of all possible errors, please consult our section on possible answers to API calls here

Examples:

https://ra.bouwsoft.be/api/v1/WorkCodes/2

with the following parameters :

Header Parameters :
ParameterName: Clientnr, ParameterValue: 115
ParameterName: AccessToken, ParameterValue: PtGfWxfOrPzSftOfffzRqmrDffrrfGrVffAkzmDDmlGGPVPVrt

Success gives statuscode 200 And the following result

{ “Content-Range”:“0–0/1”, “Records”: [
  {
    "id": 2,
    "workcode": "AO",
    "worktext": "AO",
    "worked": false,
    "actualcostitem_id": 0,
    "absence_actualcostitem_name": "",
    "vacation": false,
    "paid": true
  }
]
}

/WorkCodes/FieldInfo

If everything succeeds the HTTP response status is 200
(200 OK)

If there is something wrong with the request, the response status and code is 400
(400 Bad Request)

If there is no record that has the requested id the HTTP response status and code is 404
(404 Not found)

If you forget to send the Authorization, the response status is 401
(401 Unauthorized)

If what you sent can’t be processed, the response status is 500
(500 Internal Server Error)

For an explanation of all possible errors, please consult our section on possible answers to API calls here

Examples:

https://ra.bouwsoft.be/api/v1/WorkCodes/FieldInfo

with the following parameters :

Header Parameters :
ParameterName: AccessToken, ParameterValue: UOIfWxffkAzSfrUjPtzRqUUbfkrkIOlljbPtzDDlVrfGjAmtfb
ParameterName: Clientnr, ParameterValue: 115

Success gives statuscode 200 And the following result

[
  {
    "name": "workcode",
    "type_id": 2,
    "type_name": "tpString",
    "length": 4,
    "required": false,
    "writeable": false,
    "forcewrite": false,
    "link": ""
  },
  {
    "name": "worktext",
    "type_id": 2,
    "type_name": "tpString",
    "length": 250,
    "required": false,
    "writeable": false,
    "forcewrite": false,
    "link": ""
  }
,

]