> ## Documentation Index
> Fetch the complete documentation index at: https://www.ayrshare.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# विज्ञापन अपडेट करें

> Ayrshare से boost किए गए Reddit ad को pause, resume, archive या delete करें।

[Boost Post](https://www.ayrshare.com/docs/apis/ads/reddit/boost-post.md) से बनाए गए Reddit ad का status बदलें। Ad और Ayrshare द्वारा उसके लिए बनाया गया campaign साथ-साथ बदलते हैं।

<ul>
  <li>`DELETED` Reddit पर ad को archive करता है, बिल्कुल `ARCHIVED` की तरह। उसके cached response के refresh होते ही (`nextUpdate` देखें) [Boosted Ads](https://www.ayrshare.com/docs/apis/ads/reddit/get-boosted-ads.md) में उसमें `adStatus: "ARCHIVED"` दिखता है।</li>
  <li>किसी दूसरी profile द्वारा boost किए गए ad पर `code: 400` लौटाया जाता है। जिस ad का Ayrshare के पास कोई record नहीं है, उसे pause, archive या delete किया जा सकता है; उसे `ACTIVE` पर सेट करने पर `code: 400` लौटाया जाता है।</li>
  <li>अगर ad के campaign में Ayrshare के बाहर बने ads भी हैं, तो सिर्फ़ यही ad बदलता है। इसे `ACTIVE` पर सेट करने के लिए campaign का Reddit Ads में active होना ज़रूरी है, अन्यथा `code: 369` लौटाया जाता है।</li>
  <li>अगर `ACTIVE` में बदलाव विफल हो जाता है और Reddit यह पुष्टि नहीं कर पाता कि ad फिर से रुक गया है, तो error में एक `warning` होती है कि ad live हो सकता है और खर्च कर रहा हो सकता है, और ad में `adStatus: "ACTIVE"` दिखता है। इसकी जाँच करें, और आवश्यकता होने पर इसे pause करें।</li>
  <li>यदि आप Reddit की अनुमति से अधिक तेज़ी से requests भेजते हैं, तो HTTP 429 के साथ `code: 364` लौटाया जाता है।</li>
</ul>

## हैडर पैरामीटर

**Authorization** `string` *required*

[API Key](https://www.ayrshare.com/docs/apis/overview.md#authorization) of the Primary Profile.

Format: `Authorization: Bearer API_KEY`
**Profile-Key** `string`

[Profile Key](https://www.ayrshare.com/docs/apis/overview.md#profile-key-format) of a User Profile.

Format: `Profile-Key: PROFILE_KEY`

## बॉडी पैरामीटर

**adId** `string` *required*

Reddit ad ID, उदाहरण के लिए `2707300000000000001`।

**status** `string` *required*

`ACTIVE`, `PAUSED`, `ARCHIVED` या `DELETED`। Upper या lower case में।

```bash cURL theme={"system"}
curl -X PUT https://api.ayrshare.com/api/ads/reddit/ads \
  -H "Authorization: Bearer API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "adId": "2707300000000000001",
    "status": "PAUSED"
  }'
```

```json 200: Success theme={"system"}
{
  "status": "success",
  "adId": "2707300000000000001",
  "requestedStatus": "PAUSED"
}
```

```json 400: Invalid status theme={"system"}
{
  "action": "request",
  "status": "error",
  "code": 101,
  "message": "Missing or incorrect parameters. Please verify with the docs. https://www.ayrshare.com/docs/apis",
  "details": "Invalid status: STOPPED. Status must be one of ACTIVE, PAUSED, DELETED, ARCHIVED."
}
```

```json 400: Resume failed, ad may be live theme={"system"}
{
  "action": "ads",
  "status": "error",
  "code": 369,
  "message": "Unable to boost post. Please try again.",
  "warning": "The status change failed, and reddit did not confirm that ad 2707300000000000001 is stopped. It may be live and spending. Check it on reddit or pause it."
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.