BCI API Support Reference (version 1.0)


Master Data

Roles



URL path: REST Request SOAP Request Base
http://api.bciaustralia.com/rest/roles.json http://api.bciaustralia.com/roles.cfc?wsdl http://api.bciaustralia.com/roles.cfc
Serializable: Yes
Properties:
Methods: getByPK, getByQuery


getByPK
remote Struct getByPK ( required numeric roleid, string fields="", required string token )

Get BCI specific role information (passing a roleid).

Methods of access are:

SOAP: http://api.bciaustralia.com/roles.cfc?wsdl&method=getByPK&roleid={roleid}(&returnFormat=wddx / &returnFormat=json)

REST: http://api.bciaustralia.com/rest/roles/{roleid}(.json / .xml)

Output: Structure


Parameters:
   roleid: numeric, required - roleid of the specific role information requested
   fields: string, optional - passing valid field names for the return structure. Valid fields : ROLEID,ROLE_GROUPID,ROLES
   token: string, required - allocated token for current login session

getByQuery
remote Array getByQuery ( string roleid, string role, string fields="", required string token )

Get BCI Role Information (either as a list or using a simple search passing role name or list of roleids).

Methods of access are:

SOAP: http://api.bciaustralia.com/roles.cfc?wsdl&method=getByQuery(&returnFormat=wddx / &returnFormat=json)

REST: http://api.bciaustralia.com/rest/roles(.json / .xml)

Output: Array
Parameters:
   roleid: string, required - roleid of the specific role information requested, can be passed as a comma seperated list of role IDs
   role: string, optional - role name being searched, matches using exact string search (case insensitive)
   fields: string, optional - passing valid field names for the return structure. Valid fields : ROLEID,ROLE_GROUPID,ROLES
   token: string, required - allocated token for current login session

Fields
Selectable fields for role information
ROLEIDLONG
ROLE_GROUPIDLONG
ROLESSTRING(1000)
SORT_ORDERINTEGER
IMPORTANTINTEGER
Sample Output - getByPK() - XML
<wddxPacket version='1.0'> <header/> <data> <struct> <var name='ROLES'><string>Master Planner</string></var> <var name='ROLE_GROUPID'><number>3.0</number></var> <var name='ROLEID'><number>6.0</number></var> </struct> </data> </wddxPacket>
Sample Output - getByQuery() - XML
<wddxPacket version='1.0'> <header/> <data> <array length='1'> <struct> <var name='ROLES'><string>Master Planner</string></var> <var name='ROLE_GROUPID'><number>3.0</number></var> <var name='ROLEID'><number>6.0</number></var> </struct> </array> </data> </wddxPacket>