For workflows requiring air-gapped signing or manual message handling, use the --serialize flag with icx update or icx query. This serializes the signed canister call message as JSON and prints it to stdout.
When using icx update with --serialize:
- The signed message is printed to
stdout. - A corresponding
request_status message is printed to stderr.
Workflow Example
1. Sign (on an air-gapped machine or locally)
icx --fetch-root-key update --serialize rwlgt-iiaaa-aaaaa-aaaaa-cai greet '("everyone")' > output.txt
head -n 1 output.txt > update.json
tail -n 1 output.txt > request_status.json
2. Send the signed message
cat update.json | icx send
3. Check request status
cat request_status.json | icx --fetch-root-key send
# Sign
icx --fetch-root-key update --serialize rwlgt-iiaaa-aaaaa-aaaaa-cai greet '("everyone")' > output.txt
head -n 1 output.txt > update.json
tail -n 1 output.txt > request_status.json
# Send
cat update.json | icx send
# Request status
cat request_status.json | icx --fetch-root-key send