# Delegate Call to UpgradeabilityProxy

**URL:** <https://forum.openzeppelin.com/t/delegate-call-to-upgradeabilityproxy/7005>\
**Category:** Upgrades\
**Created:** [April 14, 2021, 4:52pm UTC](https://forum.openzeppelin.com/t/delegate-call-to-upgradeabilityproxy/7005 "2021-04-14T16:52:51Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![ialberquilla](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/ialberquilla/32/3865_2.png) [@ialberquilla](https://forum.openzeppelin.com/u/ialberquilla)\
**Post date:** [April 14, 2021, 4:52pm UTC](https://forum.openzeppelin.com/t/delegate-call-to-upgradeabilityproxy/7005/1 "2021-04-14T16:52:51Z")

</div>

Hi,

I’m trying to create a contract A that contains a function fA that call other contract B function fB, passing the msg.sender that initiate the transaction. The idea was to use a simple delegatecall to it,

`address(B).delegatecall(signature)`

But the contract B is a InitializableImmutableAdminUpgradeabilityProxy, so when the delegate call execution, the context is not reaching the B implementation but the B proxy, and the delegate function is not working, always returns success but assume that is because the fallback.

Is there any way to delegate the call in the contract A to the contract B using the proxy? How can I send the tx to the contract B maintaining the msg.sender that originate the transaction?

Thanks

---

<div class="post-metadata">

**Author:** ![Yoshiko](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/yoshiko/32/6858_2.png) [@Yoshiko](https://forum.openzeppelin.com/u/Yoshiko)\
**Post date:** [April 15, 2021, 6:12am UTC](https://forum.openzeppelin.com/t/delegate-call-to-upgradeabilityproxy/7005/2 "2021-04-15T06:12:50Z")

</div>

You have Contract A and Contract B. Contract B is the proxy.

There should be a Contract C, which is the implementation contract, behind Contract B.

Try the address of the implemented contract. If you need some help with figuring that out, link your contracts on etherscan or bscscan and we can try to help figure out that address.

---

<div class="post-metadata">

**Author:** ![ialberquilla](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/ialberquilla/32/3865_2.png) [@ialberquilla](https://forum.openzeppelin.com/u/ialberquilla)\
**Post date:** [April 15, 2021, 8:49am UTC](https://forum.openzeppelin.com/t/delegate-call-to-upgradeabilityproxy/7005/3 "2021-04-15T08:49:34Z")

</div>

Thanks for your help @Yoshiko

The proxy contract is [https://etherscan.io/address/0x6C3c78838c761c6Ac7bE9F59fe808ea2A6E4379d](https://etherscan.io/address/0x6C3c78838c761c6Ac7bE9F59fe808ea2A6E4379d)

And I tried to send the delegate call to the implementation, I think it’s this one [https://etherscan.io/address/0x4e750a23ddd33e2b977b19dbd014c764f074e3c2](https://etherscan.io/address/0x4e750a23ddd33e2b977b19dbd014c764f074e3c2)

But with no luck.

Is there any way to get the implementation address calling a function on the proxy address?

Thanks!

---

<div class="post-metadata">

**Author:** ![Yoshiko](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/yoshiko/32/6858_2.png) [@Yoshiko](https://forum.openzeppelin.com/u/Yoshiko)\
**Post date:** [April 15, 2021, 9:00am UTC](https://forum.openzeppelin.com/t/delegate-call-to-upgradeabilityproxy/7005/4 "2021-04-15T09:00:33Z")

</div>

> [@ialberquilla](#):
>
> And I tried to send the delegate call to the implementation, I think it’s this one

Yep that's your implementation and if you tried with that address, I'm not sure what to do here. Usually when you call the proxy to do something, it goes automatically to the implementation. So I'm stumped, perhaps someone else can answer that has experience with `delegatecall`

---

<div class="post-metadata">

**Author:** ![abcoathup](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.openzeppelin.com/abcoathup/32/415_2.png) [@abcoathup](https://forum.openzeppelin.com/u/abcoathup)\
**Post date:** [April 22, 2021, 1:04am UTC](https://forum.openzeppelin.com/t/delegate-call-to-upgradeabilityproxy/7005/5 "2021-04-22T01:04:31Z")

</div>

A post was split to a new topic: [Pass my delegated call to another proxy](https://forum.openzeppelin.com/t/pass-my-delegated-call-to-another-proxy/7218)
