- Run
npm install -g amplify-stripe-nodejs-function-template-provider
to install the plugin to your globalnode_modules
directory. - Run
amplify plugin scan
so the Amplify CLI plugin platform will pick up the newly added plugin.
For additional details on plugins, see the AWS Amplify CLI plugins docs.
Once installed, you can use this plugin to generate Amplify API Lambda handlers for you:
- Run
amplify add api
to add a new backend API or runamplify update api
to add a new path to an existing API. - [...]
- ? Choose a Lambda source > Create a new Lambda function
- ? Choose the function runtime that you want to use: > NodeJS
- ? Choose the function template that you want to use: > { Select one of the Stripe templates }
- [...]
You can view this reference implementation to see how the function templates fit into a full-stack Amplify web application.
- To contribute to this plugin, fork this repository then clone your fork to your local machine.
- Install the dependencies:
yarn
. - Build the project:
yarn build
. - Add the local plugin to your Amplify CLI:
amplify plugin add
and provide the path to your repository root. - Follow the usage steps to run the local plugin.