# NFT Bridge - Methods

## 📝 WRITE

### OWNER ONLY

* **`setFee`**\
  Sets the Lock transaction fee in Wei. The fee is charged in the blockchain coin only for NFTs on the original blockchain.
* **`transferOwneship`**\
  Changes the contract owner address.
* **`changeFeeReceiver`**\
  Changes the address for fees collected.
* **`changeOracle`**\
  Changes the Oracle address.

### PUBLIC

* **`newERC721`**\
  For the creation of a ShadowNFTContract and its association with the originalNFTContract of the ERC721 standard. In this transaction, a contract of the ERC721 standard will be deployed and the address associated. <br>
* **`newERC1155`**\
  For the creation of a ShadowNFTContract and its linking to the originalNFTContract of the ERC1155 standard. In this transaction, a contract of the ERC1155 standard will be deployed and the address linked. The transaction is called with the following parameters:\
  \
  \- name \
  \- associated title \
  \- metadataURI \
  \- originalBlockchain \
  \- originalContractAddress \
  \- destinationBlockchain \
  \- signedMessage<br>
* **`lock`**\
  To make the NFT untransferable. This method is called for the NFT in the originalContract, the NFT will be stored in the contract. If this method is called for the NFT in the shadowContract, the NFT will be burned. This transaction is called with the following parameters:\
  \
  \- metadataURI\
  \- originalBlockchain \
  \- originalContractAddress \
  \- destinationBlockchain \
  \- signedMessage

{% hint style="info" %}
The amount is always 0 for the ERC721 token standard. \
For ERC1155, the amount must be >=1.
{% endhint %}

* **`claim`**\
  To make the NFT transferable. Can only be called to transfer the locked NFT data by the wallet that performed the Lock transaction on the original blockchain. If called for the originalNFT on the original blockchain, the NFT will be transferred to this address. If called for the shadowNFT, the NFT will be minted and transferred to the owner address. This transaction is called with the following parameters:\
  \
  \- lockId \
  \- originBlockchain \
  \- originalContractAdress \
  \- ownerAddress \
  \- ID amount \
  \- claimOriginal \
  \- signedMessage

{% hint style="info" %}
The amount is always 0 for the ERC721 token standard. \
For ERC1155, the amount must be >=1 claimOriginal(bool) - 0 if an NFT in the shadowNFTContract was locked, 1 if the NFT in the originalNFTContract was locked.
{% endhint %}

## 🔎 READ

* **`getNFTContractAddressByOrigin`**\
  \
  -getNFTContractAddressByOrigin - {originalAddress, originBlockchain}. If a shadowNFTContract exists method returns the address. If it does not exist, the method returns the “execution reverted” error.

{% embed url="<https://aurorascan.dev/address/0x64e2B9796f587864746C6097c187D20ab9C61a24>" %}
AURORA – 14.06.2022
{% endembed %}

{% embed url="<https://polygonscan.com/address/0x3edef477445dfc594dfc21515d41c2d83f2d3e9f>" %}
POLYGON – 12.07.2022
{% endembed %}

{% embed url="<https://bscscan.com/address/0x64e2b9796f587864746c6097c187d20ab9c61a24>" %}
BNBCHAIN – 12.07.2022
{% endembed %}

**✅ Successfully Passed Audit by ABDK Consulting**

{% embed url="<https://github.com/abdk-consulting/audits/blob/main/elephantslab/ABDK_ElephantsLab_OctoGamexNFTBridge_v_2_0.pdf>" %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.octogamex.com/products/smart-contracts/nft-bridge-methods.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
