URL : v3/api/dependency/{type}
Description : Type can be any of the following
- help-topics
- priorities
- organizations
- users
- user-types
- types
- sources
- statuses
- sla-plans
- agents
- teams
- agents-teams(for getting both agents as well as teams)
- labels
- tags
- departments
- languages
- rating-types
- country-codes
- locations
- client-tickets(for getting client tickets)
- ticket-status-tabs (for getting client tickets status details)
Method : GET
Query Parameters:
Parameter | Type | Optional/Required | Description |
search-query | string | Optional | The string that is required to be searched.
If it is not passed in the parameter, all the records (maximum 10, if limit parameter is also not passed) will be returned. |
limit | integer | Optional | Number of records that is needed to be fetched from DB.
If it is not passed, first 10 records will be returned. |
strict-search | string | Optional | Exact string that is required to be searched. |
meta | boolean | Optional | In some scenario, we need more information from a table then just ‘id’ and ‘name’. In that case meta will be passed as true.
For eg. In case of user, at some places we only need just id and name, but at some places we need profile_pic and email also. So, for getting more detailed information meta must be passed as true. Possible use cases:
Fields in bracket are the extra fields which will be returned in the response when meta is passed as true. |
config | boolean | Optional | In admin panel, certain fields (such as status) are configured so, for that purpose all the fields are required irrespective of that field is private/public or active/inactive.
But in agent panel, only those fields are required which are activated through admin panel. So, if this parameter is passed as true, backend will send all the rows and columns available in the table. |
supplements | array/string | Optional | Any extra parameter that is required in the API can be passed to this parameter.
For eg. for help-topic linking with department, array helptopic-ids can be passed to this parameter. |
Response:
- When meta is not passed or passed as false ( for new-inbox feature only meta is required )
{ "success":true, "data":{ "types":[//type can be any value as mentioned in the description above { "id":1, "name":"type-name 1" }, { "id":2, "name":"type-name 2" } ] } }
- When meta is passed as true
//same as above + css properties (will be used to show icons as css properties for parameters like status)
- When config is passed as true
//all columns from the DB (will be used in admin panel for configuration purpose)