Skip to main content

Waitlist Requests

The Waitlist Request entity manages early access and beta program requests for Wrkbelt. It captures essential information about potential users and their organizations.

Schema Definition

type WaitlistRequest = {
// Base Properties
_id: string; // MongoDB ObjectId
first_name: string; // Required first name
last_name: string; // Required last name
email: string; // Required unique email
company_name: string; // Required company name
company_website: string; // Required company website

// Timestamps
createdAt: Date; // Auto-generated
updatedAt: Date; // Auto-updated
} & BaseEntity;

Field Descriptions

Base Properties

FieldTypeRequiredUniqueDescription
_idObjectIdYesYesUnique identifier for the request
first_namestringYesNoFirst name of the requester
last_namestringYesNoLast name of the requester
emailstringYesYesEmail address of the requester
company_namestringYesNoName of the requester's company
company_websitestringYesNoWebsite of the requester's company

Validation

  1. Email Validation

    • Must be a valid email format
    • Must be unique across all waitlist requests
    • Case-insensitive comparison
  2. Website Validation

    • Must be a valid URL format
    • Should include protocol (http/https)
  3. Name Validation

    • Required first and last names
    • No special characters allowed

Request Lifecycle

  1. Creation

    // Example of creating a waitlist request
    const request = {
    first_name: "John",
    last_name: "Doe",
    email: "john.doe@example.com",
    company_name: "Acme Corp",
    company_website: "https://acme.com"
    };
  2. Processing

    // Example of checking for duplicate requests
    const existingRequest = await WaitlistRequest.findOne({
    email: email.toLowerCase()
    });

Security Considerations

  1. Data Protection

    • Email addresses should be stored securely
    • Personal information handling compliant with GDPR
    • Rate limiting for submission endpoints
  2. Spam Prevention

    • Email verification recommended
    • CAPTCHA or similar protection
    • IP-based rate limiting

Performance Considerations

  1. Indexes

    • Unique index on email field
    • Compound indexes if needed for reporting
  2. Query Optimization

    • Case-insensitive email lookups
    • Efficient duplicate checking