# checkDelegateForContract

**checkDelegateForContract**( `to`: <mark style="color:blue;">string</mark>, `from`: <mark style="color:blue;">string</mark>, `contract`: <mark style="color:blue;">string</mark>, `rights?`: <mark style="color:blue;">string</mark> ) ⇒ Promise< <mark style="color:blue;">boolean</mark> >

&#x20;       Returns `true` if delegate is granted to act on from's behalf for entire wallet or that specific contract

<table data-header-hidden><thead><tr><th width="124"></th><th></th></tr></thead><tbody><tr><td><strong>to</strong></td><td>The delegated address to check</td></tr><tr><td><strong>from</strong></td><td>The potential address who delegated rights</td></tr><tr><td><strong>contract</strong></td><td>The address for the contract you're delegating</td></tr><tr><td><strong>rights</strong> <em>(optional)</em></td><td>Specific rights to check for, pass nothing to ignore subdelegations and check full delegations only</td></tr></tbody></table>

#### Usage Example

```javascript
const to = "0x0000000000000000000000000000000000000003";
const from = "0x0000000000000000000000000000000000000001";
const contract = "0x0000000000000000000000000000000000000002";
const isDelegateForContract = await v2.checkDelegateForContract(to, from, contract);

/* returns example

true

*/
```
