get method
Makes a GET request to the specified endpoint
endpoint - The API endpoint (will be appended to the base URL)
queryParams - Optional query parameters to append to the URL
headers - Optional headers to include in the request
useFullUrl - If true, endpoint is treated as a complete URL
Returns a Future<PlexApiResult> containing the response
Implementation
Future<PlexApiResult> get(
String endpoint, {
Map<String, dynamic>? queryParams,
Map<String, String>? headers,
bool useFullUrl = false,
}) async {
final url = useFullUrl ? endpoint : endpoint;
final response = await PlexNetworking.instance.get(
url,
query: queryParams,
headers: headers,
);
return _handleResponse(response);
}