Build on Berrier
Distribute notes
Show live series in your product and subscribe users directly.
The pattern
Discover a series, show its terms, subscribe in one call, show the position.
Discover
function openSeriesOf(address stockToken) external view returns (uint256[] memory seriesIds);Quote the terms
function getSeries(uint256 seriesId) external view returns (Series memory);Subscribe
function depositCarry(uint256 seriesId, uint256 usdgAmount) external;Hold
Show coupons paid, the next close and the cushion to the barrier, all read from BarrierCore.
GUARD
function depositGuard(uint256 seriesId, uint256 stockAmount) external; // prefund pulled in USDGIndexing
Use the events to build history; current state is always available from views.