It seems you mixed things up a bit :)
This query works for me and orders by id
/rest/api/content/search?cql=type=page+and+text~"apos"+order+by+id+asc&expand=body.storage
Lets see the problems one by one:
- filter=order+by+asc This does not work, as it is part of the cql syntax
- order+by+asc You have to tell which field should be ordered by (e.g. id or type)
- text~%22apos%22&type=page Do not separate with "&", as it is interpreted as 2 query params and not as single cql command. You have to write the key-word "and" to combine several terms.
I hope this solves your issue. Ordering by type would not have any affect in your example as you only search for pages.
Find further information here: