The Secret Santa Application is a Ballerina-based tool that automates organizing Secret Santa events. It randomly assigns participants as Secret Santas, sends email notifications with recipient details, and provides features like wishlist integration and email management for event coordination.
- Random Pairing: Ensures participants are randomly assigned Secret Santa roles.
- Google Sheets Integration: Fetches participant details (name, email, wishlist) from a Google Sheet.
- Email Notifications: Automatically sends emails to participants with their assigned recipient and wishlist.
- Ballerina installed on your system.
- Access to the Gmail API, Google Sheets API.
- OAuth 2.0 credentials and API tokens for Google services.
- Enable the following Google APIs in your Google Cloud Console:
- Gmail API
- Google Sheets API
- Generate OAuth 2.0 credentials and API tokens.
- Share your Google Sheet with the email associated with the API credentials.
- Ensure your Google Sheet has the following columns:
- Column A: Participant name
- Column B: Email address
- Column C: Wishlist
- Clone the repository:
git clone https://github.com/sm1990/secret-santa-app.git cd secret-santa-app
- Open the
main.balfile. - Update the
configurablevariables:configurable string authToken = "<YOUR_AUTH_TOKEN>"; configurable string spreadsheetId = "<YOUR_SPREADSHEET_ID>"; configurable string sheetName = "<YOUR_SHEET_NAME>";
- Run the application:
bal run
- The application will:
- Fetch participant details from the Google Sheet.
- Randomly assign Secret Santas.
- Send email notifications with recipient and wishlist details.
- Error Fetching Emails: Ensure the Gmail API token is valid and has the necessary permissions.
- Error Fetching Sheet Data: Verify the Google Sheet is shared and the token is correct.
- Email Delivery Issues: Check the email addresses for accuracy and ensure the Gmail API quota is not exceeded.
- Add a web interface for easier configuration.
- Support multiple wishlists per participant.
- Integration with payment gateways for gift purchases.
This project is licensed under the MIT License. See the LICENSE file for details.
Contributions are welcome! Feel free to fork the repository and submit a pull request.
Enjoy spreading holiday cheer with the Secret Santa Application! 🎅