References

Files GPAL Writes to Disk

GPAL.yaml - Created and Loaded Automatically

The first time your workflow runs in a given directory, GPAL.yaml does not exist, so GPAL creates it next to your executable with default settings and publishes a warning event. On every run after that, GPAL loads it automatically and confirms with an info event. GPAL.yaml holds the same settings you can configure in code -- match thresholds, typing delays, driver behavior. Call GPAL.SaveSettings() to persist runtime changes back to disk. Both LoadSettings() and SaveSettings() accept an optional GPALFile: pass one to redirect to a different path, and that path becomes the session default for all subsequent no-arg calls.

GPAL.InformationHandler += (sender, e) => Console.WriteLine(e.Message);


// First run: GPAL.yaml does not exist, creates it with defaults (WARNING).

// Every later run: loads GPAL.yaml automatically (INFO).

GPAL.WithMatchingPercentage(90).WithDownloadTimeoutInSec(30);

GPAL.SaveSettings();


// Load from a shared location

// All subsequent no-arg SaveSettings() calls use this path automatically.

GPAL.LoadSettings("C:/shared/GPAL.yaml");

NOTE

Call GPAL.LoadSettings() with a GPALFile early in your workflow to point GPAL.yaml at a shared or environment-specific location. That path becomes the session default -- subsequent no-arg LoadSettings() and SaveSettings() calls use it automatically for the rest of the run.

Optional Config Files - Load, Save, and Custom Paths

Beyond GPAL.yaml, a small set of optional config files can be written to disk when you want to tune behavior without recompiling. All four classes follow the same pattern: Load() and Save() accept an optional GPALFile. With no argument, each uses its own default path next to your executable. Pass a GPALFile to redirect to a different path -- that path becomes the new in-session default.

// No-arg: each class uses its own default path

CredentialsConfig creds = CredentialsConfig.Load(); // ./credentialsConfig.json

creds.Save();


// Pass a GPALFile to redirect

creds = CredentialsConfig.Load(

"config/creds.json");

creds.GoogleRestRedirectUri = "http://localhost:3000/access-token";

creds.Save(); // config/creds.json

creds.Save(); // still config/creds.json


// Same pattern for DigestRulesConfig and AIProvidersConfig

DigestRulesConfig.Save("config/rules.yaml");

DigestRulesConfig.Save(); // config/rules.yaml


// GPALMail uses ./GPALMail.yaml by default

GPAL.Mail.LoadSettings();

GPAL.Mail.LoadSettings("config/mail.yaml");

GPAL.Mail.SaveSettings(); // config/mail.yaml


// AIProvidersConfig

AIProvidersConfig.Load(); // ./AIProvidersConfig.yaml

AIProvidersConfig.Save("config/ai-providers.yaml");

NOTE

As stated above, passing a GPALFile becomes the new session default for all subsequent no-arg calls. Load() never writes to disk -- only Save() writes the file.

GPALRESTAPI Crash Log

GPALRESTAPI is a standalone host program -- it does not include the GPAL library and has no access to its event system. It keeps a single emergency log at C:\tempGPALRestApiCrash.log, written only when something goes wrong before normal error handling can begin: an exception during startup, or an unhandled exception that would otherwise crash the process with no record. Each entry appends a timestamp, the exception, and its stack trace. Older entries are never removed automatically. When an unhandled exception is caught, GPALRESTAPI also shows a desktop toast notification pointing you at the file.

WARNING

Plain GPAL library code never writes GPALRestApiCrash.log -- only the standalone GPALRESTAPI host process does, as a last resort when something goes wrong before it can handle errors normally. GPALRESTAPI runs independently of the GPAL library and is not connected to GPAL event handlers.

💬 Ask GPAL