I'm sure you are using Spring data with the @RepositoryRestResource annotation
@RepositoryRestResource public interface XX extends CrudRepository<AA, String>
If you want to remove the default HAL behavior, you can add the following annotation parameter
@RepositoryRestResource(exported = false) public interface XX extends CrudRepository<AA, String>
Above is the Spring Data REST configuration to show only rest endpoints for resources in the parent project, without explicitly annotating each repository in the dependency project.
According to the document
Hiding specific repositories, query methods, or fields You might not need a specific repository, the query method in the repository, or the field of your object for export. Examples include hiding fields such as a password on a user object or similar sensitive data. To tell the exporter not to export these elements, annotate them with @RestResource and set exported = false.
For example, to skip repository export:
@RepositoryRestResource(exported = false) interface PersonRepository extends CrudRepository<Person, Long> {}
source share