Skip to content
Sign UpLog In
This post is read-only. Explore Repls and connect with other creators on Community.View Community
The info in this post might be out of date, check out our docs instead. View docs
10

node.js Discord Bot running 24/7

NightmareTaken
NightmareTaken

What code do I need to use to be able to use uptime robot with node.js on replit for my discord bot?

2 years ago

Voters

Comments

TopNew
1
Coder100
Coder100

To host in node.js, try this tutorial.

2 years ago
1
RYANTADIPARTHI
RYANTADIPARTHI

host it somewhere, or get http servers.

2 years ago
1
SixBeeps
SixBeeps

You need to start an HTTP server one way or another, then link UTR to the auto-generated link for that server.

2 years ago
1
NightmareTaken
NightmareTaken

what would be the code to run that server?

@SixBeeps

2 years ago
1
SixBeeps
SixBeeps

@NightmareTaken
You could do it with Express:

const express = require('express'); const app = express(); app.get('/', (req, res) => { res.send('Hello Express app!') }); app.listen(3000, () => { console.log('server started'); });
2 years ago
1
NightmareTaken
NightmareTaken

@SixBeeps
Do I need to name the file anything special?

2 years ago
1
SixBeeps
SixBeeps

@NightmareTaken
This should be in your index file.

2 years ago
Load more