I figure this out myself. Here are the code I used for getting pull request commits, hopefully it can be useful for others.
CommitsBetweenRequest.Builder builder = new CommitsBetweenRequest.Builder(pullRequest);
CommitsBetweenRequest cbr = builder.build();
Page<Commit> commits = commitService.getCommitsBetween(cbr, new PageRequestImpl(0, SEARCH_PAGE_SIZE));
SortedMap<Integer, Commit> commit_map = commits.getOrdinalIndexedValues();
Also the Bitbucket REST APIs are to be accessed from outside of Bitbucket. It doesn’t like to be used inside the Bitbucket. This could explain the error I received when try to use it inside the plugin.