Add internal provision endpoint for rSpace Registry
Simple acknowledge endpoint — no DB to provision. Returns ok status when called by the registry during space activation. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
f5df44b7a5
commit
1c9130aa2a
|
|
@ -0,0 +1,17 @@
|
|||
import { NextResponse } from "next/server";
|
||||
|
||||
/**
|
||||
* Internal provision endpoint — called by rSpace Registry when activating
|
||||
* this app for a space. No auth required (only reachable from Docker network).
|
||||
*
|
||||
* rfunds has no server-side database — spaces are managed client-side.
|
||||
* This endpoint acknowledges the provisioning request.
|
||||
*/
|
||||
export async function POST(request: Request) {
|
||||
const body = await request.json();
|
||||
const space: string = body.space?.trim();
|
||||
if (!space) {
|
||||
return NextResponse.json({ error: "Missing space name" }, { status: 400 });
|
||||
}
|
||||
return NextResponse.json({ status: "ok", space, message: "rfunds is client-side, no provisioning needed" });
|
||||
}
|
||||
Loading…
Reference in New Issue