> For the complete documentation index, see [llms.txt](https://lgcy-network.gitbook.io/welcome/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://lgcy-network.gitbook.io/welcome/build/lgcy-contract-code.md).

# LGCY Contract Code

Connect to the API’s via https\://lgcyscan.network/devops

**LGCY Contract address** : LZuf2u5cJMm6gKwd3jGGGyJamEstvQMVGu

**1. Get LGCY Token Balance:**

> URL: <http://64.227.188.73:4000/\\>\<contract\_address>/\<user\_address>
>
> FUNCTION NAME: balanceOfToken
>
> REQUEST PARAMS: @contract address (LZuf2u5cJMm6gKwd3jGGGyJamEstvQMVGu)
>
> @user address
>
> RESPONSE: Get particular user token balance
>
> METHOD: GET

**2. Transfer LGCY Token:**

> URL: <http://64.227.188.73:4000/transferToken/\\>\<contract\_address>/\<to\_address>/\<amount>
>
> REQUEST PARAMS: @contract address (LZuf2u5cJMm6gKwd3jGGGyJamEstvQMVGu)
>
> @to address
>
> @token amount to be transferred
>
> RESPONSE: Transaction hash
>
> METHOD: GET

**3. Approve LGCY Token:**

> URL: <http://64.227.188.73:4000/approve/\\>\<contract\_address>/\<to\_address>/\<amount>/\<from\_address>
>
> REQUEST PARAMS: @contract address (LZuf2u5cJMm6gKwd3jGGGyJamEstvQMVGu)
>
> @to address
>
> @token to be approved for the particular user
>
> @from address
>
> RESPONSE: Transaction hash
>
> METHOD: GET

**4. Allowance LGCY Token:**

> URL:
>
> <http://64.227.188.73:4000/allowance/\\>\<contract\_address>/\<owner\_address>/\<to\_address>
>
> REQUEST PARAMS: @contract address (LZuf2u5cJMm6gKwd3jGGGyJamEstvQMVGu)
>
> @owner address
>
> @to address
>
> RESPONSE: Get token allowance details
>
> METHOD: GET

**5. TransferFrom LGCY Token:**

> URL:
>
> <http://64.227.188.73:4000/transferFrom/\\>\<contract\_address>/\<to\_address>/\<amount>/\<from\_address>
>
> REQUEST PARAMS: @contract address (LZuf2u5cJMm6gKwd3jGGGyJamEstvQMVGu)
>
> @to address
>
> @Token amount
>
> @from address
>
> RESPONSE: Transaction hash
>
> METHOD: GET

**6. Transaction Details:**

> URL: <http://64.227.188.73:4000/txinfo/\\>\<transaction\_hash>
>
> REQUEST PARAMS: @transaction hash
>
> RESPONSE: To get the details of transaction hash
>
> METHOD: POST
>
> CURL: curl — request POST — url <http://64.227.188.73:26667/wallet/gettransactionbyid>
>
> — header ‘Accept: application/json’ — header ‘Content-Type: application/json’ — data ‘{ “value”:
>
> “08fcda8a557938579381235b92abd61bcfaac3190013572804634f58ae1ab8ed” }’

![](https://miro.medium.com/max/700/1*aIh_DuJNCT81nR9r0gY2HQ.png)

**7. Transaction Info:**

URL: <http://64.227.188.73:4000/tx/\\>\<transaction\_hash>

REQUEST PARAMS: @transaction hash

RESPONSE: To get the fee details of transaction hash

METHOD: POST

CURL: curl — request POST — url <http://64.227.188.73:26667/wallet/gettransactioninfobyid>

— header ‘Accept: application/json’ — header ‘Content-Type: application/json’ — data

<br>

![](https://miro.medium.com/max/700/1*BMg-KuCchG2Yz4mWcgGIaQ.png)

{% embed url="<https://docs.gitbook.com/spaces/space-visibility>" %}

{% hint style="info" %}
**Good to know!** We're still documenting this version of GitBook. Some documentation links might be out of date for now!
{% endhint %}
