Turns out that Stripe module at Parse Could Code is out of date and won't be updated.
Source:
https://developers.facebook.com/bugs/523104684492016/
Parse modules are using an old version of the API and there is no plan
to update it in the near future.
As a workaround please download the newer SDKs directly off the third
party site, place it in "cloud/" folder and import it using require();
We're going to close this by design.
I have downloaded Stripe module via terminal with command
npm install stripe
I'm trying to import this module but when I deploy it to Parse, it seems that most of the modules are missing. I get errors like this:
Update failed with Error: Module child_process.js not found
at node_modules/stripe/lib/stripe.js:24:12
Hope someone can point me out on how to add third party modules to Parse Cloud Code properly. Thanks.
Seems that Parse's module support is really limited and adding submodules is impossible or too complex to even bother, that's why I decided to move to Heroku. Thanks for all answers!
I know that this is a bit old, but my "workaround" was, rather than importing the module, convert the cURL requests from Stripe's documentation to Parse.Cloud.httpRequests. You can get access to the entire API that way.
Related
I have ran into trouble with ipfs-http-client in my React app.
I'm using node 16.14.0
The error message is:
When I Ctrl + Click on 'ipfs-http-client', it still drive me to the modules file.
Solutions that I've tried, but not work:
Restart app
Reinstall module
I've tried use 33.x version, it works fine but I want to use the latest version of ipfs-http-client (57.0.3)
Please help me. Thanks a lot!
The simple Solution
When you use ipfs-http-client in the frontend you will soon also have problems using jest. The easiest way is to simply not use ipfs-http-client at all and instead use a gateway like infura and fetch() the data directly. You can use my code for that:
https://gist.github.com/aignermax/c495c98003da974d17b9c4c481ac23be
The more tricky one
The problem seems to be related to webpack 5 that does not support any Node.js functions "polyfills" anymore. The idea is to keep the frontend separate from the backend and all ipfs-http-client functions are meant to be used in backend only.
You can however still add the polyfills manually following this tutorial: Remember that "Jest" will still not work after that, so if you do unit testing you should consider using ipfs on your server instead or use "The simple Solution" above.
https://github.com/facebook/create-react-app/issues/11756#issuecomment-1001162736
I then got some webpack PolyErrors which I solved using this NPM Package:
https://www.npmjs.com/package/node-polyfill-webpack-plugin
I also Got Errors about failed to load Source-Map from source-map-loader, which will occur using WebPack5 which is included in the new React-Scripts. You fix that by using this:
Failed to parse source map
and NOW IT WORKS.
I have a working project with Twilio + Ionic, but I'm wondering if you can help me with adding Azure Communication Services(video call) into my project. I tried to follow the example from the official website, but I think it's not just installing npm library and adding it as usual in my project.
If you want to see a working sample, you can use this: https://github.com/Azure-Samples/communication-services-web-calling-hero
If you're still stuck, please respond here and I'll try to help you directly.
Invalid CommunicationUser identifier specified
I am doing research on quickbooks online integration using node and angular 8.
The official intuit developer site provides two node packages.
one is official from intuit and one is from community.
I have glanced through both of them.
the official package is fairly universal. It essentially is just a API client to send a request to remote server and the payload is basic json format.
the community package seems a bit more specific but the documentation seems a bit confusing.
Which one would you choose to do the work and why?
I would love to hear your input.
Thanks :)
The Intuit provided library (intuit-oauth) is specifically for authenticating and getting the OAuth token you need to communicate with the Quickbooks API, the other library (node-quickbooks) is for making the actual calls against the API endpoints.
You will need both libraries, unless you are handling authentication in a different way.
Fwiw for whoever finds this useful:
I forked intuit-oauth, added typescript and fixed vulnerabilities that have been fixed in the PRs of their repo for years and never updated here: https://www.npmjs.com/package/intuit-oauth-ts
Additionally I forked node-quickbooks, updated the api to return promises rather than relying on callbacks, resolved the discovery URLs automatically, changed the format of response objects to be more sensible, and added (unfortunately only some) of the typescript definitions for it here: https://www.npmjs.com/package/qbo. I don't have enough time to add the definitions for all of the files (largey because the included ones should be completely exhaustive for every property in the QBO api, which is timeconsuming to define). If someone would like to contribute by adding more of the typescript definitions or adding all of them, I would really appreciate it.
I am interested in any example angular app using intuit-oauth
Trying to work it out but getting issues since there is no document for typescript.
I’m building an app with the React JS library, using Electron and Node JS to package it as a Windows .exe
I used the “speak-tts” module to integrate speech synthesis. Everything seems to be pretty straightforward, but I can’t figure out how to load additional voices. I can only get the default voice.
Has anyone else come across this issue? Your advice is much appreciated.
I'm the creator of the speak-tts module. As you can see in the documentation (https://www.npmjs.com/package/speak-tts) there is a setVoice() method that you can call on your instance to change the voice on the fly.
You can get the list of available voices in the browser from the onvoiceschanged listener. Also there might be specific issues with Electron and this package that I'm not aware of.
If so do not hesitate to create a github issue (https://github.com/tom-s/speak-tts/issues).
Easiest way to do is use plain JS methods
For reference.
https://developer.mozilla.org/en-US/docs/Web/API/SpeechSynthesis/cancel
It has all the required methods. cancel(), start(), pause() etc
All, I am trying to using third party NodeJS SDK in Titanium Studio. However, I consistently encounter dependency issues, such as util.js, utils.js, ms.js, events.js etc. I tried to add the missing module manually, but it looks like it will become un-tractable as there are so many dependencies.
My questions are :
1. Is that possible to use NodeJS based SDK in Titanium Studio .
2. If so, what is the right approach to include the dependencies.
Thanks a lot!
Titanium can't get Coffee scripts to work natively (assuming you want to deploy the TitaniumWrapper.coffee). A possible solution you may want to try is hooking a plugin http://billdawson.com/titanium_coffee_script/ in order to pre-compile Coffee scripts.
You can also try to embed everything using a Tiwebview that wraps HTML to load mojio-js.js but you would still need to observe events mojio client (like replacing keys, login an user and create a few model instances).
Hope you find the info useful and can serve for further research.