Rank 4: Virtual Machine
Hey can anyone help me how to integrate instamojo payment gateway by using appwrite cloud functions
Votes
1
Replies
24
Participants
Unknown
Messages
25
Rank 4: Virtual Machine
Hey can anyone help me how to integrate instamojo payment gateway by using appwrite cloud functions
Rank 4: Virtual Machine
@Binyamin can you help me
Hey @bharath
What part you're now in the integration process
Rank 4: Virtual Machine
Not yet started
Rank 4: Virtual Machine
Thanks @Binyamin because of you I have completed most of my project
Rank 4: Virtual Machine
Now iam stucked at payment gateway integration
Rank 4: Virtual Machine
Rank 4: Virtual Machine
I need to integrate instamojo payment gateway in my website
Rank 4: Virtual Machine
As you know my frontend is reactjs and backend is appwrite appwrite
Rank 4: Virtual Machine
I tried with this video
Rank 4: Virtual Machine
@Binyamin are you there
Yes, I've watched the video
It seems like pretty straightforward
Rank 4: Virtual Machine
Now how do I implement in my project
You'll need to create an Appwrite cloud function, a node one.
Then you can spoof the part in which the video set to routes by setting some variable.
For example:
In your react you can send the route and the info in the function data
const res = await function.execute('instamojoFunctionID', JSON.stringify({route:'start',info: { name, email}}));Then, in your function you can
const functionData = JSON.parse( req.variables.APPWRITE_FUNCTION_DATA ?? '{}') ?? {};
if(functionData.route === 'start'){
} else if(functionData.route === 'charge'){
}And the rest is like in the video
Rank 4: Virtual Machine
???
Rank 4: Virtual Machine
Can you do this in my repo
Rank 4: Virtual Machine
@Binyamin I don't know much about cloud functions please could do in my repo
Rank 4: Virtual Machine
I will dm my repo
You can see here a quick overview of how to create functions
https://appwrite.io/docs/functions
And also in this thread: https://discord.com/channels/564160730845151244/1110177763450691586/1110191016553750608
The video of the tutorial won't give the code for free
As of that it will be difficult for me just to type all of it
Rank 4: Virtual Machine
I typed all that code
Rank 4: Virtual Machine
I will share you