Skip to content

Commit 12b0f52

Browse files
authored
Merge pull request #189 from appwrite/dev
Dev
2 parents cab0a13 + d803cef commit 12b0f52

File tree

157 files changed

+3195
-1791
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

157 files changed

+3195
-1791
lines changed

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,6 @@ install:
2424
deploy:
2525
provider: script
2626
skip_cleanup: true
27-
script: cd $TRAVIS_BUILD_DIR && dart format ./lib/ && flutter pub publish -f
27+
script: cd $TRAVIS_BUILD_DIR && dart format ./lib/ && dart format ./test/ && flutter pub publish -f
2828
on:
2929
tags: true

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
## 12.0.0
2+
3+
* Added enum support
4+
* Added SSR support
5+
* Added messaging service support
6+
* Added contains query support
7+
* Added or query support
8+
19
## 11.0.1
210

311
* Fix between queries

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Copyright (c) 2023 Appwrite (https://appwrite.io) and individual contributors.
1+
Copyright (c) 2024 Appwrite (https://appwrite.io) and individual contributors.
22
All rights reserved.
33

44
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

README.md

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,26 +2,26 @@
22

33
[![pub package](https://img.shields.io/pub/v/appwrite?style=flat-square)](https://pub.dartlang.org/packages/appwrite)
44
![License](https://img.shields.io/github/license/appwrite/sdk-for-flutter.svg?style=flat-square)
5-
![Version](https://img.shields.io/badge/api%20version-1.4.x-blue.svg?style=flat-square)
5+
![Version](https://img.shields.io/badge/api%20version-1.5.x-blue.svg?style=flat-square)
66
[![Build Status](https://img.shields.io/travis/com/appwrite/sdk-generator?style=flat-square)](https://travis-ci.com/appwrite/sdk-generator)
77
[![Twitter Account](https://img.shields.io/twitter/follow/appwrite?color=00acee&label=twitter&style=flat-square)](https://twitter.com/appwrite)
88
[![Discord](https://img.shields.io/discord/564160730845151244?label=discord&style=flat-square)](https://appwrite.io/discord)
99

10-
**This SDK is compatible with Appwrite server version 1.4.x. For older versions, please check [previous releases](https://github.com/appwrite/sdk-for-flutter/releases).**
10+
**This SDK is compatible with Appwrite server version 1.5.x. For older versions, please check [previous releases](https://github.com/appwrite/sdk-for-flutter/releases).**
1111

1212
Appwrite is an open-source backend as a service server that abstract and simplify complex and repetitive development tasks behind a very simple to use REST API. Appwrite aims to help you develop your apps faster and in a more secure way. Use the Flutter SDK to integrate your app with the Appwrite server to easily start interacting with all of Appwrite backend APIs and tools. For full API documentation and tutorials go to [https://appwrite.io/docs](https://appwrite.io/docs)
1313

1414

1515

16-
![Appwrite](https://appwrite.io/images/github.png)
16+
![Appwrite](https://github.com/appwrite/appwrite/raw/main/public/images/github.png)
1717

1818
## Installation
1919

2020
Add this to your package's `pubspec.yaml` file:
2121

2222
```yml
2323
dependencies:
24-
appwrite: ^11.0.1
24+
appwrite: ^12.0.0
2525
```
2626
2727
You can install packages from the command line:
@@ -138,10 +138,7 @@ When trying to connect to Appwrite from an emulator or a mobile device, localhos
138138
Account account = Account(client);
139139
final user = await account
140140
.create(
141-
userId: ID.unique(),
142-
143-
password: 'password',
144-
name: 'My Name'
141+
userId: ID.unique(), email: "[email protected]", password: "password", name: "Walter O'Brien"
145142
);
146143
```
147144

@@ -166,10 +163,7 @@ void main() {
166163
167164
final user = await account
168165
.create(
169-
userId: ID.unique(),
170-
171-
password: 'password',
172-
name: 'My Name'
166+
userId: ID.unique(), email: "[email protected]", password: "password", name: "Walter O'Brien"
173167
);
174168
}
175169
```
@@ -181,7 +175,7 @@ The Appwrite Flutter SDK raises `AppwriteException` object with `message`, `type
181175
Account account = Account(client);
182176
183177
try {
184-
final user = await account.create(userId: ID.unique(), email: [email protected]’,password: password, name: ‘name’);
178+
final user = await account.create(userId: ID.unique(), email: "[email protected]", password: "password", name: "Walter O'Brien");
185179
print(user.toMap());
186180
} on AppwriteException catch(e) {
187181
//show message to user or do other operation based on error as required
Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,9 @@
11
import 'package:appwrite/appwrite.dart';
22

3-
void main() { // Init SDK
4-
Client client = Client();
5-
Account account = Account(client);
6-
7-
client
3+
Client client = Client()
84
.setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
9-
.setProject('5df5acd0d48c2') // Your project ID
10-
;
11-
Future result = account.createAnonymousSession();
5+
.setProject('5df5acd0d48c2'); // Your project ID
6+
7+
Account account = Account(client);
128

13-
result
14-
.then((response) {
15-
print(response);
16-
}).catchError((error) {
17-
print(error.response);
18-
});
19-
}
9+
Session result = await account.createAnonymousSession();
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
import 'package:appwrite/appwrite.dart';
2+
3+
Client client = Client()
4+
.setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5+
.setProject('5df5acd0d48c2'); // Your project ID
6+
7+
Account account = Account(client);
8+
9+
Session result = await account.createEmailPasswordSession(
10+
11+
password: 'password',
12+
);

docs/examples/account/create-email-session.md

Lines changed: 0 additions & 22 deletions
This file was deleted.
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
import 'package:appwrite/appwrite.dart';
2+
3+
Client client = Client()
4+
.setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
5+
.setProject('5df5acd0d48c2'); // Your project ID
6+
7+
Account account = Account(client);
8+
9+
Token result = await account.createEmailToken(
10+
userId: '<USER_ID>',
11+
12+
phrase: false, // optional
13+
);

docs/examples/account/create-j-w-t.md

Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,9 @@
11
import 'package:appwrite/appwrite.dart';
22

3-
void main() { // Init SDK
4-
Client client = Client();
5-
Account account = Account(client);
6-
7-
client
3+
Client client = Client()
84
.setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
9-
.setProject('5df5acd0d48c2') // Your project ID
10-
;
11-
Future result = account.createJWT();
5+
.setProject('5df5acd0d48c2'); // Your project ID
6+
7+
Account account = Account(client);
128

13-
result
14-
.then((response) {
15-
print(response);
16-
}).catchError((error) {
17-
print(error.response);
18-
});
19-
}
9+
Jwt result = await account.createJWT();

docs/examples/account/create-magic-u-r-l-session.md

Lines changed: 0 additions & 22 deletions
This file was deleted.

0 commit comments

Comments
 (0)