6 stable releases

2.2.0 May 25, 2023
2.1.0 May 23, 2023
2.0.3 May 17, 2023
2.0.2 May 10, 2023

#260 in Configuration

Download history 57/week @ 2023-05-06 62/week @ 2023-05-13 66/week @ 2023-05-20 22/week @ 2023-05-27

207 downloads per month



Cedar CLI

This package contains the Command Line Interface (CLI) for Cedar.

For more information about the Cedar language/project, please take a look at cedarpolicy.com. See also the cedar-policy package, which is the main public Rust API for Cedar.

This app uses the annotation @id("PID") as a simple way to define policy ids. This usage is not standard and annotations have custom use depending on the app.


CLI is a command line tool. It supports the following subcommands:

  • authorize: Evaluate an authorization request
  • evaluate: Evaluate a Cedar expression
  • validate: Validate a policy set against a schema
  • check-parse: Check that policies successfully parse
  • link: Link a template
  • format: Format a policy set
  • help: Print this message or the help of the given subcommand(s)


You will need to install Rust, via rustup

To build the CLI, run cargo build or cargo build --release


To run the CLI, try cargo run -- --help or ../target/release/cedar --help. The sub-folder sample-data contains examples for the CLI. Please refer to the instructions in README.md or command.txt to run the examples.


~252K SLoC