All Questions
1,547
questions
-1
votes
0
answers
19
views
Passport.js Error Handling Instead of throwing the error into stdout
So I Have The Current Code For Authorization (and im probably going to merge login with signup):
Strategy:
const passport = require("passport")
const { Strategy } = require("passport-local")
const ...
-1
votes
0
answers
41
views
How do I resolve client-side problem with JWT unauthorized 401
I am learning Expressjs, so today i was looking at bcrypt, jsonwebtoken. so i created this after all the readings but after login the server console has this
> [email protected] ...
0
votes
0
answers
35
views
WordPress api call from react Express server hosted on render.com timeout issue
I have a SaaS software that sends an API call over HTTP to my WordPress site on my react Express server. When the server is hosted locally, I recieve a response from my API call successfully. When I ...
0
votes
1
answer
36
views
How to show just only one of the headers in the REST API request with Pino logger?
We use Pino as logger for our REST API. We have set the pino options to redact the headers for req and res with
redact: ["req.headers", "res.headers"],
as we do not want to show ...
1
vote
1
answer
44
views
error in rendering a RESTful comments in ejs
when working with ejs and render a file of comments contains username and comment it only renders the username and the comments is not rendering at all
index of comments
const comments = [
{
...
0
votes
0
answers
16
views
Feathers.js (Express.js) service doesnt' work as REST
I'm setting up a little website using an Adaptable.io template to use on their service, but it uses frameworks i don't have knowledge (for ref, it's this package here https://adaptable.io/docs/...
0
votes
0
answers
24
views
Model Import fails ExpressJS / Sequelize fail?
Hey guys I am building a fullstack website to to learn Express , Sequelize and REST api
I have this model for a post request ``
module.exports = (sequelize, DataTypes) => {
const PaymentMethods = ...
0
votes
1
answer
39
views
2Hire Webhook URL Not Working in Express.js After Conversion from Fastify
I recently converted a Fastify application handling 2Hire webhooks to Express.js. However, the webhook URL isn't triggering as I expected.
2Hire webhooks Subscription API Doc: https://developer.2hire....
0
votes
0
answers
27
views
ExpressJS Postman POST request body is undefined [duplicate]
I am using the light version of Postman 11.0.12 on a Windows 10 server.
My body values always returns undefined.
If I use Query Params then key returns the correct value.
I suspect could it be this ...
0
votes
0
answers
25
views
Where to use Date.now function for saving data to database
I have a REST API server with Express, connects to MongoDB. Basically my app accept an input form to save some reports daily and of course the timestamp has to be that current time.
My question is, ...
0
votes
0
answers
39
views
How do you log actions on the backend?
I am trying to implement action logging on an employee management system I'm working on for my company, below is how I implemented it:
Modifying the global Request object:
declare global {
namespace ...
1
vote
1
answer
28
views
Not Getting any response From the REST api Node js
As title suggests I am not getting any response any my api rather it just keep on loading. For some reason my middleware is not triggered. For example from the below code I tried to console log random ...
0
votes
0
answers
44
views
No 'Access-Control-Allow-Origin' - CORS error
I built a tiny api to help me send emails from my front end to my gmail inbox.
I have installed cors, express and dotenv as dependencies to build this api.
const express = require("express");...
0
votes
0
answers
25
views
router. function doesn't execute after auth middleware
router.get('/', auth, function(req, res){
funcs.getBalance(req.params.user, function(err, result){
if (err) {
console.log(err);
res.status(500).json({error: err....
0
votes
0
answers
9
views
Securing AWS Cognito Signup Route
I've a ExpressJS application and I'm using AWS Cognito to provide simple signup capabilities to users.
Javascript SDK does not support a Client Secret according to docs.
My question is, how should I ...