MergeTree Maxxer
MergeTree Maxxer
Explore posts from servers
CDCloudflare Developers
Created by MergeTree Maxxer on 2/17/2025 in #workers-help
I have mee stubbornly fighting this error on a Cloudflare Workers Slack app for over 5 hours :(
I could use some help. I'm experiencing a very frustrating error at the moment that I can't seem to find any documentation or a source for. All I'm getting in the Cloudflare Logs for my Slack app is:
Failed to authorize (error: SlackAPIError: Failed to call auth.test due to not_authed: {"ok":false,"error":"not_authed","headers":{}}, query: {"isEnterpriseInstall":false,"teamId":"T07TRN2EE85","userId":"U07TUHW4NPL"})",
Failed to authorize (error: SlackAPIError: Failed to call auth.test due to not_authed: {"ok":false,"error":"not_authed","headers":{}}, query: {"isEnterpriseInstall":false,"teamId":"T07TRN2EE85","userId":"U07TUHW4NPL"})",
Which doesn't tell me anything, because essentially copying the example from the slack-edge documentation exactly. The only thing I've been thinking that could be an issue is that apparently Slack doesn't respect JSON? This might be an old issue but apparently in 2017, the WebAPI doesn't support application/json. And I'm finding issues about this error up until 2024 that essentially just say the token isn't being passed. The problem is that the docs for the slack-cloudflare-workers docs don't say anything about special issues you may run into passing the token, and just give a barebones example. The error I also get on the webpage is this:
Please try again from here or contact the app owner (reason: The state parameter is missing or invalid)
Please try again from here or contact the app owner (reason: The state parameter is missing or invalid)
So something isn't getting passed, I just can't figure out what, and if it's a quirk of being an edge SDK or if it's something I messed up. Currently I only have set this URL set up as my redirect URL in the dashboard: - https://[redacted].workers.dev/slack/oauth_redirect And the events are getting the challenge param fine, so that's ok, but something is not letting me auth and install. References: https://github.com/slack-edge/slack-cloudflare-workers/blob/main/docs/oauth_app.md https://stackoverflow.com/questions/42009076/slack-webapi-fails-with-not-authed https://trailhead.salesforce.com/trailblazer-community/feed/0D5KX00000KhkXH0AZ
1 replies
PD🧩 Plasmo Developers
Created by MergeTree Maxxer on 3/7/2024 in #👾extension
Can't figure out how to navigate from my extention to my auth page
I'm trying to test a popup extension I made that has a button that is supposed to navigate to http://localhost:3000 when clicked:
<script>
import { fade } from 'svelte/transition';
function handleLoginClick() {
window.location.href = 'http://www.localhost:3000';
}
</script>

<div class="container" transition:fade>
<div class="header">
<img class="logo" src="https://www.dropbox.com/scl/fi/zd8sxq5w8dt0nhkm5d271/dunewordmark.png?rlkey=chxno12hj7kjy4zzb27k9rd3k&dl=1" alt="Dune Logo">
<div class="closeIcon">
<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M13.1102 3.96732C13.4077 3.66978 13.4077 3.18737 13.1102 2.88982C12.8126 2.59228 12.3302 2.59228 12.0327 2.88982L8 6.9225L3.96732 2.88982C3.66978 2.59228 3.18737 2.59228 2.88983 2.88982C2.59229 3.18737 2.59229 3.66978 2.88983 3.96732L6.92251 8L2.88983 12.0327C2.59229 12.3302 2.59229 12.8126 2.88983 13.1102C3.18737 13.4077 3.66978 13.4077 3.96732 13.1102L8 9.0775L12.0327 13.1102C12.3302 13.4077 12.8126 13.4077 13.1102 13.1102C13.4077 12.8126 13.4077 12.3302 13.1102 12.0327L9.0775 8L13.1102 3.96732Z" fill="#949FB1"></path></svg>
</div>
</div>
<script>
import { fade } from 'svelte/transition';
function handleLoginClick() {
window.location.href = 'http://www.localhost:3000';
}
</script>

<div class="container" transition:fade>
<div class="header">
<img class="logo" src="https://www.dropbox.com/scl/fi/zd8sxq5w8dt0nhkm5d271/dunewordmark.png?rlkey=chxno12hj7kjy4zzb27k9rd3k&dl=1" alt="Dune Logo">
<div class="closeIcon">
<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M13.1102 3.96732C13.4077 3.66978 13.4077 3.18737 13.1102 2.88982C12.8126 2.59228 12.3302 2.59228 12.0327 2.88982L8 6.9225L3.96732 2.88982C3.66978 2.59228 3.18737 2.59228 2.88983 2.88982C2.59229 3.18737 2.59229 3.66978 2.88983 3.96732L6.92251 8L2.88983 12.0327C2.59229 12.3302 2.59229 12.8126 2.88983 13.1102C3.18737 13.4077 3.66978 13.4077 3.96732 13.1102L8 9.0775L12.0327 13.1102C12.3302 13.4077 12.8126 13.4077 13.1102 13.1102C13.4077 12.8126 13.4077 12.3302 13.1102 12.0327L9.0775 8L13.1102 3.96732Z" fill="#949FB1"></path></svg>
</div>
</div>
But when I click it it throws this error:
popup.html#:14 Refused to execute inline event handler because it violates the following Content Security Policy directive: "script-src 'self' 'wasm-unsafe-eval' 'inline-speculation-rules' http://localhost:* http://127.0.0.1:*". Either the 'unsafe-inline' keyword, a hash ('sha256-...'), or a nonce ('nonce-...') is required to enable inline execution. Note that hashes do not apply to event handlers, style attributes and javascript: navigations unless the 'unsafe-hashes' keyword is present.
popup.html#:14 Refused to execute inline event handler because it violates the following Content Security Policy directive: "script-src 'self' 'wasm-unsafe-eval' 'inline-speculation-rules' http://localhost:* http://127.0.0.1:*". Either the 'unsafe-inline' keyword, a hash ('sha256-...'), or a nonce ('nonce-...') is required to enable inline execution. Note that hashes do not apply to event handlers, style attributes and javascript: navigations unless the 'unsafe-hashes' keyword is present.
7 replies