Create a new :class:`.LiveThread`. :param title: The title of the new :class:`.LiveThread`. :param description: The new :class:`.LiveThread`'s description. :param nsfw: Indicate whether this thread is not safe for work (default: ``False``). :param resourc
(
self,
title: str,
*,
description: str | None = None,
nsfw: bool = False,
resources: str | None = None,
)
| 252 | return LiveThread(self._reddit, id=id) |
| 253 | |
| 254 | def create( |
| 255 | self, |
| 256 | title: str, |
| 257 | *, |
| 258 | description: str | None = None, |
| 259 | nsfw: bool = False, |
| 260 | resources: str | None = None, |
| 261 | ) -> models.LiveThread: |
| 262 | """Create a new :class:`.LiveThread`. |
| 263 | |
| 264 | :param title: The title of the new :class:`.LiveThread`. |
| 265 | :param description: The new :class:`.LiveThread`'s description. |
| 266 | :param nsfw: Indicate whether this thread is not safe for work (default: |
| 267 | ``False``). |
| 268 | :param resources: Markdown formatted information that is useful for the |
| 269 | :class:`.LiveThread`. |
| 270 | |
| 271 | :returns: The new :class:`.LiveThread` object. |
| 272 | |
| 273 | """ |
| 274 | return self._reddit.post( |
| 275 | API_PATH["livecreate"], |
| 276 | data={ |
| 277 | "description": description, |
| 278 | "nsfw": nsfw, |
| 279 | "resources": resources, |
| 280 | "title": title, |
| 281 | }, |
| 282 | ) |
| 283 | |
| 284 | def info(self, ids: list[str]) -> Iterator[models.LiveThread]: |
| 285 | """Fetch information about each live thread in ``ids``. |