<?xml version="1.0" encoding="utf-16"?>
<berkeResponse status="ok" responseCode="200">
<department parentSourceDepartmentId="companyRootId" sourceDepartmentId="companyRootId" name="Your Company" description="Your company's department tree can be n-levels deep" isEnabled="true">
<department parentSourceDepartmentId="companyRootId" sourceDepartmentId="department1Id" name="Department 1" description="Departments can contain teams, sub-departments, subsidiaries, etc." isEnabled="true">
<department parentSourceDepartmentId="department1Id" sourceDepartmentId="department1Team1Id" name="Department 1 Team 1" description="" isEnabled="false" />
<department parentSourceDepartmentId="department2Id" sourceDepartmentId="department1Team2Id" name="Department 2 Team 1" description="" isEnabled="true" />
</department>
<department parentSourceDepartmentId="companyRootId" sourceDepartmentId="department2Id" name="Department 2" description="Departments can also contain locations." isEnabled="true">
<department parentSourceDepartmentId="department1Id" sourceDepartmentId="department2Location1" name="Department 2 Location #1" description="" isEnabled="true" />
<department parentSourceDepartmentId="department2Id" sourceDepartmentId="department2Location2" name="Department 2 Location #2" description="" isEnabled="false" />
<department parentSourceDepartmentId="department2Id" sourceDepartmentId="department2Location3" name="Department 2 Location #3" description="" isEnabled="true" />
</department>
<department parentSourceDepartmentId="companyRootId" sourceDepartmentId="department3Id" name="Department 3" description="Department 3 has no child departments." isEnabled="false" />
</department>
</berkeResponse>
{
"department": {
"childDepartments": [
{
"childDepartments": [
{
"childDepartments": [],
"parentSourceDepartmentId": "department1Id",
"sourceDepartmentId": "department1Team1Id",
"name": "Department 1 Team 1",
"description": "",
"isEnabled": false
},
{
"childDepartments": [],
"parentSourceDepartmentId": "department2Id",
"sourceDepartmentId": "department1Team2Id",
"name": "Department 2 Team 1",
"description": "",
"isEnabled": true
}
],
"parentSourceDepartmentId": "companyRootId",
"sourceDepartmentId": "department1Id",
"name": "Department 1",
"description": "Departments can contain teams, sub-departments, subsidiaries, etc.",
"isEnabled": true
},
{
"childDepartments": [
{
"childDepartments": [],
"parentSourceDepartmentId": "department1Id",
"sourceDepartmentId": "department2Location1",
"name": "Department 2 Location #1",
"description": "",
"isEnabled": true
},
{
"childDepartments": [],
"parentSourceDepartmentId": "department2Id",
"sourceDepartmentId": "department2Location2",
"name": "Department 2 Location #2",
"description": "",
"isEnabled": false
},
{
"childDepartments": [],
"parentSourceDepartmentId": "department2Id",
"sourceDepartmentId": "department2Location3",
"name": "Department 2 Location #3",
"description": "",
"isEnabled": true
}
],
"parentSourceDepartmentId": "companyRootId",
"sourceDepartmentId": "department2Id",
"name": "Department 2",
"description": "Departments can also contain locations.",
"isEnabled": true
},
{
"childDepartments": [],
"parentSourceDepartmentId": "companyRootId",
"sourceDepartmentId": "department3Id",
"name": "Department 3",
"description": "Department 3 has no child departments.",
"isEnabled": false
}
],
"parentSourceDepartmentId": "companyRootId",
"sourceDepartmentId": "companyRootId",
"name": "Your Company",
"description": "Your company's department tree can be n-levels deep",
"isEnabled": true
},
"status": "ok",
"response": null,
"responseCode": "200"
}
<?xml version="1.0" encoding="utf-16"?>
<berkeResponse status="[!=ok]" response="[Error Message], [Parameter]=[[ParameterValue]]" responseCode="[!=200]" />
{
"status": "[!=ok]",
"response": "[Error Message], [Parameter]=[[ParameterValue]]",
"responseCode": "[!=200]"
}
|
Most API exceptions are due to invalid parameters. Review the notes below each parameter as well as
the output and HTTP response code from the error message. If all values
are appropriate, the failure is likely authentication-related. Authentication failure
types include, but are not limited to,:
- Too many failed calls
- Maximum per minute or per day API calls reached
- API call made via insecure connection
- Invalid API key
- API is not enabled for target company
- API is disabled for all companies (typically during maintenance)
- Company is inactive or expired
- Invalid username
- User is inactive or expired
|
)
|
Requested ParentSourceDepartmentId could not be found or was longer than 50 characters. Try leaving this value empty to retrieve the entire department tree.
|
|
Most API exceptions are due to invalid parameters. Review the notes below each parameter as well as
the output and HTTP response code from the error message. If all values
are appropriate, the failure is likely authentication-related. Authentication failure
types include, but are not limited to,:
- Too many failed calls
- Maximum per minute or per day API calls reached
- API call made via insecure connection
- Invalid API key
- API is not enabled for target company
- API is disabled for all companies (typically during maintenance)
- Company is inactive or expired
- Invalid username
- User is inactive or expired
- Unknown sourceJobId - check your API job assignments in the primary Berke customer site
- Invalid assessment complete action
<?xml version="1.0" encoding="utf-16"?>
<berkeResponse status="[!=ok]" response="[API Method] API method requests exceeded burst limit of 120 occurrences within 60000 milliseconds. Excess requests occurred 3 times from [2024-11-22T09:05:39.4017938Z] to [2024-11-22T09:05:40.0017938Z]." responseCode="429" callDeniedDateTime="2024-11-22T09:05:40.1017938Z" callExpiresOnCompletion="true" countCallsExceeded="3" estimatedMillisecondsToNextAllowedCall="423" firstCallDeniedDateTime="2024-11-22T09:05:39.8017938Z" isDailyLimit="false" maximumCallsPerTimeFrame="120" timeFrameMilliseconds="60000" />
{
"callDeniedDateTime": "2024-11-22T09:05:40.1017938Z",
"callExpiresOnCompletion": true,
"countCallsExceeded": 3,
"estimatedMillisecondsToNextAllowedCall": 423,
"firstCallDeniedDateTime": "2024-11-22T09:05:39.8017938Z",
"isDailyLimit": false,
"maximumCallsPerTimeFrame": 120,
"timeFrameMilliseconds": 60000,
"status": "[!=ok]",
"response": "[API Method] API method requests exceeded burst limit of 120 occurrences within 60000 milliseconds. Excess requests occurred 3 times from [2024-11-22T09:05:39.4017938Z] to [2024-11-22T09:05:40.0017938Z].",
"responseCode": "429"
}
API requests exceeded the maximum allowed per time-frame or the maximum allowed at any point in time.
API throttle limits are set per-company. Please login and return to this area to see
your company's specific throttle configuration.
Your application can use the following API method response information to determine its course of action when HTTP status code 429
is returned by an API method call:
-
callDeniedDateTime: The date and time that the API method call was denied execution.
-
callExpiresUponCompletion: If this value is true then too many simultaneous calls occurred to a particular group of API methods.
If this value is false then too many requests occurred for a particular time frame (daily or short-term).
-
countCallsExceeded: The count of calls that exceeded the maximum number of allowed API calls for the time frame.
-
estimatedMillisecondsToNextAllowedCall: The estimated number of milliseconds, from the callDeniedDateTime, before an API
call will be allowed to execute. If callExpiresUponCompletion is true then this value will be zero as the time is dependent on
numerous factors.
If callExpiresUponCompletion is false then this value indicates the amount of time your application(s) should wait before
attempting to make the same API method call. If a daily API call limit has been exceeded the this value indicates the amount of time
your application(s) should wait before calling any API method.
-
firstCallDeniedDateTime: The date and time that the first call, of potentially many calls, was denied for the time frame.
For example, if an application was denied ten calls within a time frame then firstCallDeniedDateTime
indicates date and time that the first of the ten calls was denied.
-
isDailyLimit: If this value is true then the response indicates that the maximum number of API methods calls for the current day has been exceeded. If this
value is false then the response indicates that the maximum number of API method calls for a time frame, other than daily, has been exceeded.
-
maximumCallsPerTimeFrame: Indicates the maximum number of times an API method can be called for daily, short-term or simultaneous call limits.
-
timeFrameMilliseconds: Indicates the number of milliseconds in which maximumCallsPerTimeFrame API method calls is allowed.
|