Skip to content

Commit

Permalink
feat(routes): add Farcaster post URL meta tag
Browse files Browse the repository at this point in the history
enhance communication with Farcaster by including post URL
  • Loading branch information
nekofar committed Sep 26, 2024
1 parent b5f5f0b commit 2f3d78e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/routes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,7 @@ pub async fn handle_redirect<D>(req: Request, ctx: RouteContext<D>) -> worker::R
<meta property="fc:frame:button:1" content="{}" />
<meta property="fc:frame:button:1:action" content="link">
<meta property="fc:frame:button:1:target" content="https://warpcast.com/~/composer-action?url={}&view=prompt" />
<meta property="fc:frame:post_url" content= "https://warpcast.com/~/composer-action?url={}&view=prompt">
<meta http-equiv="refresh" content="3; url={}" />
Expand Down Expand Up @@ -202,6 +203,7 @@ pub async fn handle_redirect<D>(req: Request, ctx: RouteContext<D>) -> worker::R
image, // Farcaster Image
"Read", // Farcaster Button #1
mini_app_url, // Farcaster Composer URL
mini_app_url, // Farcaster Post URL
url, // Page Refresh URL
encode_safe(&title), // Page Title
encode_safe(&description), // Page Description
Expand Down

0 comments on commit 2f3d78e

Please sign in to comment.