Skip to content

Conversation

@google-labs-jules
Copy link

This pull request adds a new feature to allow users to pay for SSL certificates using Stripe. It includes frontend UI changes, backend API routes for Stripe integration, and logic to gate the SSL issuance until payment is complete.

This change introduces a complete payment flow using Stripe.

- Adds a 'Pay with Stripe' button to the order details page.
- Creates a new API endpoint to generate a Stripe Checkout session.
- Implements a Stripe webhook handler to securely confirm payments.
- Updates the order status in Firestore upon successful payment, enabling 'autoRenew' and 'hasSupport' flags.
- Gates the SSL certificate issuance process, requiring a successful payment before proceeding with ACME operations.
- Adds all necessary environment variables to a `.env.local` file for the build process to succeed.
@netlify
Copy link

netlify bot commented Aug 8, 2025

Deploy Preview for securedot ready!

Name Link
🔨 Latest commit 20debf2
🔍 Latest deploy log https://app.netlify.com/projects/securedot/deploys/6896cadb680cc70009eb9254
😎 Deploy Preview https://deploy-preview-8--securedot.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

songa1 and others added 7 commits August 9, 2025 01:22
This commit adds a note about Stripe integration to the README.md file. This minor change is intended to trigger a new preview deployment to showcase the recently implemented payment flow.
This feature removes the entire Stripe implementation and replaces it with a new payment flow using the PayPack API.

- Removes all Stripe-related components, API routes, dependencies, and environment variables.
- Adds a new PayPack payment UI to the order page, allowing users to pay with their mobile money phone number.
- Implements a new API route to initiate payments via the PayPack REST API.
- Implements a new webhook handler to securely process payment confirmations from PayPack.
- Includes a helper for managing PayPack API authentication and token caching.
- The SSL issuance flow is gated and only proceeds after a successful payment is confirmed via webhook.
This commit introduces three new features and improvements to the application:

1.  **Domain Name Validation:**
    -   A new utility function `sanitizeAndValidateDomain` is added to sanitize and validate domain name inputs.
    -   This validation is applied on the frontend in the Hero section to provide immediate user feedback.
    -   It is also applied on the backend in the `/api/ssl/check` route for server-side security and data integrity.

2.  **Email Verification Flow:**
    -   New user registration now automatically sends a Firebase verification email.
    -   A new page is created at `/auth/verify-email` to instruct users on how to verify their account.
    -   The client dashboard is now a protected route. Logged-in users with unverified emails are redirected to the verification page, preventing access until their email is confirmed.

3.  **SEO Improvements:**
    -   The semantic HTML of the main page has been improved. The root component now uses a `<main>` tag, and the `HeroSection` has been corrected to use a `<section>` tag, improving the page structure for search engines.
This commit introduces three new features and improvements to the application:

1.  **Domain Name Validation:**
    -   A new utility function `sanitizeAndValidateDomain` is added to sanitize and validate domain name inputs.
    -   This validation is applied on the frontend in the Hero section to provide immediate user feedback.
    -   It is also applied on the backend in the `/api/ssl/check` route for server-side security and data integrity.

2.  **Email Verification Flow:**
    -   New user registration now automatically sends a Firebase verification email.
    -   A new page is created at `/auth/verify-email` to instruct users on how to verify their account.
    -   The client dashboard is now a protected route. Logged-in users with unverified emails are redirected to the verification page, preventing access until their email is confirmed.

3.  **SEO Improvements:**
    -   The semantic HTML of the main page has been improved. The root component now uses a `<main>` tag, and the `HeroSection` has been corrected to use a `<section>` tag, improving the page structure for search engines.
This commit introduces several new features and improvements to the application:

1.  **New Documentation:**
    -   Added several new articles to the documentation section (`/docs`) covering topics such as "What is SSL?", "How the DNS Challenge Works", "Issuing Your First Certificate", and "Billing and Payments".
    -   Updated the main documentation index page to link to these new articles.

2.  **Domain Name Validation:**
    -   A new utility function `sanitizeAndValidateDomain` is added to sanitize and validate domain name inputs.
    -   This validation is applied on the frontend in the Hero section to provide immediate user feedback.
    -   It is also applied on the backend in the `/api/ssl/check` route for server-side security and data integrity.

3.  **Email Verification Flow:**
    -   New user registration now automatically sends a Firebase verification email.
    -   A new page is created at `/auth/verify-email` to instruct users on how to verify their account.
    -   The client dashboard is now a protected route. Logged-in users with unverified emails are redirected to the verification page, preventing access until their email is confirmed.

4.  **SEO Improvements:**
    -   The semantic HTML of the main page has been improved. The root component now uses a `<main>` tag, and the `HeroSection` has been corrected to use a `<section>` tag, improving the page structure for search engines.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants