daily pastebin goal
89%
SHARE
TWEET

Untitled

a guest Jan 23rd, 2019 71 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. const http = require('http');
  2. const express = require('express');
  3. const app = express();
  4. app.get("/", (request, response) => {
  5.   console.log(Date.now() + " Ping Received");
  6.   response.sendStatus(200);
  7. });
  8. app.listen(process.env.PORT);
  9. setInterval(() => {
  10.   http.get(`http://${process.env.PROJECT_DOMAIN}.glitch.me/`);
  11. }, 280000);
  12.  
  13. const Discord = require('discord.js');
  14. const client = new Discord.Client();
  15. const {prefix} = require("./config.json");
  16.  
  17.  
  18. client.once('ready', () => {
  19.     console.log('Ready!');
  20. });
  21.  
  22. client.on('message', message => {
  23.     if (message.content === '!ping') {
  24.         message.channel.send('Pong.');
  25.     }
  26. });
  27.  
  28. client.login(process.env.TOKEN);
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top