Configuration keys and precedence
Generated Caller packages use this priority order; lower numeric priority wins. .NET and Node.js are fully covered; other runtimes follow the same conceptual levels—confirm field names and helpers in the installed package:
| Priority | Source | Generated source name |
|---|---|---|
| 1 | Runtime/graft-specific environment | <graft-name>-config |
| 2 | Global environment | graftcode-config |
| 3 | Runtime/graft-specific file | <graft-name>-config.json, .yaml, .txt |
| 4 | Global file | graftcode-config.json, .yaml, .txt |
| 5 | Programmatic user config | SetConfig(...) / setConfig(...) |
| 6 | Generated library default | registered by GraftConfig |
At equal name and priority, the first added configuration is kept. Relative files resolve from the application's current working directory.
Keys
Generated defaults include:
name;runtime;modules;host(inmemoryby default);stateless(falseby default).
JSON and YAML require a top-level configurations object. Text accepts semicolon-delimited
connection-string data and requires at least name and runtime.
Set generated static fields before the first call. The runtime context is cached and no supported reset/re-resolve operation is exposed by generated packages.
Programmatic remote host example (copy imports and names from Vision):
GraftConfig.Host = "ws://localhost/ws";GraftConfig.Stateless = true;