This documentation is about a version that is out of support, here is the latest documentation version.

How about downloading a newer, supported version?

Custom user info API

The Custom user info Rest API allows to manage the custom information of the Bonita’s users.

Definition

Description

Manage the custom user definitions.

Identifier

Simple, the ID of the object (a long value)

Representation

{
  "id":"_id of definition_",
  "description":"_definition description_",
  "name":"_definition name_"
}

Methods

The methods used for this resource are:

  • GET

  • POST

  • DELETE

Add a new definition

Use the method POST to add a new definition.

  • URL
    http://localhost:8080/bonita/API/customuserinfo/definition
    Example: Add a definition called skill.

  • Method
    POST

  • Data Params

  • Request Payload
    JSON representation of definition, without id

    {
      "name": "skill",
      "description": "code slayer"
    }
  • Success Response

    • Code: 200

    • Payload:
      JSON representation of complete definition including generated id

      {
        "id":"101",
        "description":"code slayer",
        "name":"skill"
      }

Delete a definition

Use the DELETE method to delete an existing definition.

  • URL
    http://localhost:8080/bonita/API/customuserinfo/definition/

  • Method
    DELETE

List the custom user information

Use a GET method to search for definitions.

There are no filters, and no search terms. All the definitions are returned.

  • URL
    /API/customuserinfo/definition

  • Method
    GET

  • Data Params

    • c: number of result per page

    • p: page number

  • Success Response

    • Code: 200

    • Payload:
      An array of definition objects

Value

Description

Manage the value of the custom user definitions.

Identifier

Simple, the ID of the object (a long value)

Representation

{
  "userId":"_id of user_",
  "value":"_content of the value_",
  "definitionId":"_id of definition_"
}

Methods

The methods used for this resource are:

  • GET

  • PUT

Associate definitions to users

Use a PUT method to associate users with custom information.

  • URL
    http://localhost:8080/bonita/API/customuserinfo/value/:userId/:definitionId
    Example: Associate the user with id = 1 with the definition with id = 2. http://localhost:8080/bonita/API/customuserinfo/value/1/2

  • Method
    PUT

  • Request Payload

    {
      "value":"customUserInfoValue"
    }
  • Success Response

    • Code: 200

Search custom user info

Use a GET method to search for custom user information associated to a specific user.

  • URL
    /API/customuserinfo/value
    Example: http://localhost:8080/bonita/API/customuserinfo/value?c=10&p=0&f=definitionId=1

  • Method
    GET

  • Data Params (Required)

    • c: number of result per page

    • p: page number

    • f : filter to apply on results with the format f={filter_name}={filter_value}
      possible filter names: userId, value, definitionId (the filter value being the custom user information definition ID)

  • Success Response
    An array of customuserinfo/value objects

    • Code: 200

User

Description

Manage the custom user info associated to a specific user

Identifier

Simple, the ID of the object (a long value)

Representation

{
  "userId":"_id of user_",
  "value":"_content of the value_",
  "definitionId":{
    "id" : "_id of definition_",
    "description" : "_definition description_",
    "name" : "_definition name_"
  }
}

Methods

The methods used for this resource are:

  • GET

Search custom user info

Use a GET method to search for custom user information associated to a specific user.

  • URL
    /API/customuserinfo/user
    Example: http://localhost:8080/bonita/API/customuserinfo/user?c=10&p=0&f=userId=1

  • Method
    GET

  • Data Params (Required)

    • c: number of result per page

    • p: page number

    • f : filter to apply on results with the format f={filter_name}={filter_value}
      the filter userId is mandatory f=userId=id

  • Success Response
    An array of customuserinfo/user objects

    • Code: 200