Update flutter version + upgrade packages + use openapi gen + update to null safety

This commit is contained in:
Fransolet Thomas 2023-03-17 18:09:59 +01:00
parent fd168a9f2c
commit 7c1f562870
715 changed files with 44983 additions and 7853 deletions

View File

@ -14,3 +14,23 @@ A few resources to get you started if this is your first Flutter project:
For help getting started with Flutter, view our For help getting started with Flutter, view our
[online documentation](https://flutter.dev/docs), which offers tutorials, [online documentation](https://flutter.dev/docs), which offers tutorials,
samples, guidance on mobile development, and a full API reference. samples, guidance on mobile development, and a full API reference.
# OPENAPI Generation cmd
flutter clean
flutter pub get
flutter pub run build_runner build --delete-conflicting-outputs
Le fichier est dans le projet.
# Publication sur le Google PlayStore
// Les paramètres de signing sont les mêmes que pour l'application tablet (donc la même android key).
Puis :
flutter build appbundle
Faut pas oublier d'aller changer la version avant chaque upload de version (Puis mettre l'app bundle dans le dossier du PC, peut-être mettre sur le repos aussi ?)

View File

@ -26,7 +26,7 @@ apply plugin: 'kotlin-android'
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
android { android {
compileSdkVersion 31 compileSdkVersion 32
sourceSets { sourceSets {
main.java.srcDirs += 'src/main/kotlin' main.java.srcDirs += 'src/main/kotlin'
@ -36,16 +36,62 @@ android {
disable 'InvalidPackage' disable 'InvalidPackage'
} }
def versionPropsFile = file('version.properties')
def value = 0
Properties versionProps = new Properties()
if (!versionPropsFile.exists()) {
versionProps['VERSION_MAJOR'] = "1"
versionProps['VERSION_MINOR'] = "0"
versionProps['VERSION_PATCH'] = "0"
versionProps['VERSION_BUILD'] = "0"
versionProps.store(versionPropsFile.newWriter(), null)
}
def runTasks = gradle.startParameter.taskNames
if ('assembleRelease' in runTasks) {
value = 1
}
if (versionPropsFile.canRead()) {
versionProps.load(new FileInputStream(versionPropsFile))
versionProps['VERSION_PATCH'] = (versionProps['VERSION_PATCH'].toInteger() + value).toString()
versionProps['VERSION_BUILD'] = (versionProps['VERSION_BUILD'].toInteger() + 1).toString()
versionProps.store(versionPropsFile.newWriter(), null)
// change major and minor version here
def mVersionName = "${versionProps['VERSION_MAJOR']}.${versionProps['VERSION_MINOR']}.${versionProps['VERSION_PATCH']}"
defaultConfig {
applicationId "be.unov.myhomie" // leave it at the value you have in your file
minSdkVersion 23 // this as well
targetSdkVersion 28 // and this
versionCode versionProps['VERSION_BUILD'].toInteger()
versionName "${mVersionName} Build: ${versionProps['VERSION_BUILD']}"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
}
else {
throw new GradleException("Could not read version.properties!")
}
/*
defaultConfig { defaultConfig {
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
applicationId "be.unov.myhomie" applicationId "be.unov.myhomie"
minSdkVersion 20 minSdkVersion 20
targetSdkVersion 31 targetSdkVersion 32
versionCode flutterVersionCode.toInteger() versionCode flutterVersionCode.toInteger()
versionName flutterVersionName versionName flutterVersionName
multiDexEnabled true multiDexEnabled true
} }
*/
buildTypes { buildTypes {
release { release {
// TODO: Add your own signing config for the release build. // TODO: Add your own signing config for the release build.

View File

@ -0,0 +1,5 @@
#Fri Mar 17 18:03:23 CET 2023
VERSION_BUILD=17
VERSION_MAJOR=1
VERSION_MINOR=0
VERSION_PATCH=0

View File

@ -2,35 +2,44 @@ import 'package:flutter/material.dart';
import 'package:myhomie_app/constants.dart'; import 'package:myhomie_app/constants.dart';
class RoundedButton extends StatelessWidget { class RoundedButton extends StatelessWidget {
final String text; final String? text;
final Function press; final Function? press;
final IconData? icon;
final Color color, textColor; final Color color, textColor;
final double fontSize; final double? fontSize;
final double? vertical;
final double? horizontal;
const RoundedButton({ const RoundedButton({
Key key, Key? key,
this.text, this.text,
this.press, this.press,
this.icon,
this.color = kBodyTextColor, // TODO this.color = kBodyTextColor, // TODO
this.textColor = Colors.white, this.textColor = Colors.white,
this.fontSize this.fontSize,
this.vertical,
this.horizontal
}) : super(key: key); }) : super(key: key);
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
Size size = MediaQuery.of(context).size; Size size = MediaQuery.of(context).size;
return FlatButton( return TextButton(
shape: RoundedRectangleBorder( style: ButtonStyle(
borderRadius: BorderRadius.circular(35.0), padding: MaterialStateProperty.resolveWith((states) => EdgeInsets.symmetric(vertical: this.vertical != null ? this.vertical! : 25, horizontal: this.horizontal != null ? this.horizontal! : (icon == null ? 85 : 30))),
//side: BorderSide(color: kSubTitleColor) backgroundColor: MaterialStateColor.resolveWith((states) => color),
shape: MaterialStateProperty.all<RoundedRectangleBorder>(
RoundedRectangleBorder(
borderRadius: BorderRadius.circular(30.0),
)
)
), ),
padding: EdgeInsets.symmetric(vertical: 8, horizontal: 25),
color: color,
onPressed: () => { onPressed: () => {
press() press!()
}, },
child: Text( child: Text(
text, text!,
style: new TextStyle(color: textColor, fontSize: fontSize, fontWeight: FontWeight.w400), style: new TextStyle(color: textColor, fontSize: fontSize, fontWeight: FontWeight.w400),
), ),
); );

View File

@ -10,7 +10,7 @@ class CustomNavItem extends StatelessWidget {
final int id; final int id;
final Function setPage; final Function setPage;
const CustomNavItem({this.setPage, this.icon, this.id}); const CustomNavItem({required this.setPage, required this.icon, required this.id});
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {

View File

@ -2,7 +2,7 @@ import 'package:flare_flutter/flare_actor.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
class Loading extends StatelessWidget { class Loading extends StatelessWidget {
Loading({Key key}) : super(key: key); Loading({Key? key}) : super(key: key);
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {

View File

@ -3,14 +3,14 @@ import 'package:myhomie_app/Components/text_field_container.dart';
import 'package:myhomie_app/constants.dart'; import 'package:myhomie_app/constants.dart';
class RoundedInputField extends StatelessWidget { class RoundedInputField extends StatelessWidget {
final String hintText; final String? hintText;
final IconData icon; final IconData? icon;
final ValueChanged<String> onChanged; final ValueChanged<String>? onChanged;
final String initialValue; final String? initialValue;
final Color color, textColor, iconColor; final Color color, textColor, iconColor;
final int maxLength; final int? maxLength;
const RoundedInputField({ const RoundedInputField({
Key key, Key? key,
this.hintText, this.hintText,
this.initialValue, this.initialValue,
this.icon, this.icon,

View File

@ -3,9 +3,9 @@ import 'package:myhomie_app/Components/text_field_container.dart';
import 'package:myhomie_app/constants.dart'; import 'package:myhomie_app/constants.dart';
class RoundedPasswordField extends StatelessWidget { class RoundedPasswordField extends StatelessWidget {
final ValueChanged<String> onChanged; final ValueChanged<String>? onChanged;
const RoundedPasswordField({ const RoundedPasswordField({
Key key, Key? key,
this.onChanged, this.onChanged,
}) : super(key: key); }) : super(key: key);

View File

@ -2,10 +2,10 @@ import 'package:flutter/material.dart';
import 'package:myhomie_app/constants.dart'; import 'package:myhomie_app/constants.dart';
class TextFieldContainer extends StatelessWidget { class TextFieldContainer extends StatelessWidget {
final Widget child; final Widget? child;
final Color color; final Color color;
const TextFieldContainer({ const TextFieldContainer({
Key key, Key? key,
this.child, this.child,
this.color = kBackgroundColor, // TODO this.color = kBackgroundColor, // TODO
}) : super(key: key); }) : super(key: key);

View File

@ -19,12 +19,9 @@ class DatabaseHelper {
DatabaseHelper._privateConstructor(); DatabaseHelper._privateConstructor();
static final DatabaseHelper instance = DatabaseHelper._privateConstructor(); static final DatabaseHelper instance = DatabaseHelper._privateConstructor();
static Database _database; static Database? _database;
Future<Database> get database async { Future<Database> get database async =>
if (_database != null) return _database; _database ??= await _initDatabase();
_database = await _initDatabase();
return _database;
}
_initDatabase() async { _initDatabase() async {
String path = join(await getDatabasesPath(), _databaseName); String path = join(await getDatabasesPath(), _databaseName);
@ -48,8 +45,14 @@ class DatabaseHelper {
Future<int> insert(HomieAppContext homieAppContext) async { Future<int> insert(HomieAppContext homieAppContext) async {
Database db = await instance.database; Database db = await instance.database;
var res = await db.insert(table, homieAppContext.toMap()); var test = await instance.getData();
return res; if(test != null) {
var res = await db.update(table, homieAppContext.toMap());
return res;
} else {
var res = await db.insert(table, homieAppContext.toMap());
return res;
}
} }
Future<void> update(HomieAppContext homieAppContext) async { Future<void> update(HomieAppContext homieAppContext) async {
@ -75,15 +78,17 @@ class DatabaseHelper {
return await db.delete(table, where: '$columnUserId = ?', whereArgs: [userId]); return await db.delete(table, where: '$columnUserId = ?', whereArgs: [userId]);
} }
Future<void> clearTable() async { Future<List<Map<String, Object?>>> clearTable() async {
Database db = await instance.database; Database db = await instance.database;
return await db.rawQuery("DELETE FROM $table"); return await db.rawQuery("DELETE FROM $table");
} }
Future<HomieAppContext> getData() async { Future<HomieAppContext?> getData() async {
HomieAppContext homieAppContext; HomieAppContext? homieAppContext;
await DatabaseHelper.instance.queryAllRows().then((value) { await DatabaseHelper.instance.queryAllRows().then((value) {
print("value");
print(value);
value.forEach((element) { value.forEach((element) {
print("DB - CONTEXT --- "); print("DB - CONTEXT --- ");

View File

@ -21,22 +21,22 @@ class MQTTHelper {
print(homieAppContext.clientMQTT); print(homieAppContext.clientMQTT);
homieAppContext.clientMQTT.updates.listen((List<MqttReceivedMessage<MqttMessage>> c) async { homieAppContext.clientMQTT.updates!.listen((List<MqttReceivedMessage<MqttMessage>> c) async {
print("IN Received message"); print("IN Received message");
final MqttPublishMessage message = c[0].payload; final MqttMessage? message = c[0].payload;
final payload = MqttPublishPayload.bytesToStringAsString(message.payload.message); /*final payload = MqttPublishPayload.bytesToStringAsString(message!);
print('Received message:$payload from topic: ${c[0].topic}'); print('Received message:$payload from topic: ${c[0].topic}');*/
appContext.setLastMessage('Received message:$payload from topic: ${c[0].topic}'); appContext.setLastMessage('Received message:$message from topic: ${c[0].topic}');
var topic = c[0].topic.split('/')[0]; var topic = c[0].topic.split('/')[0];
switch(topic) { switch(topic) {
case "config": case "config":
print('Get message in topic config = $payload'); print('Get message in topic config = $message');
break; break;
case "player": case "player":
print('Get message in topic player = $payload'); print('Get message in topic player = $message');
// refresh device info // refresh device info
try { try {
} }
@ -68,7 +68,7 @@ class MQTTHelper {
print('Unsubscribed topic: $topic'); print('Unsubscribed topic: $topic');
} }
Future<MqttServerClient> connect(dynamic appContext) async { Future<MqttServerClient?> connect(dynamic appContext) async {
HomieAppContext homieAppContext = appContext.getContext(); HomieAppContext homieAppContext = appContext.getContext();
if (homieAppContext == null) { if (homieAppContext == null) {
@ -78,7 +78,7 @@ class MQTTHelper {
print(homieAppContext.host); print(homieAppContext.host);
if(homieAppContext.host != null) { if(homieAppContext.host != null) {
homieAppContext.clientMQTT = MqttServerClient.withPort(homieAppContext.host.replaceAll('http://', ''), 'homie_app_'+ Uuid().v1(), 1883); homieAppContext.clientMQTT = MqttServerClient.withPort(homieAppContext.host!.replaceAll('http://', ''), 'homie_app_'+ Uuid().v1(), 1883);
isInstantiated = true; isInstantiated = true;
homieAppContext.clientMQTT.logging(on: false); homieAppContext.clientMQTT.logging(on: false);
@ -98,7 +98,7 @@ class MQTTHelper {
.keepAliveFor(60) .keepAliveFor(60)
.withWillTopic('player/status') .withWillTopic('player/status')
.withWillMessage(jsonEncode(message)) .withWillMessage(jsonEncode(message))
.withClientIdentifier('tablet_app_'+homieAppContext.userId) .withClientIdentifier('tablet_app_'+homieAppContext.userId!)
.startClean() .startClean()
.withWillQos(MqttQos.atLeastOnce); .withWillQos(MqttQos.atLeastOnce);

View File

@ -1,19 +1,18 @@
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:mqtt_client/mqtt_server_client.dart'; import 'package:mqtt_client/mqtt_server_client.dart';
import 'package:mycoreapi/api.dart';
import 'dart:convert'; import 'dart:convert';
import 'package:myhomie_app/client.dart'; import 'package:myhomie_app/client.dart';
class HomieAppContext with ChangeNotifier{ class HomieAppContext with ChangeNotifier{
Client clientAPI; Client clientAPI = Client("http://192.168.31.140"); // Replace by https://api.mymuseum.be //http://192.168.31.140:8089
MqttServerClient clientMQTT; MqttServerClient clientMQTT = MqttServerClient.withPort("192.168.31.140", "TODO", 1883); // Replace by https://api.mymuseum.be //http://192.168.31.140:8089
String userId; String? userId;
String homeId; String? homeId;
String token; String? token;
String host; String? host;
String language; String? language;
HomieAppContext({this.userId, this.homeId, this.host, this.language, this.token}); HomieAppContext({this.userId, this.homeId, this.host, this.language, this.token});
@ -41,6 +40,6 @@ class HomieAppContext with ChangeNotifier{
// Implement toString to make it easier to see information about // Implement toString to make it easier to see information about
@override @override
String toString() { String toString() {
return 'TabletAppContext{userId: $userId, homeId: $homeId, language: $language, host: $host}'; return 'HomieAppContext{userId: $userId, homeId: $homeId, language: $language, host: $host}';
} }
} }

View File

@ -5,7 +5,7 @@ import 'package:myhomie_app/app_context.dart';
import 'package:provider/provider.dart'; import 'package:provider/provider.dart';
class DebugPage extends StatefulWidget { class DebugPage extends StatefulWidget {
DebugPage({Key key}) : super(key: key); DebugPage({Key? key}) : super(key: key);
@override @override
_DebugPageState createState() => _DebugPageState(); _DebugPageState createState() => _DebugPageState();

View File

@ -3,8 +3,8 @@ import 'package:flutter/material.dart';
class Background extends StatelessWidget { class Background extends StatelessWidget {
final Widget child; final Widget child;
const Background({ const Background({
Key key, Key? key,
@required this.child, required this.child,
}) : super(key: key); }) : super(key: key);
@override @override

View File

@ -1,7 +1,7 @@
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:fluttertoast/fluttertoast.dart'; import 'package:fluttertoast/fluttertoast.dart';
import 'package:mqtt_client/mqtt_server_client.dart'; import 'package:mqtt_client/mqtt_server_client.dart';
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
import 'package:myhomie_app/Components/Buttons/rounded_button.dart'; import 'package:myhomie_app/Components/Buttons/rounded_button.dart';
import 'package:myhomie_app/Components/rounded_input_field.dart'; import 'package:myhomie_app/Components/rounded_input_field.dart';
import 'package:myhomie_app/Components/rounded_password_field.dart'; import 'package:myhomie_app/Components/rounded_password_field.dart';
@ -18,7 +18,7 @@ import '../../../Helpers/DatabaseHelper.dart';
class Body extends StatefulWidget { class Body extends StatefulWidget {
const Body({ const Body({
Key key, Key? key,
}) : super(key: key); }) : super(key: key);
@override @override
@ -27,7 +27,8 @@ class Body extends StatefulWidget {
class _BodyState extends State<Body> { class _BodyState extends State<Body> {
final clientAPI = Client('http://192.168.31.140'); // TODO field final clientAPI = Client('http://192.168.31.140'); // TODO field
TokenDTO token; TokenDTO? token;
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
final appContext = Provider.of<AppContext>(context); final appContext = Provider.of<AppContext>(context);
@ -62,33 +63,37 @@ class _BodyState extends State<Body> {
if (connected) { if (connected) {
HomieAppContext homieAppContext = new HomieAppContext(); HomieAppContext homieAppContext = new HomieAppContext();
UserInfoDetailDTO user = await clientAPI.userApi.userGet("6182c472e20a6dbcfe8fe82c"); // TO replace user get by email UserInfoDetailDTO? user = await clientAPI.userApi!.userGet("6182c472e20a6dbcfe8fe82c"); // TO replace user get by email
print(user); print(user);
homieAppContext.host = "http://192.168.31.140";// TODO if(user != null) {
homieAppContext.clientMQTT = new MqttServerClient(homieAppContext.host.replaceAll('http://', ''),'my_homie_app_'+ Uuid().v1()); homieAppContext.host = "http://192.168.31.140";// TODO
homieAppContext.clientAPI = clientAPI; homieAppContext.clientMQTT = new MqttServerClient(homieAppContext.host!.replaceAll('http://', ''),'my_homie_app_'+ Uuid().v1());
homieAppContext.userId = user.id; homieAppContext.clientAPI = clientAPI;
homieAppContext.language = user.language == null ? 'FR': user.language; // homieAppContext.userId = user.id;
homieAppContext.token = token.accessToken; homieAppContext.language = user.language == null ? 'FR': user.language; //
homieAppContext.token = token!.accessToken;
// TODO check if we select by default or ask user to select // TODO check if we select by default or ask user to select
if(user.homeIds.length > 0) { if(user.homeIds!.length > 0) {
homieAppContext.homeId = user.homeIds.first; homieAppContext.homeId = user.homeIds!.first;
} else { } else {
// TODO invite home creation // TODO invite home creation
}
setState(() {
appContext.setContext(homieAppContext);
});
} }
setState(() {
appContext.setContext(homieAppContext);
});
// STORE IT LOCALLY (SQLite) // STORE IT LOCALLY (SQLite)
HomieAppContext localContext = await DatabaseHelper.instance.getData(); HomieAppContext? localContext = await DatabaseHelper.instance.getData();
if (localContext != null) { // Check if sql DB exist if (localContext != null) { // Check if sql DB exist
print("STORE IT LOCALLY - update");
await DatabaseHelper.instance.update(homieAppContext); await DatabaseHelper.instance.update(homieAppContext);
} else { } else {
print("STORE IT LOCALLY - insert");
await DatabaseHelper.instance.insert(homieAppContext); await DatabaseHelper.instance.insert(homieAppContext);
} }
@ -143,11 +148,11 @@ class _BodyState extends State<Body> {
try { try {
//LoginDTO loginDTO = new LoginDTO(email: "test@email.be", password: "kljqsdkljqsd"); //LoginDTO loginDTO = new LoginDTO(email: "test@email.be", password: "kljqsdkljqsd");
LoginDTO loginDTO = new LoginDTO(email: "", password: ""); LoginDTO loginDTO = new LoginDTO(email: "", password: "");
token = await clientAPI.authenticationApi.authenticationAuthenticateWithJson(loginDTO); token = await clientAPI.authenticationApi!.authenticationAuthenticateWithJson(loginDTO);
print("Token ??"); print("Token ??");
print(token); print(token);
print(token.accessToken); print(token!.accessToken);
setAccessToken(token.accessToken); setAccessToken(token!.accessToken!);
isConnected = true; // TODO update context + db isConnected = true; // TODO update context + db
} }
catch (e) { catch (e) {
@ -215,10 +220,11 @@ class _BodyState extends State<Body> {
} }
void setAccessToken(String accessToken) { void setAccessToken(String accessToken) {
clientAPI.apiApi.authentications.forEach((key, auth) { clientAPI.apiApi!.addDefaultHeader('authorization', 'Bearer '+accessToken);
/*clientAPI.apiApi!.authentications!.forEach((key, auth) {
if (auth is OAuth) { if (auth is OAuth) {
auth.accessToken = accessToken; auth.accessToken = accessToken;
} }
}); });*/
} }
} }

View File

@ -3,7 +3,7 @@ import 'package:myhomie_app/app_context.dart';
import 'package:provider/provider.dart'; import 'package:provider/provider.dart';
class AutomationsScreen extends StatefulWidget { class AutomationsScreen extends StatefulWidget {
AutomationsScreen({Key key}) : super(key: key); AutomationsScreen({Key? key}) : super(key: key);
@override @override
_AutomationsScreenState createState() => _AutomationsScreenState(); _AutomationsScreenState createState() => _AutomationsScreenState();

View File

@ -3,7 +3,7 @@ import 'package:myhomie_app/app_context.dart';
import 'package:provider/provider.dart'; import 'package:provider/provider.dart';
class EnergyScreen extends StatefulWidget { class EnergyScreen extends StatefulWidget {
EnergyScreen({Key key}) : super(key: key); EnergyScreen({Key? key}) : super(key: key);
@override @override
_EnergyScreenState createState() => _EnergyScreenState(); _EnergyScreenState createState() => _EnergyScreenState();

View File

@ -1,5 +1,5 @@
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
import 'package:myhomie_app/Components/loading.dart'; import 'package:myhomie_app/Components/loading.dart';
import 'package:myhomie_app/Models/homieContext.dart'; import 'package:myhomie_app/Models/homieContext.dart';
import 'package:myhomie_app/app_context.dart'; import 'package:myhomie_app/app_context.dart';
@ -7,7 +7,7 @@ import 'package:myhomie_app/constants.dart';
import 'package:provider/provider.dart'; import 'package:provider/provider.dart';
class HomeScreen extends StatefulWidget { class HomeScreen extends StatefulWidget {
HomeScreen({Key key}) : super(key: key); HomeScreen({Key? key}) : super(key: key);
@override @override
_HomeScreenState createState() => _HomeScreenState(); _HomeScreenState createState() => _HomeScreenState();
@ -35,13 +35,13 @@ class _HomeScreenState extends State<HomeScreen> {
return interfaceElements(); return interfaceElements();
} else {*/ } else {*/
return FutureBuilder( return FutureBuilder(
future: homieAppContext.clientAPI.roomApi.roomGetAllWithMainDetails(homieAppContext.homeId), future: homieAppContext.clientAPI.roomApi!.roomGetAllWithMainDetails(homieAppContext.homeId!),
builder: (context, AsyncSnapshot<List<RoomMainDetailDTO>> snapshot) { builder: (context, AsyncSnapshot<List<RoomMainDetailDTO>?> snapshot) {
if (snapshot.connectionState == ConnectionState.done) { if (snapshot.connectionState == ConnectionState.done) {
print("connectionState done"); print("connectionState done");
print(snapshot); print(snapshot);
if(snapshot.data != null) { if(snapshot.data != null) {
return interfaceElements(snapshot.data); return interfaceElements(snapshot.data!);
} else { } else {
return Text("No data - or error"); return Text("No data - or error");
} }
@ -70,7 +70,7 @@ class _HomeScreenState extends State<HomeScreen> {
displacement: 20, displacement: 20,
onRefresh: () async { onRefresh: () async {
print("onRefresh"); print("onRefresh");
await homieAppContext.clientAPI.roomApi.roomGetAllWithMainDetails(homieAppContext.homeId); await homieAppContext.clientAPI.roomApi!.roomGetAllWithMainDetails(homieAppContext.homeId!);
}, },
child: Container( child: Container(
height: size.height * 0.8, height: size.height * 0.8,
@ -101,14 +101,14 @@ class _HomeScreenState extends State<HomeScreen> {
Align( Align(
alignment: Alignment.bottomLeft, alignment: Alignment.bottomLeft,
child: Text( child: Text(
roomsMaindetails[index].name, roomsMaindetails[index].name!,
style: new TextStyle(fontSize: kDetailSize, color: kBackgroundSecondGrey), style: new TextStyle(fontSize: kDetailSize, color: kBackgroundSecondGrey),
), ),
), ),
], ],
), ),
if(roomsMaindetails[index].isTemperature) if(roomsMaindetails[index].isTemperature!)
Positioned( Positioned(
bottom: 10, bottom: 10,
left: 0, left: 0,
@ -120,7 +120,7 @@ class _HomeScreenState extends State<HomeScreen> {
color: kMainColor, color: kMainColor,
), ),
Text( Text(
roomsMaindetails[index].temperature, roomsMaindetails[index].temperature!,
style: new TextStyle(fontSize: kDescriptionDetailSize, color: kBackgroundSecondGrey), style: new TextStyle(fontSize: kDescriptionDetailSize, color: kBackgroundSecondGrey),
maxLines: 1, maxLines: 1,
), ),
@ -128,10 +128,10 @@ class _HomeScreenState extends State<HomeScreen> {
) )
), ),
if(roomsMaindetails[index].isHumidity) if(roomsMaindetails[index].isHumidity!)
Positioned( Positioned(
bottom: 10, bottom: 10,
left: roomsMaindetails[index].isTemperature ? 55 : 0, left: roomsMaindetails[index].isTemperature! ? 60 : 0,
child: Row( child: Row(
children: [ children: [
Icon( Icon(
@ -140,7 +140,7 @@ class _HomeScreenState extends State<HomeScreen> {
color: kMainColor, color: kMainColor,
), ),
Text( Text(
roomsMaindetails[index].humidity, roomsMaindetails[index].humidity!,
style: new TextStyle(fontSize: kDescriptionDetailSize, color: kBackgroundSecondGrey), style: new TextStyle(fontSize: kDescriptionDetailSize, color: kBackgroundSecondGrey),
maxLines: 1, maxLines: 1,
), ),
@ -148,7 +148,7 @@ class _HomeScreenState extends State<HomeScreen> {
) )
), ),
if(roomsMaindetails[index].isDoor) if(roomsMaindetails[index].isDoor!)
Positioned( Positioned(
bottom: 10, bottom: 10,
right: 5, right: 5,
@ -157,22 +157,22 @@ class _HomeScreenState extends State<HomeScreen> {
Icon( Icon(
Icons.motion_photos_on_rounded, Icons.motion_photos_on_rounded,
size: 20, size: 20,
color: !roomsMaindetails[index].door ? kMainColor : kBackgroundSecondGrey, color: !roomsMaindetails[index].door! ? kMainColor : kBackgroundSecondGrey,
), ),
], ],
) )
), ),
if(roomsMaindetails[index].isMotion) if(roomsMaindetails[index].isMotion!)
Positioned( Positioned(
bottom: 10, bottom: 10,
right: roomsMaindetails[index].isDoor ? 20 : 5, right: roomsMaindetails[index].isDoor! ? 20 : 5,
child: Row( child: Row(
children: [ children: [
Icon( Icon(
Icons.directions_walk, Icons.directions_walk,
size: 20, size: 20,
color: roomsMaindetails[index].motion ? kMainColor : kBackgroundSecondGrey, color: roomsMaindetails[index].motion! ? kMainColor : kBackgroundSecondGrey,
), ),
], ],
) )

View File

@ -22,7 +22,7 @@ PageController pageController = PageController(initialPage: 0);
int currentIndex = 0; int currentIndex = 0;
class MainPage extends StatefulWidget { class MainPage extends StatefulWidget {
MainPage({Key key}) : super(key: key); MainPage({Key? key}) : super(key: key);
@override @override
_MainPageState createState() => _MainPageState(); _MainPageState createState() => _MainPageState();

View File

@ -3,7 +3,7 @@ import 'package:myhomie_app/app_context.dart';
import 'package:provider/provider.dart'; import 'package:provider/provider.dart';
class ProfileScreen extends StatefulWidget { class ProfileScreen extends StatefulWidget {
ProfileScreen({Key key}) : super(key: key); ProfileScreen({Key? key}) : super(key: key);
@override @override
_ProfileScreenState createState() => _ProfileScreenState(); _ProfileScreenState createState() => _ProfileScreenState();

View File

@ -3,7 +3,7 @@ import 'package:myhomie_app/app_context.dart';
import 'package:provider/provider.dart'; import 'package:provider/provider.dart';
class SecurityScreen extends StatefulWidget { class SecurityScreen extends StatefulWidget {
SecurityScreen({Key key}) : super(key: key); SecurityScreen({Key? key}) : super(key: key);
@override @override
_SecurityScreenState createState() => _SecurityScreenState(); _SecurityScreenState createState() => _SecurityScreenState();

15
lib/api/openApiTest.dart Normal file
View File

@ -0,0 +1,15 @@
import 'package:openapi_generator_annotations/openapi_generator_annotations.dart';
@Openapi(
additionalProperties:
AdditionalProperties(pubName: 'mycore_api', pubAuthor: 'Fransolet Thomas', useEnumExtension: true),
inputSpecFile: 'lib/api/swagger.yaml',
generatorName: Generator.dart,
alwaysRun: true,
outputDirectory: 'mycore_api')
class Example extends OpenapiGeneratorConfig {}
/*
RUN
>flutter pub run build_runner build --delete-conflicting-outputs
*/

4888
lib/api/swagger.yaml Normal file

File diff suppressed because it is too large Load Diff

View File

@ -5,7 +5,7 @@ import 'Models/homieContext.dart';
class AppContext with ChangeNotifier { class AppContext with ChangeNotifier {
HomieAppContext _homieContext; HomieAppContext _homieContext;
Client clientAPI; Client clientAPI = Client("http://192.168.31.140");
List<String> _lastMQTTMessages = []; List<String> _lastMQTTMessages = [];
AppContext(this._homieContext); AppContext(this._homieContext);

View File

@ -1,42 +1,41 @@
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
//import 'package:openapi_dart_common/openapi.dart';
class Client { class Client {
ApiClient _apiClient; ApiClient? _apiClient;
ApiClient get apiApi => _apiClient; ApiClient? get apiApi => _apiClient;
TokenApi _tokenApi; TokenApi? _tokenApi;
TokenApi get tokenApi => _tokenApi; TokenApi? get tokenApi => _tokenApi;
AuthenticationApi _authenticationApi; AuthenticationApi? _authenticationApi;
AuthenticationApi get authenticationApi => _authenticationApi; AuthenticationApi? get authenticationApi => _authenticationApi;
UserApi _userApi; UserApi? _userApi;
UserApi get userApi => _userApi; UserApi? get userApi => _userApi;
HomeApi _homeApi; HomeApi? _homeApi;
HomeApi get homeApi => _homeApi; HomeApi? get homeApi => _homeApi;
AlarmApi _alarmApi; AlarmApi? _alarmApi;
AlarmApi get alarmApi => _alarmApi; AlarmApi? get alarmApi => _alarmApi;
EventApi _eventApi; EventApi? _eventApi;
EventApi get eventApi => _eventApi; EventApi? get eventApi => _eventApi;
GroupApi _groupApi; GroupApi? _groupApi;
GroupApi get groupApi => _groupApi; GroupApi? get groupApi => _groupApi;
DeviceApi _deviceApi; DeviceApi? _deviceApi;
DeviceApi get deviceApi => _deviceApi; DeviceApi? get deviceApi => _deviceApi;
AutomationApi _automationApi; AutomationApi? _automationApi;
AutomationApi get automationApi => _automationApi; AutomationApi? get automationApi => _automationApi;
ProviderApi _providerApi; ProviderApi? _providerApi;
ProviderApi get providerApi => _providerApi; ProviderApi? get providerApi => _providerApi;
RoomApi _roomApi; RoomApi? _roomApi;
RoomApi get roomApi => _roomApi; RoomApi? get roomApi => _roomApi;
Client(String path) { Client(String path) {
_apiClient = ApiClient( _apiClient = ApiClient(

View File

@ -12,14 +12,14 @@ import 'constants.dart';
void main() async { void main() async {
WidgetsFlutterBinding.ensureInitialized(); WidgetsFlutterBinding.ensureInitialized();
String initialRoute; String initialRoute;
HomieAppContext localContext = new HomieAppContext(); HomieAppContext? localContext = new HomieAppContext();
bool isLogged = false; bool isLogged = false;
localContext = await DatabaseHelper.instance.getData(); localContext = await DatabaseHelper.instance.getData();
if(localContext != null) { if(localContext != null) {
print("we've got an local db !"); print("we've got an local db !");
localContext.clientAPI = new Client(localContext.host); // TODO "http://192.168.31.140" localContext.clientAPI = new Client(localContext.host!); // TODO "http://192.168.31.140"
//isLogged = localContext.token != null; // TODO refresh token.. //isLogged = localContext.token != null; // TODO refresh token..
isLogged = false; isLogged = false;
print(localContext); print(localContext);
@ -31,16 +31,16 @@ void main() async {
final MyApp myApp = MyApp( final MyApp myApp = MyApp(
initialRoute: initialRoute, initialRoute: initialRoute,
homieAppContext: localContext, homieAppContext: localContext!,
); );
runApp(myApp); runApp(myApp);
} }
class MyApp extends StatefulWidget { class MyApp extends StatefulWidget {
final String initialRoute; String initialRoute = "";
final HomieAppContext homieAppContext; HomieAppContext homieAppContext;
MyApp({this.initialRoute, this.homieAppContext}); MyApp({Key? key, required this.initialRoute, required this.homieAppContext}) : super(key: key);
@override @override
_MyAppState createState() => _MyAppState(); _MyAppState createState() => _MyAppState();

View File

@ -5,6 +5,9 @@
list(APPEND FLUTTER_PLUGIN_LIST list(APPEND FLUTTER_PLUGIN_LIST
) )
list(APPEND FLUTTER_FFI_PLUGIN_LIST
)
set(PLUGIN_BUNDLED_LIBRARIES) set(PLUGIN_BUNDLED_LIBRARIES)
foreach(plugin ${FLUTTER_PLUGIN_LIST}) foreach(plugin ${FLUTTER_PLUGIN_LIST})
@ -13,3 +16,8 @@ foreach(plugin ${FLUTTER_PLUGIN_LIST})
list(APPEND PLUGIN_BUNDLED_LIBRARIES $<TARGET_FILE:${plugin}_plugin>) list(APPEND PLUGIN_BUNDLED_LIBRARIES $<TARGET_FILE:${plugin}_plugin>)
list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries})
endforeach(plugin) endforeach(plugin)
foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST})
add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/linux plugins/${ffi_plugin})
list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries})
endforeach(ffi_plugin)

32
mycore_api/.gitignore vendored
View File

@ -1,27 +1,17 @@
# See https://www.dartlang.org/tools/private-files.html # See https://dart.dev/guides/libraries/private-files
# Files and directories created by pub .dart_tool/
.buildlog
.packages .packages
.project
.pub/
build/ build/
**/packages/ pubspec.lock # Except for application packages
# Files created by dart2js
# (Most Dart developers will use pub build to compile Dart, use/modify these
# rules if you intend to use dart2js directly
# Convention is to use extension '.dart.js' for Dart compiled to Javascript to
# differentiate from explicit Javascript files)
*.dart.js
*.part.js
*.js.deps
*.js.map
*.info.json
# Directory created by dartdoc
doc/api/ doc/api/
# Don't commit pubspec lock file # IntelliJ
# (Library packages only! Remove pattern if developing an application package) *.iml
pubspec.lock *.ipr
*.iws
.idea/
# Mac
.DS_Store

View File

@ -1,6 +1,8 @@
.gitignore .gitignore
.openapi-generator-ignore
.travis.yml .travis.yml
README.md README.md
analysis_options.yaml
doc/Action.md doc/Action.md
doc/ActionType.md doc/ActionType.md
doc/AlarmApi.md doc/AlarmApi.md
@ -10,6 +12,8 @@ doc/AlarmModeCreateOrUpdateDetailDTOAllOf.md
doc/AlarmModeDTO.md doc/AlarmModeDTO.md
doc/AlarmModeDetailDTO.md doc/AlarmModeDetailDTO.md
doc/AlarmModeDetailDTOAllOf.md doc/AlarmModeDetailDTOAllOf.md
doc/AlarmModeGeolocalizedMode.md
doc/AlarmModeProgrammedMode.md
doc/AlarmTriggered.md doc/AlarmTriggered.md
doc/AlarmType.md doc/AlarmType.md
doc/AuthenticationApi.md doc/AuthenticationApi.md
@ -24,6 +28,7 @@ doc/AzureApi.md
doc/Book.md doc/Book.md
doc/BooksApi.md doc/BooksApi.md
doc/Condition.md doc/Condition.md
doc/ConditionState.md
doc/ConditionType.md doc/ConditionType.md
doc/ConditionValue.md doc/ConditionValue.md
doc/ConnectionStatus.md doc/ConnectionStatus.md
@ -42,6 +47,8 @@ doc/EventDTO.md
doc/EventDetailDTO.md doc/EventDetailDTO.md
doc/EventDetailDTOAllOf.md doc/EventDetailDTOAllOf.md
doc/EventFilter.md doc/EventFilter.md
doc/EventGetDeviceTypeParameter.md
doc/EventGetEventTypeParameter.md
doc/EventHomeFilter.md doc/EventHomeFilter.md
doc/EventHomeFilterAllOf.md doc/EventHomeFilterAllOf.md
doc/EventType.md doc/EventType.md
@ -58,17 +65,20 @@ doc/GroupDetailDTOAllOf.md
doc/GroupSummaryDTO.md doc/GroupSummaryDTO.md
doc/HomeApi.md doc/HomeApi.md
doc/HomeDTO.md doc/HomeDTO.md
doc/HomeDTOCurrentAlarmMode.md
doc/HomeDetailDTO.md doc/HomeDetailDTO.md
doc/HomeDetailDTOAllOf.md doc/HomeDetailDTOAllOf.md
doc/IOTApi.md doc/IOTApi.md
doc/LayoutApi.md doc/LayoutApi.md
doc/ListResponseOfEventDetailDTOAndEventHomeFilter.md doc/ListResponseOfEventDetailDTOAndEventHomeFilter.md
doc/ListResponseOfEventDetailDTOAndEventHomeFilterRequestParameters.md
doc/LoginDTO.md doc/LoginDTO.md
doc/MQTTApi.md doc/MQTTApi.md
doc/MeansOfCommunication.md doc/MeansOfCommunication.md
doc/MqttMessageDTO.md doc/MqttMessageDTO.md
doc/OddApi.md doc/OddApi.md
doc/OddNice.md doc/OddNice.md
doc/OddNiceOdds.md
doc/OddObject.md doc/OddObject.md
doc/PanelMenuItem.md doc/PanelMenuItem.md
doc/PanelSection.md doc/PanelSection.md
@ -87,6 +97,7 @@ doc/ScreenDeviceApi.md
doc/SmartGardenMessage.md doc/SmartGardenMessage.md
doc/SmartPrinterMessage.md doc/SmartPrinterMessage.md
doc/TimePeriodAlarm.md doc/TimePeriodAlarm.md
doc/TimePeriodAlarmAlarmMode.md
doc/TokenApi.md doc/TokenApi.md
doc/TokenDTO.md doc/TokenDTO.md
doc/Trigger.md doc/Trigger.md
@ -140,6 +151,8 @@ lib/model/alarm_mode_create_or_update_detail_dto_all_of.dart
lib/model/alarm_mode_detail_dto.dart lib/model/alarm_mode_detail_dto.dart
lib/model/alarm_mode_detail_dto_all_of.dart lib/model/alarm_mode_detail_dto_all_of.dart
lib/model/alarm_mode_dto.dart lib/model/alarm_mode_dto.dart
lib/model/alarm_mode_geolocalized_mode.dart
lib/model/alarm_mode_programmed_mode.dart
lib/model/alarm_triggered.dart lib/model/alarm_triggered.dart
lib/model/alarm_type.dart lib/model/alarm_type.dart
lib/model/automation_detail_dto.dart lib/model/automation_detail_dto.dart
@ -150,6 +163,7 @@ lib/model/automation_triggered.dart
lib/model/azure_ad_auth_model.dart lib/model/azure_ad_auth_model.dart
lib/model/book.dart lib/model/book.dart
lib/model/condition.dart lib/model/condition.dart
lib/model/condition_state.dart
lib/model/condition_type.dart lib/model/condition_type.dart
lib/model/condition_value.dart lib/model/condition_value.dart
lib/model/connection_status.dart lib/model/connection_status.dart
@ -165,6 +179,8 @@ lib/model/event_detail_dto.dart
lib/model/event_detail_dto_all_of.dart lib/model/event_detail_dto_all_of.dart
lib/model/event_dto.dart lib/model/event_dto.dart
lib/model/event_filter.dart lib/model/event_filter.dart
lib/model/event_get_device_type_parameter.dart
lib/model/event_get_event_type_parameter.dart
lib/model/event_home_filter.dart lib/model/event_home_filter.dart
lib/model/event_home_filter_all_of.dart lib/model/event_home_filter_all_of.dart
lib/model/event_type.dart lib/model/event_type.dart
@ -179,11 +195,14 @@ lib/model/group_summary_dto.dart
lib/model/home_detail_dto.dart lib/model/home_detail_dto.dart
lib/model/home_detail_dto_all_of.dart lib/model/home_detail_dto_all_of.dart
lib/model/home_dto.dart lib/model/home_dto.dart
lib/model/home_dto_current_alarm_mode.dart
lib/model/list_response_of_event_detail_dto_and_event_home_filter.dart lib/model/list_response_of_event_detail_dto_and_event_home_filter.dart
lib/model/list_response_of_event_detail_dto_and_event_home_filter_request_parameters.dart
lib/model/login_dto.dart lib/model/login_dto.dart
lib/model/means_of_communication.dart lib/model/means_of_communication.dart
lib/model/mqtt_message_dto.dart lib/model/mqtt_message_dto.dart
lib/model/odd_nice.dart lib/model/odd_nice.dart
lib/model/odd_nice_odds.dart
lib/model/odd_object.dart lib/model/odd_object.dart
lib/model/panel_menu_item.dart lib/model/panel_menu_item.dart
lib/model/panel_section.dart lib/model/panel_section.dart
@ -199,6 +218,7 @@ lib/model/screen_device.dart
lib/model/smart_garden_message.dart lib/model/smart_garden_message.dart
lib/model/smart_printer_message.dart lib/model/smart_printer_message.dart
lib/model/time_period_alarm.dart lib/model/time_period_alarm.dart
lib/model/time_period_alarm_alarm_mode.dart
lib/model/token_dto.dart lib/model/token_dto.dart
lib/model/trigger.dart lib/model/trigger.dart
lib/model/trigger_type.dart lib/model/trigger_type.dart
@ -208,3 +228,110 @@ lib/model/user_info.dart
lib/model/user_info_detail_dto.dart lib/model/user_info_detail_dto.dart
lib/model/view_by.dart lib/model/view_by.dart
pubspec.yaml pubspec.yaml
test/action_test.dart
test/action_type_test.dart
test/alarm_api_test.dart
test/alarm_mode_create_or_update_detail_dto_all_of_test.dart
test/alarm_mode_create_or_update_detail_dto_test.dart
test/alarm_mode_detail_dto_all_of_test.dart
test/alarm_mode_detail_dto_test.dart
test/alarm_mode_dto_test.dart
test/alarm_mode_geolocalized_mode_test.dart
test/alarm_mode_programmed_mode_test.dart
test/alarm_mode_test.dart
test/alarm_triggered_test.dart
test/alarm_type_test.dart
test/authentication_api_test.dart
test/automation_api_test.dart
test/automation_detail_dto_all_of_test.dart
test/automation_detail_dto_test.dart
test/automation_dto_test.dart
test/automation_state_test.dart
test/automation_triggered_test.dart
test/azure_ad_auth_model_test.dart
test/azure_api_test.dart
test/book_test.dart
test/books_api_test.dart
test/condition_state_test.dart
test/condition_test.dart
test/condition_type_test.dart
test/condition_value_test.dart
test/connection_status_test.dart
test/create_or_update_home_dto_all_of_test.dart
test/create_or_update_home_dto_test.dart
test/device_api_test.dart
test/device_detail_dto_all_of_test.dart
test/device_detail_dto_test.dart
test/device_state_test.dart
test/device_summary_dto_test.dart
test/device_type_test.dart
test/electricity_production_test.dart
test/energy_api_test.dart
test/event_api_test.dart
test/event_detail_dto_all_of_test.dart
test/event_detail_dto_test.dart
test/event_dto_test.dart
test/event_filter_test.dart
test/event_get_device_type_parameter_test.dart
test/event_get_event_type_parameter_test.dart
test/event_home_filter_all_of_test.dart
test/event_home_filter_test.dart
test/event_type_test.dart
test/facebook_api_test.dart
test/facebook_auth_model_test.dart
test/geolocalized_mode_test.dart
test/google_api_test.dart
test/google_auth_model_test.dart
test/group_api_test.dart
test/group_create_or_update_detail_dto_all_of_test.dart
test/group_create_or_update_detail_dto_test.dart
test/group_detail_dto_all_of_test.dart
test/group_detail_dto_test.dart
test/group_summary_dto_test.dart
test/home_api_test.dart
test/home_detail_dto_all_of_test.dart
test/home_detail_dto_test.dart
test/home_dto_current_alarm_mode_test.dart
test/home_dto_test.dart
test/iot_api_test.dart
test/layout_api_test.dart
test/list_response_of_event_detail_dto_and_event_home_filter_request_parameters_test.dart
test/list_response_of_event_detail_dto_and_event_home_filter_test.dart
test/login_dto_test.dart
test/means_of_communication_test.dart
test/mqtt_api_test.dart
test/mqtt_message_dto_test.dart
test/odd_api_test.dart
test/odd_nice_odds_test.dart
test/odd_nice_test.dart
test/odd_object_test.dart
test/panel_menu_item_test.dart
test/panel_section_test.dart
test/programmed_mode_test.dart
test/provider_api_test.dart
test/provider_dto_test.dart
test/provider_type_test.dart
test/room_api_test.dart
test/room_create_or_update_detail_dto_test.dart
test/room_detail_dto_test.dart
test/room_main_detail_dto_all_of_test.dart
test/room_main_detail_dto_test.dart
test/room_summary_dto_test.dart
test/screen_device_api_test.dart
test/screen_device_test.dart
test/smart_garden_message_test.dart
test/smart_printer_message_test.dart
test/time_period_alarm_alarm_mode_test.dart
test/time_period_alarm_test.dart
test/token_api_test.dart
test/token_dto_test.dart
test/trigger_test.dart
test/trigger_type_test.dart
test/twitter_api_test.dart
test/twitter_auth_model_test.dart
test/user_api_test.dart
test/user_info_detail_dto_test.dart
test/user_info_test.dart
test/user_test.dart
test/values_api_test.dart
test/view_by_test.dart

View File

@ -1 +1 @@
5.1.0 unset

View File

@ -6,7 +6,7 @@
language: dart language: dart
dart: dart:
# Install a specific stable release # Install a specific stable release
- "2.2.0" - "2.12"
install: install:
- pub get - pub get

View File

@ -1,4 +1,4 @@
# mycoreapi # mycore_api
API description API description
This Dart package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project: This Dart package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
@ -8,7 +8,7 @@ This Dart package is automatically generated by the [OpenAPI Generator](https://
## Requirements ## Requirements
Dart 2.0 or later Dart 2.12 or later
## Installation & Usage ## Installation & Usage
@ -16,7 +16,7 @@ Dart 2.0 or later
If this Dart package is published to Github, add the following dependency to your pubspec.yaml If this Dart package is published to Github, add the following dependency to your pubspec.yaml
``` ```
dependencies: dependencies:
mycoreapi: mycore_api:
git: https://github.com/GIT_USER_ID/GIT_REPO_ID.git git: https://github.com/GIT_USER_ID/GIT_REPO_ID.git
``` ```
@ -24,8 +24,8 @@ dependencies:
To use the package in your local drive, add the following dependency to your pubspec.yaml To use the package in your local drive, add the following dependency to your pubspec.yaml
``` ```
dependencies: dependencies:
mycoreapi: mycore_api:
path: /path/to/mycoreapi path: /path/to/mycore_api
``` ```
## Tests ## Tests
@ -37,7 +37,7 @@ TODO
Please follow the [installation procedure](#installation--usage) and then run the following: Please follow the [installation procedure](#installation--usage) and then run the following:
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
@ -56,7 +56,7 @@ try {
## Documentation for API Endpoints ## Documentation for API Endpoints
All URIs are relative to *http://localhost:5000* All URIs are relative to *http://192.168.31.140*
Class | Method | HTTP request | Description Class | Method | HTTP request | Description
------------ | ------------- | ------------- | ------------- ------------ | ------------- | ------------- | -------------
@ -167,6 +167,8 @@ Class | Method | HTTP request | Description
- [AlarmModeDTO](doc\/AlarmModeDTO.md) - [AlarmModeDTO](doc\/AlarmModeDTO.md)
- [AlarmModeDetailDTO](doc\/AlarmModeDetailDTO.md) - [AlarmModeDetailDTO](doc\/AlarmModeDetailDTO.md)
- [AlarmModeDetailDTOAllOf](doc\/AlarmModeDetailDTOAllOf.md) - [AlarmModeDetailDTOAllOf](doc\/AlarmModeDetailDTOAllOf.md)
- [AlarmModeGeolocalizedMode](doc\/AlarmModeGeolocalizedMode.md)
- [AlarmModeProgrammedMode](doc\/AlarmModeProgrammedMode.md)
- [AlarmTriggered](doc\/AlarmTriggered.md) - [AlarmTriggered](doc\/AlarmTriggered.md)
- [AlarmType](doc\/AlarmType.md) - [AlarmType](doc\/AlarmType.md)
- [AutomationDTO](doc\/AutomationDTO.md) - [AutomationDTO](doc\/AutomationDTO.md)
@ -177,6 +179,7 @@ Class | Method | HTTP request | Description
- [AzureADAuthModel](doc\/AzureADAuthModel.md) - [AzureADAuthModel](doc\/AzureADAuthModel.md)
- [Book](doc\/Book.md) - [Book](doc\/Book.md)
- [Condition](doc\/Condition.md) - [Condition](doc\/Condition.md)
- [ConditionState](doc\/ConditionState.md)
- [ConditionType](doc\/ConditionType.md) - [ConditionType](doc\/ConditionType.md)
- [ConditionValue](doc\/ConditionValue.md) - [ConditionValue](doc\/ConditionValue.md)
- [ConnectionStatus](doc\/ConnectionStatus.md) - [ConnectionStatus](doc\/ConnectionStatus.md)
@ -192,6 +195,8 @@ Class | Method | HTTP request | Description
- [EventDetailDTO](doc\/EventDetailDTO.md) - [EventDetailDTO](doc\/EventDetailDTO.md)
- [EventDetailDTOAllOf](doc\/EventDetailDTOAllOf.md) - [EventDetailDTOAllOf](doc\/EventDetailDTOAllOf.md)
- [EventFilter](doc\/EventFilter.md) - [EventFilter](doc\/EventFilter.md)
- [EventGetDeviceTypeParameter](doc\/EventGetDeviceTypeParameter.md)
- [EventGetEventTypeParameter](doc\/EventGetEventTypeParameter.md)
- [EventHomeFilter](doc\/EventHomeFilter.md) - [EventHomeFilter](doc\/EventHomeFilter.md)
- [EventHomeFilterAllOf](doc\/EventHomeFilterAllOf.md) - [EventHomeFilterAllOf](doc\/EventHomeFilterAllOf.md)
- [EventType](doc\/EventType.md) - [EventType](doc\/EventType.md)
@ -204,13 +209,16 @@ Class | Method | HTTP request | Description
- [GroupDetailDTOAllOf](doc\/GroupDetailDTOAllOf.md) - [GroupDetailDTOAllOf](doc\/GroupDetailDTOAllOf.md)
- [GroupSummaryDTO](doc\/GroupSummaryDTO.md) - [GroupSummaryDTO](doc\/GroupSummaryDTO.md)
- [HomeDTO](doc\/HomeDTO.md) - [HomeDTO](doc\/HomeDTO.md)
- [HomeDTOCurrentAlarmMode](doc\/HomeDTOCurrentAlarmMode.md)
- [HomeDetailDTO](doc\/HomeDetailDTO.md) - [HomeDetailDTO](doc\/HomeDetailDTO.md)
- [HomeDetailDTOAllOf](doc\/HomeDetailDTOAllOf.md) - [HomeDetailDTOAllOf](doc\/HomeDetailDTOAllOf.md)
- [ListResponseOfEventDetailDTOAndEventHomeFilter](doc\/ListResponseOfEventDetailDTOAndEventHomeFilter.md) - [ListResponseOfEventDetailDTOAndEventHomeFilter](doc\/ListResponseOfEventDetailDTOAndEventHomeFilter.md)
- [ListResponseOfEventDetailDTOAndEventHomeFilterRequestParameters](doc\/ListResponseOfEventDetailDTOAndEventHomeFilterRequestParameters.md)
- [LoginDTO](doc\/LoginDTO.md) - [LoginDTO](doc\/LoginDTO.md)
- [MeansOfCommunication](doc\/MeansOfCommunication.md) - [MeansOfCommunication](doc\/MeansOfCommunication.md)
- [MqttMessageDTO](doc\/MqttMessageDTO.md) - [MqttMessageDTO](doc\/MqttMessageDTO.md)
- [OddNice](doc\/OddNice.md) - [OddNice](doc\/OddNice.md)
- [OddNiceOdds](doc\/OddNiceOdds.md)
- [OddObject](doc\/OddObject.md) - [OddObject](doc\/OddObject.md)
- [PanelMenuItem](doc\/PanelMenuItem.md) - [PanelMenuItem](doc\/PanelMenuItem.md)
- [PanelSection](doc\/PanelSection.md) - [PanelSection](doc\/PanelSection.md)
@ -226,6 +234,7 @@ Class | Method | HTTP request | Description
- [SmartGardenMessage](doc\/SmartGardenMessage.md) - [SmartGardenMessage](doc\/SmartGardenMessage.md)
- [SmartPrinterMessage](doc\/SmartPrinterMessage.md) - [SmartPrinterMessage](doc\/SmartPrinterMessage.md)
- [TimePeriodAlarm](doc\/TimePeriodAlarm.md) - [TimePeriodAlarm](doc\/TimePeriodAlarm.md)
- [TimePeriodAlarmAlarmMode](doc\/TimePeriodAlarmAlarmMode.md)
- [TokenDTO](doc\/TokenDTO.md) - [TokenDTO](doc\/TokenDTO.md)
- [Trigger](doc\/Trigger.md) - [Trigger](doc\/Trigger.md)
- [TriggerType](doc\/TriggerType.md) - [TriggerType](doc\/TriggerType.md)
@ -252,4 +261,3 @@ Class | Method | HTTP request | Description

View File

View File

@ -1,8 +1,8 @@
# mycoreapi.model.Action # mycore_api.model.Action
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.ActionType # mycore_api.model.ActionType
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,11 +1,11 @@
# mycoreapi.api.AlarmApi # mycore_api.api.AlarmApi
## Load the API package ## Load the API package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
All URIs are relative to *http://localhost:5000* All URIs are relative to *http://192.168.31.140*
Method | HTTP request | Description Method | HTTP request | Description
------------- | ------------- | ------------- ------------- | ------------- | -------------
@ -24,16 +24,16 @@ Method | HTTP request | Description
Activate specified alarm mode Activate specified alarm mode
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = AlarmApi(); final api_instance = AlarmApi();
final alarmModeId = alarmModeId_example; // String | Alarm mode to activate final alarmModeId = alarmModeId_example; // String | Alarm mode to activate
try { try {
final result = api_instance.alarmActivate(alarmModeId); final result = api_instance.alarmActivate(alarmModeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -67,16 +67,16 @@ Name | Type | Description | Notes
Create an alarm mode Create an alarm mode
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = AlarmApi(); final api_instance = AlarmApi();
final alarmModeCreateOrUpdateDetailDTO = AlarmModeCreateOrUpdateDetailDTO(); // AlarmModeCreateOrUpdateDetailDTO | Alarm mode to create final alarmModeCreateOrUpdateDetailDTO = AlarmModeCreateOrUpdateDetailDTO(); // AlarmModeCreateOrUpdateDetailDTO | Alarm mode to create
try { try {
final result = api_instance.alarmCreate(alarmModeCreateOrUpdateDetailDTO); final result = api_instance.alarmCreate(alarmModeCreateOrUpdateDetailDTO);
print(result); print(result);
} catch (e) { } catch (e) {
@ -110,16 +110,16 @@ Name | Type | Description | Notes
Create default alarm modes Create default alarm modes
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = AlarmApi(); final api_instance = AlarmApi();
final homeId = homeId_example; // String | Home Id final homeId = homeId_example; // String | Home Id
try { try {
final result = api_instance.alarmCreateDefaultAlarms(homeId); final result = api_instance.alarmCreateDefaultAlarms(homeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -153,16 +153,16 @@ Name | Type | Description | Notes
Delete an alarm mode Delete an alarm mode
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = AlarmApi(); final api_instance = AlarmApi();
final alarmModeId = alarmModeId_example; // String | Id of alarm mode to delete final alarmModeId = alarmModeId_example; // String | Id of alarm mode to delete
try { try {
final result = api_instance.alarmDelete(alarmModeId); final result = api_instance.alarmDelete(alarmModeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -196,16 +196,16 @@ Name | Type | Description | Notes
Delete all alarm mode for a specified home Delete all alarm mode for a specified home
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = AlarmApi(); final api_instance = AlarmApi();
final homeId = homeId_example; // String | Home Id final homeId = homeId_example; // String | Home Id
try { try {
final result = api_instance.alarmDeleteAllForHome(homeId); final result = api_instance.alarmDeleteAllForHome(homeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -239,16 +239,16 @@ Name | Type | Description | Notes
Get all alarm modes for the specified home Get all alarm modes for the specified home
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = AlarmApi(); final api_instance = AlarmApi();
final homeId = homeId_example; // String | Home Id final homeId = homeId_example; // String | Home Id
try { try {
final result = api_instance.alarmGetAll(homeId); final result = api_instance.alarmGetAll(homeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -282,16 +282,16 @@ Name | Type | Description | Notes
Get detail info of a specified alarm mode Get detail info of a specified alarm mode
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = AlarmApi(); final api_instance = AlarmApi();
final alarmModeId = alarmModeId_example; // String | alarm id final alarmModeId = alarmModeId_example; // String | alarm id
try { try {
final result = api_instance.alarmGetDetail(alarmModeId); final result = api_instance.alarmGetDetail(alarmModeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -325,16 +325,16 @@ Name | Type | Description | Notes
Update an alarm mode Update an alarm mode
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = AlarmApi(); final api_instance = AlarmApi();
final alarmModeCreateOrUpdateDetailDTO = AlarmModeCreateOrUpdateDetailDTO(); // AlarmModeCreateOrUpdateDetailDTO | alarm mode to update final alarmModeCreateOrUpdateDetailDTO = AlarmModeCreateOrUpdateDetailDTO(); // AlarmModeCreateOrUpdateDetailDTO | alarm mode to update
try { try {
final result = api_instance.alarmUpdate(alarmModeCreateOrUpdateDetailDTO); final result = api_instance.alarmUpdate(alarmModeCreateOrUpdateDetailDTO);
print(result); print(result);
} catch (e) { } catch (e) {

View File

@ -1,8 +1,8 @@
# mycoreapi.model.AlarmMode # mycore_api.model.AlarmMode
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties
@ -17,8 +17,8 @@ Name | Type | Description | Notes
**createdDate** | [**DateTime**](DateTime.md) | | [optional] **createdDate** | [**DateTime**](DateTime.md) | | [optional]
**updatedDate** | [**DateTime**](DateTime.md) | | [optional] **updatedDate** | [**DateTime**](DateTime.md) | | [optional]
**type** | [**AlarmType**](AlarmType.md) | | [optional] **type** | [**AlarmType**](AlarmType.md) | | [optional]
**programmedMode** | [**OneOfProgrammedMode**](OneOfProgrammedMode.md) | | [optional] **programmedMode** | [**AlarmModeProgrammedMode**](AlarmModeProgrammedMode.md) | | [optional]
**geolocalizedMode** | [**OneOfGeolocalizedMode**](OneOfGeolocalizedMode.md) | | [optional] **geolocalizedMode** | [**AlarmModeGeolocalizedMode**](AlarmModeGeolocalizedMode.md) | | [optional]
**triggers** | [**List<Trigger>**](Trigger.md) | | [optional] [default to const []] **triggers** | [**List<Trigger>**](Trigger.md) | | [optional] [default to const []]
**actions** | [**List<Action>**](Action.md) | | [optional] [default to const []] **actions** | [**List<Action>**](Action.md) | | [optional] [default to const []]
**devicesIds** | **List<String>** | | [optional] [default to const []] **devicesIds** | **List<String>** | | [optional] [default to const []]

View File

@ -1,8 +1,8 @@
# mycoreapi.model.AlarmModeCreateOrUpdateDetailDTO # mycore_api.model.AlarmModeCreateOrUpdateDetailDTO
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.AlarmModeCreateOrUpdateDetailDTOAllOf # mycore_api.model.AlarmModeCreateOrUpdateDetailDTOAllOf
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.AlarmModeDTO # mycore_api.model.AlarmModeDTO
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.AlarmModeDetailDTO # mycore_api.model.AlarmModeDetailDTO
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.AlarmModeDetailDTOAllOf # mycore_api.model.AlarmModeDetailDTOAllOf
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -0,0 +1,18 @@
# mycore_api.model.AlarmModeGeolocalizedMode
## Load the model package
```dart
import 'package:mycore_api/api.dart';
```
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**latitude** | **String** | | [optional]
**longitude** | **String** | | [optional]
**homeMode** | [**TimePeriodAlarmAlarmMode**](TimePeriodAlarmAlarmMode.md) | | [optional]
**absentMode** | [**TimePeriodAlarmAlarmMode**](TimePeriodAlarmAlarmMode.md) | | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -0,0 +1,21 @@
# mycore_api.model.AlarmModeProgrammedMode
## Load the model package
```dart
import 'package:mycore_api/api.dart';
```
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**monday** | [**List<TimePeriodAlarm>**](TimePeriodAlarm.md) | | [optional] [default to const []]
**tuesday** | [**List<TimePeriodAlarm>**](TimePeriodAlarm.md) | | [optional] [default to const []]
**wednesday** | [**List<TimePeriodAlarm>**](TimePeriodAlarm.md) | | [optional] [default to const []]
**thursday** | [**List<TimePeriodAlarm>**](TimePeriodAlarm.md) | | [optional] [default to const []]
**friday** | [**List<TimePeriodAlarm>**](TimePeriodAlarm.md) | | [optional] [default to const []]
**saturday** | [**List<TimePeriodAlarm>**](TimePeriodAlarm.md) | | [optional] [default to const []]
**sunday** | [**List<TimePeriodAlarm>**](TimePeriodAlarm.md) | | [optional] [default to const []]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,8 +1,8 @@
# mycoreapi.model.AlarmTriggered # mycore_api.model.AlarmTriggered
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.AlarmType # mycore_api.model.AlarmType
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,11 +1,11 @@
# mycoreapi.api.AuthenticationApi # mycore_api.api.AuthenticationApi
## Load the API package ## Load the API package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
All URIs are relative to *http://localhost:5000* All URIs are relative to *http://192.168.31.140*
Method | HTTP request | Description Method | HTTP request | Description
------------- | ------------- | ------------- ------------- | ------------- | -------------
@ -18,9 +18,9 @@ Method | HTTP request | Description
Authenticate with form parameters (used by Swagger test client) Authenticate with form parameters (used by Swagger test client)
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
@ -31,7 +31,7 @@ final password = password_example; // String |
final clientId = clientId_example; // String | final clientId = clientId_example; // String |
final clientSecret = clientSecret_example; // String | final clientSecret = clientSecret_example; // String |
try { try {
final result = api_instance.authenticationAuthenticateWithForm(grantType, username, password, clientId, clientSecret); final result = api_instance.authenticationAuthenticateWithForm(grantType, username, password, clientId, clientSecret);
print(result); print(result);
} catch (e) { } catch (e) {
@ -69,16 +69,16 @@ Name | Type | Description | Notes
Authenticate with Json parameters (used by most clients) Authenticate with Json parameters (used by most clients)
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = AuthenticationApi(); final api_instance = AuthenticationApi();
final loginDTO = LoginDTO(); // LoginDTO | Login DTO final loginDTO = LoginDTO(); // LoginDTO | Login DTO
try { try {
final result = api_instance.authenticationAuthenticateWithJson(loginDTO); final result = api_instance.authenticationAuthenticateWithJson(loginDTO);
print(result); print(result);
} catch (e) { } catch (e) {

View File

@ -1,11 +1,11 @@
# mycoreapi.api.AutomationApi # mycore_api.api.AutomationApi
## Load the API package ## Load the API package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
All URIs are relative to *http://localhost:5000* All URIs are relative to *http://192.168.31.140*
Method | HTTP request | Description Method | HTTP request | Description
------------- | ------------- | ------------- ------------- | ------------- | -------------
@ -22,16 +22,16 @@ Method | HTTP request | Description
Create an automation Create an automation
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = AutomationApi(); final api_instance = AutomationApi();
final automationDetailDTO = AutomationDetailDTO(); // AutomationDetailDTO | Automation to create final automationDetailDTO = AutomationDetailDTO(); // AutomationDetailDTO | Automation to create
try { try {
final result = api_instance.automationCreate(automationDetailDTO); final result = api_instance.automationCreate(automationDetailDTO);
print(result); print(result);
} catch (e) { } catch (e) {
@ -65,16 +65,16 @@ Name | Type | Description | Notes
Delete an automation Delete an automation
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = AutomationApi(); final api_instance = AutomationApi();
final automationId = automationId_example; // String | Id of automation to delete final automationId = automationId_example; // String | Id of automation to delete
try { try {
final result = api_instance.automationDelete(automationId); final result = api_instance.automationDelete(automationId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -108,16 +108,16 @@ Name | Type | Description | Notes
Delete all automation for a specified home Delete all automation for a specified home
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = AutomationApi(); final api_instance = AutomationApi();
final homeId = homeId_example; // String | Home Id final homeId = homeId_example; // String | Home Id
try { try {
final result = api_instance.automationDeleteAllForHome(homeId); final result = api_instance.automationDeleteAllForHome(homeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -151,16 +151,16 @@ Name | Type | Description | Notes
Get all automations for the specified home Get all automations for the specified home
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = AutomationApi(); final api_instance = AutomationApi();
final homeId = homeId_example; // String | Home Id final homeId = homeId_example; // String | Home Id
try { try {
final result = api_instance.automationGetAll(homeId); final result = api_instance.automationGetAll(homeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -194,16 +194,16 @@ Name | Type | Description | Notes
Get detail info of a specified automation Get detail info of a specified automation
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = AutomationApi(); final api_instance = AutomationApi();
final automationId = automationId_example; // String | automation id final automationId = automationId_example; // String | automation id
try { try {
final result = api_instance.automationGetDetail(automationId); final result = api_instance.automationGetDetail(automationId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -237,16 +237,16 @@ Name | Type | Description | Notes
Update an automation Update an automation
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = AutomationApi(); final api_instance = AutomationApi();
final automationDetailDTO = AutomationDetailDTO(); // AutomationDetailDTO | automation to update final automationDetailDTO = AutomationDetailDTO(); // AutomationDetailDTO | automation to update
try { try {
final result = api_instance.automationUpdate(automationDetailDTO); final result = api_instance.automationUpdate(automationDetailDTO);
print(result); print(result);
} catch (e) { } catch (e) {

View File

@ -1,8 +1,8 @@
# mycoreapi.model.AutomationDTO # mycore_api.model.AutomationDTO
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.AutomationDetailDTO # mycore_api.model.AutomationDetailDTO
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.AutomationDetailDTOAllOf # mycore_api.model.AutomationDetailDTOAllOf
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.AutomationState # mycore_api.model.AutomationState
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.AutomationTriggered # mycore_api.model.AutomationTriggered
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.AzureADAuthModel # mycore_api.model.AzureADAuthModel
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,11 +1,11 @@
# mycoreapi.api.AzureApi # mycore_api.api.AzureApi
## Load the API package ## Load the API package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
All URIs are relative to *http://localhost:5000* All URIs are relative to *http://192.168.31.140*
Method | HTTP request | Description Method | HTTP request | Description
------------- | ------------- | ------------- ------------- | ------------- | -------------
@ -17,16 +17,16 @@ Method | HTTP request | Description
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = AzureApi(); final api_instance = AzureApi();
final azureADAuthModel = AzureADAuthModel(); // AzureADAuthModel | final azureADAuthModel = AzureADAuthModel(); // AzureADAuthModel |
try { try {
final result = api_instance.azureCreate(azureADAuthModel); final result = api_instance.azureCreate(azureADAuthModel);
print(result); print(result);
} catch (e) { } catch (e) {

View File

@ -1,8 +1,8 @@
# mycoreapi.model.Book # mycore_api.model.Book
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,11 +1,11 @@
# mycoreapi.api.BooksApi # mycore_api.api.BooksApi
## Load the API package ## Load the API package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
All URIs are relative to *http://localhost:5000* All URIs are relative to *http://192.168.31.140*
Method | HTTP request | Description Method | HTTP request | Description
------------- | ------------- | ------------- ------------- | ------------- | -------------
@ -21,16 +21,16 @@ Method | HTTP request | Description
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = BooksApi(); final api_instance = BooksApi();
final book = Book(); // Book | final book = Book(); // Book |
try { try {
final result = api_instance.booksCreate(book); final result = api_instance.booksCreate(book);
print(result); print(result);
} catch (e) { } catch (e) {
@ -64,16 +64,16 @@ Name | Type | Description | Notes
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = BooksApi(); final api_instance = BooksApi();
final id = id_example; // String | final id = id_example; // String |
try { try {
final result = api_instance.booksDelete(id); final result = api_instance.booksDelete(id);
print(result); print(result);
} catch (e) { } catch (e) {
@ -107,16 +107,16 @@ Name | Type | Description | Notes
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = BooksApi(); final api_instance = BooksApi();
final id = id_example; // String | final id = id_example; // String |
try { try {
final result = api_instance.booksGet(id); final result = api_instance.booksGet(id);
print(result); print(result);
} catch (e) { } catch (e) {
@ -150,15 +150,15 @@ Name | Type | Description | Notes
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = BooksApi(); final api_instance = BooksApi();
try { try {
final result = api_instance.booksGetAll(); final result = api_instance.booksGetAll();
print(result); print(result);
} catch (e) { } catch (e) {
@ -189,9 +189,9 @@ This endpoint does not need any parameter.
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
@ -199,7 +199,7 @@ final api_instance = BooksApi();
final id = id_example; // String | final id = id_example; // String |
final book = Book(); // Book | final book = Book(); // Book |
try { try {
final result = api_instance.booksUpdate(id, book); final result = api_instance.booksUpdate(id, book);
print(result); print(result);
} catch (e) { } catch (e) {

View File

@ -1,15 +1,15 @@
# mycoreapi.model.Condition # mycore_api.model.Condition
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties
Name | Type | Description | Notes Name | Type | Description | Notes
------------ | ------------- | ------------- | ------------- ------------ | ------------- | ------------- | -------------
**deviceId** | **String** | | [optional] **deviceId** | **String** | | [optional]
**state** | [**OneOfAutomationState**](OneOfAutomationState.md) | | [optional] **state** | [**ConditionState**](ConditionState.md) | | [optional]
**startTime** | **String** | | [optional] **startTime** | **String** | | [optional]
**endTime** | **String** | | [optional] **endTime** | **String** | | [optional]
**type** | [**ConditionType**](ConditionType.md) | | [optional] **type** | [**ConditionType**](ConditionType.md) | | [optional]

View File

@ -0,0 +1,16 @@
# mycore_api.model.ConditionState
## Load the model package
```dart
import 'package:mycore_api/api.dart';
```
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **String** | | [optional]
**value** | **String** | | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,8 +1,8 @@
# mycoreapi.model.ConditionType # mycore_api.model.ConditionType
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.ConditionValue # mycore_api.model.ConditionValue
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.ConnectionStatus # mycore_api.model.ConnectionStatus
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.CreateOrUpdateHomeDTO # mycore_api.model.CreateOrUpdateHomeDTO
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties
@ -12,7 +12,7 @@ Name | Type | Description | Notes
**name** | **String** | | [optional] **name** | **String** | | [optional]
**isAlarm** | **bool** | | [optional] **isAlarm** | **bool** | | [optional]
**isDefault** | **bool** | | [optional] **isDefault** | **bool** | | [optional]
**currentAlarmMode** | [**OneOfAlarmModeDTO**](OneOfAlarmModeDTO.md) | | [optional] **currentAlarmMode** | [**HomeDTOCurrentAlarmMode**](HomeDTOCurrentAlarmMode.md) | | [optional]
**createdDate** | [**DateTime**](DateTime.md) | | [optional] **createdDate** | [**DateTime**](DateTime.md) | | [optional]
**updatedDate** | [**DateTime**](DateTime.md) | | [optional] **updatedDate** | [**DateTime**](DateTime.md) | | [optional]
**usersIds** | **List<String>** | | [optional] [default to const []] **usersIds** | **List<String>** | | [optional] [default to const []]

View File

@ -1,8 +1,8 @@
# mycoreapi.model.CreateOrUpdateHomeDTOAllOf # mycore_api.model.CreateOrUpdateHomeDTOAllOf
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,11 +1,11 @@
# mycoreapi.api.DeviceApi # mycore_api.api.DeviceApi
## Load the API package ## Load the API package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
All URIs are relative to *http://localhost:5000* All URIs are relative to *http://192.168.31.140*
Method | HTTP request | Description Method | HTTP request | Description
------------- | ------------- | ------------- ------------- | ------------- | -------------
@ -28,16 +28,16 @@ Method | HTTP request | Description
Create a device Create a device
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = DeviceApi(); final api_instance = DeviceApi();
final deviceDetailDTO = DeviceDetailDTO(); // DeviceDetailDTO | Device to create final deviceDetailDTO = DeviceDetailDTO(); // DeviceDetailDTO | Device to create
try { try {
final result = api_instance.deviceCreate(deviceDetailDTO); final result = api_instance.deviceCreate(deviceDetailDTO);
print(result); print(result);
} catch (e) { } catch (e) {
@ -71,9 +71,9 @@ Name | Type | Description | Notes
Create devices from provider Create devices from provider
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
@ -81,7 +81,7 @@ final api_instance = DeviceApi();
final homeId = homeId_example; // String | Home Id final homeId = homeId_example; // String | Home Id
final providerId = providerId_example; // String | Id of Provider final providerId = providerId_example; // String | Id of Provider
try { try {
final result = api_instance.deviceCreateDevicesFromProvider(homeId, providerId); final result = api_instance.deviceCreateDevicesFromProvider(homeId, providerId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -116,16 +116,16 @@ Name | Type | Description | Notes
Delete a device Delete a device
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = DeviceApi(); final api_instance = DeviceApi();
final deviceId = deviceId_example; // String | Id of device to delete final deviceId = deviceId_example; // String | Id of device to delete
try { try {
final result = api_instance.deviceDelete(deviceId); final result = api_instance.deviceDelete(deviceId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -159,16 +159,16 @@ Name | Type | Description | Notes
Delete all device for a specified home Delete all device for a specified home
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = DeviceApi(); final api_instance = DeviceApi();
final homeId = homeId_example; // String | Id of home final homeId = homeId_example; // String | Id of home
try { try {
final result = api_instance.deviceDeleteAllForHome(homeId); final result = api_instance.deviceDeleteAllForHome(homeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -202,9 +202,9 @@ Name | Type | Description | Notes
Delete devices from provider Delete devices from provider
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
@ -212,7 +212,7 @@ final api_instance = DeviceApi();
final homeId = homeId_example; // String | Home Id final homeId = homeId_example; // String | Home Id
final providerId = providerId_example; // String | Id of Provider final providerId = providerId_example; // String | Id of Provider
try { try {
final result = api_instance.deviceDeleteDevicesFromProvider(homeId, providerId); final result = api_instance.deviceDeleteDevicesFromProvider(homeId, providerId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -247,16 +247,16 @@ Name | Type | Description | Notes
Get all devices summary Get all devices summary
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = DeviceApi(); final api_instance = DeviceApi();
final homeId = homeId_example; // String | Home Id final homeId = homeId_example; // String | Home Id
try { try {
final result = api_instance.deviceGetAll(homeId); final result = api_instance.deviceGetAll(homeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -290,16 +290,16 @@ Name | Type | Description | Notes
Get a specific device info Get a specific device info
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = DeviceApi(); final api_instance = DeviceApi();
final deviceId = deviceId_example; // String | id of device final deviceId = deviceId_example; // String | id of device
try { try {
final result = api_instance.deviceGetDetail(deviceId); final result = api_instance.deviceGetDetail(deviceId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -333,9 +333,9 @@ Name | Type | Description | Notes
Get list of devices from a type Get list of devices from a type
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
@ -343,7 +343,7 @@ final api_instance = DeviceApi();
final homeId = homeId_example; // String | Home Id final homeId = homeId_example; // String | Home Id
final type = ; // DeviceType | device type final type = ; // DeviceType | device type
try { try {
final result = api_instance.deviceGetDevicesByType(homeId, type); final result = api_instance.deviceGetDevicesByType(homeId, type);
print(result); print(result);
} catch (e) { } catch (e) {
@ -378,9 +378,9 @@ Name | Type | Description | Notes
Get devices from provider Get devices from provider
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
@ -388,7 +388,7 @@ final api_instance = DeviceApi();
final homeId = homeId_example; // String | Home Id final homeId = homeId_example; // String | Home Id
final providerId = providerId_example; // String | Id of Provider final providerId = providerId_example; // String | Id of Provider
try { try {
final result = api_instance.deviceGetDevicesFromProvider(homeId, providerId); final result = api_instance.deviceGetDevicesFromProvider(homeId, providerId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -423,16 +423,16 @@ Name | Type | Description | Notes
Get all zigbee2Mqtt devices Get all zigbee2Mqtt devices
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = DeviceApi(); final api_instance = DeviceApi();
final homeId = homeId_example; // String | Home Id final homeId = homeId_example; // String | Home Id
try { try {
final result = api_instance.deviceGetDevicesFromZigbee2Mqtt(homeId); final result = api_instance.deviceGetDevicesFromZigbee2Mqtt(homeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -466,16 +466,16 @@ Name | Type | Description | Notes
Send action to device Send action to device
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = DeviceApi(); final api_instance = DeviceApi();
final action = Action(); // Action | Action to sent final action = Action(); // Action | Action to sent
try { try {
final result = api_instance.deviceSendAction(action); final result = api_instance.deviceSendAction(action);
print(result); print(result);
} catch (e) { } catch (e) {
@ -509,9 +509,9 @@ Name | Type | Description | Notes
Update a device Update a device
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
@ -519,7 +519,7 @@ final api_instance = DeviceApi();
final deviceId = deviceId_example; // String | final deviceId = deviceId_example; // String |
final deviceDetailDTO = DeviceDetailDTO(); // DeviceDetailDTO | Device to update final deviceDetailDTO = DeviceDetailDTO(); // DeviceDetailDTO | Device to update
try { try {
final result = api_instance.deviceUpdate(deviceId, deviceDetailDTO); final result = api_instance.deviceUpdate(deviceId, deviceDetailDTO);
print(result); print(result);
} catch (e) { } catch (e) {

View File

@ -1,8 +1,8 @@
# mycoreapi.model.DeviceDetailDTO # mycore_api.model.DeviceDetailDTO
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.DeviceDetailDTOAllOf # mycore_api.model.DeviceDetailDTOAllOf
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.DeviceState # mycore_api.model.DeviceState
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.DeviceSummaryDTO # mycore_api.model.DeviceSummaryDTO
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.DeviceType # mycore_api.model.DeviceType
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.ElectricityProduction # mycore_api.model.ElectricityProduction
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,11 +1,11 @@
# mycoreapi.api.EnergyApi # mycore_api.api.EnergyApi
## Load the API package ## Load the API package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
All URIs are relative to *http://localhost:5000* All URIs are relative to *http://192.168.31.140*
Method | HTTP request | Description Method | HTTP request | Description
------------- | ------------- | ------------- ------------- | ------------- | -------------
@ -17,9 +17,9 @@ Method | HTTP request | Description
Get summary production of Kwh/Year Get summary production of Kwh/Year
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
@ -27,7 +27,7 @@ final api_instance = EnergyApi();
final homeId = homeId_example; // String | final homeId = homeId_example; // String |
final viewBy = ; // ViewBy | final viewBy = ; // ViewBy |
try { try {
final result = api_instance.energyGetElectricityProduction(homeId, viewBy); final result = api_instance.energyGetElectricityProduction(homeId, viewBy);
print(result); print(result);
} catch (e) { } catch (e) {

View File

@ -1,11 +1,11 @@
# mycoreapi.api.EventApi # mycore_api.api.EventApi
## Load the API package ## Load the API package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
All URIs are relative to *http://localhost:5000* All URIs are relative to *http://192.168.31.140*
Method | HTTP request | Description Method | HTTP request | Description
------------- | ------------- | ------------- ------------- | ------------- | -------------
@ -20,16 +20,16 @@ Method | HTTP request | Description
Delete an event Delete an event
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = EventApi(); final api_instance = EventApi();
final eventId = eventId_example; // String | Id of event to delete final eventId = eventId_example; // String | Id of event to delete
try { try {
final result = api_instance.eventDelete(eventId); final result = api_instance.eventDelete(eventId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -63,16 +63,16 @@ Name | Type | Description | Notes
Delete all events for a specified home Delete all events for a specified home
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = EventApi(); final api_instance = EventApi();
final homeId = homeId_example; // String | Home Id final homeId = homeId_example; // String | Home Id
try { try {
final result = api_instance.eventDeleteAllForHome(homeId); final result = api_instance.eventDeleteAllForHome(homeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -106,9 +106,9 @@ Name | Type | Description | Notes
Get events for the specified home Get events for the specified home
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
@ -120,10 +120,10 @@ final startIndex = 56; // int |
final count = 56; // int | final count = 56; // int |
final dateStart = 2013-10-20T19:20:30+01:00; // DateTime | final dateStart = 2013-10-20T19:20:30+01:00; // DateTime |
final dateEnd = 2013-10-20T19:20:30+01:00; // DateTime | final dateEnd = 2013-10-20T19:20:30+01:00; // DateTime |
final eventType = ; // OneOfEventType | final eventType = ; // EventGetEventTypeParameter |
final deviceType = ; // OneOfDeviceType | final deviceType = ; // EventGetDeviceTypeParameter |
try { try {
final result = api_instance.eventGet(homeId, deviceId, roomId, startIndex, count, dateStart, dateEnd, eventType, deviceType); final result = api_instance.eventGet(homeId, deviceId, roomId, startIndex, count, dateStart, dateEnd, eventType, deviceType);
print(result); print(result);
} catch (e) { } catch (e) {
@ -142,8 +142,8 @@ Name | Type | Description | Notes
**count** | **int**| | [optional] **count** | **int**| | [optional]
**dateStart** | **DateTime**| | [optional] **dateStart** | **DateTime**| | [optional]
**dateEnd** | **DateTime**| | [optional] **dateEnd** | **DateTime**| | [optional]
**eventType** | [**OneOfEventType**](.md)| | [optional] **eventType** | [**EventGetEventTypeParameter**](.md)| | [optional]
**deviceType** | [**OneOfDeviceType**](.md)| | [optional] **deviceType** | [**EventGetDeviceTypeParameter**](.md)| | [optional]
### Return type ### Return type
@ -165,16 +165,16 @@ Name | Type | Description | Notes
Get detail info of a specified event Get detail info of a specified event
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = EventApi(); final api_instance = EventApi();
final eventId = eventId_example; // String | event id final eventId = eventId_example; // String | event id
try { try {
final result = api_instance.eventGetDetail(eventId); final result = api_instance.eventGetDetail(eventId);
print(result); print(result);
} catch (e) { } catch (e) {

View File

@ -1,8 +1,8 @@
# mycoreapi.model.EventDTO # mycore_api.model.EventDTO
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.EventDetailDTO # mycore_api.model.EventDetailDTO
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.EventDetailDTOAllOf # mycore_api.model.EventDetailDTOAllOf
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.EventFilter # mycore_api.model.EventFilter
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties
@ -12,8 +12,8 @@ Name | Type | Description | Notes
**count** | **int** | | [optional] **count** | **int** | | [optional]
**dateStart** | [**DateTime**](DateTime.md) | | [optional] **dateStart** | [**DateTime**](DateTime.md) | | [optional]
**dateEnd** | [**DateTime**](DateTime.md) | | [optional] **dateEnd** | [**DateTime**](DateTime.md) | | [optional]
**eventType** | [**OneOfEventType**](OneOfEventType.md) | | [optional] **eventType** | [**EventGetEventTypeParameter**](EventGetEventTypeParameter.md) | | [optional]
**deviceType** | [**OneOfDeviceType**](OneOfDeviceType.md) | | [optional] **deviceType** | [**EventGetDeviceTypeParameter**](EventGetDeviceTypeParameter.md) | | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -0,0 +1,14 @@
# mycore_api.model.EventGetDeviceTypeParameter
## Load the model package
```dart
import 'package:mycore_api/api.dart';
```
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -0,0 +1,14 @@
# mycore_api.model.EventGetEventTypeParameter
## Load the model package
```dart
import 'package:mycore_api/api.dart';
```
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,8 +1,8 @@
# mycoreapi.model.EventHomeFilter # mycore_api.model.EventHomeFilter
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties
@ -12,8 +12,8 @@ Name | Type | Description | Notes
**count** | **int** | | [optional] **count** | **int** | | [optional]
**dateStart** | [**DateTime**](DateTime.md) | | [optional] **dateStart** | [**DateTime**](DateTime.md) | | [optional]
**dateEnd** | [**DateTime**](DateTime.md) | | [optional] **dateEnd** | [**DateTime**](DateTime.md) | | [optional]
**eventType** | [**OneOfEventType**](OneOfEventType.md) | | [optional] **eventType** | [**EventGetEventTypeParameter**](EventGetEventTypeParameter.md) | | [optional]
**deviceType** | [**OneOfDeviceType**](OneOfDeviceType.md) | | [optional] **deviceType** | [**EventGetDeviceTypeParameter**](EventGetDeviceTypeParameter.md) | | [optional]
**deviceId** | **String** | | [optional] **deviceId** | **String** | | [optional]
**roomId** | **String** | | [optional] **roomId** | **String** | | [optional]

View File

@ -1,8 +1,8 @@
# mycoreapi.model.EventHomeFilterAllOf # mycore_api.model.EventHomeFilterAllOf
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.EventType # mycore_api.model.EventType
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,11 +1,11 @@
# mycoreapi.api.FacebookApi # mycore_api.api.FacebookApi
## Load the API package ## Load the API package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
All URIs are relative to *http://localhost:5000* All URIs are relative to *http://192.168.31.140*
Method | HTTP request | Description Method | HTTP request | Description
------------- | ------------- | ------------- ------------- | ------------- | -------------
@ -17,16 +17,16 @@ Method | HTTP request | Description
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = FacebookApi(); final api_instance = FacebookApi();
final facebookAuthModel = FacebookAuthModel(); // FacebookAuthModel | final facebookAuthModel = FacebookAuthModel(); // FacebookAuthModel |
try { try {
final result = api_instance.facebookCreate(facebookAuthModel); final result = api_instance.facebookCreate(facebookAuthModel);
print(result); print(result);
} catch (e) { } catch (e) {

View File

@ -1,8 +1,8 @@
# mycoreapi.model.FacebookAuthModel # mycore_api.model.FacebookAuthModel
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.GeolocalizedMode # mycore_api.model.GeolocalizedMode
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties
@ -10,8 +10,8 @@ Name | Type | Description | Notes
------------ | ------------- | ------------- | ------------- ------------ | ------------- | ------------- | -------------
**latitude** | **String** | | [optional] **latitude** | **String** | | [optional]
**longitude** | **String** | | [optional] **longitude** | **String** | | [optional]
**homeMode** | [**OneOfAlarmMode**](OneOfAlarmMode.md) | | [optional] **homeMode** | [**TimePeriodAlarmAlarmMode**](TimePeriodAlarmAlarmMode.md) | | [optional]
**absentMode** | [**OneOfAlarmMode**](OneOfAlarmMode.md) | | [optional] **absentMode** | [**TimePeriodAlarmAlarmMode**](TimePeriodAlarmAlarmMode.md) | | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,11 +1,11 @@
# mycoreapi.api.GoogleApi # mycore_api.api.GoogleApi
## Load the API package ## Load the API package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
All URIs are relative to *http://localhost:5000* All URIs are relative to *http://192.168.31.140*
Method | HTTP request | Description Method | HTTP request | Description
------------- | ------------- | ------------- ------------- | ------------- | -------------
@ -17,16 +17,16 @@ Method | HTTP request | Description
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = GoogleApi(); final api_instance = GoogleApi();
final googleAuthModel = GoogleAuthModel(); // GoogleAuthModel | final googleAuthModel = GoogleAuthModel(); // GoogleAuthModel |
try { try {
final result = api_instance.googleCreate(googleAuthModel); final result = api_instance.googleCreate(googleAuthModel);
print(result); print(result);
} catch (e) { } catch (e) {

View File

@ -1,8 +1,8 @@
# mycoreapi.model.GoogleAuthModel # mycore_api.model.GoogleAuthModel
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,11 +1,11 @@
# mycoreapi.api.GroupApi # mycore_api.api.GroupApi
## Load the API package ## Load the API package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
All URIs are relative to *http://localhost:5000* All URIs are relative to *http://192.168.31.140*
Method | HTTP request | Description Method | HTTP request | Description
------------- | ------------- | ------------- ------------- | ------------- | -------------
@ -26,16 +26,16 @@ Method | HTTP request | Description
Create a group Create a group
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = GroupApi(); final api_instance = GroupApi();
final groupCreateOrUpdateDetailDTO = GroupCreateOrUpdateDetailDTO(); // GroupCreateOrUpdateDetailDTO | Group to create final groupCreateOrUpdateDetailDTO = GroupCreateOrUpdateDetailDTO(); // GroupCreateOrUpdateDetailDTO | Group to create
try { try {
final result = api_instance.groupCreate(groupCreateOrUpdateDetailDTO); final result = api_instance.groupCreate(groupCreateOrUpdateDetailDTO);
print(result); print(result);
} catch (e) { } catch (e) {
@ -69,16 +69,16 @@ Name | Type | Description | Notes
Create groups from provider Create groups from provider
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = GroupApi(); final api_instance = GroupApi();
final homeId = homeId_example; // String | Home Id final homeId = homeId_example; // String | Home Id
try { try {
final result = api_instance.groupCreateDevicesFromZigbee2Mqtt(homeId); final result = api_instance.groupCreateDevicesFromZigbee2Mqtt(homeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -112,9 +112,9 @@ Name | Type | Description | Notes
Delete device from a group Delete device from a group
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
@ -122,7 +122,7 @@ final api_instance = GroupApi();
final deviceId = deviceId_example; // String | Id of device to delete from the group final deviceId = deviceId_example; // String | Id of device to delete from the group
final groupId = groupId_example; // String | Id of group final groupId = groupId_example; // String | Id of group
try { try {
final result = api_instance.groupDelete(deviceId, groupId); final result = api_instance.groupDelete(deviceId, groupId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -157,16 +157,16 @@ Name | Type | Description | Notes
Delete a group Delete a group
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = GroupApi(); final api_instance = GroupApi();
final groupId = groupId_example; // String | Id of group final groupId = groupId_example; // String | Id of group
try { try {
final result = api_instance.groupDelete2(groupId); final result = api_instance.groupDelete2(groupId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -200,16 +200,16 @@ Name | Type | Description | Notes
Delete all group for a specified home Delete all group for a specified home
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = GroupApi(); final api_instance = GroupApi();
final homeId = homeId_example; // String | Home Id final homeId = homeId_example; // String | Home Id
try { try {
final result = api_instance.groupDeleteAllForHome(homeId); final result = api_instance.groupDeleteAllForHome(homeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -243,16 +243,16 @@ Name | Type | Description | Notes
Get all groups for the specified home Get all groups for the specified home
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = GroupApi(); final api_instance = GroupApi();
final homeId = homeId_example; // String | Home Id final homeId = homeId_example; // String | Home Id
try { try {
final result = api_instance.groupGetAll(homeId); final result = api_instance.groupGetAll(homeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -286,16 +286,16 @@ Name | Type | Description | Notes
Get detail info of a specified group Get detail info of a specified group
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = GroupApi(); final api_instance = GroupApi();
final groupId = groupId_example; // String | groupid final groupId = groupId_example; // String | groupid
try { try {
final result = api_instance.groupGetDetail(groupId); final result = api_instance.groupGetDetail(groupId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -329,9 +329,9 @@ Name | Type | Description | Notes
Get list of group from a type Get list of group from a type
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
@ -339,7 +339,7 @@ final api_instance = GroupApi();
final homeId = homeId_example; // String | home Id final homeId = homeId_example; // String | home Id
final type = type_example; // String | group type final type = type_example; // String | group type
try { try {
final result = api_instance.groupGetGroupsByType(homeId, type); final result = api_instance.groupGetGroupsByType(homeId, type);
print(result); print(result);
} catch (e) { } catch (e) {
@ -374,16 +374,16 @@ Name | Type | Description | Notes
Get all zigbee2Mqtt groups Get all zigbee2Mqtt groups
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = GroupApi(); final api_instance = GroupApi();
final homeId = homeId_example; // String | Home Id final homeId = homeId_example; // String | Home Id
try { try {
final result = api_instance.groupGetGroupsFromZigbee2Mqtt(homeId); final result = api_instance.groupGetGroupsFromZigbee2Mqtt(homeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -417,16 +417,16 @@ Name | Type | Description | Notes
Update a group Update a group
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = GroupApi(); final api_instance = GroupApi();
final groupCreateOrUpdateDetailDTO = GroupCreateOrUpdateDetailDTO(); // GroupCreateOrUpdateDetailDTO | group to update final groupCreateOrUpdateDetailDTO = GroupCreateOrUpdateDetailDTO(); // GroupCreateOrUpdateDetailDTO | group to update
try { try {
final result = api_instance.groupUpdate(groupCreateOrUpdateDetailDTO); final result = api_instance.groupUpdate(groupCreateOrUpdateDetailDTO);
print(result); print(result);
} catch (e) { } catch (e) {

View File

@ -1,8 +1,8 @@
# mycoreapi.model.GroupCreateOrUpdateDetailDTO # mycore_api.model.GroupCreateOrUpdateDetailDTO
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.GroupCreateOrUpdateDetailDTOAllOf # mycore_api.model.GroupCreateOrUpdateDetailDTOAllOf
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.GroupDetailDTO # mycore_api.model.GroupDetailDTO
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.GroupDetailDTOAllOf # mycore_api.model.GroupDetailDTOAllOf
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,8 +1,8 @@
# mycoreapi.model.GroupSummaryDTO # mycore_api.model.GroupSummaryDTO
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,11 +1,11 @@
# mycoreapi.api.HomeApi # mycore_api.api.HomeApi
## Load the API package ## Load the API package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
All URIs are relative to *http://localhost:5000* All URIs are relative to *http://192.168.31.140*
Method | HTTP request | Description Method | HTTP request | Description
------------- | ------------- | ------------- ------------- | ------------- | -------------
@ -21,16 +21,16 @@ Method | HTTP request | Description
Create a home Create a home
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = HomeApi(); final api_instance = HomeApi();
final createOrUpdateHomeDTO = CreateOrUpdateHomeDTO(); // CreateOrUpdateHomeDTO | Home to create final createOrUpdateHomeDTO = CreateOrUpdateHomeDTO(); // CreateOrUpdateHomeDTO | Home to create
try { try {
final result = api_instance.homeCreate(createOrUpdateHomeDTO); final result = api_instance.homeCreate(createOrUpdateHomeDTO);
print(result); print(result);
} catch (e) { } catch (e) {
@ -64,16 +64,16 @@ Name | Type | Description | Notes
Delete a home Delete a home
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = HomeApi(); final api_instance = HomeApi();
final homeId = homeId_example; // String | Id of home to delete final homeId = homeId_example; // String | Id of home to delete
try { try {
final result = api_instance.homeDelete(homeId); final result = api_instance.homeDelete(homeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -107,16 +107,16 @@ Name | Type | Description | Notes
Get all home for specified user Get all home for specified user
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = HomeApi(); final api_instance = HomeApi();
final userId = userId_example; // String | User Id final userId = userId_example; // String | User Id
try { try {
final result = api_instance.homeGetAll(userId); final result = api_instance.homeGetAll(userId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -150,16 +150,16 @@ Name | Type | Description | Notes
Get detail info of a specified home Get detail info of a specified home
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = HomeApi(); final api_instance = HomeApi();
final homeId = homeId_example; // String | home id final homeId = homeId_example; // String | home id
try { try {
final result = api_instance.homeGetDetail(homeId); final result = api_instance.homeGetDetail(homeId);
print(result); print(result);
} catch (e) { } catch (e) {
@ -193,16 +193,16 @@ Name | Type | Description | Notes
Update a home Update a home
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = HomeApi(); final api_instance = HomeApi();
final createOrUpdateHomeDTO = CreateOrUpdateHomeDTO(); // CreateOrUpdateHomeDTO | Home to update final createOrUpdateHomeDTO = CreateOrUpdateHomeDTO(); // CreateOrUpdateHomeDTO | Home to update
try { try {
final result = api_instance.homeUpdate(createOrUpdateHomeDTO); final result = api_instance.homeUpdate(createOrUpdateHomeDTO);
print(result); print(result);
} catch (e) { } catch (e) {

View File

@ -1,8 +1,8 @@
# mycoreapi.model.HomeDTO # mycore_api.model.HomeDTO
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties
@ -12,7 +12,7 @@ Name | Type | Description | Notes
**name** | **String** | | [optional] **name** | **String** | | [optional]
**isAlarm** | **bool** | | [optional] **isAlarm** | **bool** | | [optional]
**isDefault** | **bool** | | [optional] **isDefault** | **bool** | | [optional]
**currentAlarmMode** | [**OneOfAlarmModeDTO**](OneOfAlarmModeDTO.md) | | [optional] **currentAlarmMode** | [**HomeDTOCurrentAlarmMode**](HomeDTOCurrentAlarmMode.md) | | [optional]
**createdDate** | [**DateTime**](DateTime.md) | | [optional] **createdDate** | [**DateTime**](DateTime.md) | | [optional]
**updatedDate** | [**DateTime**](DateTime.md) | | [optional] **updatedDate** | [**DateTime**](DateTime.md) | | [optional]
**usersIds** | **List<String>** | | [optional] [default to const []] **usersIds** | **List<String>** | | [optional] [default to const []]

View File

@ -0,0 +1,23 @@
# mycore_api.model.HomeDTOCurrentAlarmMode
## Load the model package
```dart
import 'package:mycore_api/api.dart';
```
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**id** | **String** | | [optional]
**homeId** | **String** | | [optional]
**name** | **String** | | [optional]
**type** | [**AlarmType**](AlarmType.md) | | [optional]
**activated** | **bool** | | [optional]
**isDefault** | **bool** | | [optional]
**notification** | **bool** | | [optional]
**createdDate** | [**DateTime**](DateTime.md) | | [optional]
**updatedDate** | [**DateTime**](DateTime.md) | | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,8 +1,8 @@
# mycoreapi.model.HomeDetailDTO # mycore_api.model.HomeDetailDTO
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties
@ -12,7 +12,7 @@ Name | Type | Description | Notes
**name** | **String** | | [optional] **name** | **String** | | [optional]
**isAlarm** | **bool** | | [optional] **isAlarm** | **bool** | | [optional]
**isDefault** | **bool** | | [optional] **isDefault** | **bool** | | [optional]
**currentAlarmMode** | [**OneOfAlarmModeDTO**](OneOfAlarmModeDTO.md) | | [optional] **currentAlarmMode** | [**HomeDTOCurrentAlarmMode**](HomeDTOCurrentAlarmMode.md) | | [optional]
**createdDate** | [**DateTime**](DateTime.md) | | [optional] **createdDate** | [**DateTime**](DateTime.md) | | [optional]
**updatedDate** | [**DateTime**](DateTime.md) | | [optional] **updatedDate** | [**DateTime**](DateTime.md) | | [optional]
**usersIds** | **List<String>** | | [optional] [default to const []] **usersIds** | **List<String>** | | [optional] [default to const []]

View File

@ -1,8 +1,8 @@
# mycoreapi.model.HomeDetailDTOAllOf # mycore_api.model.HomeDetailDTOAllOf
## Load the model package ## Load the model package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
## Properties ## Properties

View File

@ -1,11 +1,11 @@
# mycoreapi.api.IOTApi # mycore_api.api.IOTApi
## Load the API package ## Load the API package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
All URIs are relative to *http://localhost:5000* All URIs are relative to *http://192.168.31.140*
Method | HTTP request | Description Method | HTTP request | Description
------------- | ------------- | ------------- ------------- | ------------- | -------------
@ -19,9 +19,9 @@ Method | HTTP request | Description
Retrieve all SmartPrinterMessage Retrieve all SmartPrinterMessage
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
@ -29,7 +29,7 @@ final api_instance = IOTApi();
final idDevice = idDevice_example; // String | final idDevice = idDevice_example; // String |
final id = 56; // int | Id of the smart printer message final id = 56; // int | Id of the smart printer message
try { try {
final result = api_instance.iOTGetSmartPrinterMessages(idDevice, id); final result = api_instance.iOTGetSmartPrinterMessages(idDevice, id);
print(result); print(result);
} catch (e) { } catch (e) {
@ -64,9 +64,9 @@ Name | Type | Description | Notes
It's the method to post data from mqtt broker to Database (Thanks Rpi!) It's the method to post data from mqtt broker to Database (Thanks Rpi!)
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
@ -74,7 +74,7 @@ final api_instance = IOTApi();
final idDevice = 56; // int | Id of the device to upload to DB final idDevice = 56; // int | Id of the device to upload to DB
final smartPrinterMessage = [List<SmartPrinterMessage>()]; // List<SmartPrinterMessage> | Content that will be uploaded final smartPrinterMessage = [List<SmartPrinterMessage>()]; // List<SmartPrinterMessage> | Content that will be uploaded
try { try {
final result = api_instance.iOTPostToDBPrinter(idDevice, smartPrinterMessage); final result = api_instance.iOTPostToDBPrinter(idDevice, smartPrinterMessage);
print(result); print(result);
} catch (e) { } catch (e) {
@ -109,9 +109,9 @@ Name | Type | Description | Notes
It's the method to post data from mqtt broker to Database (Thanks Rpi!) It's the method to post data from mqtt broker to Database (Thanks Rpi!)
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
@ -119,7 +119,7 @@ final api_instance = IOTApi();
final idDevice = 56; // int | final idDevice = 56; // int |
final smartGardenMessage = [List<SmartGardenMessage>()]; // List<SmartGardenMessage> | final smartGardenMessage = [List<SmartGardenMessage>()]; // List<SmartGardenMessage> |
try { try {
final result = api_instance.iOTPostToDBSmartGarden(idDevice, smartGardenMessage); final result = api_instance.iOTPostToDBSmartGarden(idDevice, smartGardenMessage);
print(result); print(result);
} catch (e) { } catch (e) {

View File

@ -1,11 +1,11 @@
# mycoreapi.api.LayoutApi # mycore_api.api.LayoutApi
## Load the API package ## Load the API package
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
``` ```
All URIs are relative to *http://localhost:5000* All URIs are relative to *http://192.168.31.140*
Method | HTTP request | Description Method | HTTP request | Description
------------- | ------------- | ------------- ------------- | ------------- | -------------
@ -17,15 +17,15 @@ Method | HTTP request | Description
It's a test ! :) It's a test ! :)
### Example ### Example
```dart ```dart
import 'package:mycoreapi/api.dart'; import 'package:mycore_api/api.dart';
// TODO Configure OAuth2 access token for authorization: bearer // TODO Configure OAuth2 access token for authorization: bearer
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN'; //defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = LayoutApi(); final api_instance = LayoutApi();
try { try {
final result = api_instance.layoutGet(); final result = api_instance.layoutGet();
print(result); print(result);
} catch (e) { } catch (e) {

Some files were not shown because too many files have changed in this diff Show More