Getting started
A "Getting started" guide for Memphis Functions
How to develop a new private function
Memphis functions offers two types of function libraries: Public, and private. The public library is available by default for each account and is powered by Memphis.dev Functions repository.
The private library is available for your account only and therefore requires the user to develop functions and integrate its account with the designated repositories.
A function comprises code files (based on Memphis template) and a memphis.yaml
file contained within a unified directory.
The directory ought to be included in a Git repository that's linked with Memphis.
Here is a brief hierarchy diagram of how a compatible function file tree should be constructed:
🚀 Step-by-step Guide:
Clone or create a new repository (At the moment, support is exclusively available for GitHub.)
Within this repository, establish a fresh directory and initialize it to your chosen programming language
Generate a template or Copy one of the Memphis Functions templates. For this guide, we chose Node.js
Required. Write your logic inside the
eventHandler
block. Incoming events will be accumulated and dispatched to a function collectively in a batch; therefore, the wrapper
Messages will return to the Memphis Station in a batch as well.
5. Required. Add or modify the memphis.yaml
file based on the following template:
Optional. Add a
README
file to describe your function so others will know what to do :)Optional. Add
test.json
so when a user tests the function, thetest event
will already be populatedConnect the designated repository with your Memphis account
my-function
should be available through the Functions main page or a station
How to develop a new public function
Add your function's directory, including
memphis.yaml
fileCreate a PR
The addition of the new function will take place following a thorough review and subsequent approval
Get your swag pack! 😍
Last updated