Back

Need ideas for automating appwrite collections, indexes, storage bucket

  • 0
  • Web
yatharth
2 Oct, 2023, 05:55

I have created a project during last hackathon of appwrite. It was Formvibe which helps user create forms with ease.

I have made it open source. Problem is in the initial setup of the project. I have some collections in database and one bucket in storage which i want to automate somehow, so that if any user try to setup my project from github, appwrite part will be automated somehow and he doesn't need to create those collections and bucket

TL;DR
The user wants to automate the creation of collections, indexes, and storage buckets for their Appwrite project. They mention using the node-appwrite SDK and creating a script that takes an API key to perform the automation. Another user mentions the possibility of using the console SDK but is unsure of its capabilities. It is suggested to at least generate an endpoint, project ID, and API key with correct permissions for initial setup. The user also shares that they have an open-source project with initial collections and a bucket that they want to automate for easy setup.
yatharth
2 Oct, 2023, 05:56

Any ideas on this ?

darShan
2 Oct, 2023, 06:07

I don't think there'll be a complete automation. The minimum setup required would be to at-least generate an

  1. Endpoint,
  2. The Project Id,
  3. The API Key with correct permissions.

With these, you can create a form, take these inputs & create the initial collections, databases. This would only make sense if there are quite many dbs or collections. Else creating a DB & a Collection isn't that much.

Ajit Singh
2 Oct, 2023, 06:15

I am not sure but there is the console sdk

Ajit Singh
2 Oct, 2023, 06:15

that may help you but I dont know how powerful it is

darShan
2 Oct, 2023, 06:19

Console SDK isn't for public use, afaik.

yatharth
2 Oct, 2023, 06:29

I guess you are right. I will have to create a script that will use node-appwrite sdk maybe and that will take api key to do all these automation like creating database, collections, indexes and storage bucket and all those resources which i require initially

D5
2 Oct, 2023, 06:43

What do you mean by automating collections, indexes and buckets? You mean creating new one automatically? For what do you need this?

D5
2 Oct, 2023, 06:44

You can with node SDK as you said

yatharth
2 Oct, 2023, 06:45

I have this project which is using Appwrite in backend . Now if anyone wants to setup my project locally he would have to create collections attributes and indexes manually in console

yatharth
2 Oct, 2023, 06:45

That part I want to automate

yatharth
2 Oct, 2023, 06:46

It will be one time only

yatharth
2 Oct, 2023, 06:46

Initially required before running the project

D5
2 Oct, 2023, 06:47

You can create what you mentioned with any of the existing server side SDK

yatharth
2 Oct, 2023, 06:48

Sure got it.

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more