mirror of
https://github.com/swissmakers/swiss-datashare.git
synced 2026-04-11 10:27:01 +02:00
initial commit
This commit is contained in:
18
.setup/services/aw.service.ts
Normal file
18
.setup/services/aw.service.ts
Normal file
@@ -0,0 +1,18 @@
|
||||
import sdk from "node-appwrite";
|
||||
const aw = () => {
|
||||
let client = new sdk.Client();
|
||||
|
||||
client
|
||||
.setEndpoint(process.env["APPWRITE_HOST"])
|
||||
.setProject("pingvin-share")
|
||||
.setKey(process.env["APPWRITE_API_KEY"])
|
||||
.setSelfSigned();
|
||||
|
||||
const database = new sdk.Database(client);
|
||||
const storage = new sdk.Database(client);
|
||||
const functions = new sdk.Functions(client);
|
||||
|
||||
return { database, storage, functions };
|
||||
};
|
||||
|
||||
export default aw;
|
||||
Reference in New Issue
Block a user