Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

103
Visualizações
Practice with API Endpoints

I'm practicing writing back-end code to handle the routing for an API endpoint using Node, Express, PostgreSQL, and Knex. This is the ERD (Entity Relationship Diagram) of the Call Center Database.

https://i.imgur.com/4xkosHp.png

The API endpoints here is for /tickets in the following two links:

tickets.controller.js: https://pastebin.com/Zh31H7uW

tickets.router.js: https://pastebin.com/tauBein4

I'm trying to meet this criteria:

  • get info about the ticket based on id
  • create a ticket
  • get info about a ticket, including the employee associated with the ticket. There is also a controller and router file associated with this through employees which can be referenced, but it does not need to be organized.

employees.controller.js: https://pastebin.com/jpkaX0VJ

employees.router.js: https://pastebin.com/nyHMvthy

Did I organize the code in tickets.controller.js and tickets.router.js to meet the above criteria for the API endpoints and follow best practices? Open to any and all feedback for this. Thank you!

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda