Features
The package allows you to integrate Chatgpt with just api key needed.
1. Depend on it
Add this to your package's pubspec.yaml
file:
dependencies:
gptbot: ^0.0.1
2. Install it
You can install packages from the command line:
with pub
:
pub get
with Flutter
:
flutter pub get
3. Import it
Now in your Dart
code, you can use:
import 'package:gptbot/gptbot';
Usage
GptBot
is a widget that allows you to integrate Chatgpt with just api key needed to save time to integrate the whole method.
When you want to use Chatgpt use it like:
class Bot extends StatelessWidget {
const Bot({super.key});
@override
Widget build(BuildContext context) {
return const Scaffold(
body: Gpt_flutter(apiKey: APIKey.apiKey),
);
}
}
It needs three arguments -
apiKey
– the apikey you need to get the gpt response