How to integrate PhonePe Payment Gateway with React/Next JS.

Поделиться
HTML-код
  • Опубликовано: 25 окт 2024

Комментарии • 77

  • @techmalasi9802
    @techmalasi9802  5 месяцев назад +2

    Hey guys if you have got following problems while integrating phone pe payment gateway with next.js
    1) BAD Request
    2) Too may requests - 429
    3) 404
    then find below url and go through the article and download updated code. you might get solution. Soon I will try to upload video for the same.
    mmantratech.com/next-js-14-phone-pe-payment-gateway-integration-bad-request-too-many-request-429-404-errors-resolved

  • @atharv906
    @atharv906 8 месяцев назад +1

    I had to watch a lot of videos before this one cause no one explained it properly, but you nailed it. Thanks

  • @VickTechPro
    @VickTechPro Месяц назад +1

    Thanks so much for the great explanation. It was a huge help!

  • @HarshSingh-kr2ci
    @HarshSingh-kr2ci 6 месяцев назад +1

    Thank you 🙏 for creating such valuable content in Next.js, specifically in Hindi 🇮🇳.

  • @dreamerb1
    @dreamerb1 4 месяца назад +1

    Thank you sir this is best and first video on phonepe integration looking from many days finally found it
    Best alertenative for razorpay as razorpay charges 2% for UPI transactions

  • @SajalSuraj
    @SajalSuraj 6 месяцев назад +1

    This is gold content, really helpful

  • @kartikpatekar9151
    @kartikpatekar9151 8 месяцев назад

    Thankyou soo much easily integrated phonepay into my final year project without any hassle, furhtermore also gained insight of the workflow . can you please also help to add images in nextjs in database

  • @AryanRaj-zt6cq
    @AryanRaj-zt6cq 5 месяцев назад

    thank you for this amazing content, ek question hai sir kya production pr live jane ke liye hume vahi domain pr code setup krna padega jipr humne approval liya hai ya phir hum kisi pr bhi kr sakte hai?

    • @techmalasi9802
      @techmalasi9802  5 месяцев назад

      yes. request should be from the registered domain for production

  • @riyanali3667
    @riyanali3667 10 месяцев назад +1

    Thank you so much sir , I am in much need for this !!!!!

  • @AbhayBharti1
    @AbhayBharti1 14 дней назад +1

    UAT env API is throwing too many 429 error. I tried using PROD endpoint directly, I am able to receive payment, when redirectURL is invoked, getting 500 internal server error

    • @techmalasi9802
      @techmalasi9802  14 дней назад +1

      Plz check my pinned comment for this. you will get solution

  • @adarshrathi8265
    @adarshrathi8265 5 месяцев назад +3

    razor pay pa bhi bana do , because ya to gst hona ka bad hi hoga, razor pay to pahala bhi ho sakta ha in next js 14

  • @शाकुन्तलम्
    @शाकुन्तलम् 2 месяца назад

    Yo Bro, I am trying to integrate phonepe payment gateway using React + NodeJs (I don't want to expose salt key publicly in the frontend) but it is adding a layer of complexity and an additional service call React -> Node -> Phonepe -> Node -> React
    Is it okay if I use the Salt Key publicly in react frontend? I was going for server side option so far.

  • @lalitdeshmukh7971
    @lalitdeshmukh7971 9 месяцев назад +1

    Thank you so much please make next js projects playlist

    • @techmalasi9802
      @techmalasi9802  9 месяцев назад

      Thanks. I am already working on that . Soon you will get it

  • @polticalface3007
    @polticalface3007 Месяц назад

    thanks , in testing work fine , but when i update production salt key it gives cors error

    • @techmalasi9802
      @techmalasi9802  Месяц назад

      Please check my pinned comment . You will latest code link. Implement that. According to phone pe documentation:
      Note: Merchants must use their backend server to hit these APIs. If they attempt to hit the API from the frontend server, they will encounter a CORS policy error.

  • @ZorooLaxman
    @ZorooLaxman 3 месяца назад +1

    The explanation was great. gold content . i am facing one problem after success full transaction it is going to the redirectURL but here i am getting an error. which is 404 This page could not be found.. can anyone tell me how to solve this error. and i have done all the steps from the video still the error is coming....
    thanks

  • @yogeshpal8946
    @yogeshpal8946 Месяц назад

    hey, if i am not using muid than what happens can you tell me

  • @atifali3485
    @atifali3485 8 месяцев назад

    im having strange error.. jab postman s wo phonePe wala url kholra to payment successfull hora, likin next.js jab same jaga redirect kerha to tab payment success nhi hora... in phonePe it says transaction url doesnt match with onboarding url directing

  • @zyncc
    @zyncc 4 месяца назад +1

    I'm getting error code 401 which means incorrect x-verify but i have done all the steps correctly

  • @hellofriend6834
    @hellofriend6834 7 месяцев назад +1

    At 30:35 I am getting a 401 BAD Request error.
    I think the XVERIFY is not matching the checksum.
    Why and how can I fix this?

    • @techmalasi9802
      @techmalasi9802  7 месяцев назад

      Plz check your keys . Generally it is related to wrong keys combination and invalid checksum

    • @techmalasi9802
      @techmalasi9802  5 месяцев назад

      mmantratech.com/next-js-14-phone-pe-payment-gateway-integration-bad-request-too-many-request-429-404-errors-resolved

  • @HarshSingh-kr2ci
    @HarshSingh-kr2ci 6 месяцев назад

    [00:03]Integration of PhonePe Payment Gateway with React/Next JS
    [02:09]Integrating PhonePe Payment Gateway Logic with React/Next JS
    [06:30]Integrating PhonePe payment gateway with React/Next JS
    [08:34]Setting up Next.js project and running it
    [13:19]Implementing PhonePe payment gateway integration steps in React/Next JS.
    [16:06]Integrating S256 Encryption with PhonePe API
    [20:14] Integration of PhonePe Payment Gateway with React/Next JS
    [22:14] Integrating PhonePe Payment Gateway with React/Next JS
    [26:28] Integrating PhonePe Payment Gateway in React/Next JS
    [28:46] Integrating PhonePe payment gateway involves URL, request encoding, headers, and payment page redirection
    [34:11] Integrating PhonePe Payment Gateway with React/Next JS
    [36:17] Creating post and get routes in route.gs file
    [40:27] Integrating PhonePe payment gateway with React/Next JS
    [42:39] Integrating PhonePe Payment Gateway details
    [47:21] Demonstrate successful payment integration with PhonePe
    [50:16] Explaining the integration of ffpa

  • @i5news919
    @i5news919 8 месяцев назад +1

    How to get real marchantId and key , please do video in react native expo

    • @techmalasi9802
      @techmalasi9802  8 месяцев назад +1

      Phone pe team will mail you the same as soon as you register yourself with them

    • @i5news919
      @i5news919 7 месяцев назад +1

      thankyou for replying bro

  • @PrakharArya-kg2lk
    @PrakharArya-kg2lk 5 месяцев назад

    After cloning your github code im getting same error: code
    :
    "ERR_BAD_REQUEST"
    config
    :
    {transitional: {…}, adapter: Array(2), transformRequest: Array(1), transformResponse: Array(1), timeout: 0, …}
    message
    :
    "Request failed with status code 400"
    name
    :
    "AxiosError". Plz help it is little urgent. i have to include this feature in my project and monday is deadline.

    • @techmalasi9802
      @techmalasi9802  5 месяцев назад

      mmantratech.com/next-js-14-phone-pe-payment-gateway-integration-bad-request-too-many-request-429-404-errors-resolved

  • @nihalshaikh9898
    @nihalshaikh9898 5 месяцев назад

    Can u tell me how to call this api on server side because the phonepay team expects it from server side

    • @techmalasi9802
      @techmalasi9802  5 месяцев назад

      import { payment } from "@/action/ServerActions";
      const makePayment = async (e) => {
      e.preventDefault();
      const redirect = await payment();
      router.push(redirect);
      };
      Create a file
      ServerAction.js
      "use server";
      import { v4 as uuidv4 } from "uuid";
      import sha256 from "crypto-js/sha256";
      import axios from "axios";
      export async function payment() {}
      shift all payment related code here

    • @techmalasi9802
      @techmalasi9802  5 месяцев назад

      mmantratech.com/next-js-14-phone-pe-payment-gateway-integration-bad-request-too-many-request-429-404-errors-resolved

  • @anuragambekar3209
    @anuragambekar3209 9 месяцев назад

    Even I am facing cors issue when tried to clone your app and added my own merchantid and salt key

    • @nihalshaikh9898
      @nihalshaikh9898 5 месяцев назад

      This was because the api is called on client side but the phone pay expects ita for server side

  • @vijaykumarprajapati190
    @vijaykumarprajapati190 7 месяцев назад

    Kisi ne prodction pr code run kiya? Mera testing me chal rha hai but production me nhi chal rha...

  • @spider-man150
    @spider-man150 7 месяцев назад

    it will give
    AxiosError: Request failed with status code 429
    this error when i clcik for call makePayemnt function how can fix it please anyone tell me

    • @techmalasi9802
      @techmalasi9802  7 месяцев назад +1

      Plz share your code

    • @spider-man150
      @spider-man150 7 месяцев назад

      @@techmalasi9802 sir in your GitHub repo after changes my .env file it will give same error and also in my project code

    • @techmalasi9802
      @techmalasi9802  5 месяцев назад

      mmantratech.com/next-js-14-phone-pe-payment-gateway-integration-bad-request-too-many-request-429-404-errors-resolved

  • @sansind
    @sansind 10 месяцев назад

    Coming cors error in both environments UAT and Prod

    • @techmalasi9802
      @techmalasi9802  10 месяцев назад

      Are you getting first payment screen of phonepe sandbox or before that you got CORS error.
      Are you using my github code or integrating logic in your code.
      Plz share payload + axios/fetch code (screenshot) to phonepe UAT API to better understand your env
      you can also give me screenshot of console to answer properly.
      My suggestion : plz check callbackurl + redirect url + mode + checksum in your code
      contact : techmalasi@gmail.com

  • @Stepbystep666
    @Stepbystep666 22 дня назад +1

    Please make a video to add phonepe payment gateway in bagisto Laravel please please please please please please please

  • @NitinKannojia-ol8cg
    @NitinKannojia-ol8cg 6 месяцев назад

    AxiosError: Request failed with status code 400 plss help it give me error while click on pay button

  • @ajayi4662
    @ajayi4662 10 месяцев назад +1

    Im getting this error
    {
    "success": false,
    "code": "BAD_REQUEST",
    "message": "Please check the inputs you have provided.",
    "data": {}
    }
    but all payload values are correct.? why this error comming.?

    • @techmalasi9802
      @techmalasi9802  10 месяцев назад +1

      You might have missed x-verify parameters in header or x-verify format is wrong. Check sha256 format. You can send your code ( without node modules) to techmalasi@gmail.com , if you want me to debug.

    • @ajayi4662
      @ajayi4662 10 месяцев назад

      Thanks for your reply

    • @NitinKannojia-ol8cg
      @NitinKannojia-ol8cg 6 месяцев назад

      hey broo plss answer your question
      @@ajayi4662

    • @techmalasi9802
      @techmalasi9802  5 месяцев назад

      mmantratech.com/next-js-14-phone-pe-payment-gateway-integration-bad-request-too-many-request-429-404-errors-resolved

  • @kamalsinghkhanna8143
    @kamalsinghkhanna8143 2 месяца назад

    decimal values in amount giving errors but working fine for normal numbers
    for examlple amount = 12.42 * 100 is not working but 12 * 100 is working
    data: {
    servlet: 'jersey',
    message: 'Request failed.',
    url: '/pg/v1/pay',
    status: '500'
    }

  • @tejasrathi5418
    @tejasrathi5418 5 месяцев назад +1

    Getting 429 (Too Many Requests) Error
    {
    "success": false,
    "code": "TOO_MANY_REQUESTS",
    "message": "Too many requests. Please try again.",
    "data": {}
    }

    • @PrakharArya-kg2lk
      @PrakharArya-kg2lk 5 месяцев назад

      Even im getting same error. if u get any solution for this please update in comment section.

    • @adarshrathi8265
      @adarshrathi8265 5 месяцев назад +1

      @@PrakharArya-kg2lk same problem

    • @techmalasi9802
      @techmalasi9802  5 месяцев назад

      mmantratech.com/next-js-14-phone-pe-payment-gateway-integration-bad-request-too-many-request-429-404-errors-resolved

  • @rajnailwal6005
    @rajnailwal6005 10 месяцев назад +1

    i want some help regarding this how i contact you

    • @techmalasi9802
      @techmalasi9802  10 месяцев назад

      you can contact me at techmalasi@gmail.com

  • @HMS_55
    @HMS_55 5 месяцев назад +1

    {
    "success": false,
    "code": "TOO_MANY_REQUESTS",
    "message": "Too many requests. Please try again.",
    "data": {}
    }

    • @techmalasi9802
      @techmalasi9802  5 месяцев назад

      mmantratech.com/next-js-14-phone-pe-payment-gateway-integration-bad-request-too-many-request-429-404-errors-resolved

  • @Stepbystep666
    @Stepbystep666 22 дня назад

    Please make a video to add phonepe payment gateway in bagisto Laravel please please please please please please please

  • @Stepbystep666
    @Stepbystep666 22 дня назад

    Please make a video to add phonepe payment gateway in bagisto Laravel please please please please please please please

  • @Stepbystep666
    @Stepbystep666 22 дня назад

    Please make a video to add phonepe payment gateway in bagisto Laravel please please please please please please please

  • @Stepbystep666
    @Stepbystep666 22 дня назад

    Please make a video to add phonepe payment gateway in bagisto Laravel please please please please please please please