apiverve_dndgenerator 1.2.3
apiverve_dndgenerator: ^1.2.3 copied to clipboard
D&D Generator creates random content for tabletop role-playing games including characters, NPCs, monsters, treasure, encounters, taverns, and quests.
D&D Generator API - Dart/Flutter Client #
D&D Generator creates random content for tabletop role-playing games including characters, NPCs, monsters, treasure, encounters, taverns, and quests.
This is the Dart/Flutter client for the D&D Generator API.
Installation #
Add this to your pubspec.yaml:
dependencies:
apiverve_dndgenerator: ^1.2.3
Then run:
dart pub get
# or for Flutter
flutter pub get
Usage #
import 'package:apiverve_dndgenerator/apiverve_dndgenerator.dart';
void main() async {
final client = DndgeneratorClient('YOUR_API_KEY');
try {
final response = await client.execute({
'type': 'all',
'count': 1
});
print('Status: ${response.status}');
print('Data: ${response.data}');
} catch (e) {
print('Error: $e');
}
}
Response #
{
"status": "ok",
"error": null,
"data": {
"type": "character",
"count": 1,
"results": {
"name": "Ashorshadow",
"race": "Elf",
"class": "Warlock",
"level": 6,
"background": "Criminal",
"alignment": "Lawful Good",
"stats": {
"strength": 10,
"dexterity": 12,
"constitution": 7,
"intelligence": 15,
"wisdom": 12,
"charisma": 10
},
"hitPoints": 20
}
}
}
API Reference #
- API Home: D&D Generator API
- Documentation: docs.apiverve.com/ref/dndgenerator
Authentication #
All requests require an API key. Get yours at apiverve.com.
License #
MIT License - see LICENSE for details.
Built with Dart for APIVerve