Is it possible to query elements based on string fragments?

System Information
  • Strapi Version: v3.4.0
  • Operating System: Linux raspberrypi 5.4.79-v7+
  • Database: (not sure. the one that comes default with a fresh strapi install)
  • Node Version: v10.21.0
  • NPM Version: 6.14.10
  • Yarn Version: none

Dear strapi community!
I’m quite new to strapi and building a practice project containing a vehicle database.
My question is if I can query (fetch from frontend app) entries based on a fragment of a string?

-Example1:
-query:
/vehicles?brand=Opel
-result:
all vehicles which brand is “Opel”

-Example2:
-query:
/vehicles?brand=e
-result:
all vehicles which brand is strictly “e”. Which there are none, but I’d like to find all entries which name contain “e” like “Opel”, “Renault”, “Citroen” …

Is there a way to do it in a default strapi app or I have to modify the backend for it to work?

Thank you for the help!

Fortunately one dear friend answered my noobish question. -,- If anyone wonders it’s in the documentation:
https://strapi.io/documentation/developer-docs/latest/content-api/parameters.html#available-operators

1 Like