| Crates.io | canic-dsl |
| lib.rs | canic-dsl |
| version | 0.9.10 |
| created_at | 2026-01-12 17:08:14.73584+00 |
| updated_at | 2026-01-23 13:33:03.162615+00 |
| description | Canic — a canister orchestration and management toolkit for the Internet Computer |
| homepage | https://github.com/dragginzgame/canic |
| repository | https://github.com/dragginzgame/canic |
| max_upload_size | |
| id | 2038217 |
| size | 5,267 |
Symbolic tokens for Canic endpoint macros.
This crate defines zero-cost marker constants used inside #[canic_query] and
#[canic_update] attributes. The symbols are never evaluated; the proc-macro
crate pattern-matches on identifiers and expands them into runtime access calls.
Use requires(...) expressions with all(...), any(...), and not(...) to
compose predicates.
use canic_dsl::access::{app, caller};
use canic_dsl_macros::canic_update;
#[canic_update(requires(app::allows_updates(), caller::is_controller()))]
async fn admin_only_expr() -> Result<(), canic::Error> {
Ok(())
}