apiverve_shortcodegenerator 1.2.5
apiverve_shortcodegenerator: ^1.2.5 copied to clipboard
Short Code Generator creates custom alphanumeric short codes for vouchers, referral tokens, and redirect slugs. Specify a length, batch count, and character set like numeric, hex, or Base58 to receive [...]
Short Code Generator API - Dart/Flutter Client #
Short Code Generator creates custom alphanumeric short codes for vouchers, referral tokens, and redirect slugs. Specify a length, batch count, and character set like numeric, hex, or Base58 to receive an array of random strings.
This is the Dart/Flutter client for the Short Code Generator API.
Installation #
Add this to your pubspec.yaml:
dependencies:
apiverve_shortcodegenerator: ^1.2.5
Then run:
dart pub get
# or for Flutter
flutter pub get
Usage #
import 'package:apiverve_shortcodegenerator/apiverve_shortcodegenerator.dart';
void main() async {
final client = ShortcodegeneratorClient('YOUR_API_KEY');
try {
final response = await client.execute({
'count': 1,
'length': 8,
'charset': 'alphanumeric'
});
print('Status: ${response.status}');
print('Data: ${response.data}');
} catch (e) {
print('Error: $e');
}
}
Response #
{
"status": "ok",
"error": null,
"data": {
"codes": [
"bgiFznFh",
"jr84hHsG",
"Q77qABwn",
"gvMjXxXs",
"WDPJzCsi"
],
"count": 5,
"length": 8,
"charset": "alphanumeric",
"url_safe": true
}
}
API Reference #
- API Home: Short Code Generator API
- Documentation: docs.apiverve.com/ref/shortcodegenerator
Authentication #
All requests require an API key. Get yours at apiverve.com.
License #
MIT License - see LICENSE for details.
Built with Dart for APIVerve