zoom-auth-api
v1.1.4
Published
You can access to the Api of your Zoom acount
Downloads
7
Readme
Get api of your zoom acount whit Auth2
This is a way to save you the process of obtaining your Zoom account details.
The sections available:
Meeting/Meetings User/Users ONLY (GETUSER)
First of all you must obtain what is the access token for the requests, which you should do with the GetToken function:
require('dotenv').config();
const express = require('express');
const app = express();
const bodyParser = require('body-parser');
import { GetToken } from 'zoom-auth-api';
app.use(bodyParser.urlencoded({ extended: false }));
app.use(bodyParser.json());
// Main Constants
const authCode = process.env.TOKEN; // Token obtained after calling the /auth/zoom route
const clientID = process.env.clientID; // Your Zoom Marketplace account is found
const clientSecret = process.env.clientSecret; // Your Zoom Marketplace account is found
const meetingId = process.env.meetingID; // You can select your personal meeting id (optional) or randomly created meeting id
const redirectURL = process.env.redirectURL; // URL to which it will be redirected once the account is linked
const PORT= process.env.PORT ?? 8000; // Port on which the code will be executed
app.get('/auth/zoom',async (req, res)=>{
const redirect = redirectURL + "auth/zoom"; // URL to which it will be redirected once the account is linked
const clientId = clientID ?? "";
try{
let token = await GetToken({
res: res,
req:req,
redirectURL: redirect,
clientSecret: clientSecret,
clientID: clientId
});
res.send(token);
}
catch (error) {
res.status(500).send('Internal Server Error'); //Error handling
}
});
app.listen(PORT, () => console.log(`Zoom OAuth NodeJS App started on port ${PORT}`))
Then you can pass this token to each request or function of the library with its other respective parameters. Please refer to both the official Zoom account for developers ([https://developers.zoom.us/docs/api/]) and the github link for application examples.