Serverless automation for syncing Jersey Mike's point-of-sale, delivery, and inventory data to QuickBooks.
- Automated scraping of FlexePOS system data
- Integration with third-party delivery services (DoorDash, GrubHub, UberEats, EzCater)
- CrunchTime inventory management sync
- WhenIWork scheduling integration
- Google Drive integration for data storage
- QuickBooks data synchronization
- Serverless deployment using AWS Lambda
- AWS Lambda functions with Chrome/Selenium
- Scheduled data collection and processing
- Secure credential management via AWS Systems Manager Parameter Store
- Error monitoring and notification system
- AWS Account with appropriate permissions
- Credentials for the following services:
- FlexePOS
- DoorDash
- GrubHub
- UberEats
- EzCater
- CrunchTime
- WhenIWork
- Google Cloud Platform service account for Drive integration
- Terraform installed locally
Ensure you have AWS credentials configured locally with appropriate permissions for:
- Lambda
- Systems Manager Parameter Store
- IAM
- CloudWatch
- S3
- Navigate to the
terraform
directory - Copy the template file to create your configuration:
cp terraform.tfvars.template terraform.tfvars
- Edit
terraform.tfvars
with your specific values:- AWS account details
- Region preferences
- Service credentials
- S3 bucket name (must be globally unique)
- Google Drive configuration
- Email notification settings
- Store configuration with opening and closing dates (optional)
The following variable groups must be configured:
settings = {
account_number = "YOUR_AWS_ACCOUNT"
region = "us-east-1"
owner = "[email protected]"
accounting = "TEAM_NAME"
s3_bucket = "your-bucket-name"
}
Configure credentials for each service:
- FlexePOS (username/password)
- CrunchTime (username/password)
- DoorDash (username/password)
- GrubHub (username/password)
- UberEats (username/password/PIN)
- WhenIWork (username/password/API key)
- EzCater (username/password)
gcp_config = {
employees_folder = "FOLDER_ID"
journal_folder = "FOLDER_ID"
}
email_config = {
receiver_emails = ["[email protected]"]
from_email = "Bot Name <[email protected]>"
}
-
Initialize Terraform:
terraform init
-
Review the planned changes:
terraform plan
-
Apply the configuration:
terraform apply
- Update values in terraform.tfvars
- Run terraform plan to review changes
- Apply changes with terraform apply
- All sensitive credentials are stored in AWS Systems Manager Parameter Store
- Passwords and API keys are stored as SecureString parameters
- Never commit terraform.tfvars to version control
- Rotate service credentials regularly
- Monitor AWS CloudTrail for unauthorized API usage
- Review IAM roles and permissions regularly
The system includes several error handling mechanisms:
- Automated retries for failed scrapes
- Comprehensive logging via CloudWatch
- Email notifications for failures
- Automated recovery procedures
- Fork the repository
- Create feature branch
- Submit pull request
Please ensure you:
- Do not commit any credentials
- Test all changes locally
- Update documentation as needed
- Follow existing code style
Common issues and solutions:
- Credential issues: Check SSM Parameter Store values
- Lambda timeouts: Review Chrome instance memory usage
- Scraping failures: Verify service endpoint changes
MIT License - See LICENSE file
For issues and feature requests, please use the GitHub issue tracker.