Request form
Cookbook may introduce a token in the future. Share and contribute to be eligible for future airdrops.
close icon
relevant tag icon
Superfluid Host
copy icon
Superfluid
• version 1.0.0
Agreement
Promise
Contract
Finance
Deployable

Superfluid Host

The Superfluid Host Contract is the centerpiece of the Superfluid Protocol which connects Super Tokens, Super Agreements, and Super Apps. It works like a conduit for information throughout the Superfluid Protocol.

*Visit desktop site to download or deploy

Version

1.0.0

Creator

Superfluid

Last Publish

11/26/2022
Any contract you deploy is yours.
Fully owned and controlled by your wallet.
Documentation
Source Code
APP_WHITE_LISTING_ENABLED() :
Whether or not white listing is enabled.
CALLBACK_GAS_LIMIT() :
Callback gas limit.
NON_UPGRADABLE_DEPLOYMENT() :
Whether or not the contract is upgradable after deployment.
addToAgreementClassesBitmap(uint256,bytes32) :
Create a new bitmask by adding a agreement class to it
allowCompositeApp(address) :
Whitelist the target app for app composition for the source app (msg.sender)
appCallbackPop(bytes,int256) :
Pop from the current app callback stack
appCallbackPush(bytes,address,uint256,int256,address) :
(For agreements) Create a new callback stack
batchCall(tuple[]) :
Batch call function
callAgreement(address,bytes,bytes) :
Call agreement function
callAgreementWithContext(address,bytes,bytes,bytes) :
Call agreement function. Send additional bytes as context.
callAppAction(address,bytes) :
Calls an app's action
callAppActionWithContext(address,bytes,bytes) :
Calls an app's action. Send additional bytes as context.
callAppAfterCallback(address,bytes,bool,bytes) :
Calls an app after the callback is reached.
callAppBeforeCallback(address,bytes,bool,bytes) :
Calls an app before the callback is reached.
castrate() :
allows to mark logic contracts as initialized in order to reduce the attack surface
ctxUseCredit(bytes,int256) :
(For agreements) Use app credit.
decodeCtx(bytes) :
ABI decodes a context.
forwardBatchCall(tuple[]) :
Batch call function for trusted forwarders (EIP-2771)
getAgreementClass(bytes32) :
agreementType is the keccak256 hash of: "org.superfluid-finance.agreements.<AGREEMENT_NAME>.<VERSION>
getAppCallbackLevel(address) :
Query app callbacklevel
getAppManifest(address) :
Query app manifest
getCodeAddress() :
Query code address
getGovernance() :
Get the current governance address of the Superfluid host
getNow() :
Returns current timestamp
getSuperTokenFactory() :
Get the super token factory address attached to the Superfluid host.
getSuperTokenFactoryLogic() :
Get the super token factory logic (applicable to upgradable deployment)
initialize(address) :
Initializes the contract.
isAgreementClassListed(address) :
Check if the agreement class is whitelisted
isAgreementTypeListed(bytes32) :
Check if the agreement type is whitelisted
isApp(address) :
Check is is app.
isAppJailed(address) :
Check if a specific app is jailed.
isCompositeAppAllowed(address,address) :
Query if source app is allowed to call the target app as downstream app
isCtxValid(bytes) :
Check if the context is valid.
isTrustedForwarder(address) :
Check if the forwarder is trusted
jailApp(bytes,address,uint256) :
Jails an app.
mapAgreementClasses(uint256) :
Map list of the agreement classes using a bitmap
proxiableUUID() :
Proxiable UUID marker function, this would help to avoid wrong logic contract to be used for upgrading.
registerAgreementClass(address) :
Register a new agreement class to the system
registerApp(uint256) :
Message sender (must be a contract) declares itself as a super app.
registerAppByFactory(address,uint256) :
Message sender (must be a contract) declares app as a super app
registerAppWithKey(uint256,string) :
Message sender declares itself as a super app.
removeFromAgreementClassesBitmap(uint256,bytes32) :
Create a new bitmask by removing a agreement class from it
replaceGovernance(address) :
Replace the current governance with a new one
updateAgreementClass(address) :
Update code of an agreement class
updateCode(address) :
Updates the code.
updateSuperTokenFactory(address) :
Updates the super token factory address
updateSuperTokenLogic(address) :
Update the super token logic to the latest
versionRecipient() :
EIP 2771 version

Get Cookin'
share iconShare

copy iconNo-Code Deploy
copy iconDownload Source
copy iconnpx cookbookdev i Superfluid-Host
copy icon

Bytecode

Download

Last Publish

11/26/2022

Version

1.0.0

Creator

Superfluid

Cookbook is free.
Any contract you deploy is yours.
Your contract is owned and controlled by you.