spinframework / spinframework/spin
add Methods set field to http trigger configuration options
Open
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 6.5k
- Forks
- 310
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 24
Description
[[trigger.http]]
route = "/hello"
methods: ["GET", "POST"]
This way a component will only be executed if route and method matches. Omitting the methods section would result in current behavior of the component being executed regardless of request method.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the Rust code that parses and applies the [[trigger.http]] configuration, then inspect how route matching currently handles request methods. Add support for an optional methods list and verify that matching methods execute the component, while omitting the list preserves current behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- api, backend
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 50/100