Skip to content

Commit 196f6ef

Browse files
Merge pull request #34 from appwrite/1.6.x
1.6.x
2 parents 21eea18 + b3bb237 commit 196f6ef

File tree

292 files changed

+4902
-4276
lines changed

Some content is hidden

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

292 files changed

+4902
-4276
lines changed

README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
# Appwrite PHP SDK
22

33
![License](https://img.shields.io/github/license/appwrite/sdk-for-php.svg?style=flat-square&v=1)
4-
![Version](https://img.shields.io/badge/api%20version-1.5.7-blue.svg?style=flat-square&v=1)
4+
![Version](https://img.shields.io/badge/api%20version-1.6.0-blue.svg?style=flat-square&v=1)
55
[![Build Status](https://img.shields.io/travis/com/appwrite/sdk-generator?style=flat-square)](https://travis-ci.com/appwrite/sdk-generator)
66
[![Twitter Account](https://img.shields.io/twitter/follow/appwrite?color=00acee&label=twitter&style=flat-square)](https://twitter.com/appwrite)
77
[![Discord](https://img.shields.io/discord/564160730845151244?label=discord&style=flat-square)](https://appwrite.io/discord)
88

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

1111
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 PHP 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)
1212

docs/account.md

+5-6
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ DELETE https://cloud.appwrite.io/v1/account/identities/{identityId}
7373
## Create JWT
7474

7575
```http request
76-
POST https://cloud.appwrite.io/v1/account/jwt
76+
POST https://cloud.appwrite.io/v1/account/jwts
7777
```
7878

7979
** Use this endpoint to create a JSON Web Token. You can use the resulting JWT to authenticate on behalf of the current user when working with the Appwrite server-side API and SDKs. The JWT secret is valid for 15 minutes from its creation and will be invalid if the user will logout in that time frame. **
@@ -106,7 +106,7 @@ PATCH https://cloud.appwrite.io/v1/account/mfa
106106
| --- | --- | --- | --- |
107107
| mfa | boolean | Enable or disable MFA. | |
108108

109-
## Add Authenticator
109+
## Create Authenticator
110110

111111
```http request
112112
POST https://cloud.appwrite.io/v1/account/mfa/authenticators/{type}
@@ -126,7 +126,7 @@ POST https://cloud.appwrite.io/v1/account/mfa/authenticators/{type}
126126
PUT https://cloud.appwrite.io/v1/account/mfa/authenticators/{type}
127127
```
128128

129-
** Verify an authenticator app after adding it using the [add authenticator](/docs/references/cloud/client-web/account#createMfaAuthenticator) method. add **
129+
** Verify an authenticator app after adding it using the [add authenticator](/docs/references/cloud/client-web/account#createMfaAuthenticator) method. **
130130

131131
### Parameters
132132

@@ -148,9 +148,8 @@ DELETE https://cloud.appwrite.io/v1/account/mfa/authenticators/{type}
148148
| Field Name | Type | Description | Default |
149149
| --- | --- | --- | --- |
150150
| type | string | **Required** Type of authenticator. | |
151-
| otp | string | Valid verification token. | |
152151

153-
## Create 2FA Challenge
152+
## Create MFA Challenge
154153

155154
```http request
156155
POST https://cloud.appwrite.io/v1/account/mfa/challenge
@@ -562,7 +561,7 @@ POST https://cloud.appwrite.io/v1/account/verification/phone
562561

563562
** Use this endpoint to send a verification SMS to the currently logged in user. This endpoint is meant for use after updating a user's phone number using the [accountUpdatePhone](https://appwrite.io/docs/references/cloud/client-web/account#updatePhone) endpoint. Learn more about how to [complete the verification process](https://appwrite.io/docs/references/cloud/client-web/account#updatePhoneVerification). The verification code sent to the user's phone number is valid for 15 minutes. **
564563

565-
## Create phone verification (confirmation)
564+
## Update phone verification (confirmation)
566565

567566
```http request
568567
PUT https://cloud.appwrite.io/v1/account/verification/phone

docs/avatars.md

+4-2
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,8 @@ GET https://cloud.appwrite.io/v1/avatars/favicon
4646
```
4747

4848
** Use this endpoint to fetch the favorite icon (AKA favicon) of any remote website URL.
49-
**
49+
50+
This endpoint does not follow HTTP redirects. **
5051

5152
### Parameters
5253

@@ -83,7 +84,8 @@ GET https://cloud.appwrite.io/v1/avatars/image
8384
** Use this endpoint to fetch a remote image URL and crop it to any image size you want. This endpoint is very useful if you need to crop and display remote images in your app or in case you want to make sure a 3rd party image is properly served using a TLS protocol.
8485

8586
When one dimension is specified and the other is 0, the image is scaled with preserved aspect ratio. If both dimensions are 0, the API provides an image at source quality. If dimensions are not specified, the default size of image returned is 400x400px.
86-
**
87+
88+
This endpoint does not follow HTTP redirects. **
8789

8890
### Parameters
8991

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

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2'); // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>'); // Your project ID
99

1010
$account = new Account($client);
1111

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

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2'); // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>'); // Your project ID
99

1010
$account = new Account($client);
1111

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

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2'); // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>'); // Your project ID
99

1010
$account = new Account($client);
1111

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

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2'); // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>'); // Your project ID
99

1010
$account = new Account($client);
1111

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

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2'); // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>'); // Your project ID
99

1010
$account = new Account($client);
1111

docs/examples/account/create-mfa-authenticator.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ use Appwrite\Enums\AuthenticatorType;
66
77
$client = (new Client())
88
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
9-
->setProject('5df5acd0d48c2') // Your project ID
9+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
1010
->setSession(''); // The user session to authenticate with
1111

1212
$account = new Account($client);

docs/examples/account/create-mfa-challenge.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ use Appwrite\Enums\AuthenticationFactor;
66
77
$client = (new Client())
88
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
9-
->setProject('5df5acd0d48c2'); // Your project ID
9+
->setProject('<YOUR_PROJECT_ID>'); // Your project ID
1010

1111
$account = new Account($client);
1212

docs/examples/account/create-mfa-recovery-codes.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/create-o-auth2token.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ use Appwrite\Enums\OAuthProvider;
66
77
$client = (new Client())
88
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
9-
->setProject('5df5acd0d48c2'); // Your project ID
9+
->setProject('<YOUR_PROJECT_ID>'); // Your project ID
1010

1111
$account = new Account($client);
1212

docs/examples/account/create-phone-token.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2'); // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>'); // Your project ID
99

1010
$account = new Account($client);
1111

docs/examples/account/create-phone-verification.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/create-recovery.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/create-session.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2'); // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>'); // Your project ID
99

1010
$account = new Account($client);
1111

docs/examples/account/create-verification.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/create.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2'); // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>'); // Your project ID
99

1010
$account = new Account($client);
1111

docs/examples/account/delete-identity.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/delete-mfa-authenticator.md

+2-3
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,11 @@ use Appwrite\Enums\AuthenticatorType;
66
77
$client = (new Client())
88
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
9-
->setProject('5df5acd0d48c2') // Your project ID
9+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
1010
->setSession(''); // The user session to authenticate with
1111

1212
$account = new Account($client);
1313

1414
$result = $account->deleteMfaAuthenticator(
15-
type: AuthenticatorType::TOTP(),
16-
otp: '<OTP>'
15+
type: AuthenticatorType::TOTP()
1716
);

docs/examples/account/delete-session.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/delete-sessions.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/get-mfa-recovery-codes.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/get-prefs.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/get-session.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/get.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/list-identities.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/list-logs.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/list-mfa-factors.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/list-sessions.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/update-email.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/update-m-f-a.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

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

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2'); // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>'); // Your project ID
99

1010
$account = new Account($client);
1111

docs/examples/account/update-mfa-authenticator.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ use Appwrite\Enums\AuthenticatorType;
66
77
$client = (new Client())
88
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
9-
->setProject('5df5acd0d48c2') // Your project ID
9+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
1010
->setSession(''); // The user session to authenticate with
1111

1212
$account = new Account($client);

docs/examples/account/update-mfa-challenge.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/update-mfa-recovery-codes.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

docs/examples/account/update-name.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Appwrite\Services\Account;
55
66
$client = (new Client())
77
->setEndpoint('https://cloud.appwrite.io/v1') // Your API Endpoint
8-
->setProject('5df5acd0d48c2') // Your project ID
8+
->setProject('<YOUR_PROJECT_ID>') // Your project ID
99
->setSession(''); // The user session to authenticate with
1010

1111
$account = new Account($client);

0 commit comments

Comments
 (0)