Search Applications

Details#

This endpoint is used to search company Applications. It supports pagination and different search filters.

URL : /applications/company/search

Method :

GET

Authentication

Auth is required an Admin to search applications.

Parameters#

limit#

Query Parameter
Optional
Number

Default: 100
Minimum: 1
Maximum: 100

Limits the number of applications returned.

offset#

Query Parameter
Optional
Number

Default: 0
Minimum: 0

Number of applications to skip.

companyName#

Query Parameter
Optional
String

Filters the applications by the name of the respective companies.

state#

Query Parameter
Optional
Array

Array of strings which filters the application by their state.

caution

Must be a valid state (currently ["PENDING", "APPROVED", "REJECTED"]).

submissionDateFrom#

Query Parameter
Optional
Date (ISO8601 String)

Filters the applications by their submission date, by removing the ones before the specified date.

submissionDateTo#

Query Parameter
Optional
Date (ISO8601 String)

Filters the applications by their submission date, by removing the ones after the specified date.

sortBy#

Query Parameter
Optional
String

String describing how the applications should be sorted. The default is to sort by submittedAt descending.

caution

It must follow the following format: field:(desc|asc)?[,field:(desc|asc)?]*

Each field must be one of ["email", "password", "companyName", "motivation", "submittedAt", "approvedAt" , "rejectedAt", "rejectReason"]

Response#

applications#

Response Field
Array

Array of objects containing the applications found by the search.

docCount#

Response Field
Number

Number of results found by the search.

Request examples#

Example 1 - No filters (Logged-in as Admin)#

Code :

200 OK

/applications/company/search

Example 2 - With Filters (Logged-in as Admin)#

Code :

200 OK

/applications/company/search?state=PENDING&state=APPROVED&sortBy=companyName

Example 3 - Logged-in as Company#

Code :

401 UNAUTHORIZED

/applications/company/search

Example 4 - Invalid State#

Code :

422 UNPROCESSABLE ENTITY

/applications/company/search?state=INVALID

Example 5 - Invalid SortBy field#

Code :

422 UNPROCESSABLE ENTITY

/applications/company/search?sortBy=field

Example 6 - Invalid SortBy Format#

Code :

422 UNPROCESSABLE ENTITY

/applications/company/search?sortBy=companyName:invalid