Signing Flows
Document type: Frontend requirements
Doc ID: FE-SIGNING-FLOWS
Status: Final v0.1
Release date: December 21, 2025
Author: Nicolas Turcotte, Founder
Source repo: dcorps-docs-public (docs/frontend/SIGNING_FLOWS.md)
Last updated: 2025-12-24
Scope: Wallet connection and signing flows for core Hub operations. These flows align with docs/engineering/API_SURFACES.md.
1. Authority assumptions
Each transaction requires a signer with the required role binding for the entity:
- Entity registration: creator is the initial authority.
- Role updates:
ROLE_ADMINorROLE_BOARD. - Wallet bindings:
ROLE_TREASURERorROLE_ADMIN. - Accounting events:
ROLE_TREASURERorROLE_FINANCE. - Document anchors:
ROLE_SECRETARYorROLE_ADMIN. - Module attach/detach:
ROLE_ADMIN.
Role type labels map to SPEC-DATA.md catalogs.
2. Wallet connection flow
- Connect wallet (Keplr, Leap, or Cosmostation via cosmos-kit).
- Verify chain ID and bech32 prefix (docs/devops/NETWORK_PARAMS.md).
- Fetch entity roles and validate required role for the action.
- Block the action if role authority is missing.
3. Core transaction flows
3.1 Register entity
- Collect entity type, name, initial roles, and wallet bindings.
- Show fee summary (gas in DCHUB and service fee in USDC if applicable).
- Sign
MsgRegisterEntity. - Confirm entity ID and next steps (roles and wallets).
3.2 Update roles
- Display current role bindings.
- Show diff for role add/remove.
- Sign
MsgBindRoleorMsgUnbindRole.
3.3 Bind wallets
- Select wallet type and address.
- Validate wallet type against catalog.
- Sign
MsgBindWalletorMsgUnbindWallet.
3.4 Record accounting event
- Select entity, wallet, counterparty, amount, and category.
- Require category and minimal tags.
- Sign
MsgRecordEvent.
3.5 Anchor document
- Capture hash and optional URI.
- Show evidence type and link target.
- Sign
MsgAnchorDocument.
3.6 Attach or detach module
- Select module and show risk tier.
- Confirm eligibility and costs.
- Sign
MsgAttachModuleorMsgDetachModule.
4. Transaction summary requirements
Each signing dialog MUST show:
- entity name and entity ID,
- action type and target,
- amounts and denoms,
- category and tags (for accounting events),
- fees and estimated gas,
- evidence hash or module ID when applicable.
5. Error and rejection states
- If role authority is missing, block the action with a clear message.
- If fees cannot be paid, prompt to top up DCHUB or request a fee grant.
- If tags are invalid, show required fields from
SPEC-DATA.md.