multi-account-post-schedule.../routes/mentions.js

29 lines
692 B
JavaScript

import accounts_to_select from "../src/configs";
var express = require('express');
var router = express.Router();
const Masto = require('mastodon');
/* GET users listing. */
router.get('/', function(req, res, next) {
module.exports.toot = async ({accessToken, status, visibility, file}) => {
const masto = new Masto({/* w w w . d em o 2s . c o m */
access_token: accessToken,
api_url: process.env.INSTANCE_MASTODON+'/api/v1/',
});
return masto.get('notifications', {
type : "mention"
});
};
// res.send('private messages');
res.render('mentions', {accounts_to_select, reqBody: req.body, });
});
module.exports = router;