You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/guides/canister-calls/calling-from-clients.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,8 +1,8 @@
1
1
---
2
-
title: "Offchain Calls"
2
+
title: "Calling from Clients"
3
3
description: "Call canister functions from frontends, scripts, and backend services using IC agent libraries"
4
4
sidebar:
5
-
order: 3
5
+
order: 4
6
6
---
7
7
8
8
An **agent** is a client-side library that constructs ingress messages, signs them with a cryptographic identity, and sends them to ICP boundary nodes. Agents handle the protocol details (CBOR encoding, request IDs, certificate verification) so your application code works with native language types.
When one canister calls another, Candid handles the argument encoding and response decoding transparently. See [Onchain calls](onchain-calls.md) for how to make inter-canister calls in Motoko and Rust.
294
+
When one canister calls another, Candid handles the argument encoding and response decoding transparently. See [Inter-canister calls](inter-canister-calls.md) for how to make inter-canister calls in Motoko and Rust.
295
295
296
296
## Safe interface upgrades
297
297
@@ -420,7 +420,7 @@ async fn invoke_callee() {
420
420
}
421
421
```
422
422
423
-
The `.dynamic_callee("PUBLIC_CANISTER_ID:callee")` mode reads the canister ID from a canister environment variable at runtime. The same `PUBLIC_CANISTER_ID:<name>` variables that `icp deploy` injects (see [canister discovery](onchain-calls.md#canister-discovery)). For canisters with fixed IDs, use `.static_callee(principal)` instead.
423
+
The `.dynamic_callee("PUBLIC_CANISTER_ID:callee")` mode reads the canister ID from a canister environment variable at runtime. The same `PUBLIC_CANISTER_ID:<name>` variables that `icp deploy` injects (see [canister discovery](inter-canister-calls.md#canister-discovery)). For canisters with fixed IDs, use `.static_callee(principal)` instead.
424
424
{/* Needs human verification: the upstream ic-cdk-bindgen README uses ICP_CANISTER_ID: in its example, but icp-cli sets PUBLIC_CANISTER_ID:. We use PUBLIC_CANISTER_ID: here to match icp-cli. An issue has been filed on dfinity/cdk-rs to align the upstream README. */}
425
425
426
426
For type selector configuration and advanced options, see the [`ic-cdk-bindgen` documentation](https://crates.io/crates/ic-cdk-bindgen).
@@ -443,8 +443,8 @@ For type selector configuration and advanced options, see the [`ic-cdk-bindgen`
443
443
444
444
## Next steps
445
445
446
-
- [Onchain calls](onchain-calls.md): make inter-canister calls using Candid interfaces
447
-
- [Offchain calls](offchain-calls.md): call canisters from JavaScript frontends and agents
446
+
- [Inter-canister calls](inter-canister-calls.md): make inter-canister calls using Candid interfaces
447
+
- [Calling from clients](calling-from-clients.md): call canisters from JavaScript frontends and agents
448
448
- [Candid specification](../../reference/candid-spec.md): full type reference and subtyping rules
449
449
450
450
{/* Upstream: informed by dfinity/portal docs/building-apps/interact-with-canisters/candid/ (3 files), docs/building-apps/developer-tools/cdks/rust/generating-candid.mdx, icp-cli concepts/binding-generation.md, ic-cdk-bindgen README, and @icp-sdk/bindgen. Type mappings verified against .sources/candid (spec), .sources/motoko (IDL-Motoko.md), and .sources/cdk-rs. */}
Copy file name to clipboardExpand all lines: docs/guides/canister-calls/inter-canister-calls.mdx
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
1
---
2
-
title: "Onchain Calls"
2
+
title: "Inter-canister Calls"
3
3
description: "Call functions on other canisters from your canister code"
4
4
sidebar:
5
5
order: 2
@@ -27,7 +27,7 @@ There are two types of canister methods, and the choice affects latency, cost, a
27
27
28
28
**Use update calls** when modifying state, transferring cycles, or when the caller needs a consensus-backed guarantee that the call was executed correctly.
29
29
30
-
To make query responses verifiable without the cost of update calls, see [Certified Variables](../backends/certified-variables.md). For running multiple query calls in parallel, see [Parallel Calls and Composite Queries](parallel-calls.md).
30
+
To make query responses verifiable without the cost of update calls, see [Certified Variables](../backends/certified-variables.md). For running multiple query calls in parallel, see [Parallel inter-canister calls](parallel-inter-canister-calls.md).
31
31
32
32
## Making calls
33
33
@@ -398,7 +398,7 @@ Calls between canisters on the same subnet complete within a single round. Cross
398
398
399
399
## Next steps
400
400
401
-
-[Parallel Calls and Composite Queries](parallel-calls.md): make multiple calls concurrently and use composite queries for efficient read patterns
401
+
-[Parallel inter-canister calls](parallel-inter-canister-calls.md): make multiple calls concurrently and use composite queries for efficient read patterns
402
402
-[Candid](candid.md): define the interface your canister exposes for inter-canister calls
403
403
-[Certified Variables](../backends/certified-variables.md): make query responses verifiable without update call overhead
In Rust, there is no built-in `is_controller` function: checking controllers requires an async call to the management canister. See [onchain calls](../canister-calls/onchain-calls.md) for inter-canister call patterns.
247
+
In Rust, there is no built-in `is_controller` function: checking controllers requires an async call to the management canister. See [inter-canister calls](../canister-calls/inter-canister-calls.md) for inter-canister call patterns.
0 commit comments