onairos 0.1.6
onairos: ^0.1.6 copied to clipboard
Onairos is a flutter package to interact with the Onairos App and recieve user AI Data
Onairos Package v0.1.0 #
A Flutter package for opening a custom overlay using deep links and passing data between applications.
Features #
- Open a custom overlay with a deep link.
- Pass request data and a return link to the overlay.
- Customizable button with the Onairos logo.
Getting Started #
To use the Onairos package, include it in your pubspec.yaml file:
dependencies:
onairos: ^0.1.0
iOS Integration #
To handle onairos biometric key store access (necessary) and other functionality on iOS with the Onairos package, you need to add the following configuration to your Info.plist file:
1st configurations
<key>NSFaceIDUsageDescription</key>
<string>Authenticate to access secure storage</string>
<key>NSBiometryUsageDescription</key>
<string>This app requires access to your biometric information for authentication purposes.</string>
<key>keychain-access-groups</key>
<array>
<string>$(AppIdentifierPrefix)com.example.yourappbundleid</string>
</array>
2nd
Secure Enclave Access:
In your app's target settings, under the "Signing & Capabilities" tab, add the "Secure Enclave" capability.
<array>
<dict>
<key>CFBundleURLSchemes</key>
<array>
<string>onairos</string>
</array>
<key>CFBundleURLName</key>
<string>com.yourcompany.onairos</string>
</dict>
</array>
Usage #
Here is a simple example of using the OnairosButton widget in your app:
import 'package:flutter/material.dart';
import 'package:onairos/onairos.dart';
void main() => runApp(MyApp());
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
body: Center(
// Use the OnairosButton widget
child: OnairosButton(
requestData: {
'type': 'Personality',
'descriptions': 'Find out Your Anime Interests',
'reward': "\$0.30 - Test Money",
},
returnLink: 'yourapp://returnlink',
logoAssetPath: 'onairos_logo.png',
),
),
),
);
}
}
Replace 'yourapp://returnlink' with the actual return link for your application, and ensure the logoAssetPath points to a valid asset in your project.
Customization #
The OnairosButton widget allows for customization of the request data and return link. Make sure to provide a valid asset path to display the Onairos logo on the button.
Contributing Feel free to contribute to the Onairos package. If you have suggestions or find bugs, please open an issue or create a pull request.