> */ public static function get_models(): array { return [ [ 'id' => 'google/gemini-2.5-flash-image', 'name' => 'Gemini 2.5 Flash Image (Nano Banana)', 'provider' => 'openrouter', 'cost_per_image' => 0.005, 'capabilities' => [ 'image_generation' ], 'description' => __( 'Good quality, low cost. Recommended.', 'prautoblogger' ), ], [ 'id' => 'google/gemini-3.1-flash-image-preview', 'name' => 'Gemini 3.1 Flash Image (Nano Banana 2)', 'provider' => 'openrouter', 'cost_per_image' => 0.008, 'capabilities' => [ 'image_generation' ], 'description' => __( 'Latest Google. Better quality.', 'prautoblogger' ), ], [ 'id' => 'google/gemini-3-pro-image-preview', 'name' => 'Gemini 3 Pro Image (Nano Banana Pro)', 'provider' => 'openrouter', 'cost_per_image' => 0.03, 'capabilities' => [ 'image_generation' ], 'description' => __( 'Highest quality Google. Premium.', 'prautoblogger' ), ], [ 'id' => 'openai/gpt-5-image-mini', 'name' => 'GPT-5 Image Mini', 'provider' => 'openrouter', 'cost_per_image' => 0.02, 'capabilities' => [ 'image_generation' ], 'description' => __( 'OpenAI budget image model.', 'prautoblogger' ), ], [ 'id' => 'openai/gpt-5-image', 'name' => 'GPT-5 Image', 'provider' => 'openrouter', 'cost_per_image' => 0.08, 'capabilities' => [ 'image_generation' ], 'description' => __( 'OpenAI premium. Photorealistic.', 'prautoblogger' ), ], [ 'id' => 'flux-1-schnell', 'name' => 'FLUX.1 schnell (Cloudflare)', 'provider' => 'cloudflare', 'cost_per_image' => 0.0007, 'capabilities' => [ 'image_generation' ], 'description' => __( 'Cheapest. Low quality, 4-step.', 'prautoblogger' ), ], ]; } /** * Return the provider id for a known model, or empty string if the * model id is not in the registry. * * @param string $model_id Model slug from the admin UI. * @return string Provider id ('openrouter' | 'cloudflare' | ''). */ public static function provider_for( string $model_id ): string { foreach ( self::get_models() as $model ) { if ( ( $model['id'] ?? '' ) === $model_id ) { return (string) ( $model['provider'] ?? '' ); } } return ''; } }