# How to use the API to set a timer for a topic?

**URL:** https://meta.discourse.org/t/how-to-use-the-api-to-set-a-timer-for-a-topic/353494
**Category:** Development
**Created:** [February 21, 2025, 4:18am UTC](https://meta.discourse.org/t/how-to-use-the-api-to-set-a-timer-for-a-topic/353494 "2025-02-21T04:18:46Z")
**Posts on this page:** 1
**Showing post:** 2

<div class="post-metadata">

### Author: ![Arkshine](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/arkshine/32/298682_2.png) [@Arkshine](https://meta.discourse.org/u/Arkshine)
#### Post date: [February 21, 2025, 4:42am UTC](https://meta.discourse.org/t/how-to-use-the-api-to-set-a-timer-for-a-topic/353494/2 "2025-02-21T04:42:46Z")

</div>

The best way to figure out how the API works is to follow [Reverse engineer the Discourse API](https://meta.discourse.org/t/reverse-engineer-the-discourse-api/20576).

Note in the doc, the param is not “required”. It depends on the `status_type`.  
You would need it if you use the `publish_to_category` type.

Auto-close 30 days will pass these params:  
 ![image](https://global.discourse-cdn.com/meta/original/4X/1/8/7/187500fa74e16e88a32abca6c7eefd852344a0ad.png)

And returns this data:

 ![image](https://global.discourse-cdn.com/meta/original/4X/2/7/d/27dfc8645adc529e512fd71a5c05ba2961f2fb27.png)

---

_[View the full topic](https://meta.discourse.org/t/how-to-use-the-api-to-set-a-timer-for-a-topic/353494)._
