From 93a02e151a810bc1f29f2751456bc8a06999ca02 Mon Sep 17 00:00:00 2001 From: Chris Reilly Date: Wed, 4 Feb 2026 15:26:33 -0700 Subject: [PATCH 01/10] remove note that Payments arent supported on Devvit Web --- docs/earn-money/payments/payments_overview.md | 4 ---- 1 file changed, 4 deletions(-) diff --git a/docs/earn-money/payments/payments_overview.md b/docs/earn-money/payments/payments_overview.md index 73e15a1..c1c0bee 100644 --- a/docs/earn-money/payments/payments_overview.md +++ b/docs/earn-money/payments/payments_overview.md @@ -19,7 +19,3 @@ You can use the sandbox to build and test payments, but before you can publish y - Accept and comply with our [Earn Terms](https://redditinc.com/policies/earn-terms) and [Earn Policy](https://www.redditinc.com/policies/earn-policy). All products will be reviewed by the Developer Platform team to ensure compliance with our content policy. Products are approved during the app review process after you publish your app. - -:::note -Payment functionality is supported on [Devvit Blocks](../../capabilities/blocks/overview.md) only. [Devvit Web](../../capabilities/devvit-web/devvit_web_overview.mdx) is currently not supported. -::: From 94ceead35320c2c242b3b991fd81a50de4bad136 Mon Sep 17 00:00:00 2001 From: Chris Reilly Date: Wed, 4 Feb 2026 15:29:27 -0700 Subject: [PATCH 02/10] remove scalable from redis reference --- docs/capabilities/server/overview.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/capabilities/server/overview.md b/docs/capabilities/server/overview.md index a36be05..2bf8085 100644 --- a/docs/capabilities/server/overview.md +++ b/docs/capabilities/server/overview.md @@ -16,9 +16,9 @@ Allows you to build apps where the end user can upload custom images to Reddit's Allows you to query information from Reddit such as comments, posts and upvotes. Limited to installation scope of the application. -## [Scalable storage (Redis)](./redis.mdx) +## [Data storage (Redis)](./redis.mdx) -Allows you to store app data in a scalable database, free of charge. Limited to the installation scope of the application. +Allows you to store app data in a key-value database, free of charge. Limited to the installation scope of the application. ## [Scheduler](./scheduler.md) From a36a5314bce7f5fa240863250f87ecd19f6e94a3 Mon Sep 17 00:00:00 2001 From: Chris Reilly Date: Wed, 4 Feb 2026 15:32:31 -0700 Subject: [PATCH 03/10] Update Templates --- docs/examples/template-library.md | 5 +++++ versioned_docs/version-0.12/examples/template-library.md | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/docs/examples/template-library.md b/docs/examples/template-library.md index 592636b..3da8c38 100644 --- a/docs/examples/template-library.md +++ b/docs/examples/template-library.md @@ -12,8 +12,13 @@ Here are some starter projects and templates for your Devvit projects - [Phaser starter](https://github.com/reddit/devvit-template-phaser) - a feature-rich HTML5 game framework for building 2D games in the browser. It includes preinstalled libraries for Devvit, Vite, Phaser, Express, and TypeScript. This template is good for handling physics, animations, input, sound, and asset management. +- [Unity starter](https://github.com/reddit/devvit-template-unity) - a template for building games with Unity. Includes setup for WebGL builds and integration with Devvit's server-side capabilities. + +- [GameMaker starter](https://github.com/reddit/devvit-template-gamemaker) - a template for building games with GameMaker. Includes setup for HTML5 exports and integration with Devvit's server-side capabilities. + - [Hello world](https://github.com/reddit/devvit-template-hello-world/tree/main) - a simple template to build a counter app with no frameworks or opinions. + ## Devvit Blocks [Devvit Blocks](../capabilities/blocks/overview.md) lets you build applications that run inside of a Reddit post, using Reddit's own design system: optimized for performance and cross-platform compatibility. diff --git a/versioned_docs/version-0.12/examples/template-library.md b/versioned_docs/version-0.12/examples/template-library.md index 592636b..3da8c38 100644 --- a/versioned_docs/version-0.12/examples/template-library.md +++ b/versioned_docs/version-0.12/examples/template-library.md @@ -12,8 +12,13 @@ Here are some starter projects and templates for your Devvit projects - [Phaser starter](https://github.com/reddit/devvit-template-phaser) - a feature-rich HTML5 game framework for building 2D games in the browser. It includes preinstalled libraries for Devvit, Vite, Phaser, Express, and TypeScript. This template is good for handling physics, animations, input, sound, and asset management. +- [Unity starter](https://github.com/reddit/devvit-template-unity) - a template for building games with Unity. Includes setup for WebGL builds and integration with Devvit's server-side capabilities. + +- [GameMaker starter](https://github.com/reddit/devvit-template-gamemaker) - a template for building games with GameMaker. Includes setup for HTML5 exports and integration with Devvit's server-side capabilities. + - [Hello world](https://github.com/reddit/devvit-template-hello-world/tree/main) - a simple template to build a counter app with no frameworks or opinions. + ## Devvit Blocks [Devvit Blocks](../capabilities/blocks/overview.md) lets you build applications that run inside of a Reddit post, using Reddit's own design system: optimized for performance and cross-platform compatibility. From 485ed4717bbee777a6b34999199410e662cfd3ff Mon Sep 17 00:00:00 2001 From: Chris Reilly Date: Wed, 4 Feb 2026 16:03:52 -0700 Subject: [PATCH 04/10] Update logs page to show devvit web example --- docs/guides/tools/logs.md | 44 ++++++++++++++----- .../version-0.12/guides/tools/logs.md | 44 ++++++++++++++----- 2 files changed, 66 insertions(+), 22 deletions(-) diff --git a/docs/guides/tools/logs.md b/docs/guides/tools/logs.md index 7628e20..b89b5f1 100644 --- a/docs/guides/tools/logs.md +++ b/docs/guides/tools/logs.md @@ -6,21 +6,43 @@ Stream log events from your installed app to your command line to troubleshoot y Any logs sent to `console` will be available via `devvit logs` for installed apps. For example, `console.log()`, `console.info()` and `console.error()` will produce logs with timestamps as expected. -The following example creates a basic app that simply creates a single log. +The following example creates a basic app with a menu action that creates a log when clicked. -```typescript title="main.tsx" -import { Context, Devvit } from '@devvit/public-api'; +```json title="devvit.json" +{ + "$schema": "https://developers.reddit.com/schema/config-file.v1.json", + "name": "app-name", -Devvit.addMenuItem({ - location: 'post', - label: 'Create a log!', - onPress: (event, context) => { - console.log('Action called!'); - context.ui.showToast(`Successfully logged!`); + "server": { + "dir": "dist/server", + "entry": "index.cjs" }, -}); + "permissions": { + "reddit": true + }, + "menu": { + "items": [ + { + "label": "Create a log!", + "location": "subreddit", + "endpoint": "/internal/log-action", + "forUserType": "moderator" + } + ] + } +} +``` -export default Devvit; +```typescript title="server/index.ts" +router.post("/internal/log-action", async (_req, res): Promise => { + console.log("log-action"); + res.json({ + showToast: { + text: "Log action", + appearance: "success", + }, + }); +}); ``` ## Stream logs diff --git a/versioned_docs/version-0.12/guides/tools/logs.md b/versioned_docs/version-0.12/guides/tools/logs.md index 7628e20..b89b5f1 100644 --- a/versioned_docs/version-0.12/guides/tools/logs.md +++ b/versioned_docs/version-0.12/guides/tools/logs.md @@ -6,21 +6,43 @@ Stream log events from your installed app to your command line to troubleshoot y Any logs sent to `console` will be available via `devvit logs` for installed apps. For example, `console.log()`, `console.info()` and `console.error()` will produce logs with timestamps as expected. -The following example creates a basic app that simply creates a single log. +The following example creates a basic app with a menu action that creates a log when clicked. -```typescript title="main.tsx" -import { Context, Devvit } from '@devvit/public-api'; +```json title="devvit.json" +{ + "$schema": "https://developers.reddit.com/schema/config-file.v1.json", + "name": "app-name", -Devvit.addMenuItem({ - location: 'post', - label: 'Create a log!', - onPress: (event, context) => { - console.log('Action called!'); - context.ui.showToast(`Successfully logged!`); + "server": { + "dir": "dist/server", + "entry": "index.cjs" }, -}); + "permissions": { + "reddit": true + }, + "menu": { + "items": [ + { + "label": "Create a log!", + "location": "subreddit", + "endpoint": "/internal/log-action", + "forUserType": "moderator" + } + ] + } +} +``` -export default Devvit; +```typescript title="server/index.ts" +router.post("/internal/log-action", async (_req, res): Promise => { + console.log("log-action"); + res.json({ + showToast: { + text: "Log action", + appearance: "success", + }, + }); +}); ``` ## Stream logs From 1f492a49be587218f034ab55d3f3cf87544885aa Mon Sep 17 00:00:00 2001 From: Chris Reilly Date: Wed, 4 Feb 2026 16:05:59 -0700 Subject: [PATCH 05/10] Fix typo on Feature-guide --- docs/guides/launch/feature-guide.md | 2 +- versioned_docs/version-0.12/guides/launch/feature-guide.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/guides/launch/feature-guide.md b/docs/guides/launch/feature-guide.md index 8349e8f..516ae36 100644 --- a/docs/guides/launch/feature-guide.md +++ b/docs/guides/launch/feature-guide.md @@ -34,7 +34,7 @@ Games that see organic growth are also likely to be scouted by our team for feat Reddit features games and developers across multiple discovery surfaces to help players find new favorites: -- **Games Feed.** The Games Feed showcases playable experiences directly within Reddit. When featured, games are rotated into a list of games that is algorythmically served to users visiting the feed. +- **Games Feed.** The Games Feed showcases playable experiences directly within Reddit. When featured, games are rotated into a list of games that is algorithmically served to users visiting the feed. ![Featured games](../../assets/featured_games.png) diff --git a/versioned_docs/version-0.12/guides/launch/feature-guide.md b/versioned_docs/version-0.12/guides/launch/feature-guide.md index 8349e8f..516ae36 100644 --- a/versioned_docs/version-0.12/guides/launch/feature-guide.md +++ b/versioned_docs/version-0.12/guides/launch/feature-guide.md @@ -34,7 +34,7 @@ Games that see organic growth are also likely to be scouted by our team for feat Reddit features games and developers across multiple discovery surfaces to help players find new favorites: -- **Games Feed.** The Games Feed showcases playable experiences directly within Reddit. When featured, games are rotated into a list of games that is algorythmically served to users visiting the feed. +- **Games Feed.** The Games Feed showcases playable experiences directly within Reddit. When featured, games are rotated into a list of games that is algorithmically served to users visiting the feed. ![Featured games](../../assets/featured_games.png) From 4fd0921601e2690db876a95fa4457c8078de5656 Mon Sep 17 00:00:00 2001 From: Chris Reilly Date: Wed, 4 Feb 2026 16:09:27 -0700 Subject: [PATCH 06/10] Reduce image sizes --- .../{feature-guide.md => feature-guide.mdx} | 17 +++++++++-------- .../{feature-guide.md => feature-guide.mdx} | 17 +++++++++-------- 2 files changed, 18 insertions(+), 16 deletions(-) rename docs/guides/launch/{feature-guide.md => feature-guide.mdx} (82%) rename versioned_docs/version-0.12/guides/launch/{feature-guide.md => feature-guide.mdx} (82%) diff --git a/docs/guides/launch/feature-guide.md b/docs/guides/launch/feature-guide.mdx similarity index 82% rename from docs/guides/launch/feature-guide.md rename to docs/guides/launch/feature-guide.mdx index 516ae36..107b770 100644 --- a/docs/guides/launch/feature-guide.md +++ b/docs/guides/launch/feature-guide.mdx @@ -12,7 +12,7 @@ Learn how your game can be featured across Reddit and reach thousands of players ## What is featuring? -Whether you’re prototyping an early version of your first Reddit game or launching a polished experience to a wide audience, you have an opportunity to be featured. Our mission is to help developers grow by connecting their work with the Reddit users that will love it. Featuring selections are curated by our team and refreshed regularly to spotlight innovation, polished play, and player engagement. +Whether you're prototyping an early version of your first Reddit game or launching a polished experience to a wide audience, you have an opportunity to be featured. Our mission is to help developers grow by connecting their work with the Reddit users that will love it. Featuring selections are curated by our team and refreshed regularly to spotlight innovation, polished play, and player engagement. Note that our top featuring slots are reserved for games that are of professional quality, as well as games that see exceptional engagement as they grow (CTR, dwell times, positive user engagement, retention). @@ -36,13 +36,13 @@ Reddit features games and developers across multiple discovery surfaces to help - **Games Feed.** The Games Feed showcases playable experiences directly within Reddit. When featured, games are rotated into a list of games that is algorithmically served to users visiting the feed. -![Featured games](../../assets/featured_games.png) +Featured games - **Community Drawer.** Our lefthand drawer provides an easy access point for any redditor to see a mix of recently played games and curated popular games. -![Community drawer web](../../assets/featured_cd_web.png) +Community drawer web -![Community drawer mobile](../../assets/featured_cd_mobile.png) +Community drawer mobile - **Home Feed boosting.** One selected game per week is given an extra algorithmic boost in user home feeds, reaching broad audiences. - **r/GamesOnReddit.** The curated [r/GamesOnReddit](https://www.reddit.com/r/GamesOnReddit/) banner highlights new and trending games for Reddit players. @@ -52,11 +52,11 @@ Reddit features games and developers across multiple discovery surfaces to help ## Featuring tiers -| Tier | Description | Featuring Spots | Who It’s For | Level of Polish | Approximate Impressions\* | +| Tier | Description | Featuring Spots | Who It's For | Level of Polish | Approximate Impressions\* | | --------------- | -------------------------------------------------------------- | ------------------------------------------------------------------------------------------------- | ----------------------------------------------- | -------------------------------------------------- | ------------------------------------------- | | **Distributed** | Games get initial exposure on r/GamesOnReddit featuring | Cross-posted by Reddit, pinned banner on r/GamesOnReddit | Developers seeking first players | Early builds of launched apps | Thousands | | **Promoted** | Polished games selected to gain more visibility and engagement | Games Feed listing, more visibility in r/GamesOnReddit launch pad | Developers ready to expand their reach | Polished, working seamlessly across all platforms | Tens of thousands of impressions | -| **Highlighted** | High-performing games that drive significant player engagement | Games Feed top positions, added to Community Drawer “recently played” or one of the popular slots | Developers with highly polished, iterated games | Highly polished, optimized for scale and retention | Hundreds of thousands of impressions | +| **Highlighted** | High-performing games that drive significant player engagement | Games Feed top positions, added to Community Drawer "recently played" or one of the popular slots | Developers with highly polished, iterated games | Highly polished, optimized for scale and retention | Hundreds of thousands of impressions | | **Hero** | Top-tier, standout games featured broadly across Reddit | Games Feed highlight, featured in Community Drawer, Home Feed highlight | Developers with flagship-quality games | Pro quality, high retention and engagement | Millions to tens of millions of impressions | \*This is a rough estimate and does not reflect what any particular game will reach at this tier. @@ -78,7 +78,7 @@ In order to promote a game, we need to ensure the experience for redditors meets ## Featuring considerations -Our goal is to feature games that feel great to play and reflect Reddit’s creative spirit. With each featuring tier, the quality of featured apps becomes more stringent. Beyond the basic featuring requirements, we want to see: +Our goal is to feature games that feel great to play and reflect Reddit's creative spirit. With each featuring tier, the quality of featured apps becomes more stringent. Beyond the basic featuring requirements, we want to see: - **Standout user experience.** Fast, intuitive, and responsive gameplay across devices. - **Design and polish.** Cohesive visuals, appealing splash screens, and optimized mobile layouts. @@ -91,6 +91,7 @@ Our goal is to feature games that feel great to play and reflect Reddit’s crea ## Celebrating your app -Games that reach featured tiers often see thousands of daily players and dedicated community followings. When your game is featured, you’ll receive promotional visibility through banners, feeds, and subreddit posts, as well as the opportunity to share your success across social channels and developer communities. +Games that reach featured tiers often see thousands of daily players and dedicated community followings. When your game is featured, you'll receive promotional visibility through banners, feeds, and subreddit posts, as well as the opportunity to share your success across social channels and developer communities. See stories about successful games like [Honk](https://developers.reddit.com/docs/blog/honk) and [Syllocrostic](https://www.reddit.com/r/Devvit/comments/1n0vn97/reddit_has_acquired_syllacrostic/), which Reddit acquired after successful featuring. + diff --git a/versioned_docs/version-0.12/guides/launch/feature-guide.md b/versioned_docs/version-0.12/guides/launch/feature-guide.mdx similarity index 82% rename from versioned_docs/version-0.12/guides/launch/feature-guide.md rename to versioned_docs/version-0.12/guides/launch/feature-guide.mdx index 516ae36..107b770 100644 --- a/versioned_docs/version-0.12/guides/launch/feature-guide.md +++ b/versioned_docs/version-0.12/guides/launch/feature-guide.mdx @@ -12,7 +12,7 @@ Learn how your game can be featured across Reddit and reach thousands of players ## What is featuring? -Whether you’re prototyping an early version of your first Reddit game or launching a polished experience to a wide audience, you have an opportunity to be featured. Our mission is to help developers grow by connecting their work with the Reddit users that will love it. Featuring selections are curated by our team and refreshed regularly to spotlight innovation, polished play, and player engagement. +Whether you're prototyping an early version of your first Reddit game or launching a polished experience to a wide audience, you have an opportunity to be featured. Our mission is to help developers grow by connecting their work with the Reddit users that will love it. Featuring selections are curated by our team and refreshed regularly to spotlight innovation, polished play, and player engagement. Note that our top featuring slots are reserved for games that are of professional quality, as well as games that see exceptional engagement as they grow (CTR, dwell times, positive user engagement, retention). @@ -36,13 +36,13 @@ Reddit features games and developers across multiple discovery surfaces to help - **Games Feed.** The Games Feed showcases playable experiences directly within Reddit. When featured, games are rotated into a list of games that is algorithmically served to users visiting the feed. -![Featured games](../../assets/featured_games.png) +Featured games - **Community Drawer.** Our lefthand drawer provides an easy access point for any redditor to see a mix of recently played games and curated popular games. -![Community drawer web](../../assets/featured_cd_web.png) +Community drawer web -![Community drawer mobile](../../assets/featured_cd_mobile.png) +Community drawer mobile - **Home Feed boosting.** One selected game per week is given an extra algorithmic boost in user home feeds, reaching broad audiences. - **r/GamesOnReddit.** The curated [r/GamesOnReddit](https://www.reddit.com/r/GamesOnReddit/) banner highlights new and trending games for Reddit players. @@ -52,11 +52,11 @@ Reddit features games and developers across multiple discovery surfaces to help ## Featuring tiers -| Tier | Description | Featuring Spots | Who It’s For | Level of Polish | Approximate Impressions\* | +| Tier | Description | Featuring Spots | Who It's For | Level of Polish | Approximate Impressions\* | | --------------- | -------------------------------------------------------------- | ------------------------------------------------------------------------------------------------- | ----------------------------------------------- | -------------------------------------------------- | ------------------------------------------- | | **Distributed** | Games get initial exposure on r/GamesOnReddit featuring | Cross-posted by Reddit, pinned banner on r/GamesOnReddit | Developers seeking first players | Early builds of launched apps | Thousands | | **Promoted** | Polished games selected to gain more visibility and engagement | Games Feed listing, more visibility in r/GamesOnReddit launch pad | Developers ready to expand their reach | Polished, working seamlessly across all platforms | Tens of thousands of impressions | -| **Highlighted** | High-performing games that drive significant player engagement | Games Feed top positions, added to Community Drawer “recently played” or one of the popular slots | Developers with highly polished, iterated games | Highly polished, optimized for scale and retention | Hundreds of thousands of impressions | +| **Highlighted** | High-performing games that drive significant player engagement | Games Feed top positions, added to Community Drawer "recently played" or one of the popular slots | Developers with highly polished, iterated games | Highly polished, optimized for scale and retention | Hundreds of thousands of impressions | | **Hero** | Top-tier, standout games featured broadly across Reddit | Games Feed highlight, featured in Community Drawer, Home Feed highlight | Developers with flagship-quality games | Pro quality, high retention and engagement | Millions to tens of millions of impressions | \*This is a rough estimate and does not reflect what any particular game will reach at this tier. @@ -78,7 +78,7 @@ In order to promote a game, we need to ensure the experience for redditors meets ## Featuring considerations -Our goal is to feature games that feel great to play and reflect Reddit’s creative spirit. With each featuring tier, the quality of featured apps becomes more stringent. Beyond the basic featuring requirements, we want to see: +Our goal is to feature games that feel great to play and reflect Reddit's creative spirit. With each featuring tier, the quality of featured apps becomes more stringent. Beyond the basic featuring requirements, we want to see: - **Standout user experience.** Fast, intuitive, and responsive gameplay across devices. - **Design and polish.** Cohesive visuals, appealing splash screens, and optimized mobile layouts. @@ -91,6 +91,7 @@ Our goal is to feature games that feel great to play and reflect Reddit’s crea ## Celebrating your app -Games that reach featured tiers often see thousands of daily players and dedicated community followings. When your game is featured, you’ll receive promotional visibility through banners, feeds, and subreddit posts, as well as the opportunity to share your success across social channels and developer communities. +Games that reach featured tiers often see thousands of daily players and dedicated community followings. When your game is featured, you'll receive promotional visibility through banners, feeds, and subreddit posts, as well as the opportunity to share your success across social channels and developer communities. See stories about successful games like [Honk](https://developers.reddit.com/docs/blog/honk) and [Syllocrostic](https://www.reddit.com/r/Devvit/comments/1n0vn97/reddit_has_acquired_syllacrostic/), which Reddit acquired after successful featuring. + From e9e05b73aaecf674584788b052e94acf21bf6b0d Mon Sep 17 00:00:00 2001 From: Chris Reilly Date: Wed, 4 Feb 2026 17:15:38 -0700 Subject: [PATCH 07/10] Add thing descriptions --- docs/capabilities/server/reddit-api.mdx | 25 +++++++++++++++++++ .../capabilities/server/reddit-api.mdx | 25 +++++++++++++++++++ 2 files changed, 50 insertions(+) diff --git a/docs/capabilities/server/reddit-api.mdx b/docs/capabilities/server/reddit-api.mdx index 273e710..44ced71 100644 --- a/docs/capabilities/server/reddit-api.mdx +++ b/docs/capabilities/server/reddit-api.mdx @@ -36,6 +36,31 @@ Here's how to obtain a reference to the Reddit client +## Reddit Thing IDs + +Reddit uses prefixed IDs (called "things") to identify different types of content: + +| Prefix | Type | Example | Description | +| ------ | ---- | ------- | ----------- | +| `t1_` | Comment | `t1_abc123` | A comment on a post or reply to another comment | +| `t2_` | User | `t2_xyz789` | A Reddit user account | +| `t3_` | Post | `t3_def456` | A post | +| `t4_` | Message | `t4_ghi012` | A private message | +| `t5_` | Subreddit | `t5_jkl345` | A subreddit community | + +These IDs are returned by API methods and used when referencing specific content: + +```ts +// Get a post by its full ID +const post = await reddit.getPostById('t3_abc123'); + +// Get a comment by its full ID +const comment = await reddit.getCommentById('t1_xyz789'); + +// A comment's parentId can be either a post (t3_) or another comment (t1_) +const parentId = comment.parentId; // 't3_abc123' or 't1_def456' +``` + ## Example usage ### Submitting a post diff --git a/versioned_docs/version-0.12/capabilities/server/reddit-api.mdx b/versioned_docs/version-0.12/capabilities/server/reddit-api.mdx index 273e710..44ced71 100644 --- a/versioned_docs/version-0.12/capabilities/server/reddit-api.mdx +++ b/versioned_docs/version-0.12/capabilities/server/reddit-api.mdx @@ -36,6 +36,31 @@ Here's how to obtain a reference to the Reddit client +## Reddit Thing IDs + +Reddit uses prefixed IDs (called "things") to identify different types of content: + +| Prefix | Type | Example | Description | +| ------ | ---- | ------- | ----------- | +| `t1_` | Comment | `t1_abc123` | A comment on a post or reply to another comment | +| `t2_` | User | `t2_xyz789` | A Reddit user account | +| `t3_` | Post | `t3_def456` | A post | +| `t4_` | Message | `t4_ghi012` | A private message | +| `t5_` | Subreddit | `t5_jkl345` | A subreddit community | + +These IDs are returned by API methods and used when referencing specific content: + +```ts +// Get a post by its full ID +const post = await reddit.getPostById('t3_abc123'); + +// Get a comment by its full ID +const comment = await reddit.getCommentById('t1_xyz789'); + +// A comment's parentId can be either a post (t3_) or another comment (t1_) +const parentId = comment.parentId; // 't3_abc123' or 't1_def456' +``` + ## Example usage ### Submitting a post From 52e9cf3de55c11c6eadabe91dc385777bc8c6761 Mon Sep 17 00:00:00 2001 From: Chris Reilly Date: Wed, 4 Feb 2026 17:22:17 -0700 Subject: [PATCH 08/10] Remove splash screen references --- docs/changelog.md | 2 +- docs/guides/launch/feature-guide.mdx | 2 +- sidebars.ts | 1 - versioned_docs/version-0.12/changelog.md | 2 +- versioned_docs/version-0.12/guides/launch/feature-guide.mdx | 2 +- versioned_sidebars/version-0.12-sidebars.json | 1 - 6 files changed, 4 insertions(+), 6 deletions(-) diff --git a/docs/changelog.md b/docs/changelog.md index 97abd6b..0940c91 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -239,4 +239,4 @@ We'd love to hear about your experience with Devvit Web! Join the conversation i In addition to Devvit Web, release 0.12 also adds: - **Post data** - [Post data](./capabilities/server/post-data.mdx) allows you to add data to your post when you submit it so that you can retrieve and use in your app without an additional Redis call. -- **Splash screen** - Having a compelling first screen of your app is one of the most important indicators of good post engagement. Every submitPost will come with a default per-post [splash screen](./capabilities/server/splash-screen.mdx) you can customize. +- **Splash screen** - Having a compelling first screen of your app is one of the most important indicators of good post engagement. Every submitPost will come with a default per-post splash screen. diff --git a/docs/guides/launch/feature-guide.mdx b/docs/guides/launch/feature-guide.mdx index 107b770..5717079 100644 --- a/docs/guides/launch/feature-guide.mdx +++ b/docs/guides/launch/feature-guide.mdx @@ -69,7 +69,7 @@ Games can be promoted to our highest featuring tiers if they see exceptional eng In order to promote a game, we need to ensure the experience for redditors meets certain quality criteria. To be featured at any level you must have: -- **A compelling first screen.** Your game must have a custom [splash screen](https://developers.reddit.com/docs/capabilities/server/splash-screen). +- **A compelling first screen.** Your game must have a custom first screen. - **Cross platform support.** Your game's viewport must be accessible and clean on both mobile and desktop platforms. - **Self-explanatory design.** Anyone should be able to click into your post and have the context needed to learn, play, or participate. - **Responsive design.** All screens should be visible within fullscreen, mobile, and desktop. Avoid unnecessary scrolls. Scrolling within inline webviews is prohibited. diff --git a/sidebars.ts b/sidebars.ts index c6682b0..9e2795a 100644 --- a/sidebars.ts +++ b/sidebars.ts @@ -300,7 +300,6 @@ const sidebars: SidebarsConfig = { type: "category", label: "Splash Screens", items: [ - "capabilities/server/splash-screen", "capabilities/server/launch_screen_and_entry_points/splash_migration", ], }, diff --git a/versioned_docs/version-0.12/changelog.md b/versioned_docs/version-0.12/changelog.md index 97abd6b..0940c91 100644 --- a/versioned_docs/version-0.12/changelog.md +++ b/versioned_docs/version-0.12/changelog.md @@ -239,4 +239,4 @@ We'd love to hear about your experience with Devvit Web! Join the conversation i In addition to Devvit Web, release 0.12 also adds: - **Post data** - [Post data](./capabilities/server/post-data.mdx) allows you to add data to your post when you submit it so that you can retrieve and use in your app without an additional Redis call. -- **Splash screen** - Having a compelling first screen of your app is one of the most important indicators of good post engagement. Every submitPost will come with a default per-post [splash screen](./capabilities/server/splash-screen.mdx) you can customize. +- **Splash screen** - Having a compelling first screen of your app is one of the most important indicators of good post engagement. Every submitPost will come with a default per-post splash screen. diff --git a/versioned_docs/version-0.12/guides/launch/feature-guide.mdx b/versioned_docs/version-0.12/guides/launch/feature-guide.mdx index 107b770..5717079 100644 --- a/versioned_docs/version-0.12/guides/launch/feature-guide.mdx +++ b/versioned_docs/version-0.12/guides/launch/feature-guide.mdx @@ -69,7 +69,7 @@ Games can be promoted to our highest featuring tiers if they see exceptional eng In order to promote a game, we need to ensure the experience for redditors meets certain quality criteria. To be featured at any level you must have: -- **A compelling first screen.** Your game must have a custom [splash screen](https://developers.reddit.com/docs/capabilities/server/splash-screen). +- **A compelling first screen.** Your game must have a custom first screen. - **Cross platform support.** Your game's viewport must be accessible and clean on both mobile and desktop platforms. - **Self-explanatory design.** Anyone should be able to click into your post and have the context needed to learn, play, or participate. - **Responsive design.** All screens should be visible within fullscreen, mobile, and desktop. Avoid unnecessary scrolls. Scrolling within inline webviews is prohibited. diff --git a/versioned_sidebars/version-0.12-sidebars.json b/versioned_sidebars/version-0.12-sidebars.json index 61e52c0..2fda9f4 100644 --- a/versioned_sidebars/version-0.12-sidebars.json +++ b/versioned_sidebars/version-0.12-sidebars.json @@ -289,7 +289,6 @@ "type": "category", "label": "Splash Screens", "items": [ - "capabilities/server/splash-screen", "capabilities/server/launch_screen_and_entry_points/splash_migration" ] } From 696aaac3b6dfdccff028da233e1b9cb52b95b7bc Mon Sep 17 00:00:00 2001 From: Chris Reilly Date: Wed, 4 Feb 2026 17:25:45 -0700 Subject: [PATCH 09/10] Fix --help syntax --- docs/guides/tools/playtest.md | 2 +- versioned_docs/version-0.11/playtest.md | 2 +- versioned_docs/version-0.12/guides/tools/playtest.md | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/guides/tools/playtest.md b/docs/guides/tools/playtest.md index fb18fa4..6743628 100644 --- a/docs/guides/tools/playtest.md +++ b/docs/guides/tools/playtest.md @@ -37,7 +37,7 @@ The auto-generated playtest subreddit is created for you by u/devvit-dev-bot. Th - Allows reddit admins to join your subreddit :::note -If you need help, run `devvit playtest —-help` for additional information. +If you need help, run `devvit playtest --help` for additional information. ::: ## View logs diff --git a/versioned_docs/version-0.11/playtest.md b/versioned_docs/version-0.11/playtest.md index 53b2e5d..c87049f 100644 --- a/versioned_docs/version-0.11/playtest.md +++ b/versioned_docs/version-0.11/playtest.md @@ -37,7 +37,7 @@ The auto-generated playtest subreddit is created for you by u/devvit-dev-bot. Th - Allows reddit admins to join your subreddit :::note -If you need help, run `devvit playtest —-help` for additional information. +If you need help, run `devvit playtest --help` for additional information. ::: ## View logs diff --git a/versioned_docs/version-0.12/guides/tools/playtest.md b/versioned_docs/version-0.12/guides/tools/playtest.md index fb18fa4..6743628 100644 --- a/versioned_docs/version-0.12/guides/tools/playtest.md +++ b/versioned_docs/version-0.12/guides/tools/playtest.md @@ -37,7 +37,7 @@ The auto-generated playtest subreddit is created for you by u/devvit-dev-bot. Th - Allows reddit admins to join your subreddit :::note -If you need help, run `devvit playtest —-help` for additional information. +If you need help, run `devvit playtest --help` for additional information. ::: ## View logs From 53aed3a68102ffefb87028c7a518a07c512d2baf Mon Sep 17 00:00:00 2001 From: Chris Reilly Date: Wed, 4 Feb 2026 17:30:58 -0700 Subject: [PATCH 10/10] Update logs --verbose' --- docs/guides/tools/logs.md | 9 +-------- versioned_docs/version-0.12/guides/tools/logs.md | 9 +-------- 2 files changed, 2 insertions(+), 16 deletions(-) diff --git a/docs/guides/tools/logs.md b/docs/guides/tools/logs.md index b89b5f1..846e5fa 100644 --- a/docs/guides/tools/logs.md +++ b/docs/guides/tools/logs.md @@ -4,7 +4,7 @@ Stream log events from your installed app to your command line to troubleshoot y ## Create logs -Any logs sent to `console` will be available via `devvit logs` for installed apps. For example, `console.log()`, `console.info()` and `console.error()` will produce logs with timestamps as expected. +Use `console.log()`, `console.info()`, and `console.error()` in your server code to create logs. View them with `devvit logs` for installed apps, or add `--verbose` to include timestamps. The following example creates a basic app with a menu action that creates a log when clicked. @@ -71,13 +71,6 @@ You should now see logs streaming onto your console: To exit the streaming logger, enter `CTRL + c`. -Currently, `console.log` calls will only stream when they are run from the server (not the client). - -:::note - -Custom post apps use a client-side runtime to speed up execution, so `console.log` calls won't always show up in Devvit logs or Devvit playtest commands. However, these calls will show up in other dev tools (like Chrome) when viewing the app during a playtest. - -::: ## Historical logs diff --git a/versioned_docs/version-0.12/guides/tools/logs.md b/versioned_docs/version-0.12/guides/tools/logs.md index b89b5f1..846e5fa 100644 --- a/versioned_docs/version-0.12/guides/tools/logs.md +++ b/versioned_docs/version-0.12/guides/tools/logs.md @@ -4,7 +4,7 @@ Stream log events from your installed app to your command line to troubleshoot y ## Create logs -Any logs sent to `console` will be available via `devvit logs` for installed apps. For example, `console.log()`, `console.info()` and `console.error()` will produce logs with timestamps as expected. +Use `console.log()`, `console.info()`, and `console.error()` in your server code to create logs. View them with `devvit logs` for installed apps, or add `--verbose` to include timestamps. The following example creates a basic app with a menu action that creates a log when clicked. @@ -71,13 +71,6 @@ You should now see logs streaming onto your console: To exit the streaming logger, enter `CTRL + c`. -Currently, `console.log` calls will only stream when they are run from the server (not the client). - -:::note - -Custom post apps use a client-side runtime to speed up execution, so `console.log` calls won't always show up in Devvit logs or Devvit playtest commands. However, these calls will show up in other dev tools (like Chrome) when viewing the app during a playtest. - -::: ## Historical logs