PayMongo

PayMongo API Reference

Welcome to the PayMongo developer hub. You'll find comprehensive guides and documentation to help you start working with PayMongo as quickly as possible, as well as support if you get stuck. Let's jump right in!

API Reference    

Questions

Ask A Question
4
ANSWERED

webhook signature error

Hello, I'm trying the webhook in paymongo by using the spatie/laravel-webhook-client but unfortunately i got the error of signature exception. I did generate the secret_key. by the way I used ngrok to public my link. Below is the error log: [2020-11-01 11:48:39] local.ERROR: The signature is invalid. {"exception":"[object] (Spatie\\WebhookClient\\Exceptions\\WebhookFailed(code: 0): The signature is invalid. at F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\spatie\\laravel-webhook-client\\src\\Exceptions\\WebhookFailed.php:11) [stacktrace] #0 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\spatie\\laravel-webhook-client\\src\\WebhookProcessor.php(44): Spatie\\WebhookClient\\Exceptions\\WebhookFailed::invalidSignature() #1 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\spatie\\laravel-webhook-client\\src\\WebhookProcessor.php(26): Spatie\\WebhookClient\\WebhookProcessor->ensureValidSignature() #2 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\spatie\\laravel-webhook-client\\src\\WebhookController.php(11): Spatie\\WebhookClient\\WebhookProcessor->process() #3 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\ControllerDispatcher.php(48): Spatie\\WebhookClient\\WebhookController->__invoke(Object(Illuminate\\Http\\Request), Object(Spatie\\WebhookClient\\WebhookConfig)) #4 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Route.php(255): Illuminate\\Routing\\ControllerDispatcher->dispatch(Object(Illuminate\\Routing\\Route), Object(Spatie\\WebhookClient\\WebhookController), '__invoke') #5 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Route.php(197): Illuminate\\Routing\\Route->runController() #6 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Router.php(691): Illuminate\\Routing\\Route->run() #7 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php(128): Illuminate\\Routing\\Router->Illuminate\\Routing\\{closure}(Object(Illuminate\\Http\\Request)) #8 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Middleware\\SubstituteBindings.php(41): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request)) #9 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php(167): Illuminate\\Routing\\Middleware\\SubstituteBindings->handle(Object(Illuminate\\Http\\Request), Object(Closure)) #10 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Foundation\\Http\\Middleware\\VerifyCsrfToken.php(77): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request)) #11 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php(167): Illuminate\\Foundation\\Http\\Middleware\\VerifyCsrfToken->handle(Object(Illuminate\\Http\\Request), Object(Closure)) #12 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\View\\Middleware\\ShareErrorsFromSession.php(49): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request)) #13 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php(167): Illuminate\\View\\Middleware\\ShareErrorsFromSession->handle(Object(Illuminate\\Http\\Request), Object(Closure)) #14 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Session\\Middleware\\StartSession.php(121): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request)) #15 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Session\\Middleware\\StartSession.php(63): Illuminate\\Session\\Middleware\\StartSession->handleStatefulRequest(Object(Illuminate\\Http\\Request), Object(Illuminate\\Session\\Store), Object(Closure)) #16 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php(167): Illuminate\\Session\\Middleware\\StartSession->handle(Object(Illuminate\\Http\\Request), Object(Closure)) #17 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Cookie\\Middleware\\AddQueuedCookiesToResponse.php(37): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request)) #18 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php(167): Illuminate\\Cookie\\Middleware\\AddQueuedCookiesToResponse->handle(Object(Illuminate\\Http\\Request), Object(Closure)) #19 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Cookie\\Middleware\\EncryptCookies.php(67): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request)) #20 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php(167): Illuminate\\Cookie\\Middleware\\EncryptCookies->handle(Object(Illuminate\\Http\\Request), Object(Closure)) #21 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php(103): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request)) #22 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Router.php(693): Illuminate\\Pipeline\\Pipeline->then(Object(Closure)) #23 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Router.php(668): Illuminate\\Routing\\Router->runRouteWithinStack(Object(Illuminate\\Routing\\Route), Object(Illuminate\\Http\\Request)) #24 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Router.php(634): Illuminate\\Routing\\Router->runRoute(Object(Illuminate\\Http\\Request), Object(Illuminate\\Routing\\Route)) #25 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Routing\\Router.php(623): Illuminate\\Routing\\Router->dispatchToRoute(Object(Illuminate\\Http\\Request)) #26 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Foundation\\Http\\Kernel.php(166): Illuminate\\Routing\\Router->dispatch(Object(Illuminate\\Http\\Request)) #27 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php(128): Illuminate\\Foundation\\Http\\Kernel->Illuminate\\Foundation\\Http\\{closure}(Object(Illuminate\\Http\\Request)) #28 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Foundation\\Http\\Middleware\\TransformsRequest.php(21): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request)) #29 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php(167): Illuminate\\Foundation\\Http\\Middleware\\TransformsRequest->handle(Object(Illuminate\\Http\\Request), Object(Closure)) #30 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Foundation\\Http\\Middleware\\TransformsRequest.php(21): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request)) #31 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php(167): Illuminate\\Foundation\\Http\\Middleware\\TransformsRequest->handle(Object(Illuminate\\Http\\Request), Object(Closure)) #32 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Foundation\\Http\\Middleware\\ValidatePostSize.php(27): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request)) #33 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php(167): Illuminate\\Foundation\\Http\\Middleware\\ValidatePostSize->handle(Object(Illuminate\\Http\\Request), Object(Closure)) #34 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Foundation\\Http\\Middleware\\PreventRequestsDuringMaintenance.php(87): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request)) #35 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php(167): Illuminate\\Foundation\\Http\\Middleware\\PreventRequestsDuringMaintenance->handle(Object(Illuminate\\Http\\Request), Object(Closure)) #36 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\fruitcake\\laravel-cors\\src\\HandleCors.php(37): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request)) #37 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php(167): Fruitcake\\Cors\\HandleCors->handle(Object(Illuminate\\Http\\Request), Object(Closure)) #38 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\fideloper\\proxy\\src\\TrustProxies.php(57): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request)) #39 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php(167): Fideloper\\Proxy\\TrustProxies->handle(Object(Illuminate\\Http\\Request), Object(Closure)) #40 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Pipeline\\Pipeline.php(103): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request)) #41 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Foundation\\Http\\Kernel.php(141): Illuminate\\Pipeline\\Pipeline->then(Object(Closure)) #42 F:\\xampp\\htdocs\\RESTfulAPI\\vendor\\laravel\\framework\\src\\Illuminate\\Foundation\\Http\\Kernel.php(110): Illuminate\\Foundation\\Http\\Kernel->sendRequestThroughRouter(Object(Illuminate\\Http\\Request)) #43 F:\\xampp\\htdocs\\RESTfulAPI\\public\\index.php(52): Illuminate\\Foundation\\Http\\Kernel->handle(Object(Illuminate\\Http\\Request))

Posted by Jayvee 10 months ago

4

Two really important yet lacking features in PayMongo.

I really hope you fellas consider this because there are so many applications for these features. I'm 100% sure a lot of people had to drop PayMongo for PayPal or for some other service out there that supports these. I'm dead serious when I say that the lack of these features is what stopping PayMongo from being the de facto payment gateway in the PH. 1. Recurring payments. Even the oldest PH payment gateways have these. e.g PesoPay, AsiaPay, iPay88, etc. You get the point. Netflix, YouTube Premium, GitHub, Shopify, and nearly every single SaaS out there rely on subscriptions. 2. One-to-many payouts. Payouts to multiple PayMongo accounts from one payment. Even better if you could somehow integrate it with popular wallets. So one payment that can be paid out to a PayMongo account, and then a GCash account. It doesn't just have to be two, but the point is there: multiple recipients. Middlemen-type platforms like Ko-Fi, Grab, Uber, AirBnB, Patreon, RedBubble, and etc. These services are extremely popular everywhere (some I guess). This could even be augmented on top of the subscriptions feature, which just opens so many applications. Please listen. These payment methods are _really_ common in SaaS, and by not including it, it just makes it much harder for the startup scene in the Philippines to flourish. You fellas already have the appeal of being developer friendly. It's just so difficult when the current payment methods are so one dimensional, and restrictive. Your slogan is, "PayMongo makes it easy for you to run an online business. We help you get paid by your customers, any time and anywhere.". But the only online business you really support are the brick and mortar businesses that went online. If these features are implemented, I'm sure that the startup scene would be more appealing for a lot of developers. It's just sad that the good options like Stripe aren't available here. Moving a business outside PH just to be able to use Stripe because there are no better options is really sad. Please this is very important.

Posted by Glowing Octopus Engine 7 months ago