Back to skills
SKILL.md
Orpc Astro
ASecurityUse oRPC inside an Astro project.
- 8 stars
- 0 votes
- 0 copies
- 1 view
- Added September 12, 2026
Works with
Security analysis
100/100npx -y skills add ali-master/skills --skill orpc-astro --agent claude-codeAre you the author of Orpc Astro?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/ali-master-orpc-astro)---
name: oRPC Astro Adapter
description: Use oRPC inside an Astro project.
license: MIT
metadata:
author: Ali Torki
homepage: https://github.com/ali-master
version: "1.0.0"
---
# Astro Adapter
[Astro](https://astro.build/) is a JavaScript web framework optimized for fast, content-driven websites. For HTTP context, see the [HTTP Adapter](/docs/adapters/http) guide.
## Basic
```ts
// pages/rpc/[...rest].ts
import { RPCHandler } from '@orpc/server/fetch'
import { onError } from '@orpc/server'
const handler = new RPCHandler(router, {
interceptors: [
onError((error) => {
console.error(error)
}),
],
})
export const prerender = false
export const ALL: APIRoute = async ({ request }) => {
const { response } = await handler.handle(request, {
prefix: '/rpc',
context: {},
})
return response ?? new Response('Not found', { status: 404 })
}
```
> The `handler` can be any supported oRPC handler — `RPCHandler`, `OpenAPIHandler`, or a custom handler.
Attribution
Comments
Loading comments…
Newsletter
Get the weekly list of safe new skills, and the ones we pulled.