NOTE: User must me logged in as agent or admin to access this API
URL : service-desk/api/contract-list
Method : GET
Query Parameters :
Parameter | Type | Possible Values | Required/Optional | Description |
sort-field | String | name, contract_number, expiry | Optional | Field name to sort |
sort-order | String | asc, desc | Optional | Sorting order either ascending or descending |
search-query | String | any | Optional | Keyword to be searched in contract list page |
limit | Integer | any | Optional | Number of records to be displayed in each page |
page | Integer | any | Optional | Page number |
contract_ids | Array | Array of integers | Optional | Array of contract ids |
contract_type_ids | Array | Array of integers | Optional | Array of contract type ids |
approver_ids | Array | Array of integers | Optional | Array of contract approver ids |
vendor_ids | Array | Array of integers | Optional | Array of vendor ids |
license_type_ids | Array | Array of integers | Optional | Array of license type ids |
status_ids | Array | Array of integers | Optional | Array of status ids |
renewal_status_ids | Array | Array of integers | Optional | Array of renewal status ids |
owner_ids | Array | Array of integers | Optional | Array of owner ids |
identifiers | Array | Array of identifiers(strings) | Optional | Array of identifiers |
cost_begin | Unsigned Integer | Any positive value | Optional | Contract Cost |
cost_end | Unsigned Integer | Any positive value | Optional | Contract Cost |
notify_in_days_begin | Unsigned Integer | Any positive value | Optional | Contract Notify before in days |
notify_in_days_end | Unsigned Integer | Any positive value | Optional | Contract Notify before in days |
contract_start_date | String | DateTime range for planned_start_date in format start_date~end_date (YYYY-MM-DD HH:MM:SS) | Optional | Contract start time by which contracts needs to be filtered |
contract_end_date | String | DateTime range for planned_end_date in format start_date~end_date (YYYY-MM-DD HH:MM:SS) | Optional | Contract end time by which contracts needs to be filtered |
asset_ids | Array | Array of integers | Optional | Array of asset ids |
notify_agent_ids | Array | Array of integers | Optional | Array of change ids |
created_at | String | DateTime range for created_at in format start_date~end_date (YYYY-MM-DD HH:MM:SS) | Optional | Contract created time by which contracts needs to be filtered |
updated_at | String | DateTime range for updated_at in format start_date~end_date (YYYY-MM-DD HH:MM:SS) | Optional | Contract updated time by which contracts needs to be filtered |
Success Response:
{ "success": true, "data": { "current_page": 1, "first_page_url": "http://faveo-helpdesk-advance/public/service-desk/api/contract-list?page=1", "from": 1, "last_page": 1, "last_page_url": "http://faveo-helpdesk-advance/public/service-desk/api/contract-list?page=1", "next_page_url": null, "path": "http://faveo-helpdesk-advance/public/service-desk/api/contract-list", "per_page": 10, "prev_page_url": null, "to": 2, "total": 2, "contracts": [ { "id": 1, "name": "Lenovo Laptop", "cost": 34534, "expiry": "2020-03-07 10:32:00", "contract_status": { "id": 3, "name": "active" }, "contract_renewal_status": { "id": 12, "name": "extended" }, "vendor": { "id": 1, "name": "Lenovo" }, "contract_type": { "id": 2, "name": "Software License" }, "contract_number": "#CNTR-1" }, { "id": 2, "name": "Dell Laptop", "cost": 34534, "expiry": "2020-04-07 10:32:00", "contract_status": { "id": 3, "name": "active" }, "contract_renewal_status": { "id": 12, "name": "extended" }, "vendor": { "id": 1, "name": "Dell" }, "contract_type": { "id": 2, "name": "Software License" }, "contract_number": "#CNTR-2" } ] } }