Skip to content
This repository has been archived by the owner on Nov 19, 2024. It is now read-only.

feat: add support for canister properties #13

Closed
wants to merge 9 commits into from
17 changes: 16 additions & 1 deletion spec/index.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -420,7 +420,7 @@ The certified data of the canister with the given id, see <<system-api-certified
[#state-tree-canister-information]
=== Canister information

Users have the ability to learn about the hash of the canister's module, its current controllers, and metadata in a certified way.
Users have the ability to learn about the hash of the canister's module, its current controllers, metadata and properties in a certified way.

* `/canister/<canister_id>/module_hash` (blob):
+
Expand All @@ -438,6 +438,15 @@ If the canister has a https://webassembly.github.io/spec/core/binary/modules.htm
+
It is recommended for the canister to have a custom section called "icp:public candid:service", which contains the UTF-8 encoding of https://github.com/dfinity/candid/blob/master/spec/Candid.md#core-grammar[the Candid interface] for the canister.

* `/canister/<canister_id>/property/<name>` (blob):
+
Canister administrators may set and update a list of named canister setting properties.

The system may impose a size limit on the properties; it allows at least 4KB of combined size of the keys keys and values. Values can be empty.

These properties are configured and kept independently from installing or uninstalling code.


[#http-interface]
== HTTPS Interface

Expand Down Expand Up @@ -1560,6 +1569,12 @@ Calls to a frozen canister will be rejected (like for a stopping canister). Addi
+
Default value: 2592000 (approximately 30 days).

* `properties` (`vec record { name: text; value: blob; }`)
+
A set of arbitrary named properties with arbitrary values. The names in the list must be free of duplicates. See `_state-tree-canister-information`.
+
Default value: The empty list.


[#ic-update_settings]
=== IC method `update_settings`
Expand Down