How to add PAYTM gateway integration in react js web application? - node.js

I got it working from here https://github.com/paytm/paytm-pg-node-sdk-sample/blob/master/javascript/DemoApp.js I used this in express and it is working but now I want do it from react and payment has to be done from frontend.

I was also wondering how I can do that, then I tried the youtube video mentioned by Robokishan, But I found that things were not that good. As we use Reactjs we don't want to redirect our user to another page. So I contacted the Paytm dev support team and they suggested js checkout solution.
Let me go through the steps you can use to implement it in your react app
You have to create a transaction token in your backend. This link will help you with that: https://developer.paytm.com/docs/api/initiate-transaction-api/
Then go to this GitHub repo https://github.com/paytm/paytm-blink-checkout-react just download it and extract it here you will find two folders 1st named lib and 2nd example. You don't need the lib folder as you can install that package from npm so just ignore it.
Now install the package mentioned above in your react project https://www.npmjs.com/package/paytm-blink-checkout-react
Now to go that download repo go to example/src/component/app.js here you will find all the codes you need to implement Paytm gateway in your code just copy it and modify it as your need
Please feel free to suggest some improvement or if you have any other better solution

You can use paytm blink checkout solution as you already integrated node sdk for backend.
Please refer the link blink checkout available on developer section of paytm.
Sample code for react is available on github for blink checkout.
https://github.com/paytm/paytm-blink-checkout-react

Related

Azure Communication Services with Ionic

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

How to upload OneSignal SDK file in node js?

I want to use web push notification using onesignal. I create account on onsignal.com and i follow the steps (I choose chrome web push). But on step six is "Upload OneSignal SDK file". I download the files and i read the documentations but i couldn't understand it. I am using web app created on node js. Bellow I put the link of step 6 from OneSignal documentations.
https://documentation.onesignal.com/docs/web-push-typical-setup#section--span-class-step-step-6-span-upload-onesignal-sdk
Any help please. Thank you.
Actually it was simple, I was just confused and forgot some terms on node js. After some fight i fix it.
I just need to put the Unzipped file in my working directory (main root). Then make it publicly available. Simply like this, then it works.
app.use(express.static(path.("foldername")));

after creating the xamarin-android in azure, how do I download the backend as well

While learning how to create Android-xamarin-azure application, I must have done steps from different tutorials. I've just created a new test application, and this picture shows what's the final screen.
This screen is showing that I've already have a connection string and a Todo table. I remember that before I was able to download a backend project. Now, I'm just being told that I've already a table, but I don't know how to download the backend project.
I'd like to download the backend project as well, so that I can start expending it.
Thanks for helping
Just follow this link. It shows how to download backend project
https://azure.microsoft.com/en-us/documentation/articles/app-service-mobile-dotnet-backend-how-to-use-server-sdk/#create-app

How to Setup API Environment in Node

I'm building a Node.js REST API. I have a repository which will hold this REST API code.
I want to be able to test my API. For now I'll just test via Express and make GET requests to start but I want my express stuff in a separate project because a REST API isn't gonna have any web app portion.
I'm using Webstorm. So right now I have created a gitHub repo to hold the API which I'll expose REST endpoints.
I want to create a new project also again that will be a Node-Express project for the purpose of pulling in the REST API and consume it. I am also doing this in a seperate project because I don't want my Express stuff checked into my REST API repo, it doesn't belong there. I am just using Express for testing stuff.
I realize I can later test my REST endpoints headless, but right now I just wanna get started and figure that out later and just going with an Express project to somehow consume my other API REST project.
I'm not quite sure on a few things, as I come from a .NET enviornment and no longer a .NET developer. Here are some questions I have:
My Question: If I have my Node Express project open in Webstorm, how would I "include" or "require" my rest-api? Would I somehow npm it down? But my REST api is not public. Would I just branch my git REST API repo down, then what? How would I include it into my seperate Express App project?
Or...do people usually still add express to their REST API projects anyway, maybe it doesn't matter?
You can use npm link to link a local package
$ cd main-project
$ npm link ../path/to/web-api
Then in your main project, you can require it as you would any other module
If you don't intend on publish it, the package.json in your web-api should have
{
"private": true
}

using nodegit within angularjs app

I am building an app in AngularJS that needs to clone GitHub wikis attached to GitHub repos. The GitHub API does not have functionality to do anything with the GitHub wikis and GitHub support suggested I could use libgit2. With that in mind, I found nodegit.
So, now I have nodegit installed, and I made a basic javascript file out of the code example they have for Cloning a repository and reading a file. I have that file, called nodegit.js, working and by navigating to the folder containing it and typing
node ./nodegit.js
The script runs great and clones the repo into the temp folder.
Fantastic.
Now...how can I use this script in my angularjs app?
Is there a way to run a node script from angular?
Is there a way to use nodegit from angular itself?
Is there some other angular->github non-GitHub API script out there?
Any help greatly appreciated. I've gotten stuck on this one.
thank you,
Scott
Thanks shaunhusain. I ended up setting up an ExpressJS server via NodeJS and putting my code there and calling the ExpressJS server from my Angular app.
thanks, scott
Just wanted to add that I currently have a strong focus on getting the library running in the browser to address this use case. I'll update this comment once the code has landed. An issue to track the status is here:
https://github.com/nodegit/nodegit/issues/142

Resources