Skip to content

Route exact owner Threads approvals through the Relay publisher - #23

Merged
AyobamiH merged 10 commits into
mainfrom
fix/threads-controlled-handoff
Nov 3, 2026
Merged

AyobamiH merged 10 commits into
mainfrom
fix/threads-controlled-handoff

Conversation

@AyobamiH

@AyobamiH AyobamiH commented Nov 3, 2026 •

Copy link
Copy Markdown
Collaborator

Problem

The owner's existing Threads Publish now job could not reach the authenticated local publisher from the hosted worker. A grant alone did not supply the missing transport.

Changes

  • Add a bounded authenticated HTTPS handoff to the existing local Relay publisher.
  • Bind the original tenant, queue, job, account generation, approved text and the actual publication attempt/dispatch operation.
  • Check relay readiness before claiming the job.
  • Persist a local dispatch fence before the provider call and preserve accepted and verified receipts across restart.
  • Recover an interrupted response through read-only activity and post inspection; an unresolved outcome never permits another send.
  • Keep provider credentials on the local publisher and preserve the database connection/approval fence.

Validation

  • Isolated npm run ci passed at eb7cabd3cfb3a3e0051090907959bfa4463f2196.
  • GitHub build-test and authenticated readiness checks passed for the same commit; Cloudflare build also passed.
  • The hosted immutable version completed the original approved Threads job on 3 November 2026: one claim, one completed job, zero failures.
  • Production has exactly one publication attempt and one history row. Independent provider readback matched the approved text and account, and the product attempt is verified.
  • Published Threads post.
  • Restarted the local service and recovered the same exact receipt through the authenticated receipt-only request. Unauthenticated requests return 404.

Rollout scope

This is an exact owner approval path. General customer generation and dispatch remain separately gated. Instagram and the broader customer journey retain their independent acceptance requirements.

Detailed production evidence: AyobamiH/oneclickpostfactory#46.

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Nov 3, 2026 •

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
oneclickpostfactory-agent eb7cabd Commit Preview URL

Branch Preview URL
Nov 03 2026, 01:32 PM

@AyobamiH
AyobamiH marked this pull request as ready for review November 3, 2026 13:45
@AyobamiH
AyobamiH merged commit 3ed0be7 into main Nov 3, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant