docs: add canister discovery, binding generation, and frontend development docs#338
Merged
docs: add canister discovery, binding generation, and frontend development docs#338
Conversation
marc0olo
commented
Feb 4, 2026
| execSync(`icp network status -e ${environment} --json`, { encoding: "utf-8" }) | ||
| ); | ||
| const rootKey: string = networkStatus.root_key; | ||
| const proxyTarget: string = networkStatus.api_url; |
Member
Author
There was a problem hiding this comment.
note:
- the dev server wouldn't work correctly until we update the
network statuscommand to deliver theapi_url
raymondk
reviewed
Feb 4, 2026
|
|
||
| ### Other Languages | ||
|
|
||
| The `didc` CLI generates bindings for various languages. See the [Candid repository](https://github.com/dfinity/candid) for available targets. |
Contributor
There was a problem hiding this comment.
We should have a note somewhere that not all generated bindings will work well with icp-cli.
- The target canister id needs to be fixed, or
- the target canister id has to be fetched from the environment variables.
raymondk
reviewed
Feb 4, 2026
raymondk
reviewed
Feb 4, 2026
auto-merge was automatically disabled
February 11, 2026 15:33
Pull request was converted to draft
marc0olo
commented
Feb 11, 2026
| execSync(`icp network status -e ${environment} --json`, { encoding: "utf-8" }) | ||
| ); | ||
| const rootKey: string = networkStatus.root_key; | ||
| // TODO: Use networkStatus.api_url when CLI supports it |
Member
Author
There was a problem hiding this comment.
@raymondk I added this todo now which we should apply once icp network status supports what we want.
adamspofford-dfinity
approved these changes
Feb 11, 2026
raymondk
approved these changes
Feb 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Comprehensive documentation for canister discovery, binding generation, and frontend development workflows.
New Documentation
docs/concepts/canister-discovery.mdicp deployautomatically injectsPUBLIC_CANISTER_ID:*variables into all canisters; reading IDs in Rust/Motoko;ic_envcookie mechanism for frontend canister discoverydocs/concepts/binding-generation.md@icp-sdk/bindgen,candidcrate)Updated Documentation
docs/guides/local-development.mdicp network status --json), and two development approachesdocs/reference/environment-variables.mdPUBLIC_CANISTER_ID:*andIC_ROOT_KEYdocs/concepts/build-deploy-sync.mddocs/tutorial.mddocs/index.md,docs/concepts/index.mddocs-site/astro.config.mjsUpdated Example
examples/.../vite.config.tsicp network status --jsonfor all environments; properic_root_keycookie formatexamples/.../App.tsxIC_ROOT_KEYtype toUint8Array; cleaner implementationexamples/.../README.mdic_envcookie mechanism and dev server setupInfrastructure Updates
.claude/CLAUDE.mdscripts/prepare-docs.sh.mdlinks to Starlight URLsKey Technical Details
ic_root_key(lowercase); library returnsIC_ROOT_KEYasUint8Arrayic_cdk::api::env_var_value()+Principal::from_text()Prim.envVar<system>()(available since Motoko 0.16.2) +Principal.fromText()