@devvit/protos 0.11.20-next-2025-07-23-16-35-06-4e9bd2820.0 → 0.11.20-next-2025-07-23-18-03-59-68cb855f3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -7,7 +7,29 @@ import "google/protobuf/struct.proto";
7
7
  option go_package = "github.snooguts.net/reddit/reddit-devplatform-monorepo/go-common/generated/protos/types/devvit/ui/effects/web_view/v1alpha";
8
8
  option java_package = "com.reddit.devvit.ui.effects.web_view.v1alpha";
9
9
 
10
+ // Initialization data sent from the client (Shreddit, Android, iOS) to the
11
+ // web view.
12
+ message BridgeContext {
13
+ // to-do: use webbit_token once it is a superset of DevvitPostData and a
14
+ // decoder is available.
15
+ DevvitPostData post_data = 1 [deprecated = true];
16
+ ShareParam share_param = 2;
17
+ // to-do: use webbit_token once it is a superset of WebViewContext.
18
+ WebViewContext web_view_context = 3 [deprecated = true];
19
+ // Signed WebbitToken user JWT (header, payload, signature base64 strings
20
+ // separated by dots). Users shouldn't share their JWTs with others, but
21
+ // perfectly fine for a given user to see. Named WebbitToken to match GQL's
22
+ // definition. Eg:
23
+ // eyJhbGciOiJIUzI1NiIsImtpZCI6ImVlYzJjOWUzLWM0NTctNTM3Zi05NThmLTI5MDg3N2U4NjNlYyIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJkZXZ2aXQtZ2F0ZXdheS5yZWRkaXQuY29tIiwiYXVkIjpbIjhlMGUwZWI3LTc0NzgtNGVmMS1hNGZmLTk5NTlmMTkzZmNkMC0wLTAtOS13ZWJ2aWV3LmRldnZpdC5uZXQiXSwiZXhwIjoxNzUzMzcxODU2LCJuYmYiOjE3NTMyODU0NTYsImlhdCI6MTc1MzI4NTQ1NiwianRpIjoiYTA5NWMyOTktOWJkNS00MGUzLWEyYTEtYzhkYTBiMDc0ZjRhIiwiZGV2dml0LXBvc3QtaWQiOiJ0M18xbTdjcHZxIiwiZGV2dml0LXBvc3QtZGF0YSI6e30sImRldnZpdC11c2VyLWlkIjoidDJfazZsZGJqaDMiLCJkZXZ2aXQtaW5zdGFsbGF0aW9uIjoiOGUwZTBlYjctNzQ3OC00ZWYxLWE0ZmYtOTk1OWYxOTNmY2QwIn0.6M4NKCUsB4kWhZmslE909IL-hf2FAVMrkjB-peaHLHc
24
+ string webbit_token = 4;
25
+ // Untrusted unknown debug user data passed in the case-insensitive
26
+ // `devvitdebug` query param of the hosting
27
+ // window (eg, `reddit.com?devvitdebug=...`).
28
+ string devvit_debug = 5;
29
+ }
30
+
10
31
  message WebViewContext {
32
+ option deprecated = true;
11
33
  // Subreddit Thing ID (t5)
12
34
  string subreddit_id = 1;
13
35
  string subreddit_name = 2;
@@ -28,3 +50,26 @@ message DevvitPostData {
28
50
  // Developer-provided data on the Post, in JSON format. This is what developers set via submitPost({ postData: {...} }). Eg: { "riddle": "hello world" }
29
51
  google.protobuf.Struct developer_data = 2;
30
52
  }
53
+
54
+ // App deep link. Passed in case-insensitive `devvitshare` query param of the
55
+ // hosting window (eg, `reddit.com?devvitshare=...`) as user data.
56
+ //
57
+ // url.searchParams.set(
58
+ // JSON.stringify({params: {foo: 'bar'}, path: '/a/b/c/index.html', hash: '#abc'} satisfies ShareParam) // Encodes.
59
+ // )
60
+ // const shareParam: ShareParam | undefined = JSON.parse(
61
+ // url.searchParams.get('devvitshare') || '{}' // Decodes.
62
+ // ) ?? undefined
63
+ // ...Verify user data...
64
+ //
65
+ // Links are always assumed to use PDP.
66
+ message ShareParam {
67
+ // Everything after and including the first /. Aligns to
68
+ // https://developer.mozilla.org/en-US/docs/Web/API/URL/pathname.
69
+ string path = 1;
70
+ // URL query parameters (key-value).
71
+ map<string, string> params = 2;
72
+ // Everything after and including the first #. Aligns to
73
+ // https://developer.mozilla.org/en-US/docs/Web/API/URL/hash.
74
+ string hash = 3;
75
+ }
@@ -7,7 +7,29 @@ import "google/protobuf/struct.proto";
7
7
  option go_package = "github.snooguts.net/reddit/reddit-devplatform-monorepo/go-common/generated/protos/types/devvit/ui/effects/web_view/v1alpha";
8
8
  option java_package = "com.reddit.devvit.ui.effects.web_view.v1alpha";
9
9
 
10
+ // Initialization data sent from the client (Shreddit, Android, iOS) to the
11
+ // web view.
12
+ message BridgeContext {
13
+ // to-do: use webbit_token once it is a superset of DevvitPostData and a
14
+ // decoder is available.
15
+ DevvitPostData post_data = 1 [deprecated = true];
16
+ ShareParam share_param = 2;
17
+ // to-do: use webbit_token once it is a superset of WebViewContext.
18
+ WebViewContext web_view_context = 3 [deprecated = true];
19
+ // Signed WebbitToken user JWT (header, payload, signature base64 strings
20
+ // separated by dots). Users shouldn't share their JWTs with others, but
21
+ // perfectly fine for a given user to see. Named WebbitToken to match GQL's
22
+ // definition. Eg:
23
+ // eyJhbGciOiJIUzI1NiIsImtpZCI6ImVlYzJjOWUzLWM0NTctNTM3Zi05NThmLTI5MDg3N2U4NjNlYyIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJkZXZ2aXQtZ2F0ZXdheS5yZWRkaXQuY29tIiwiYXVkIjpbIjhlMGUwZWI3LTc0NzgtNGVmMS1hNGZmLTk5NTlmMTkzZmNkMC0wLTAtOS13ZWJ2aWV3LmRldnZpdC5uZXQiXSwiZXhwIjoxNzUzMzcxODU2LCJuYmYiOjE3NTMyODU0NTYsImlhdCI6MTc1MzI4NTQ1NiwianRpIjoiYTA5NWMyOTktOWJkNS00MGUzLWEyYTEtYzhkYTBiMDc0ZjRhIiwiZGV2dml0LXBvc3QtaWQiOiJ0M18xbTdjcHZxIiwiZGV2dml0LXBvc3QtZGF0YSI6e30sImRldnZpdC11c2VyLWlkIjoidDJfazZsZGJqaDMiLCJkZXZ2aXQtaW5zdGFsbGF0aW9uIjoiOGUwZTBlYjctNzQ3OC00ZWYxLWE0ZmYtOTk1OWYxOTNmY2QwIn0.6M4NKCUsB4kWhZmslE909IL-hf2FAVMrkjB-peaHLHc
24
+ string webbit_token = 4;
25
+ // Untrusted unknown debug user data passed in the case-insensitive
26
+ // `devvitdebug` query param of the hosting
27
+ // window (eg, `reddit.com?devvitdebug=...`).
28
+ string devvit_debug = 5;
29
+ }
30
+
10
31
  message WebViewContext {
32
+ option deprecated = true;
11
33
  // Subreddit Thing ID (t5)
12
34
  string subreddit_id = 1;
13
35
  string subreddit_name = 2;
@@ -28,3 +50,26 @@ message DevvitPostData {
28
50
  // Developer-provided data on the Post, in JSON format. This is what developers set via submitPost({ postData: {...} }). Eg: { "riddle": "hello world" }
29
51
  google.protobuf.Struct developer_data = 2;
30
52
  }
53
+
54
+ // App deep link. Passed in case-insensitive `devvitshare` query param of the
55
+ // hosting window (eg, `reddit.com?devvitshare=...`) as user data.
56
+ //
57
+ // url.searchParams.set(
58
+ // JSON.stringify({params: {foo: 'bar'}, path: '/a/b/c/index.html', hash: '#abc'} satisfies ShareParam) // Encodes.
59
+ // )
60
+ // const shareParam: ShareParam | undefined = JSON.parse(
61
+ // url.searchParams.get('devvitshare') || '{}' // Decodes.
62
+ // ) ?? undefined
63
+ // ...Verify user data...
64
+ //
65
+ // Links are always assumed to use PDP.
66
+ message ShareParam {
67
+ // Everything after and including the first /. Aligns to
68
+ // https://developer.mozilla.org/en-US/docs/Web/API/URL/pathname.
69
+ string path = 1;
70
+ // URL query parameters (key-value).
71
+ map<string, string> params = 2;
72
+ // Everything after and including the first #. Aligns to
73
+ // https://developer.mozilla.org/en-US/docs/Web/API/URL/hash.
74
+ string hash = 3;
75
+ }