Skip to content
This repository has been archived by the owner on Jul 16, 2022. It is now read-only.

[Suggestions] Suggest new Idea for Cloud Function Demos 💡 #29

Open
Glide7 opened this issue Dec 17, 2020 · 3 comments
Open

[Suggestions] Suggest new Idea for Cloud Function Demos 💡 #29

Glide7 opened this issue Dec 17, 2020 · 3 comments
Labels
dwoc Issues for devscript winter of code enhancement New feature or request help wanted Extra attention is needed

Comments

@Glide7
Copy link
Contributor

Glide7 commented Dec 17, 2020

Suggest new Idea for Cloud Function Demos 💡

We use Appwrite Cloud Functions demos as a good way to show how Cloud Functions can be used with Appwrite, and also as a good starting point for developers wanting to write their new functions.

We would love to receive your suggestions for other cloud function demos!
Please comment down below if you have such an idea ♥

Before starting any work ⚙

  • Please wait for Appwrite team feedback 💙
  • Let us know if you wish to start a new issue and be assigned to work on a function demo
  • A separate issue will be opened once an idea is approved
  • What language you want to help with book 🧾
@Glide7 Glide7 added dwoc Issues for devscript winter of code enhancement New feature or request help wanted Extra attention is needed labels Dec 17, 2020
@eldadfux eldadfux pinned this issue Dec 17, 2020
@mlucas-NU
Copy link

mlucas-NU commented Feb 7, 2021

Here are some ideas to get the conversation started. Ultimately, they're meant to target granular questions someone might ask, so a bunch could be combined to make up one demo. Come to think of it, what type of demos are you imagining?

  • The simplest cronjob, like logging "hello world."
  • The simplest endpoint, like returning the current server time.
  • Basic examples that explain how to interact with each of appwrite's services.
  • An explanation of endpoint security. E.g. can we create endpoints that can be accessed without authentication? Can we restrict endpoints to certain users/teams?
  • Endpoints with required/optional parameters.
  • Formatting endpoint responses as popular MIME content types (e.g. text, application/xml, text/json, text/csv).
  • Custom wrappers for REST functions. For example, add an expiration timestamp field equal to 5 days in the future on document PUTs, do not include expiration in document GET responses, do not allow users to modify expiration through any tricky means (either through these Cloud Functions or appwrite's default routes for these documents), and do not allow users to interact with the document at all after the expiration date has passed.
  • An example of interacting with an external API that appwrite users are likely to use (e.g. cloud hosting, social media). It would be nice to use an API that has its own beginner-friendly explanation (e.g. Google Adwords' basic API) just in case the user wants to understand that API as well, but there's a risk that the explanation changes over time or is moved/deleted. In particular, I'd be interested to know how to securely store API keys in appwrite (this may be a challenge without superadmin accounts) and see a code snippet that retrieves these keys, authenticates with the external API, and does a thing.
  • Code Function best practices. Can appwrite containers ingest a directory of Code Functions as a volume when deployed? This would be incredibly useful for source control and continuous deployment/scaling. If so, how should the directory be structured? How does a developer specify to appwrite that a function is an endpoint or a cronjob? Are there any other recommendations for teams making maintainable Cloud Functions?

@mendoza
Copy link
Contributor

mendoza commented Oct 5, 2021

@Glide7 What do you think about

  • Server heartbeat (same as server time on @mlucas-NU)
  • Getting weather on a specific Geolocation with coordinates or even with a city name!

@syntaxlexx
Copy link

  • targetting specific collections when their documents get added/updated
  • A direct comparison/mapping of "here's how you did it in firebase" > "here's how you do it in appwrite" (not sure how best to word that)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
dwoc Issues for devscript winter of code enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

4 participants