Aller au contenu principal

Flutter Examples

Examples use the current flow: AzeooSDK.initialize then AzeooSDK.connect, then AzeooSDK.nutrition / AzeooSDK.training or AzeooSDKContent.

Initialize and connect

import 'package:azeoo_sdk/azeoo_sdk.dart';

Future<void> initSDK(String userId, String token) async {
await AzeooSDK.initialize(
'your-api-key',
options: AzeooSDKInitOptions(
locale: 'en',
analyticsEnabled: true,
offlineSupport: true,
safeArea: const SafeAreaConfig.all(),
),
);
await AzeooSDK.connect(userId, token);
}

Embed SDK UI (AzeooSDKContent)

import 'package:azeoo_sdk/azeoo_sdk.dart';

// In your widget tree
AzeooSDKContent()

Open screens

AzeooSDK.nutrition.showMainScreen(bottomSafeArea: true);
AzeooSDK.nutrition.showBarcodeScanner();
AzeooSDK.training.showWorkoutPlans();

Full example app

See the example/flutter_example project for a complete app with auth, AzeooSDKContent, and theme customization.

Next steps