https://github.com/vinceramcesoliveros/paymongo_sdk
Unofficial PayMongo SDK written in Dart.
https://github.com/vinceramcesoliveros/paymongo_sdk
dart dart-lang dart-package flutter flutter-package flutter-plugin payment-gateway payment-integration paymongo paymongo-flutter
Last synced: 9 months ago
JSON representation
Unofficial PayMongo SDK written in Dart.
- Host: GitHub
- URL: https://github.com/vinceramcesoliveros/paymongo_sdk
- Owner: vinceramcesoliveros
- License: mit
- Created: 2021-05-05T12:00:35.000Z (about 5 years ago)
- Default Branch: main
- Last Pushed: 2024-06-15T03:31:31.000Z (about 2 years ago)
- Last Synced: 2025-04-09T16:05:09.087Z (about 1 year ago)
- Topics: dart, dart-lang, dart-package, flutter, flutter-package, flutter-plugin, payment-gateway, payment-integration, paymongo, paymongo-flutter
- Language: Dart
- Homepage:
- Size: 299 KB
- Stars: 10
- Watchers: 2
- Forks: 9
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# PayMongo SDK

A dart implementation of PayMongo Client SDK.
## Flutter package for paymongo
The flutter package for paymongo will be in separate package. This is to separate
what endpoints to use in the frontend or backend APIs.
### Create Account
you can register your account here https://dashboard.paymongo.com/login.
### API Keys
Go to Developers and locate the _Public Key_ and _Secret Key_.
copy the key and use it in your project.
### TODO
| Payment | Documentation | Production |
| :-------------------------------------------------------------------------: | :-----------: | :--------: |
| [GCash](https://developers.paymongo.com/docs/accepting-gcash-payments) | 🚧 | ✅ |
| [Debit/Credit](https://developers.paymongo.com/docs/accepting-cards) | 🚧 | ✅ |
| [PayMaya](https://developers.paymongo.com/docs/accepting-paymaya-payments) | 🚧 | 🚧 |
| [Grab Pay](https://developers.paymongo.com/docs/accepting-grabpay-payments) | 🚧 | ❌ |
_Let me know if you have concerns with the SDK by creating an [issue](https://github.com/ram231/paymongo_sdk/issues)_
## Usage
full [example](./example/lib/main.dart) project.
```dart
/// for dart standalone project usage
import 'package:paymongo_sdk/paymongo_sdk.dart'
void main() async {
/// apiKey can be either public key or secret key.
/// but do not use secret key in your front-end.
final publicSDK = PaymongoClient(apiKey);
final data = SourceAttributes(
type: 'gcash',
amount: amount,
currency: 'PHP',
redirect: const Redirect(
success: "https://google.com/success",
failed: "https://google.com/failed",
),
billing: billing,
);
final result = await publicSDK.instance.source.create(data);
}
```