PayStream is a Next.js application designed to streamline financial management for a non-profit client.
Explore the docs »
Report Bug
·
Request Feature
Table of Contents
Before using this application, make sure you have the following in place:
- Stripe Account: You’ll need a Stripe account to connect to the payment gateway and manage donations.
- Salesforce Account: You must have a Salesforce account with the necessary permissions to set up the integration.
- Web Server: This application requires a web server to host the integration. You can use a cloud service like AWS, Google Cloud, or Heroku.
- API Keys: Obtain API keys from both Stripe and Salesforce for secure communication between the systems.
-
Get your publishable and secret Stripe API Keys at: https://dashboard.stripe.com/test/apikeys
-
Get your Salesforce access token by following the following steps: https://help.salesforce.com/s/articleView?id=sf.remoteaccess_oauth_jwt_flow.htm&type=5
-
Clone the repo
git clone https://github.com/oslabs-beta/PayStream.git
-
Install NPM packages
npm install
-
Enter your JWT Secret into the
.env
file:JWT_SECRET = 'ENTER YOUR JWT SECRET';
-
Enter your Salesforce Authentication information into the
.env
file:SALESFORCE_GRAPHQL_URI = '[YOUR SALESFORCE INSTANCE]/services/data/v58.0/graphql' SALESFORCE_COOKIE_AUTH = 'ENTER YOUR SALEFORCE COOKING AUTHORIZATION' SALESFORCE_LOGIN_URL = 'ENTER YOUR SALESFORCE LOGIN URL' SALESFORCE_AUTH_TYPE = oauth-client-credentials SALESFORCE_USERNAME = 'ENTER YOUR SALESFORCE USERNAME' SALESFORCE_PASSWORD = 'ENTER YOUR SALESFORCE PASSWORD' SALESFORCE_ORG_ID = 'ENTER YOUR SALESFORCE ORGANIZATION ID' PUB_SUB_ENDPOINT = api.pubsub.salesforce.com:7443 SALESFORCE_CLIENT_ID = 'ENTER YOUR SALESFORCE CLIENT ID' SALESFORCE_CLIENT_SECRET = 'ENTER YOUR SALESFORCE CLIENT SECRET' SALESFORCE_URL = 'https://test.salesforce.com' BASE64_PRIVATE_KEY = 'ENTER YOUR BASE64 PRIVATE KEY'
-
Enter your Stripe Authentication information into the
.env
file:NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY = 'ENTER YOUR STRIPE PUBLIC KEY'; STRIPE_SECRET_KEY = 'ENTER YOUR STRIPE SECRET KEY'; STRIPE_ENDPOINT_SECRET = 'ENTER YOUR STRIPE ENDPOINT SECRET'
-
Enter your Clerk Authentication information into the
.env
file:NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY = 'ENTER YOUR CLERK PUBLIC KEY'; CLERK_SECRET_KEY = 'ENTER YOUR CLERK SECRET KEY'; NEXT_PUBLIC_CLERK_SIGN_IN_URL=/sign-in NEXT_PUBLIC_CLERK_AFTER_SIGN_IN_URL=/
- Stripe Integration:
- Go to your Stripe dashboard and obtain your API keys.
- Update the
.env
file with your Stripe API keys. - Go to https://dashboard.stripe.com/test/apikeys and generate your Stripe endpoint for your application.
- Salesforce Integration:
- Obtain Salesforce API credentials (Consumer Key, Consumer Secret, Username, and Password).
- Update the
.env
file with your Salesforce API credentials. - The queries are mapped to custom payment records for a specific client and will need to be refactored to your application specific needs.
- Webhook Setup:
- Configure webhooks in Stripe to send events to your application’s endpoint.
- Use a service like ngrok to create a secure tunnel to your local server or set up SSL on your production server.
- Customization:
- Modify the application to match your nonprofit’s specific Salesforce objects, fields, and donation processing logic.
Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.
If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Distributed under the MIT License. See LICENSE.txt
for more information.
Email Us: [email protected]
Project Link: https://github.com/oslabs-beta/PayStream
Developed By | Github | |
---|---|---|
Chandler Charity | ||
Julia Xin | ||
Liam Hodges | ||
Robert Hoover |