Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ReferenceError: Twilio is not defined #118

Open
mhadad opened this issue May 29, 2023 · 0 comments
Open

ReferenceError: Twilio is not defined #118

mhadad opened this issue May 29, 2023 · 0 comments

Comments

@mhadad
Copy link

mhadad commented May 29, 2023

/node_modules/@twilio-labs/plugin-rtc/src/serverless/functions/token.js:4
const AccessToken = Twilio.jwt.AccessToken;
^
ReferenceError: Twilio is not defined

The above is what I'm getting for the following lines:
import * as Twilio from 'twilio';
import * as TwilioToken from '@twilio-labs/plugin-rtc/src/serverless/functions/token';

dotenv.config();
const tokenFunction: ServerlessFunction = TwilioToken.handler;
so how can I fix this?
Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant