Comments (4)
What do you mean by not having the accountSid
and authToken
from the start, can you elaborate on why and how you pull the credentials and why that is "delayed?
from nestjs-twilio.
In short - application is a microservice. It's starts right away, but receive some configuration when other microservice is started. No, there is no other hacky way to do it, if you want to ask that. Even worse, I have v1.2.0, so I don't think pull request for v3.0.0 from me will help much. Another way is somehow disable module (Twilio client initialization), and then restart whole aplication when credentials is received.
from nestjs-twilio.
Not out of the box, I'd recommend taking a look at async providers here and/or, perhaps, lazy loading modules here. The whole package is a wrapper around the twilio SDK, and this sounds like it could be a more nest-related question. I'd be happy to try and debug if you were to provide a minimal reproduction.
The async providers could be the way to go in the case of wanting to delay the module registration.
from nestjs-twilio.
I just forked version 3 and did a very neat hack for lazy client initialization with a boolean flag that client is initialized. I'm closing issue.
from nestjs-twilio.
Related Issues (20)
- testing HOT 1
- cant resolve dependency tree HOT 4
- Mock twilio module HOT 6
- Cannot install with nest v8 HOT 2
- Constructor injection gives the following error HOT 4
- does not work with sub-module HOT 4
- Nest 9.X support? HOT 6
- Update the dependencies HOT 1
- Property 'forRoot' does not exist on type 'TwilioModule' HOT 4
- Configurable module import dependency resolution error HOT 3
- Property 'forRoot' does not exist on type 'typeof TwilioModule' HOT 4
- Package JSON Bug
- The 4.1.0 was not published in NPM. HOT 1
- How can I generate a client token using nestjs-twilio? HOT 3
- Twilio itself should be a peer dependency
- Configurable module import dependency resolution error HOT 4
- Can I register multiple Twillio accounts in one app? HOT 1
- ERROR [ExceptionHandler] Nest can't resolve dependencies of the TwilioService HOT 2
- Publish action not running as intended HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nestjs-twilio.