Something went wrong. Try again.
Monorepo for Aesthetic.Computer aesthetic.computer
Something went wrong. Try again.
Markdown
DP1 Feed Integration - Quick Summary #
✅ What's Been Completed #
1. Repository Setup #
- ✅ Cloned
feral-file/dp1-feedinto/workspaces/aesthetic-computer/feed/dp1-feed/ - ✅ Installed dependencies (
npm install) - ✅ Installed
wranglerCLI globally - ✅ Updated
wrangler.tomlforfeed.aesthetic.computerdomain
2. Docker Container #
- ✅ Added
ripgrepto.devcontainer/Dockerfile - ✅ Installed
ripgrepin current container session
3. Cloudflare Credentials #
- ✅ Found existing credentials in
dark-window/conductor.env:- Email:
me@jas.life - API Token:
YOUR_CLOUDFLARE_API_KEY_HERE - Account/Zone ID:
a23b54e8877a833a1cf8db7765bce3ca
- Email:
4. Created Scripts #
- ✅
dp1-feed/setup-resources.fish- Creates KV namespaces and queues - ✅
dp1-feed/deploy-feed.fish- Deploys worker to production/dev - ✅ Both scripts are executable
5. Updated Main Package.json #
Added convenience commands:
npm run feed:dev- Run local dev servernpm run feed:setup- Create Cloudflare resourcesnpm run feed:deploy- Deploy to productionnpm run feed:deploy:dev- Deploy to devnpm run feed:test- Run API testsnpm run feed:logs- Watch production logs
6. Documentation #
- ✅
DP1-FEED-SETUP.md- Complete deployment guide (root) - ✅
dp1-feed/AESTHETIC-COMPUTER-SETUP.md- Detailed technical reference
🚀 Next Steps (What You Need to Do) #
1. Authenticate Wrangler (1 minute) #
cd /workspaces/aesthetic-computer/dp1-feed
wrangler login
This will open a browser for authentication.
2. Create Resources (2 minutes) #
npm run feed:setup
# Choose option 2 for Production
Important: Save the KV namespace IDs from the output!
3. Update wrangler.toml (1 minute) #
Edit dp1-feed/wrangler.toml and replace the placeholder IDs in the [env.production.kv_namespaces] sections with the IDs from step 2.
4. Set Secrets (3 minutes) #
cd /workspaces/aesthetic-computer/dp1-feed
# Generate and set API secret
openssl rand -hex 32 | wrangler secret put API_SECRET --env production
# Generate keys and set Ed25519 private key
npm run jwt:generate-keys
cat private-key.txt | wrangler secret put ED25519_PRIVATE_KEY --env production
Save your API secret - you'll need it to make write requests!
5. Deploy (1 minute) #
npm run feed:deploy
6. Configure Custom Domain (2 minutes) #
Go to https://dash.cloudflare.com/:
- Workers & Pages > aesthetic-feed
- Settings > Domains & Routes
- Add Custom Domain:
feed.aesthetic.computer
7. Test (1 minute) #
curl https://feed.aesthetic.computer/api/v1/health
📊 Stack Overview #
Technology #
- Runtime: Cloudflare Workers (serverless)
- Framework: Hono (fast web framework)
- Language: TypeScript
- Storage: Cloudflare KV (3 namespaces)
- Queue: Cloudflare Queues (async operations)
- Auth: Bearer token + optional JWT
API Compliance #
- OpenAPI 3.1.0 compliant
- DP-1 v1.0.0 specification
- Ed25519 signatures for playlists
- RFC 7240 async support
Resources Created #
Will create these in your Cloudflare account:
- 3 KV Namespaces (playlists, channels, items)
- 1 Queue (write operations)
- 1 Worker (the API server)
- 1 Custom Domain (feed.aesthetic.computer)
📖 Key Documentation #
- Start Here:
/workspaces/aesthetic-computer/DP1-FEED-SETUP.md - Technical Details:
/workspaces/aesthetic-computer/feed/dp1-feed/AESTHETIC-COMPUTER-SETUP.md - Original Docs:
/workspaces/aesthetic-computer/feed/dp1-feed/README.md - Development Guide:
/workspaces/aesthetic-computer/feed/dp1-feed/DEVELOPMENT.md
🎯 Quick Commands Reference #
# From repo root
npm run feed:dev # Local development
npm run feed:setup # Create Cloudflare resources
npm run feed:deploy # Deploy to production
npm run feed:logs # Watch logs
# From dp1-feed directory
./setup-resources.fish # Setup wizard
./deploy-feed.fish production # Deploy with confirmation
wrangler tail --env production # Live logs
wrangler secret list --env production # List secrets
🔗 Important URLs #
- API Endpoint: https://feed.aesthetic.computer/api/v1
- Cloudflare Dashboard: https://dash.cloudflare.com/a23b54e8877a833a1cf8db7765bce3ca/aesthetic.computer
- DNS Settings: https://dash.cloudflare.com/a23b54e8877a833a1cf8db7765bce3ca/aesthetic.computer/dns/records
- Original Repo: https://github.com/feral-file/dp1-feed
- DP-1 Spec: https://github.com/display-protocol/dp1
💡 Tips #
- Save your API_SECRET: You'll need it for all write operations
- KV Namespace IDs: Must be updated in wrangler.toml after creation
- DNS Propagation: May take a few minutes after domain setup
- Local Testing: Use
npm run feed:devbefore deploying - Monitor Logs: Use
npm run feed:logsto watch for errors
🆘 Need Help? #
See the troubleshooting section in DP1-FEED-SETUP.md for common issues and solutions.
Total Setup Time: ~10-15 minutes Status: Ready to deploy ✅