What’s Next for Private Smart Contracts on Midnight?
The premiere of After Midnight explored what developers can build with Ledger 9. On November 18, Midnight’s architecture working group will discuss how to extend calls between smart contracts to handle private data.
By SongMarketCap
Updated:
Midnight Foundation launched After Midnight on November 12 with a look at what developers can build after the Ledger 9 upgrade. The release lets one smart contract call another within a single transaction using unshielded data. During the premiere, the foundation announced a session on Discord to discuss how those calls could handle private data in a future release.
What developers can build with Ledger 9
Jay Albert, a solutions engineer at Midnight Foundation, used a collateralized loan to explain how contracts can work together. A lending contract can request an asset price from a separate contract, check whether the borrower has enough collateral, and approve the loan within the same transaction. Albert also described testing a workflow in which a vote triggers a treasury payout to the teams awarded funding.
Contracts can also emit events that external applications can watch. A software agent could detect that a vote passed and notify a community on Discord or Telegram. The contract call executes a step in the transaction, while the event gives an external application something to respond to. Both features initially support unshielded data.
Ledger 9 also expands signature verification. Albert described how a project could distribute tokens on Midnight to eligible Ethereum asset holders. In his example, a user signs with their Ethereum wallet and proves they hold a qualifying asset to claim the distribution on Midnight. The application could verify eligibility from another ecosystem while the signing key stays in the user’s wallet.
What existing Midnight applications need to update
Midnight moved its mainnet to Ledger 9 on November 6. Contracts already deployed on mainnet carried over automatically, while applications that interact with them need to move to Midnight.js 5. The upgrade documentation lists Compact toolchain 0.36.0 for compiling contracts that target Ledger 9 and Wallet SDK 2.0.0 for wallet developers.
Albert also pointed to a practical requirement for teams that want other applications to call their contracts. They need to make the contract interface and the necessary build files available so other developers can incorporate the call into their own contracts.
The two test networks followed different upgrade paths. Preview relaunched as a new chain on November 7, and Preprod upgraded in place on November 9, retaining its transaction history and deployed contracts. Karmel, the foundation’s director of product, pointed developers to Preview to try the new features with test tokens.
How Midnight Passport would limit an agent’s authority
Karmel linked the Ledger 9 features to the upcoming Midnight Passport SDK, which is intended to help users manage digital credentials and delegate tasks to software agents. During the Q&A, she explained a mechanism called scoped grants. A user defines which actions an agent is allowed to take and can revoke that permission. For an agent authorized to trade, the grant would let the user set limits on what the agent can do.
Karmel also discussed the Open Wallet Standard in the context of managing permissions for actions on and off the network. She announced a separate Passport presentation and plans to involve ecosystem members in testing selected features. She highlighted December as an important month for Passport and gave no specific release date for the SDK.
[NEWSBREAK]
Where developers can weigh in on private contract calls
Hosted by Robert Osborne, After Midnight is scheduled for every other Thursday on YouTube, X, and LinkedIn. In her Discord announcement, Eva Rodriguez M outlined ways for viewers to get involved between episodes, including technical working groups for developers, Nightforce for community members, and Build Club for founders and early-stage teams.
Albert described how applications could call one another without exposing some of the user information involved. Midnight Foundation has yet to announce when support for private data in contract calls will go live. On November 18, the network’s architecture working group will discuss the design on Discord, where developers can ask the architects how the calls would work and give feedback.