Bootstrap

Transactions

Pay:

Sender: any_address Receiver: pool_address Amount: Pool minimum balance (Formula I) + Transaction fee of the app call + 100000 (min transaction fee for asset creation)

AppCall:

Sender: pool_address (Logic Sig) Index: tinyman_amm_v2_app_id OnComplete: OptIn App Args: [“bootstrap”] Foreign Assets: [asset_1_id, asset_2_id] RekeyTo: tinyman_amm_v2_app_address Fee: (7 * min_fee) (Note: 6 * min_fee if asset 2 is Algo)

Side Effects

Local State Changes

  1. pool_token_asset_id

  2. asset_1_id

  3. asset_2_id

  4. total_fee_share

  5. protocol_fee_ratio

  6. asset_1_reserves

  7. asset_2_reserves

  8. issued_pool_tokens

  9. asset_1_protocol_fees

  10. asset_2_protocol_fees

  11. lock

  12. asset_1_cumulative_price

  13. asset_2_cumulative_price

  14. cumulative_price_update_timestamp

Inner Transactions

1. Pay:

Sender: pool_address Receiver: tinyman_amm_v2_app_address Amount: 100_000 Fee: 0

2. AssetConfig:

Sender: tinyman_amm_v2_app_address UnitName: “TMPOOL2” Name: “TinymanPool2.0 {asset_1_unit_name}-{asset_2_unit_name}” MetadataHash: “{asset_1_id}{asset_2_id}{trailing zeros}” uint64 (8 bytes) + uint64 (8 bytes) + zeros (16 bytes) Total: 18446744073709551615 Reserve: pool_address Decimals: 6 URL: “https://tinyman.org” Fee: 0

3. AssetTransfer (Opt-In):

Sender: pool_address Receiver: pool_address Index: asset_1_id Amount: 0

4. AssetTransfer (Opt-In) (If Asset 2 is not Algo):

Sender: pool_address Receiver: pool_address Index: asset_2_id Amount: 0

5. AssetTransfer (Opt-In):

Sender: pool_address Receiver: pool_address Index: created_asset_id Amount: 0

6. AssetTransfer:

Sender: tinyman_amm_v2_app_address Receiver: pool_address Index: created_asset_id Amount: 18446744073709551615

Last updated