Thanks to Tom Cools' suggestion, I found out how to do it. In the resource class:
@Inject
private ConstraintMetaModel constraintMetaModel;
@GET
@Path("constraints")
@Produces(MediaType.APPLICATION_JSON)
public Collection<String> listConstraintNames() {
return constraintMetaModel.getConstraints().stream().map(Constraint::getConstraintRef)
.map(ConstraintRef::constraintName).collect(Collectors.toSet());
}