Download the PHP package mongosprout/paymongo-bridge without Composer

On this page you can find all versions of the php package mongosprout/paymongo-bridge. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package paymongo-bridge

paymongo-bridge

PayMongo API client and webhook pipeline for Laravel. Brings the plumbing, imposes no billing model.

The package knows how to talk to PayMongo and how to receive a webhook safely. It does not know what a subscription means in your application, so it ships no billing schema and only one table of its own.

Install

Live or test mode is read from the secret key's prefix, never configured, so the two can never disagree.

Collecting money

Recurring billing works for cards and Maya only. Vault the card on the customer first, then subscribe:

Receiving webhooks

Register the endpoint once, and store the secret it prints:

PAYMONGO_WEBHOOK_SECRET accepts several secrets, comma separated. Each registered endpoint has its own and re-registering mints a new one, so a URL move or a rotation lists old and new together, then drops the old once its endpoint is disabled. A delivery verifies if any listed secret signs it.

Then listen. Every delivery is signature checked, deduplicated and queued before your listener runs.

The endpoint authenticates by signature, not by middleware, but consider adding 'throttle:60,1' to paymongo.webhook.middleware so junk traffic cannot fill your log with rejections.

Deliveries are stored in paymongo_webhook_events, full payload included, and the table grows forever. Prune it on whatever schedule suits you — but never delete rows younger than the max_age window (3 days by default). Signatures older than max_age are refused outright, so those rows are free to go; inside the window the unique event id is what stops a captured delivery from being replayed.

Sending money

Off by default. An application that only collects payments should not carry a payout surface:

Items in a batch settle independently, so reconcile per transfer rather than per batch.

Money

PayMongo speaks integer centavos. Applications often do not. Money converts across that boundary on the decimal string rather than on a float, so 0.29 cannot quietly become 28 centavos the way (int) (0.29 * 100) does.

Testing

InteractsWithPayMongo is a plain trait, so it works in Pest and in PHPUnit.

The webhook helper signs the exact bytes it sends. Posting through postJson() would re-encode the body and the signature would never match.


All versions of paymongo-bridge with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
illuminate/contracts Version ^11.0|^12.0|^13.0
illuminate/database Version ^11.0|^12.0|^13.0
illuminate/http Version ^11.0|^12.0|^13.0
illuminate/support Version ^11.0|^12.0|^13.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package mongosprout/paymongo-bridge contains the following files

Loading the files please wait ...