https://github.com/utmmcss/deerhacks-backend
DeerHacks Hackthon Dashboard Server 2024
https://github.com/utmmcss/deerhacks-backend
brevo discord-oauth2 docker hackathon mlh mlh-hackathon
Last synced: 5 months ago
JSON representation
DeerHacks Hackthon Dashboard Server 2024
- Host: GitHub
- URL: https://github.com/utmmcss/deerhacks-backend
- Owner: utmmcss
- License: gpl-3.0
- Created: 2023-10-15T00:49:25.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-04-19T12:46:03.000Z (about 2 years ago)
- Last Synced: 2024-06-20T23:57:10.984Z (almost 2 years ago)
- Topics: brevo, discord-oauth2, docker, hackathon, mlh, mlh-hackathon
- Language: Go
- Homepage:
- Size: 176 KB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
README
# DeerHacks API
[](https://deerhacks.ca)
> DeerHacks Hackathon 2024 Backend API
[](https://deerhacks.ca)
## Setup
1. Run `go build` to install dependencies
2. Add the required `.env` file with the schema specified below
3. Gather credentials from microservices and add it to the `.env` file
## Relevant URL'S
- [AWS S3 for saving resumes](https://aws.amazon.com/s3/pricing/?p=pm&c=s3&z=4)
- [AWS RDS for saving User Data](https://aws.amazon.com/rds/pricing/?p=ft&c=db)
- [Brevo for sending outbound emails](https://onboarding.brevo.com/account/register)
- [Discord Developer Portal](https://discord.com/developers/docs/intro)
## Getting Started
First, run the development server:
```bash
go run main.go
```
Send API requests to [http://localhost:8000](http://localhost:8000) (assuming port specified in .env file is 8000) with tools like Postman
### .env format
```bash
PORT=8000
DB_URL = "host= user= password= dbname= port=5432 sslmode=disable"
SECRET = "youcantypeanythingyouwanthere"
# From the Discord Developer Portal
CLIENT_ID = ""
CLIENT_SECRET = ""
BOT_TOKEN = ""
REDIRECT_URI = ""
# The discord server your discord bot will be in
GUILD_ID = "967161405017055342"
#Change this to "production" if public
APP_ENV = "development"
REGISTRATION_CUTOFF=1704085200 # (2024-01-01 00:00:00 EST)
# AWS IAM Credentials. Ensure full S3 access is given
AWS_ACCESS_KEY_ID = ""
AWS_SECRET_ACCESS_KEY = ""
# For sending emails
BREVO_API_KEY = ""
```