# myPlacedOffers

## myPlacedOffers()

```python
async def myPlacedOffers(offset: int, limit: int, authData: str) -> list[GiftOffer]
```

*Retrieve your placed offers for certain gifts*

### Returns

`list` of `GiftOffer` objects

### Raises

* `authDataError` if `authData` is not provided
* `requestError` if request fails.

### Parameters

* `authData` (str): Authentication data required to cancel the offer.
* `offset` (int): It's like a pagination. To get page you want, multiply it by `limit`. Default is `0`.
* `limit` (int): Limit of offers to show. Default is `20` .

### GiftOffer object

#### Methods

* `.toDict()` - converts the `GiftOffer` object back to a dict

#### Attributes

* `.id` - retrieves `offer_id`
* `.amount` - amount of TON offered
* `.status` - status of the offer
* `.created_at` - date+time of when the offer was created
* `.updated_at` - date+time of when the offer was updated (if was)
* `.expires_at` - expiration date+time of the offer
* `.nft`  - returns `PortalsGift` object. See [PortalsGift](https://bleach-1.gitbook.io/aportalsmp/documentation/aportalsmp.classes.objects/gifts/portalsgift)

### Example

```python
from aportalsmp.offers import myPlacedOffers
from aportalsmp.auth import update_auth
import asyncio

auth = asyncio.run(update_auth(api_id=123, api_hash="..."))

async def main():
    placed = await myPlacedOffers(authData = auth)
    for offer in placed:
        print(offer.nft.name, offer.nft.tg_id, offer.id, offer.amount)
        # it's all the same as in myReceivedOffers
        # offer.nft.name - name of the nft for which offer has been placed
        # offer.nft.tg_id - telegram id of this nft
        # offer.id - id of the offer
        # offer.amount - price offered for the nft
```

***See used functions:*** [*update\_auth*](https://bleach-1.gitbook.io/aportalsmp/aportalsmp.auth/update_auth#update_auth)
