@ebrahemsamer I really don’t know what you’re “SEO person” is talking about. You have a search endpoint that accepts a parameter, and returns matching items. There’s nothing wrong with that.
Why would a search engine think this is spam? As long as you’re returning appropriate results for queries, then that’s how search endpoints work. Search engines aren’t going to penalise you for that.
@martinbean
Sorry I did not mean spam.... I mean it will be a problem with crawlers because script keep requesting the same url so this may make a problem in indexing the website may be...
@ebrahemsamer No, it won’t. That’s literally the entire point of query strings: to show different content based on a query.
As long as you’re showing appropriate results for query in your search endpoint, then it’s functioning as it should and search engines will quite happily index that content.
If you are concerned, you also have the option to rate limit requests. No user will submit more than one search every three seconds for instance. You can also have the search form protected with csrf so that the scraper has to have established a session in order to make a request.
The advice from the 'consultant' is also rubbish in that search engines have no idea what traffic your site is getting from bogus search terms. They are not listening to all the requests to your site?