Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add sample API and fix fake session's user id #83

Merged
merged 1 commit into from
Feb 12, 2024
Merged

Conversation

JiashuHarryHuang
Copy link
Collaborator

@JiashuHarryHuang JiashuHarryHuang commented Feb 12, 2024

New template for future backend API endpoint

  • Thanks to David, now we can test our API endpoint easily.
  • Before, we have to disable our middleware and then test the API endpoint using either Thunder Client or Postman.
  • Now, we can simply set export const testingAPI = true in utils/api-testing.ts and implement the API endpoints like pages/api/example.ts. Then you can test the endpoints using Thunder Client or Postman.
  • Just make sure you never commit export const testingAPI = true to remote.

Copy link

vercel bot commented Feb 12, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
bookem-user ✅ Ready (Inspect) Visit Preview 💬 Add feedback Feb 12, 2024 9:40pm

@JiashuHarryHuang JiashuHarryHuang merged commit 7702021 into main Feb 12, 2024
6 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