# What is the right way to call TransparentUpgadeableProxy.changeAdmin()?

**URL:** <https://forum.openzeppelin.com/t/what-is-the-right-way-to-call-transparentupgadeableproxy-changeadmin/25813>\
**Category:** Upgrades\
**Created:** [March 7, 2022, 10:17pm UTC](https://forum.openzeppelin.com/t/what-is-the-right-way-to-call-transparentupgadeableproxy-changeadmin/25813 "2022-03-07T22:17:56Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Godwin](https://avatars.discourse-cdn.com/v4/letter/g/e9bcb4/32.png) [@Godwin](https://forum.openzeppelin.com/u/Godwin)\
**Post date:** [March 7, 2022, 10:17pm UTC](https://forum.openzeppelin.com/t/what-is-the-right-way-to-call-transparentupgadeableproxy-changeadmin/25813/1 "2022-03-07T22:17:57Z")

</div>

In my deploy script I am calling truffle-upgrades deployProxy.  
It automatically deploys a TransparentUpgadeableProxy and a ProxyAdmin.

From the truffle test js file, how can I call the TransparentUpgadeableProxy.changeAdmin() of the deployed contract? I don't have the original TransparentUpgadeableProxy solidity file to get the abi from, and doing this:

```auto
let data = web3.eth.abi.encodeFunctionCall(
{
  "name": "changeAdmin",
  "type": "function",
  "inputs":[
    {
      "name": "newAdmin",
      "type": "address"
    }
  ]
})
await web3.eth.sendTransaction({from:deployer, to: Contract.address, data:data, value: newAddess},
function(err, transactionHash) { if (err) { console.log(err); } else { console.log(transactionHash);

```

gives me TypeError: Cannot read property 'map' of undefined.

I want to test my that proxy cannot be upgraded by anyone else but the admin.  
Am I going about this the right way?  
tia.

---

<div class="post-metadata">

**Author:** ![Godwin](https://avatars.discourse-cdn.com/v4/letter/g/e9bcb4/32.png) [@Godwin](https://forum.openzeppelin.com/u/Godwin)\
**Post date:** [March 8, 2022, 7:36am UTC](https://forum.openzeppelin.com/t/what-is-the-right-way-to-call-transparentupgadeableproxy-changeadmin/25813/2 "2022-03-08T07:36:29Z")

</div>

Nvn, sorry I should have read more, it's at the end of [https://docs.openzeppelin.com/upgrades-plugins/1.x/](https://docs.openzeppelin.com/upgrades-plugins/1.x/)
