So I have a list of posts data that looks like this: [ {user: 'Bob', country: 'USA'} {user: 'Kim', country: 'Mexico'} {user: 'Darren', country: 'Mexico'}
How do I add Roles to users in the Cloudant user database?(_users) I have not been able to sort this out using Google or Cloudant Docs. I see some mention of a
I'm creating a WebApp that has a React front end whose build is served by a node.js back end. There is some security implementation using Auth0 token validation
We can build complex queries with Mongoose with options like $lte, $gt, $ne and so on... but I'm wondering where/how we should build those queries? If I have a
Consider this code: setContext(async (req, { headers }) => { const token = await getToken(config.resources.gatewayApi.scopes) const completeHeader
I have a backend that uses Node and the Express framework and a frontend in React. The code is in Typescript. My backend uses the elastic search client to fetch
I have a business hours object in a mongoose schema that represent a date. I'm passing a json object and retrieving the to parse to Date as string. I wonder if
This is the code I took from my professor's tutorial. LoginComp is just {username: '', password: ''} const request = new Request("/users/login", { method: "
userSchema.methods.generateAuthToken = async function() { const user = this const token = jwt.sign({_id:user._id.toString()},'thisisnewcourse') ret
I have written a code on my server(NodeJS) that will send a .csv file to the frontend with express res.download(path). I would like to know how I can handle the
Event Hub is fast to send but slow to get. I use next code: subscribe(cb: (event: any) => Promise<void>) { this.consumerClient.subscribe(
I use pg-promise and i tried to make a request to database in user model to get an array of all users like this: exports.getAllUsers = function () { let
I am using AWS Elastic Beanstalk for hosting Express/Node.js API server. It's working well with just normal APIs but I am getting this 504 Timeout error with on
I need advice, what is the best way to store a JWT token? Should we store in cookies or storages? But with the CSRF flaw and xss attacks I have a doubt. I'm sti
My app works on development but gives Text Encoder error in production. When I run the Node index.js command, I get the error "TextEncoder is not defined". Erro
I have this assignment and I'm a bit stuck. When I press the button on the site the console I get this error: GET http://localhost:3000/getUser 404 (Not Found)
I am trying to build an application in my Express and anytime i navigate to the admin page i get this error const castError = new CastError();
Screenshot of the error: Code of client side: jwt attached api: Here's the jwt verifying function: const authHeader = req.headers?.auth
I have a NodeJS Application written in KoaJS, app.ts const app = new Koa(); app.use(healthCheck()); app.use(bodyParser()); app.use(errorHandler()); app.use(end
Re: https://www.npmjs.com/package/express-openapi#getting-started On many projects I've been worked on (in other technologies) we would always support multiple