Schedura is a modern scheduling application inspired by Calendly. It enables users to create, manage, and share events for seamless bookings. With Google Calendar integration and a user-friendly interface, Schedura provides a robust solution for efficient scheduling.
- Introduction
- Features
- Tech Stack
- Prerequisites
- Environment Variables
- Database Model
- Getting Started
- License
- Author
- User Authentication: Powered by Clerk for secure and seamless user management.
- Event Management: Create events with customizable titles, descriptions, and durations.
- Google Calendar Integration: Synchronize events and bookings with Google Calendar for real-time updates.
- Dynamic Booking System: Allow clients to book events within predefined availability slots.
- Availability Management: Define availability for each day of the week with flexible time gaps.
- Responsive Design: Built with ShadCN UI and TailwindCSS for a beautiful and responsive interface.
- Secure Data Handling: Built using Prisma ORM with PostgreSQL (via NeonDB).
- Type Safety: Developed using TypeScript for a safer development experience.
- Form Validation: Uses Zod for client-side and server-side form validation.
- Frontend: Next.js, TypeScript, TailwindCSS
- Backend: Prisma ORM, PostgreSQL (via NeonDB)
- Authentication: Clerk
- Calendar Integration: Google Calendar API
- UI Components: ShadCN UI, Lucid React Icons
- Validation: Zod
To run this project, ensure you have the following:
- Node.js (v16 or above)
- PostgreSQL database (via NeonDB or another provider)
- Google Cloud Console API setup with the following scopes:
- Authentication
- User Data
- Calendar API
Create a .env
file in the root directory of the project and configure the following variables:
Variable | Description |
---|---|
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY |
Your Clerk publishable API key. |
CLERK_SECRET_KEY |
Your Clerk secret API key. |
NEXT_PUBLIC_CLERK_SIGN_IN_URL |
Path to the sign-in page (/sign-in ). |
NEXT_PUBLIC_CLERK_SIGN_OUT_URL |
Path to the sign-out page (/sign-out ). |
DATABASE_URL |
Your PostgreSQL database URL. |
Schedura uses Prisma ORM to define and interact with its database. Below is the detailed schema:
- Fields:
id
: Unique identifier for the user.clerkUserId
: ID associated with the Clerk authentication service.email
: User's email address.username
: User's chosen username.name
: User's full name.image
: Profile image URL.events
: List of events created by the user.bookings
: List of bookings associated with the user.availability
: Availability details of the user.createdAt
: Timestamp when the user was created.updatedAt
: Timestamp when the user was last updated.
- Relations: Connected to the
Event
,Booking
, andAvailability
models.
- Fields:
id
: Unique identifier for the event.title
: Title of the event.description
: Detailed description of the event.duration
: Duration of the event (in minutes).userId
: Reference to the user who created the event.privacy
: Privacy setting (e.g., public or private).createdAt
: Timestamp when the event was created.updatedAt
: Timestamp when the event was last updated.
- Relations: Connected to the
User
andBooking
models.
- Fields:
id
: Unique identifier for the booking.eventId
: Reference to the associated event.userId
: Reference to the user who made the booking (if applicable).name
: Name of the person who booked the event.email
: Email of the person who booked the event.additionalInfo
: Additional information provided during booking.startTime
: Start time of the booking.endTime
: End time of the booking.googleEventId
: Event ID for Google Calendar integration.meetLink
: Google Meet link for the event.createdAt
: Timestamp when the booking was created.updatedAt
: Timestamp when the booking was last updated.
- Relations: Connected to the
Event
andUser
models.
- Fields:
id
: Unique identifier for the availability entry.userId
: Reference to the associated user.days
: Days of the week when the user is available.timeGap
: Time interval between booking slots (in minutes).createdAt
: Timestamp when the availability was created.updatedAt
: Timestamp when the availability was last updated.
- Relations: Connected to the
User
model andDayAvailability
entries.
- Fields:
id
: Unique identifier for the day availability entry.availabilityId
: Reference to the associated availability entry.day
: Specific day of the week (e.g., MONDAY, TUESDAY).startTime
: Starting time for the availability on this day.endTime
: Ending time for the availability on this day.
- Relations: Connected to the
Availability
model.
Represents the days of the week:
MONDAY
TUESDAY
WEDNESDAY
THURSDAY
FRIDAY
SATURDAY
SUNDAY
Follow the steps below to set up and run the project:
-
Clone the repository:
git clone
-
Install the dependencies:
cd schedura npm install
-
Create a
.env
file in the root directory and configure the environment variables. -
Run the development server:
npm run dev
-
Open http://localhost:3000 to view the application in your browser.
This project is licensed under the MIT License. See the LICENSE file for more information.
- LinkedIn - aviral07
- Twitter - _aviral07
- Github - aviralsharma07
- Resume - Resume