Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion backend/.env.example
Original file line number Diff line number Diff line change
Expand Up @@ -90,4 +90,10 @@ RATE_LIMIT_ENABLED=true
# Controls which proxy headers are trusted for IP extraction in rate limiting.
# Set to 'cloudflare' to trust CF-Connecting-IP, 'akamai' for True-Client-IP.
# Leave empty to use the direct socket IP only (all proxy headers are ignored).
TRUSTED_PROXY=
TRUSTED_PROXY=

# Agents
# Comma-separated list of enabled agent IDs. Empty = all enabled. (default: '')
ENABLED_AGENTS=
# Allow users to register custom agents with arbitrary URLs. (default: false)
ALLOW_CUSTOM_AGENTS=false
28 changes: 28 additions & 0 deletions backend/drizzle/0013_next_ulik.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
CREATE TABLE "powersync"."agents" (
"id" text NOT NULL,
"name" text,
"type" text,
"transport" text,
"command" text,
"args" text,
"url" text,
"auth_method" text,
"icon" text,
"is_system" integer DEFAULT 0,
"enabled" integer DEFAULT 1,
"registry_id" text,
"installed_version" text,
"registry_version" text,
"distribution_type" text,
"install_path" text,
"package_name" text,
"description" text,
"default_hash" text,
"deleted_at" timestamp,
"user_id" text NOT NULL,
CONSTRAINT "agents_id_user_id_pk" PRIMARY KEY("id","user_id")
);
--> statement-breakpoint
ALTER TABLE "powersync"."chat_threads" ADD COLUMN "agent_id" text;--> statement-breakpoint
ALTER TABLE "powersync"."agents" ADD CONSTRAINT "agents_user_id_user_id_fk" FOREIGN KEY ("user_id") REFERENCES "public"."user"("id") ON DELETE cascade ON UPDATE no action;--> statement-breakpoint
CREATE INDEX "idx_agents_user_id" ON "powersync"."agents" USING btree ("user_id");
Loading
Loading