# Retrieve all codes Endpoint: GET /code Version: 1.0 Security: bearer ## Query parameters: - `title` (string) The title of the code Example: "Nutritional Counseling" - `page` (number) Page number (0-based) - `pageSize` (number) Number of items per page Example: 10 - `sortBy[0][field]` (string) First sort field Enum: "id", "code", "title", "category", "categoryCode", "createdAt", "updatedAt" - `sortBy[0][dir]` (string) First sort direction Enum: "asc", "desc" - `sortBy[1][field]` (string) Second sort field Enum: "id", "code", "title", "category", "categoryCode", "createdAt", "updatedAt" - `sortBy[1][dir]` (string) Second sort direction Enum: "asc", "desc" ## Response 200 fields (application/json): - `data` (array, required) Array of codes - `data.title` (string, required) The title of the code Example: "Medical Code Title" - `data.code` (string, required) The unique code associated with the title Example: "M1234" - `data.category` (string, required) The category of the code Example: "Dental" - `data.categoryCode` (string, required) The unique code for the category Example: "D4567" - `data.isEnabled` (boolean) Indicates whether the code is enabled Example: true - `data.id` (number, required) The ID of the code to be updated Example: 123 - `data.createdAt` (string, required) The date and time the code was created Example: "2021-05-01T12:00:00Z" - `data.updatedAt` (string, required) The date and time the code was last updated Example: "2021-05-01T12:00:00Z" - `meta` (object, required) Pagination metadata - `meta.page` (number, required) Current page number (0-based) - `meta.pageSize` (number, required) Number of items per page Example: 10 - `meta.total` (number, required) Total number of items Example: 150 - `meta.totalPages` (number, required) Total number of pages Example: 15 - `meta.hasNext` (boolean, required) Whether there is a next page Example: true - `meta.hasPrevious` (boolean, required) Whether there is a previous page ## Response 401 fields (application/json): - `message` (string, required) Error message indicating unauthorized access. Example: "Unauthorized" - `statusCode` (number, required) HTTP status code for unauthorized access. Example: 401