Call Header

For example, FCT Runner can allow a specific address (child account) to run only FCTs that has 0x0001 permission, while limiting execution of FCTs with 0x0001 permissions in terms of protocols, amounts and rate.

flow_control

FCT supports if/then functionality via the flow_control field combined with the "jump on" fields.

flow_control is defined using human readable string, so the user can easily see the flow condition.

EIP712 String
Value
Meaning

"continue on success, revert on fail"

0

If call reverts, revert the whole FCT, otherwise, continue to the next call according to the jump_on_success field

"continue on success, stop on fail"

1

If call reverts, stop FCT execution (previous calls are not reverted), otherwise, continue to the next call according to the jump_on_success field

"continue on success, continue on fail"

2

Whether call reverts or not, continue to the next call according to the jump_on_success and jump_on_fail fields respectively

"revert on success, continue on fail"

3

If call reverts, continue to the next call according to the jump_on_fail field, otherwise, revert the whole FCT

"revert on success, stop on fail"

4

If call reverts, stop FCT execution (previous calls are not reverted), otherwise, revert the whole FCT

"stop on success, continue on fail"

5

If call reverts, continue to the next call according to the jump_on_fail field, otherwise, stop FCT execution (previous calls are not reverted)

"stop on success, revert on fail"

6

If call reverts, revert the whole FCT, otherwise, stop FCT execution (previous calls are not reverted)

"stop on success, stop on fail"

7

Whether call reverts or not, stop FCT execution (previous calls are not reverted)

if/then blocks can be achieved by using one of the "cont" flow controls and setting the "jump_on" values

jump_on_success

Part of the flow control. Specify the amount of calls to jump over when current call succeed. When setting to 0 and the current call succeed, the adjacent call will be executed.

This value is ignored when "stop on success" or "revert on success" is being used

jump_on_fail

Part of the flow control. Specify the amount of calls to jump over when current call fails. When setting to 0 and the current call fails, the adjacent call will be executed.

This value is ignored when "stop on fail" or "revert on fail" is being used

method_interface

The name of the function to be called followed by type-names, in parentheses, without any spaces. This is used in order to calculate the function signature and selector. See more info here

ERC20 transfer method interface looks like this: "transfer(address,uint256)"

Last updated