]> git.joonet.de Git - adminer.git/commitdiff
AdminerSqlGemini: Add default key
authorJakub Vrana <jakub@vrana.cz>
Thu, 3 Apr 2025 06:28:02 +0000 (08:28 +0200)
committerJakub Vrana <jakub@vrana.cz>
Thu, 3 Apr 2025 06:28:02 +0000 (08:28 +0200)
plugins/sql-gemini.php

index 222be4555e0b3550eccdc6e312a9ba78aa150db6..1dd53cb08c05b6a3836d5b1366a1e4603270c5b9 100644 (file)
@@ -14,10 +14,10 @@ class AdminerSqlGemini {
        private $model;
 
        /**
-       * @param string $apiKey Get API key at: https://aistudio.google.com/apikey
+       * @param string $apiKey The default key is shared with all users and may run out of quota; get your own API key at: https://aistudio.google.com/apikey
        * @param string $model Available models: https://ai.google.dev/gemini-api/docs/models#available-models
        */
-       function __construct(string $apiKey, string $model = "gemini-2.0-flash") {
+       function __construct(string $apiKey = 'AIzaSyDWDbPjmvH9_hphsnY_yJGdue42qRMG3do', string $model = "gemini-2.0-flash") {
                $this->apiKey = $apiKey;
                $this->model = $model;
        }