frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Back end where you just define schema, access policy, and functions

3•emilss•1d ago
Would you use a backend where you just define schema, access policy, and functions?

Basically something like making smart contracts on EVM, but instead they run on a hyperscaler, and have regular backend fundamentals.

Here's a mock frenchie made me, was thinking something like this:

schema User { email: string @private(owner) name: string @public balance: number @private(owner, admin) }

policy { User.read: owner OR role("admin") User.update.balance: role("admin") }

function transfer(from: User, to: User, amount: number) { assert(caller == from.owner OR caller.role == "admin") assert(from.balance >= amount) from.balance -= amount to.balance += amount }

Was playing with OpenFGA, and AWS Lambda stuff, and got me thinking about this.

So you would "deploy" this contract on a hyperscaler, which then let's users access it from your lean js front-end, via something like this:

const res = await fetch("https://api.hyperscaler-example.com/c/your-contract-id/transfer", { method: "POST", headers: { "Authorization": "Bearer <user-jwt>", "Content-Type": "application/json" }, body: JSON.stringify({ from: "user_abc", to: "user_xyz", amount: 50 }) });

The runtime resolves the caller identity from the JWT, checks the policy rules, runs the function, handles the encryption/decryption of fields and so your frontend never touches any of that.

That's it, would you use it? Is there something that does this exactly already? Feeling like building this.

Comments

verdverm•1d ago
There are a lot of versions of this already, the main blocker is people not wanting to learn a bespoke DSL.

The second problem is the escape latch story, how do people customize beyond the functions when they inevitably reach that point. If you haven't hit this, you haven't built complex enough applications yet with your framework.

The elephant in the room is, why this instead of Ai? (I personally have an answer to this question, in the scope of my take on the framework described in your post)

ChatGPT finds an error in Terence Tao's math research

2•codexon•31m ago•0 comments

Ask HN: What is up with all the glitchy and off-topic comments?

3•marginalia_nu•1h ago•1 comments

Ask HN: How do you know if AI agents will choose your tool?

15•dmpyatyi•5h ago•6 comments

Ask HN: Chromebook leads for K-8 school in need?

42•techteach00•1d ago•42 comments

Ask HN: Where do you save links, notes and random useful stuff?

5•a_protsyuk•4h ago•13 comments

Ask HN: Is it better to have no Agent.md than a bad one?

4•parvardegr•8h ago•2 comments

GLP-1 Second-Order Effects

19•7777777phil•7h ago•9 comments

Ask HN: Are developers who build libs and dev tools safer from AI replacement?

2•danver0•3h ago•2 comments

Ask HN: Programmable Watches with WiFi?

11•dakiol•2d ago•5 comments

So Claude's stealing our business secrets, right?

25•arm32•1d ago•16 comments

Ask HN: What breaks when you run AI agents unsupervised?

11•marvin_nora•1d ago•6 comments

Ask HN: How are early-stage AI startups thinking about IP protection?

4•shaheeniquebal•18h ago•3 comments

Ask HN: Why doesn't HN have a rec algorithm?

9•sujayk_33•1d ago•17 comments

Ask HN: Cognitive Offloading to AI

11•daringrain32781•1d ago•5 comments

Ask HN: What Comes After Markdown?

7•YuukiJyoudai•1d ago•13 comments

Back end where you just define schema, access policy, and functions

3•emilss•1d ago•5 comments

I'm 15 and built a platform for developers to showcase WIP projects

12•amin2011•2d ago•6 comments

Ask HN: Is there a reliable way to tell if an image is AI generated?

8•leandrobon•1d ago•9 comments

Ask HN: If the "AI bubble" pops, will it really be that dramatic?

14•moomoo11•2d ago•12 comments

Tell HN: Claude mangles XML files with <name> as an XML Tag to <n>

9•exabrial•1d ago•3 comments

I made my favorite AI tool

4•sebringj•1d ago•4 comments

Should I add this acknowledgement/shoutout by xAI/Grok to my resume?

2•aehsan4004•1d ago•7 comments

Ask HN: Why don't software developers make medical devices?

7•piratesAndSons•2d ago•19 comments

Open-Source Bionic Reading Chrome Extension (MIT)

2•sdgnbs•1d ago•1 comments

Orvia – Spin up a real-time room, share files, leave – everything disappears

2•yc_surajkr•1d ago•2 comments

Ask HN: How do new blogs break the backlink–indexing loop?

4•lilcodingthings•1d ago•4 comments

Ask HN: Is it worth learning Vim in 2026?

34•zekejohn•3d ago•35 comments

Ask HN: Is there a workaround in OpenClaw for tab not found

2•jinen83•19h ago•0 comments

Peer validation platform for engineering skills (inspired by X community notes)

4•ms_sv•2d ago•16 comments

Ask HN: Do US presidents have less fiduciary liability than CEOs?

6•stopbulying•1d ago•18 comments