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

feat: Add API Key Authentication support #628

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

AffanShaikhsurab
Copy link
Contributor

PR Description

Added API Key Authentication support to allow users to authenticate their API requests using API keys. This implementation includes:

  • New Authorization UI component for configuring API keys
  • Support for both header and query parameter authentication methods
  • Reusable AuthTextField widget for form inputs
  • State management for authentication parameters
  • Integration with existing request system

Related Issues

Checklist

  • I have gone through the contributing guide
  • I have updated my branch and synced it with project main branch before making this PR
  • I am using the latest Flutter stable branch (run flutter upgrade and verify)
  • I have run the tests (flutter test) and all tests are passing

Added/updated tests?

  • Yes
  • [] No

OS on which you have developed and tested the feature?

  • Windows
  • macOS
  • Linux

AffanShaikhsurab and others added 5 commits March 2, 2025 18:32
Add comprehensive API Key Authentication functionality to the request system:

- Implement new Authorization UI component for API Key configuration
- Add support for both header and query parameter authentication methods
- Create AuthTextField widget for reusable form inputs
- Update HttpRequestModel to support auth parameters
- Add necessary constants and providers for auth state management

Technical changes:
- Create new request_authorization.dart for auth UI components
- Modify collection providers to handle auth state updates
- Update core models to support auth parameters
- Add auth-related constants in consts.dart
- Integrate auth UI in request_pane_rest.dart

Breaking changes: None
- Add test cases for Authentication tab visibility and content
- Update request pane tests to include Authentication tab checks
- Ensure Authentication tab navigation works correctly
- Update test expectations for tab indices with Authentication tab
- Fix test assertions for tab content visibility
- Align test cases with updated request pane structure

Changes made to:
- test/widgets/request_pane_test.dart
- lib/widgets/request_pane.dart
@AffanShaikhsurab
Copy link
Contributor Author

I have a quick question: Would you like to include a note section in the app ? If so, I can implement a dedicated note widget to ensure consistency throughout the application. And any ui / code changes we should make here please let me know !
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants