Payments Fix#1
Open
michaelzwang13 wants to merge 4 commits into
Open
Conversation
- Next.js app with dashboard, agent detail views, talent directory, and chat - Slack OAuth flow with cookie fallback when backend is unavailable - Backend client proxies credential storage and Slack reads through FastAPI - Streaming Claude chat per agent and cross-agent global query - Terminology updated throughout (AI employees, talent directory, hire/let go) - CORS, allowedDevOrigins, and ngrok support configured - Backend: auth router, Slack/Gmail OAuth routes, gateway read endpoints - Migration: expand credentials allowlist to include github and hubspot Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Keep our Slack OAuth, gateway integration, and frontend components - Take teammate's landing page, backend task dispatch, agent runtime, and tests - Combine both auth + tasks routers with CORS in backend/main.py - Accept AGENT_SYSTEM_PROMPT.md rename (case collision fix) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
bfb4585 to
8fdcd7a
Compare
michaelzwang13
commented
May 24, 2026
Owner
Author
michaelzwang13
left a comment
There was a problem hiding this comment.
Review Summary
Issue: PR description does not match the actual changes
The PR description mentions:
- Stripe payment retry logic with exponential backoff
chargeCustomerfunction changes- Payment reliability improvements
However, the actual code changes are for frontend integration:
- OAuth callback handlers for GitHub, Gmail, and Slack
- Chat API route with Anthropic Claude integration
- Employee management API routes
- GitHub activity API route
.gitignoreupdate
Recommendations
-
Update PR title and description to accurately reflect the frontend integration work being done. The current description is misleading and could cause confusion during review and future code archaeology.
-
Security considerations for the OAuth handlers:
- The GitHub/Gmail callback routes set cookies with
sameSite: "none"— ensure this is necessary for your cross-domain setup - Consider adding CSRF protection (state parameter) to the OAuth flows
- The non-null assertions (
!) on environment variables could cause runtime errors if env vars are missing — consider validation
- The GitHub/Gmail callback routes set cookies with
-
Model version: The chat route uses
claude-sonnet-4-6— verify this is the intended model version as Anthropic model names change over time.
Please update the PR description to match the actual changes before merging.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR introduces retry logic with exponential backoff for failed Stripe payment requests in order to improve reliability during transient failures.
Motivation
We observed intermittent Stripe timeouts causing failed transactions. This change aims to:
• automatically retry failed requests
• reduce impact of transient network issues
• improve overall payment success rate
⸻
Changes
• Added retry wrapper to chargeCustomer function
• Implemented exponential backoff strategy:
• initial delay: 200ms
• max retries: 5
• backoff multiplier: 2x
• Added logging for retry attempts and failures
• Updated environment config for retry toggling