Check Collaborateur Access
Description
This API endpoint allows you to know whether a collaborateur has some company file in his portefeuille.
Request Methods
POST: Check if a collaborateur has a company file in his portefeuille.
The base URL on cegid Developers :
POST /checkCollaborateurAccess
Request URL:
POST https://api.cegid.com/loop-api-publiques/checkCollaborateurAccess
Request Body:
The request body for the POST method should include the following fields:
Field Name | Type | Description | Required |
---|---|---|---|
domain |
string | The collaborateur's domain. | YES |
codeDossier |
string | The code Dossier. | YES |
login |
string | The collaborateur's login | YES |
Example POST Request:
POST https://api.cegid.com/loop-api-publiques/checkCollaborateurAccess
Example POST Request Body:
{
"domain": "CEGID",
"codeDossier": "A123",
"login": "collaborateur@devcegidloop.onmicrosoft.com"
]
Example POST Responses:
A successful POST request should return a response with the status code 200 and a body containing the property accessAllowed set to true or false.
Response body
{
"accessAllowed": true
}
When an HTTP POST request is unsuccessful, it should return a response with either a 400, 403, or 500 status code, along with a response body containing the error object.
Response body
{
"stack": "MicroserviceError[CollaborateurBadLogin]: The collaborateur collaborateur@devcegidloop.onmicrosofts.com is not found.",
"message": "The collaborateur collaborateur@devcegidloop.onmicrosofts.com is not found.",
"code": "CollaborateurBadLogin",
"error": null,
"id": "4dc23120-e89d-4d52-8daa-ff4e0780c55b",
"name": "MicroserviceError[CollaborateurBadLogin]",
"statusCode": 400,
"requestId": "7ff650d4-451f-4ab6-9f77-d2b28fa5c015"
}
The following are the supported values for the field code (in case of an unsuccessful request)
Error code | Description |
---|---|
CollaborateurMalformedParameter | The provided parameter must be a string. |
CollaborateurBadLogin | The collaborateur is not found. |
CollaborateurInactive | The collaborateur is not active. |
CollaborateurBadDomain | The provided domain is invalid or malformed. |
CollaborateurBadCodeDossier | The dossier is not found. |
CollaborateurQueryError | An error occurred while the request was being processed. |