Flutter
Our API is RESTful and responds in JSON. Gerencianet uses OAuth to provide authorized access to the API. Our NodeJS SDK is already prepared to perform this authentication automatically.
Below, check out the procedures for installing the Gerencianet SDK in Dart:
Installation:
To use this plugin, add Gerencianet as a dependency in your file pubspec.yaml.
Tested with
- Dart
2.12.3
Basic use
Initialize the plugin preferably in initState in your widget.
Set your credentials, certificate and whether you want to use sandbox or not:
- Dart
- Flutter
Examples
Example of how to create a charge:
All examples available in our SDK you find here.
Also see our Flutter app examples here.
Then run the command:
Converting the .p12 certificate
To use Pix API endpoints as our SDK in Flutter/Dart it is necessary that the certificate generated in your Gerencianet account be converted to .pem , this conversion can be done using the following OpenSSL commands: