Skip to main content
Glama
fallback.ts1.21 kB
/** * Fallback Credential Provider * * Used when no OS keychain is available (e.g., Windows, unsupported Linux). * Always returns unavailable and suggests using .wpnav.env instead. * * @package WP_Navigator_MCP * @since 2.7.0 */ import { BaseKeychainProvider } from './keychain.js'; import type { StoredCredential } from './types.js'; /** * Fallback provider for unsupported platforms * * All operations fail gracefully with helpful error messages. */ export class FallbackProvider extends BaseKeychainProvider { readonly name = 'Fallback (unavailable)'; readonly available = false; /** * Storage is not available */ async store(_credential: StoredCredential): Promise<void> { throw new Error( 'Keychain not available on this platform. ' + 'Store credentials in .wpnav.env file or wpnav.config.json instead.' ); } /** * Retrieval is not available */ async retrieve(_account: string): Promise<string | null> { return null; } /** * Deletion is not available */ async delete(_account: string): Promise<boolean> { return false; } /** * List is not available */ async list(): Promise<string[]> { return []; } }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/littlebearapps/wp-navigator-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server