adrielc/helios-alpha/golem-add-cors-rust

Trust tier 3
  • community
Source check pending

Checking that the SKILL.md file is still in the repository.

Configuring CORS for Rust HTTP endpoints. Use when the user asks to enable CORS, allow cross-origin requests, or configure allowed origins for HTTP endpoints.

Install

npx vskill@latest install adrielc/helios-alpha/golem-add-cors-rust

SKILL.md

Configuring CORS for Rust HTTP Endpoints

Mount-Level CORS

Set cors on #[agent_definition] to apply allowed origins to all endpoints:

rust
#[agent_definition(
mount = "/api/{name}",
cors = ["https://app.example.com"]
)]
pub trait MyAgent {
fn new(name: String) -> Self;
#[endpoint(get = "/data")]
fn get_data(&self) -> Data;
// Allows https://app.example.com
}

Endpoint-Level CORS

Set cors on #[endpoint] to add allowed origins for a specific endpoint. Origins are unioned with mount-level CORS:

rust
#[agent_definition(
mount = "/api/{name}",
cors = ["https://app.example.com"]
)]
pub trait MyAgent {
fn new(name: String) -> Self;
#[endpoint(get = "/data", cors = ["*"])]
fn get_data(&self) -> Data;
// Allows BOTH https://app.example.com AND * (all origins)
#[endpoint(get = "/other")]
fn get_other(&self) -> Data;
// Inherits mount-level: only https://app.example.com
}

Wildcard

Use "*" to allow all origins:

rust
#[agent_definition(mount = "/public/{name}", cors = ["*"])]
pub trait PublicAgent {
fn new(name: String) -> Self;
}

CORS Preflight

Golem automatically handles OPTIONS preflight requests for endpoints that have CORS configured. The preflight response includes Access-Control-Allow-Origin, Access-Control-Allow-Methods, and Access-Control-Allow-Headers headers.

Security

  • Security scanPassed, 100 of 100Pattern checks on the skill's files.
  • Model reviewPassed

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

7-day trend score
5

Not refreshed yet.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/adrielc/helios-alpha/golem-add-cors-rust/badge)](https://verified-skill.com/skills/adrielc/helios-alpha/golem-add-cors-rust)

Something wrong with this skill or its page? Tell us.