Users

On DoYouBuzz Showcase, the user id matches the DoYouBuzz user id

If you need to direct a manager to a Showcase user's profile page, you should use this URL : http://showcase.doyoubuzz.com/a/user/{dybid}/profile

Get all users for your company

GET /users

URL parameters

Name Description Type
filter Specify the kind of users you want to retrieve (user, candidate, admin of manager) u | c | a |m
page Page number (results are paginated) Integer

Example

GET /users

{
   "users": [
      {
         "id": 1,
         "username": "will.adama@bg.com",
         "email": "will.adama@bg.com",
         "firstname": "Will",
         "lastname": "Adama",
	 "phone": "02 40 69 73 15",
         "id_origin": "1"
      },
      {
         "id": 2,
         "username": "laura.roslin@bg.com",
         "email": "laura.roslin@bg.com",
         "firstname": "Laura",
         "lastname": "Roslin",
         "id_origin": "2"
      },
      {
         "id": 3,
         "username": "brendan.constanza@bg.com",
         "email": "brendan.constanza@bg.com",
         "firstname": "Brendan",
         "lastname": "Constanza",
         "kind": "user",
         "id_origin": "187"
      },
      {
         "id": 4,
         "username": "alex.quartararo@bg.com",
         "email": "alex.quartararo@bg.com",
         "firstname": "Alex",
         "lastname": "Quartararo",
         "kind": "candidate",
         "id_origin": "342"
      },
      {
         "id": 5,
         "username": "margaret.edmonson@bg.com",
         "email": "margaret.edmonson@bg.com",
         "firstname": "Margaret",
         "lastname": "Edmonson",
         "kind": "user",
         "id_origin": "812"
      },
      {
         "id": 6,
         "username": "kara.thrace@bg.com",
         "email": "kara.thrace@bg.com",
         "firstname": "Kara",
         "lastname": "Thrace",
         "kind": "user",
         "id_origin": "1664"
      },
      {
         "id": 7,
         "username": "galen.tyrol@bg.com",
         "email": "galen.tyrol@bg.com",
         "firstname": "Galen",
         "lastname": "Tyrol",
         "kind": "user",
         "id_origin": "156"
      },
      {
         "id": 8,
         "username": "samuel.anders@bg.com",
         "email": "samuel.anders@bg.com",
         "firstname": "Samuel",
         "lastname": "Anders",
         "kind": "143"
      },
      {
         "id": 9,
         "username": "billy.keikeya@bg.com",
         "email": "billy.keikeya@bg.com",
         "firstname": "Billy",
         "lastname": "Keikeya",
         "kind": "user",
         "id_origin": "111"
      },
      {
         "id": 10,
         "username": "gaius.baltar@bg.com",
         "email": "gaius.baltar@bg.com",
         "firstname": "Gaïus ",
         "lastname": "Baltar",
         "kind": "user",
         "id_origin": "786"
      },
      {
         "id": 11,
         "username": "tom.zarek@bg.com",
         "email": "tom.zarek@bg.com",
         "firstname": "Tom ",
         "lastname": "Zarek",
         "kind": "candidate",
         "id_origin": "435"
      },
      {
         "id": 18,
         "username": "lee.adama@bg.com",
         "email": "lee.adama@bg.com",
         "firstname": "Lee",
         "lastname": "Adama",
         "kind": "candidate",
         "id_origin": "1664"
      }
   ],
   "total": 12
}

Search for a user

GET /users/search

The user search will search all the user's first name, last name and email address matching the given search term.

URL parameters

Name Description Type
term Search term

Example

GET /users/search?term=will

{
	[
		{
			"username":"will.adama@bg.com",
			"email":"will.adama@bg.com",
			"id_origin":"124",
			"firstname":"Will",
			"lastname":"Adama",
			"phone": "02 40 69 73 15",
			"id":2
		},
		{
			"username":"other@bg.com",
			"email":"other@bg.com",
			"id_origin":"147",
			"firstname":"William",
			"lastname":"Roslin",
			"id":18
		},
	]
}

Get a single user information

GET /users/:id

URL parameters

Name Description Type
isIdOrigin (optional). Default to 0. Set this parameter to "1" if the id your are sending is the ID on your system. It works only if you have setup a SSO in your Showcase account boolean

Example

GET /users/6

{
    "id": 6,
    "username": "kara.thrace@bg.com",
    "email": "kara.thrace@bg.com",
    "firstname": "Kara",
    "lastname": "Thrace",
    "phone": "555 666 7777",
    "kind": "user",
    "id_origin": "1664"
}

Get a user's CV

GET /users/:id/cv

Example

GET /users/6/cv

[
	{ 
		"title": "Pilote de Viper", 
		"completion": 0.42, 
		"anonymized": false, 
		"main": true, 
		"id": 2679, 
		"public_url": "http://cv.battlestar-gallactica.cf/Piq5h6dBT7KPccWvsP5UBQ/-Xv63R1jNVGCE_osaJ9rATpbKFx4", 
		"private_url": "http://cv.battlestar-gallactica.cf/Piq5h6dBT7KPccWvsP5UBQ/-Xv63R1jNVGCE_osaJ9rATpbKFx4", 
		"created": "2013-03-07T11:08:42+0100", 
		"indexed": true, 
		"protected": false, 
		"updated": "2013-03-07T12:30:21+0100", 
		"language": "fr_FR" 
	},
	{ 
		"title": "Pilote de Viper", 
		"completion": 0.42, 
		"anonymized": true, 
		"main": false, 
		"id": 2680, 
		"public_url": "http://cv.battlestar-gallactica.cf/Piq5h6dBT7KPccWvsP5UBQ/-Xv63R1jNVGCE_osaJ9rATpbKFx4", 
		"private_url": "http://cv.battlestar-gallactica.cf/Piq5h6dBT7KPccWvsP5UBQ/-Xv63R1jNVGCE_osaJ9rATpbKFx4", 
		"created": "2013-03-07T11:24:17+0100", 
		"updated": "2013-03-07T14:48:35+0100", 
		"language": "fr_FR" 
	}
]

Get a user's tags

GET /users/:id/tags

Example

GET /users/6/tags/

[
	{
		id: 31,
		id_origin: 0,
		title: "Commercial",
		type: 0,
		translations: [
			{
				id: 102,
				locale: "en",
				field: "title",
				content: "Business Development"
			}
		]
	},
	{
		id: 214,
		id_origin: 0,
		title: "Développement",
		type: 0,
		translations: [
			{
				id: 103,
				locale: "en",
				field: "title",
				content: "Development"
			}
		]
	}
]

Logout a user

DELETE /users/:id/logout

If a user is connected on DoYouBuzz Showcase, this method will logout the user.

URL parameters

Name Description Type
isIdOrigin (optional). Default to 0. Set this parameter to "1" if the id your are sending is the ID on your system. It works only if you have setup a SSO in your Showcase account boolean

Example

DELETE /users/6/logout

	{ success: true }

Associate tags on a user

PUT /users/:id/associateTags

Body parameters

Name Description Type
tags Id of the tag to associate on the current user or array of ids integer | Array
reset (optional) You can use this option to indicates you want to reset all the current tags associated to the user before applying the one sent in the request Boolean

Example

Request

PUT /users/1/associateTags

tags[]=16&tags[]=266&tags=271&reset=1

Response

You get a 204 response code (request successful) if the association succeeded

Disassociate tags on a user

PUT /users/:id/tags

Name Description Type
tags Id of the tag to disassociate on the current user integer | Array

Example

Request

PUT /users/6/disassociateTags

tags[]=16&tags[]=266&tags=271

Response

You get a 204 response code (request successful) if the disassociation succeeded

Changer User Kind

PUT /users/:id/kind

Name Description Type
kind New kind for the user string "user", "candidate", "other"

Example

Request

PUT /users/777/kind

kind=candidate

Response

You get a 204 response code (request successful) if user's kind have been changed

Set User's manager

PUT /users/:id/manager

Name Description Type
managerId New manager for the user integer

Example

Request

PUT /users/66709/manager

managerId=36789

Response

You get a 204 response code (request successful) if user's manager has been changed