Transparent Calls
Standard Ethereum calls without encryption
Non-encrypted contract interactions using standard Ethereum transaction types. Use these for public data, contract deployment, and operations that do not require privacy.
Overview
Transparent calls are standard Ethereum operations that do not use Seismic encryption. Calldata and return values are visible on-chain, just like any regular Ethereum transaction. For functions without shielded parameters, simply use .call() or .send() directly (without .seismic()). Note that functions with shielded parameters (e.g., suint256) auto-encrypt by default — see Shielded Calls for details.
When to Use Transparent Calls
Contract deployment
Yes
No (Create txs cannot be seismic)
Reading public state
Yes
No
Writing public state
Yes
Optional
Reading private state
No
Yes
Writing private state
No
Yes
Functions with shielded parameters
No
Yes
Contract Deployment
Contract deployment always uses transparent transactions because Create transactions cannot be seismic. Use the #[sol(rpc, bytecode = "...")] attribute to generate a deploy() method:
use seismic_prelude::client::*;
sol! {
#[sol(rpc, bytecode = "0x6080604052...")]
contract SeismicCounter {
function setNumber(suint256 newNumber) public;
function isOdd() public view returns (bool);
}
}
// Deploy with generated deploy() method
let contract = SeismicCounter::deploy(&provider).await?;
println!("Deployed to: {:?}", contract.address());
// Now interact with shielded calls
// isOdd has no shielded params, so use .seismic() for encryption
let is_odd = contract.isOdd().seismic().call().await?;Transparent Write
A transparent write sends a standard eth_sendTransaction with unencrypted calldata. Use this for functions that do not handle private data.
Transparent Read
A transparent read executes a standard eth_call with unencrypted calldata. Both signed and unsigned providers can perform transparent reads.
Using an Unsigned Provider
Transparent reads do not require a private key, so you can use an unsigned provider:
Complete Example: Deploy and Interact
This example demonstrates the typical workflow: deploy a contract transparently, then use both shielded and transparent calls.
Transparent vs. Shielded
There are two ways a call becomes shielded:
Auto-encryption: Functions with shielded parameters (e.g.,
suint256) automatically return aShieldedCallBuilder. Calling.send()or.call()encrypts automatically.Manual opt-in: For functions without shielded parameters, call
.seismic()to convert aSolCallBuilderinto aShieldedCallBuilder.
When neither auto-encryption nor .seismic() is used:
No
TxSeismicElementsare attachedNo calldata encryption occurs
The transaction is sent as a standard Ethereum type
Any provider type can execute the operation
See Also
Shielded Calls — Encrypted contract interactions
Contract Interaction Overview — Comparison of all interaction patterns
SeismicUnsignedProvider — Read-only provider for transparent operations
SeismicSignedProvider — Full-featured provider
Last updated

