wip
This commit is contained in:
parent
aff1013ee8
commit
37239edad5
1 changed files with 12 additions and 0 deletions
|
@ -376,6 +376,18 @@ trait StorageBase
|
||||||
/**
|
/**
|
||||||
* Test for SUCCESS
|
* Test for SUCCESS
|
||||||
*/
|
*/
|
||||||
|
$bucket = $this->client->call(Client::METHOD_POST, '/storage/buckets', array_merge([
|
||||||
|
'content-type' => 'application/json',
|
||||||
|
'x-appwrite-project' => $this->getProject()['$id'],
|
||||||
|
'x-appwrite-key' => $this->getProject()['apiKey'],
|
||||||
|
], $this->getHeaders()), [
|
||||||
|
'name' => 'Test Bucket',
|
||||||
|
'maximumFileSize' => 2000000, //2MB
|
||||||
|
'allowedFileExtensions' => ["jpg", "png"],
|
||||||
|
'read' => ['role:all'],
|
||||||
|
'write' => ['role:all'],
|
||||||
|
]);
|
||||||
|
|
||||||
$file = $this->client->call(Client::METHOD_POST, '/storage/files', array_merge([
|
$file = $this->client->call(Client::METHOD_POST, '/storage/files', array_merge([
|
||||||
'content-type' => 'multipart/form-data',
|
'content-type' => 'multipart/form-data',
|
||||||
'x-appwrite-project' => $this->getProject()['$id'],
|
'x-appwrite-project' => $this->getProject()['$id'],
|
||||||
|
|
Loading…
Reference in a new issue