QBOS REST API documentation (workitem_humanresource)

(return to Main Document)

Introduction

The workitem_humanresource API allows client applications to maintain workitem_humanresource data including any part of its demographic record sets.

Audience

This developer's guide is intended for software developers needing a technical reference for using the QBOS REST API. The information you find in this guide is written by software engineering, and is authoritative on how the API behaves.

Additional resources, information about this guide

Occasionally, we make a mistake in this documentation, or unknowingly break a feature that you depend on. If this has happened to you, we apologize! You can help us fix the issue by contacting us. We appreciate your help.

Getting Started

To place any request in QBOS API application from third party application you need to authenticate user account and set/calculate values for the following request headers: x-qbos-id, x-qbos-nonce, x-qbos-date-utc, x-qbos-hash-version, x-qbos-auth

See details in Authentication Documentation.

workitem_humanresource properties

Properties prefixed with '_' (underscore) are read-only properties. i.e. POST and PUT processing will ignore these properties.

Name Type Max length Numeric Required
For POST
Filterable Description

id

bigint

 

 

 

Required for GET(by id),PUT,DELETE

parent_id

bigint

 

yes

 

parent_type

nvarchar

50

 

yes

 

type

nvarchar

50

 

 

 

Value is "workitem_humanresource"

humanresource_id

bigint

 

yes

 

Update this value to change ownership of a workitem

href

varchar

 

 

 

href_humanresource

varchar

 

 

 

_title

nvarchar

 

 

 

cost_to_client_unit_type

char

1

 

 

 

"h"=hour. This is currently the only supported value

cost_to_client_per_unit

money

 

 

 

est_secs

int

 

 

 

Read workitem_humanresource by id:

GET https:/.../v1/o/workitem_humanresource/{id}

Response codes:

  • 400 - Client error
  • 500 - Server error
  • 404 - Not found or user does not have permission to access resources of this type.
  • 200 - OK

Response data: GET https:/.../v1/o/workitem_humanresource/149342
{ "parent_type" : "workitem", "parent_id" : 158282, "type" : "workitem_humanresource", "id" : 149342, "sub_type" : "", "humanresource_id" : 550881, "href" : "\/v1\/o\/workitem_humanresource\/149342", "href_humanresource" : "\/v1\/o\/humanresource\/550881", "_title" : "Della Miller", "cost_to_client_unit_type" : "h", "cost_to_client_per_unit" : 0.0000, "est_secs" : 36000 }

Read workitem_humanresource from parent:

GET https:/.../v1/o/{parent_type}/{parent_id}/links/workitem_humanresource[?{filter}]

Response codes:

  • 400 - Client error
  • 500 - Server error
  • 404 - Not found or user does not have permission to access resources of this type.
  • 200 - OK

GET https:/.../v1/o/workitem/158282/links/workitem_humanresource
Response example is shown in XML format here even though REST API returns JSON format:
<workitem_humanresource><workitem_humanresource parent_type="workitem" parent_id="158282" type="workitem_humanresource" id="149342" sub_type="" _title="Della Miller" href="/v1/o/workitem_humanresource/149342"/></workitem_humanresource>

Create workitem_humanresource:

POST https:/.../v1/o/workitem/158282/workitem_humanresource

Request data [See properties]:

{"workitem_humanresource": [ { "parent_type" : "workitem", "parent_id" : 158282, "property_a" : "value-a", "property" : "See workitem_humanresource properties", "property_z" : "value-z" } ] }

Response codes:

Update workitem_humanresource:

PUT https:/.../v1/o/workitem_humanresource/{id}

Request data [See properties]:

{"workitem_humanresource": [ { "id" : 149342, "property_a" : "value-a", "property" : "See workitem_humanresource properties", "property_z" : "value-z" } ] }

Response codes:

  • 400 - Client error
  • 500 - Server error
  • 200 - OK Content returned [See response data]
  • 204 - OK No content
  • 404 - Not found

Delete workitem_humanresource:

DELETE https:/.../v1/o/workitem_humanresource/{id}

The "id" in JSON payload is required to match the {id} in the URI to ensure that deletion requests are intended and safe

{"workitem_humanresource": [{"id":149342}]}

Response codes:

  • 400 - Client error
  • 500 - Server error
  • 204 - OK
  • 404 - Not found

Response data:
{}