[+/-] Approval widget

Set wrap approval

Quick select:

Current wrap Selection

Wrapping ? AMPL
Expected balance end-result
AMPL -⇓
?
WAMPL +⇑
?
Last AMPL warning
Last AMPL error
+/-

Current unwrap Selection

Unwrapping ? AMPL
Expected balance end-result
AMPL +⇑
?
WAMPL -⇓
?
Last WAMPL warning
Last WAMPL error
+/-
Wallet Address
AMPL Balance
WAMPL Balance
Underlying AMPL
AMPL Allowance
Selected to UNwrap
Selected to wrap
Last approval tx
Last wrap tx
Last unwrap tx

How to WrΛpp

  1. Connect Metamask/Brave wallet
  2. Set/Check AMPL Allowance
  3. Set Amount AMPL to Wrap/Unwrap
  4. Confirm transaction
  5. That's a WrΛpp - your're done.

GAS WARNING: Make sure you TRIPLE CHECK GAS SETTINGS (PRICE AND LIMITS)

Introduction

WrΛpp: The Ampltools AMPL Wrapper web app.

This WrΛpp, still needs polish, is mainly tested on metamask and brave, but is ready to be used at your own risk.

This WrΛpp is just an interface for connecting with the AMPL/WAMPL contract through your wallet (Metamask) to Wrap and Unwrap AMPL.

The official on-chain contract calculates and executes how much AMPL/WAMPL you will receive when wrapping/unwrapping.

Tested with

Brave browser Brave built-in wallet
Metamask extensioin Brave Metamask Extension
Metamask smartphone app Loosely tested

GAS WARNING: Make sure you TRIPLE CHECK GAS SETTINGS (PRICE AND LIMITS)

Legenda/Definitions

Below the definitions we use in this interface for the process of going from AMPL to WAMPL and back

This site is designed around the idea that WAMPL is like a Wrapping paper for AMPL.
And so you can Wrap AMPL and Unwrap AMPL.

From an account balance perspective, when you;
  • Wrap AMPL: AMPL is removed from your account and replace by set amount of WAMPL.
  • Unwrap AMPL: WAMPL is removed from your account and replaced by set amount of AMPL.

Actions

Wrapping AMPL

To send AMPL to the WAMPL-contract and receive WAMPL.

Wallet End-result: AMPL[-] WAMPL [+]
Unwrapping AMPL

To send WAMPL to the WAMPL-contract and receive AMPL.

Wallet End-result: AMPL[+] WAMPL [-]
You could also call this:
* Burning/Melting WAMPL for AMPL
* Returning WAMPL for AMPL
* Some also call it unwrapping AMPL
 

Definitions

WAMPL-Contract The official contract used to convert AMPL ↔ WAMPL
Underlying AMPL This is the amount of AMPL underlying your current WAMPL balance.
AMPL Allowance The allowance needed to be able to Wrap AMPL and receive WAMPL.

Wrapping Amples

In short
* Set Allowance: Allow WAMPL contract to use x amount of AMPL
* Deposit AMPL into WAMPL contract

After successful wallet connection, make sure:

* You are in Wrap mode - blue
* AMPL Allowance in [Account status section] is at least the amount of AMPL you want to wrap. (Or else first set AMPL allowance)
* You have selected the amount of AMPL you want to wrap
U can then;
* Use button "Wrap AMPL"
* You wallet should open now, double check settings! and confirm.

Expected End result
When transaction on etherscan confirms successfuly you should;
* Now have an y amount more WAMPL in your wallet.
* Have x amount less AMPL in your wallet.

unWrapping Amples

In short
* Decide how many Amples you want back.
* Send unwrap transaction.
* Receive AMPL in wallet.

After successful wallet connection, make sure:

* You are in unWrap mode - orange
* You have selected and Set the amount of AMPL you want to unWrap
U can then;
* Use button "Unwrap AMPL"
* You wallet should open now, double check settings! and confirm.

Expected End result
When transaction on etherscan confirms successfuly you should;
* Now have an x amount more AMPL in your wallet.
* Have y amount less WAMPL in your wallet.

Setting Wrap allowance

For the WAMPL contract to be able to wrap your AMPL you should first allow ("delegate") an amount of AMPL which the WAMPL contract can use.

In short
* Set allowance to amount/unlimited.
* Done

Should you do a limited or unlimited allowance? Opinions differ. You decide. Or discuss. We made it easy for you to do an unlimited approval, this does not mean we necessarily agree the unlimited allowances is the way to go.

After successful wallet connection, make sure:
* You are in Wrap mode - blue
* You have selected and Set the amount of AMPL you want to allow to be wrapped.
U can then;
* Use button "Approve selected AMPL"
* Your wallet should open now, double check settings! and confirm.

Expected End result
When transaction confirms successfuly;
* The Allowance amount should now (after refresh) be vissible in the [Account status] section.

Setting unWrap allowance

It is not needed to set an UNWRAP allowance.

Checking this interface

When you are using the wrap/unwrap button's, this wrapper webapp sends a "ticket" to your wallet which you need to confirm for execution on-chain.

This ticket contains the information needed for your wallet to send the wrap/unwrap transaction.

Below we added some scenarios you could use to test the behavior of this website.

Action Expected transaction data

Allow WAMPL contract to wrap 10 AMPL

Example image: image (opens in new tab)
Amount: 10 AMPL
Interacting with: (AMPL Contract) 0xD46bA6D942050d489DBd938a2C909A5d5039A161
To/spender: [WAMPL Contract] 0xEDB171C18cE90B633DB442f2A6F72874093b49Ef
Data(function): Approve = 0x095ea7b3
Data: 0x095ea7b3000000000000000000000000edb171c18ce90b633db442f2a6f72874093b49ef00000000000000000000000000000000000000000000000000000002540be400
Data legenda: 0x[MethodID]000...000[WAMPL (spender) address]000...000[ampl amount hex]
Wrap 10 AMPL

Pre-requisite: Allowance set

Example image: image (opens in new tab)
Interacting with: (WAMPL Contract) 0xEDB171C18cE90B633DB442f2A6F72874093b49Ef
Gas Limit: ~ 150000
Data(function): Deposit = 0xb6b55f25
Data: 0xb6b55f2500000000000000000000000000000000000000000000000000000002540be400
Data legenda: 0x[MethodID]00000000000000000000000000000...000[ampl amount hex]
Unwrap AMPL

Pre-requisite: 10 AMPL wrapped in WAMPL.

Example image: image (opens in new tab)
Interacting with: (WAMPL Contract) 0xEDB171C18cE90B633DB442f2A6F72874093b49Ef
Gas Limit: USER INPUT0
Data(function): Approve = 0x2e1a7d4d
Data: 0x2e1a7d4d00000000000000000000000000000000000000000000000000000002540be400
Data legenda: 0x[MethodID]00000000000000000000000000000...000[ampl amount hex]

Issues

Missing features

* Transaction confirmations: Link to etherscan.