Skip to content

Commit 77e67e7

Browse files
committed
Fix casing
1 parent 969136a commit 77e67e7

File tree

192 files changed

+2669
-540
lines changed

Some content is hidden

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

192 files changed

+2669
-540
lines changed
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
import io.appwrite.Client;
2+
import io.appwrite.coroutines.CoroutineCallback;
3+
import io.appwrite.services.Account;
4+
import io.appwrite.enums.AuthenticatorType;
5+
6+
Client client = new Client()
7+
.setEndpoint("https://<REGION>.cloud.appwrite.io/v1") // Your API Endpoint
8+
.setProject("<YOUR_PROJECT_ID>") // Your project ID
9+
.setSession(""); // The user session to authenticate with
10+
11+
Account account = new Account(client);
12+
13+
account.createMFAAuthenticator(
14+
AuthenticatorType.TOTP, // type
15+
new CoroutineCallback<>((result, error) -> {
16+
if (error != null) {
17+
error.printStackTrace();
18+
return;
19+
}
20+
21+
System.out.println(result);
22+
})
23+
);
24+
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
import io.appwrite.Client;
2+
import io.appwrite.coroutines.CoroutineCallback;
3+
import io.appwrite.services.Account;
4+
import io.appwrite.enums.AuthenticationFactor;
5+
6+
Client client = new Client()
7+
.setEndpoint("https://<REGION>.cloud.appwrite.io/v1") // Your API Endpoint
8+
.setProject("<YOUR_PROJECT_ID>"); // Your project ID
9+
10+
Account account = new Account(client);
11+
12+
account.createMFAChallenge(
13+
AuthenticationFactor.EMAIL, // factor
14+
new CoroutineCallback<>((result, error) -> {
15+
if (error != null) {
16+
error.printStackTrace();
17+
return;
18+
}
19+
20+
System.out.println(result);
21+
})
22+
);
23+
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
import io.appwrite.Client;
2+
import io.appwrite.coroutines.CoroutineCallback;
3+
import io.appwrite.services.Account;
4+
5+
Client client = new Client()
6+
.setEndpoint("https://<REGION>.cloud.appwrite.io/v1") // Your API Endpoint
7+
.setProject("<YOUR_PROJECT_ID>") // Your project ID
8+
.setSession(""); // The user session to authenticate with
9+
10+
Account account = new Account(client);
11+
12+
account.createMFARecoveryCodes(new CoroutineCallback<>((result, error) -> {
13+
if (error != null) {
14+
error.printStackTrace();
15+
return;
16+
}
17+
18+
System.out.println(result);
19+
}));
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
import io.appwrite.Client;
2+
import io.appwrite.coroutines.CoroutineCallback;
3+
import io.appwrite.services.Account;
4+
import io.appwrite.enums.AuthenticatorType;
5+
6+
Client client = new Client()
7+
.setEndpoint("https://<REGION>.cloud.appwrite.io/v1") // Your API Endpoint
8+
.setProject("<YOUR_PROJECT_ID>") // Your project ID
9+
.setSession(""); // The user session to authenticate with
10+
11+
Account account = new Account(client);
12+
13+
account.deleteMFAAuthenticator(
14+
AuthenticatorType.TOTP, // type
15+
new CoroutineCallback<>((result, error) -> {
16+
if (error != null) {
17+
error.printStackTrace();
18+
return;
19+
}
20+
21+
System.out.println(result);
22+
})
23+
);
24+
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
import io.appwrite.Client;
2+
import io.appwrite.coroutines.CoroutineCallback;
3+
import io.appwrite.services.Account;
4+
5+
Client client = new Client()
6+
.setEndpoint("https://<REGION>.cloud.appwrite.io/v1") // Your API Endpoint
7+
.setProject("<YOUR_PROJECT_ID>") // Your project ID
8+
.setSession(""); // The user session to authenticate with
9+
10+
Account account = new Account(client);
11+
12+
account.getMFARecoveryCodes(new CoroutineCallback<>((result, error) -> {
13+
if (error != null) {
14+
error.printStackTrace();
15+
return;
16+
}
17+
18+
System.out.println(result);
19+
}));
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
import io.appwrite.Client;
2+
import io.appwrite.coroutines.CoroutineCallback;
3+
import io.appwrite.services.Account;
4+
5+
Client client = new Client()
6+
.setEndpoint("https://<REGION>.cloud.appwrite.io/v1") // Your API Endpoint
7+
.setProject("<YOUR_PROJECT_ID>") // Your project ID
8+
.setSession(""); // The user session to authenticate with
9+
10+
Account account = new Account(client);
11+
12+
account.listMFAFactors(new CoroutineCallback<>((result, error) -> {
13+
if (error != null) {
14+
error.printStackTrace();
15+
return;
16+
}
17+
18+
System.out.println(result);
19+
}));
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
import io.appwrite.Client;
2+
import io.appwrite.coroutines.CoroutineCallback;
3+
import io.appwrite.services.Account;
4+
import io.appwrite.enums.AuthenticatorType;
5+
6+
Client client = new Client()
7+
.setEndpoint("https://<REGION>.cloud.appwrite.io/v1") // Your API Endpoint
8+
.setProject("<YOUR_PROJECT_ID>") // Your project ID
9+
.setSession(""); // The user session to authenticate with
10+
11+
Account account = new Account(client);
12+
13+
account.updateMFAAuthenticator(
14+
AuthenticatorType.TOTP, // type
15+
"<OTP>", // otp
16+
new CoroutineCallback<>((result, error) -> {
17+
if (error != null) {
18+
error.printStackTrace();
19+
return;
20+
}
21+
22+
System.out.println(result);
23+
})
24+
);
25+
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
import io.appwrite.Client;
2+
import io.appwrite.coroutines.CoroutineCallback;
3+
import io.appwrite.services.Account;
4+
5+
Client client = new Client()
6+
.setEndpoint("https://<REGION>.cloud.appwrite.io/v1") // Your API Endpoint
7+
.setProject("<YOUR_PROJECT_ID>") // Your project ID
8+
.setSession(""); // The user session to authenticate with
9+
10+
Account account = new Account(client);
11+
12+
account.updateMFAChallenge(
13+
"<CHALLENGE_ID>", // challengeId
14+
"<OTP>", // otp
15+
new CoroutineCallback<>((result, error) -> {
16+
if (error != null) {
17+
error.printStackTrace();
18+
return;
19+
}
20+
21+
System.out.println(result);
22+
})
23+
);
24+
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
import io.appwrite.Client;
2+
import io.appwrite.coroutines.CoroutineCallback;
3+
import io.appwrite.services.Account;
4+
5+
Client client = new Client()
6+
.setEndpoint("https://<REGION>.cloud.appwrite.io/v1") // Your API Endpoint
7+
.setProject("<YOUR_PROJECT_ID>") // Your project ID
8+
.setSession(""); // The user session to authenticate with
9+
10+
Account account = new Account(client);
11+
12+
account.updateMFARecoveryCodes(new CoroutineCallback<>((result, error) -> {
13+
if (error != null) {
14+
error.printStackTrace();
15+
return;
16+
}
17+
18+
System.out.println(result);
19+
}));
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
import io.appwrite.Client;
2+
import io.appwrite.coroutines.CoroutineCallback;
3+
import io.appwrite.services.Messaging;
4+
5+
Client client = new Client()
6+
.setEndpoint("https://<REGION>.cloud.appwrite.io/v1") // Your API Endpoint
7+
.setProject("<YOUR_PROJECT_ID>") // Your project ID
8+
.setKey("<YOUR_API_KEY>"); // Your secret API key
9+
10+
Messaging messaging = new Messaging(client);
11+
12+
messaging.createAPNSProvider(
13+
"<PROVIDER_ID>", // providerId
14+
"<NAME>", // name
15+
"<AUTH_KEY>", // authKey (optional)
16+
"<AUTH_KEY_ID>", // authKeyId (optional)
17+
"<TEAM_ID>", // teamId (optional)
18+
"<BUNDLE_ID>", // bundleId (optional)
19+
false, // sandbox (optional)
20+
false, // enabled (optional)
21+
new CoroutineCallback<>((result, error) -> {
22+
if (error != null) {
23+
error.printStackTrace();
24+
return;
25+
}
26+
27+
System.out.println(result);
28+
})
29+
);
30+

0 commit comments

Comments
 (0)