REST APIs
if (namespace.app) { // Express app for configuration
// Write your Express Endpoints here.
//For Example
namespace.express('post', '/accept-cid', async (req, res) => {})
}namespace.express('post', '/accept-cid', async (req, res) => {
try {
const cid = req.body.cid;
if (cid) {
console.log('CID =' + cid);
res.status(200).json({ message: 'CID' });
}
} catch (err) {
console.log('CATCH IN ACCEPT CID', err);
}
});Last updated