mirror of
https://github.com/hanzo-dart/sdk.git
synced 2026-10-30 19:32:47 +00:00
16 lines
519 B
Dart
16 lines
519 B
Dart
// The README quickstart, as a file that compiles. `dart analyze` covers
|
|
// example/, so the front door cannot rot away from the client.
|
|
//
|
|
// Swap the literal for a real key and it runs; example/keys.dart is the same
|
|
// call reading one from the environment.
|
|
import 'package:hanzoai/hanzoai.dart';
|
|
|
|
Future<void> main() async {
|
|
final client = hanzo(token: 'sk-...');
|
|
|
|
final keys = await AccountApi(client).getAccountKeys();
|
|
for (final key in keys!.keys) {
|
|
print('${key.type} created ${key.createdAt}');
|
|
}
|
|
}
|