ApiKeyService class

API Key Service for managing authentication keys Handles admin key, developer keys, and authentication headers

Constructors

ApiKeyService()
factory

Properties

currentApiKey String?
Get current API key
no setter
environment String?
Get current environment
no setter
hashCode int
The hash code for this object.
no setterinherited
isInitialized bool
Check if the service is initialized
no setter
isUsingAdminKey bool
Check if current key is admin key
no setter
isUsingDeveloperKey bool
Check if current key is developer key
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

authenticatedGet(String endpoint) Future<Map<String, dynamic>>
Make authenticated HTTP GET request
authenticatedPost(String endpoint, {Map<String, dynamic>? body, String? jsonBody}) Future<Map<String, dynamic>>
Make authenticated HTTP POST request
clearApiKey() Future<void>
Clear stored API key
getAuthHeaders() Map<String, String>
Get authentication headers for API requests
initialize({String? apiKey, String? environment, bool autoInitWithAdmin = true}) Future<void>
Initialize the API key service
loadFromStorage() Future<void>
Load configuration from storage
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Constants

ADMIN_API_KEY → const String