Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

162
Vistas
json-server : how to do complex queries

I have a set of users each with a team id.

I have a set of records which are 'owned' by a user.

e.g.

users: [
{ id: 1, teamId: 1234 },
...
],
records: [
{ id: 1, usersId: 1 },
....
]

Can I issue an API call to json-server that either

  1. gets all records owned by users with a specific teamid?

    /records?users.teamId=1234

    According to the API guide I've found, this should work but doesn't. Adding _expand=users onto the query does seem to show the tables are linked.

  2. alternatively gets all records if I provide a list of userids to filter on?

    /records?usersId=[1,2,3,4]

Is there any complete documentation on what you can do on the json-server API?

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda