# How to Borrow/Repay

{% hint style="warning" %}
Before borrowing crypto assets, you will need to add supply to the Lending Market to use it as collateral
{% endhint %}

{% embed url="<https://youtu.be/WcXTTvFXi1I>" %}

## Borrow Guide <a href="#borrow-guide" id="borrow-guide"></a>

**1. Visit** [**https://nusa.finance**](https://nusa.finance/) **and click “GO TO APPS” . You will be asked to connect your wallet, make sure you are logged in to your wallet extension**

<img src="https://docs.nusa.finance/~gitbook/image?url=https%3A%2F%2F1342101389-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252F0IPisxvMGNHq66LAZqem%252Fuploads%252FLQ0vPEm5Gb7rrzDEpJFV%252FScreen%2520Shot%25202023-01-27%2520at%252013.41.49.png%3Falt%3Dmedia%26token%3D3d6f40cb-b4ad-4c99-a98d-4b686ce64989&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=7e567a32&#x26;sv=2" alt="" width="188">

**2.Before you start borrowing, you should click "Enable" from the Supply Market on the token you want to borrow and the collateral you want to include**

<img src="https://docs.nusa.finance/~gitbook/image?url=https%3A%2F%2F1342101389-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252F0IPisxvMGNHq66LAZqem%252Fuploads%252FQdr4OmyCvflJDViRkDqL%252FScreen%2520Shot%25202023-01-27%2520at%252014.13.58.png%3Falt%3Dmedia%26token%3D97e4eecb-6f1c-4ab8-9c63-75c49ebdb8f2&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=b45be18a&#x26;sv=2" alt="" width="375">

**3.Give permission to every market that you "Enable"**

<img src="https://docs.nusa.finance/~gitbook/image?url=https%3A%2F%2F1342101389-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252F0IPisxvMGNHq66LAZqem%252Fuploads%252F0CXrxwJ5pLAiwC6aFdeo%252FScreen%2520Shot%25202023-01-27%2520at%252014.14.49.png%3Falt%3Dmedia%26token%3D50212b32-6c64-4ac4-b750-0ab9845ebe87&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=3e5806e0&#x26;sv=2" alt="" width="188">

**4.Click on the token market you want to borrow. You are going to be asked for 2 permissions from the smart contract to access your wallet. Click "Confirm" for both permissions**

<img src="https://docs.nusa.finance/~gitbook/image?url=https%3A%2F%2F1342101389-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252F0IPisxvMGNHq66LAZqem%252Fuploads%252FAUOczxt3bZAVBRRmm0ws%252FScreen%2520Shot%25202023-01-27%2520at%252014.16.05.png%3Falt%3Dmedia%26token%3Db919d21a-e882-40c0-b497-868eae0a3344&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=f172cf23&#x26;sv=2" alt="" width="188">

<img src="https://docs.nusa.finance/~gitbook/image?url=https%3A%2F%2F1342101389-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252F0IPisxvMGNHq66LAZqem%252Fuploads%252FTrCbp8VlcvM1sCfVLTWr%252FScreen%2520Shot%25202023-01-27%2520at%252014.16.19.png%3Falt%3Dmedia%26token%3D60680676-4bee-4ab5-9890-6c0aef7aecd7&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=2ec5f079&#x26;sv=2" alt="" width="188">

<img src="https://docs.nusa.finance/~gitbook/image?url=https%3A%2F%2F1342101389-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252F0IPisxvMGNHq66LAZqem%252Fuploads%252Fy7VhffSAQ7vmpuBwmgdT%252FScreen%2520Shot%25202023-01-27%2520at%252014.16.34.png%3Falt%3Dmedia%26token%3D8dd7941e-b3cc-4d69-934c-69d3bc0466ea&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=efecf9e1&#x26;sv=2" alt="" width="188">

**5.Click on the token market for the second time and input the number of token you want to borrow. You can click "MAX" to borrow to the maximum amount. Please consider your borrowing limit before proceeding. Click "Borrow"**

<img src="https://docs.nusa.finance/~gitbook/image?url=https%3A%2F%2F1342101389-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252F0IPisxvMGNHq66LAZqem%252Fuploads%252FlFr2Lc4fmiNTA8bHWCU1%252FScreen%2520Shot%25202023-01-27%2520at%252014.17.07.png%3Falt%3Dmedia%26token%3De1ee6095-53d6-40c0-b14d-30b1f9322c13&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=6799f1b6&#x26;sv=2" alt="" width="375">

**6.Confirm your transaction from your wallet and wait until your borrowing number is automatically updated**

<img src="https://docs.nusa.finance/~gitbook/image?url=https%3A%2F%2F1342101389-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252F0IPisxvMGNHq66LAZqem%252Fuploads%252FZCvp4tOC3xHjWaure5M9%252FScreen%2520Shot%25202023-01-27%2520at%252014.17.32.png%3Falt%3Dmedia%26token%3D34d09765-005f-44bd-8696-6aeba65f4fab&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=f61537d&#x26;sv=2" alt="" width="188">

<img src="https://docs.nusa.finance/~gitbook/image?url=https%3A%2F%2F1342101389-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252F0IPisxvMGNHq66LAZqem%252Fuploads%252FqE72lezynWWp8zzFQTVg%252FScreen%2520Shot%25202023-01-27%2520at%252014.18.44.png%3Falt%3Dmedia%26token%3Da848635e-9cf4-4bc3-bacd-e2ad82b4155a&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=ae8e6102&#x26;sv=2" alt="" width="375">

## Repay Guide <a href="#repay-guide" id="repay-guide"></a>

**1.Click on the market loan you want to repay**

<img src="https://docs.nusa.finance/~gitbook/image?url=https%3A%2F%2F1342101389-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252F0IPisxvMGNHq66LAZqem%252Fuploads%252FWQvvRac7qXXLVikQL1gQ%252FScreen%2520Shot%25202023-02-02%2520at%252014.54.41.png%3Falt%3Dmedia%26token%3D2a9edbc8-3ff4-48e9-9605-ddd67424d4ca&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=baf3b53c&#x26;sv=2" alt="" width="188">

**2.Click the "Repay" tab, you can check your debt, borrow rate, and the PLM reward interest in the status bar**

<img src="https://docs.nusa.finance/~gitbook/image?url=https%3A%2F%2F1342101389-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252F0IPisxvMGNHq66LAZqem%252Fuploads%252FNlUOvcaKj6lYhkGxGrFN%252FScreen%2520Shot%25202023-02-02%2520at%252015.00.55.png%3Falt%3Dmedia%26token%3D5f6bcd00-c8e3-4b5e-92cf-56e569b3e5f2&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=5dc2f54a&#x26;sv=2" alt="" height="288" width="417">

**3.Input the amount of debt you want to repay, you can click the "FULL" button to automatically input all your debt. Click "Repay" to proceed**

<img src="https://docs.nusa.finance/~gitbook/image?url=https%3A%2F%2F1342101389-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252F0IPisxvMGNHq66LAZqem%252Fuploads%252FlGEfXn3SHDZJoLppJOwC%252FScreen%2520Shot%25202023-02-02%2520at%252014.55.44.png%3Falt%3Dmedia%26token%3Dd4bc589a-4f77-44fd-8a05-35b9842507ea&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=ce3a66b7&#x26;sv=2" alt="" height="329" width="487">

**4.Confirm your transaction through your wallet**

<img src="https://docs.nusa.finance/~gitbook/image?url=https%3A%2F%2F1342101389-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252F0IPisxvMGNHq66LAZqem%252Fuploads%252FjqWfhGMEXmjSt0TOuL1G%252FScreen%2520Shot%25202023-02-02%2520at%252014.56.48.png%3Falt%3Dmedia%26token%3D09181f83-4b4c-42a2-a7bd-72a5fe0d55b3&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=84afe8bd&#x26;sv=2" alt="" width="188">

**5.Wait until the transaction is done and your debt will automatically decreased or removed from the market**

<img src="https://docs.nusa.finance/~gitbook/image?url=https%3A%2F%2F1342101389-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252F0IPisxvMGNHq66LAZqem%252Fuploads%252FmWCG20Usw5U7eq3KATMe%252FScreen%2520Shot%25202023-02-02%2520at%252014.57.01.png%3Falt%3Dmedia%26token%3Df66f23e7-0a2b-4220-88ac-3f49a807d7ba&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=22d2627c&#x26;sv=2" alt="" height="275" width="412">


---

# 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.nusa.io/nusa-v1/lending-market/how-to-borrow-repay.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.
