antinvestor_api_payment 1.52.1
antinvestor_api_payment: ^1.52.1 copied to clipboard
Dart client library for Ant Investor Payment Service - Payment processing and transactions
Ant Investor Payment API - Dart Client #
Dart client library for the Ant Investor Payment Service. Payment processing and transactions
Installation #
Add this to your package's pubspec.yaml file:
dependencies:
antinvestor_payment: ^1.0.0
Then run:
dart pub get
Usage #
import 'package:antinvestor_payment/antinvestor_payment.dart';
import 'package:connectrpc/connect.dart';
void main() async {
final channel = ClientChannel('https://api.example.com');
final client = PaymentServiceClient(channel);
// Use the client...
await channel.shutdown();
}
Authentication #
All API calls require JWT authentication:
final channel = ClientChannel(
'https://api.example.com',
options: ChannelOptions(
credentials: ChannelCredentials.secure(),
),
);
final client = PaymentServiceClient(
channel,
interceptors: [
(options) => options.mergedWith(
CallOptions(metadata: {
'authorization': 'Bearer your-jwt-token',
}),
),
],
);
API Reference #
For detailed API documentation, see the generated documentation.
Contributing #
Contributions are welcome! Please see the main repository for guidelines.
License #
Copyright 2023-2024 Ant Investor Ltd
Licensed under the Apache License, Version 2.0. See LICENSE for details.