> For the complete documentation index, see [llms.txt](https://olavo-moreira.gitbook.io/studies/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://olavo-moreira.gitbook.io/studies/workshop-mongodb/endpoints/posts/fullsearch-query-methods/controller.md).

# Controller

```java
@GetMapping("/fullSearch")
public ResponseEntity<List<PostDTO>> fullSearch(
        @RequestParam("text") String text,
        @RequestParam("start") String start,
        @RequestParam("end") String end) {

    List<PostDTO> posts = postService.fullSearch(text, start, end);
    if (posts.isEmpty()) {
        return ResponseEntity.notFound().build();
    }
    return ResponseEntity.ok(posts);
}
```
