Skip to content

Feature/campaign sync#577

Merged
aunali8812 merged 2 commits intostagingfrom
feature/campaign-sync
Feb 5, 2026
Merged

Feature/campaign sync#577
aunali8812 merged 2 commits intostagingfrom
feature/campaign-sync

Conversation

@aunali8812
Copy link
Collaborator

@aunali8812 aunali8812 commented Feb 5, 2026

Summary by CodeRabbit

  • Bug Fixes
    • Fixed campaign and donation sync API endpoints to use the correct environment-specific base URLs, ensuring reliable and accurate data synchronization across all different deployment configurations. All existing error handling and response processing logic remains unchanged, providing seamless operation in test and production environments without affecting the overall API behavior.

@aunali8812 aunali8812 requested a review from Ebube111 as a code owner February 5, 2026 14:22
@vercel
Copy link

vercel bot commented Feb 5, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
potlock-next-app Ready Ready Preview, Comment Feb 5, 2026 2:24pm

Request Review

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 5, 2026

Caution

Review failed

The pull request is closed.

Walkthrough

The PR introduces conditional base URL selection for sync API endpoints in the indexer module. When NEXT_PUBLIC_ENV is "test", it uses INDEXER_API_ENDPOINT_URL; otherwise defaults to https://dev.potlock.io. This affects campaign and donation sync endpoints.

Changes

Cohort / File(s) Summary
Sync API Base URL Configuration
src/common/api/indexer/sync.ts
Introduces SYNC_API_BASE_URL constant with conditional endpoint selection based on environment; updates campaign and donation sync endpoints to use the new base URL instead of directly referencing INDEXER_API_ENDPOINT_URL.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

  • Feature/campaign sync #576: Modifies the same sync API implementation file to add/export syncApi methods alongside this PR's endpoint base URL updates.

Suggested reviewers

  • Ebube111
  • carina-akaia

Poem

🐰 A hop and a skip through endpoint land,
Where base URLs now understand,
Test or dev, the choice is clear,
Sync flows smooth from here to there! 🔄

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feature/campaign-sync

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@aunali8812 aunali8812 merged commit a7ae79f into staging Feb 5, 2026
2 of 4 checks passed
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.

1 participant