소스 정보
- 저장소
- majiayu000/claude-skill-registry
- 최근 소스 활동
- 2026년 6월 23일 12:15
- 감지된 SKILL.md 언어
- 영어
- 스타
- 543
- 포크
- 85
설치 방법
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
소스 파일 검토
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
메뉴
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
직접 명령은 검토 Prompt를 거치지 않습니다. 실행하기 전에 소스를 확인하세요.
npx skills add https://github.com/majiayu000/claude-skill-registry --skill openapi-types명령은 한 줄로 유지됩니다. 복사하기 전에 가로로 스크롤해 전체 내용을 확인하세요.
로컬 사본을 원하시나요? SkillsMP에서 현재 제공할 수 있는 파일을 다운로드하세요.
LLM token logprobs and calibration. Per-decision confidence, ECE, Brier, reliability diagrams, low-confidence triage.
Analyze LLM token logprobs and calibration. Use for per-decision confidence, ECE, Brier scores, reliability diagrams, and low-confidence triage.
回顾最近 N 天的 Claude Code 使用记录——扫描原始会话数据,按主题分组汇总"我都做了什么",并从个人操作系统视角输出模式、风险与增删建议。当用户说 /recap、"看看我这几天做了什么"、"回顾一下我最近的会话"、"这两天我用 claude 干了啥"、"活动回顾" 时使用。
SOC 직업 분류 기준
SKILL.md 표시 중
| name | openapi-types |
| description | Generate TypeScript types and client SDKs from OpenAPI specs |
| disable-model-invocation | true |
I'll generate TypeScript types, client SDKs, and Zod schemas from OpenAPI 3.0 specifications.
Arguments: $ARGUMENTS - path to OpenAPI spec file
Features:
/api-docs-generateThis skill uses code generation-specific patterns to minimize token usage:
Pattern: Cache parsed OpenAPI specification structure
.openapi-types-cache (1 hour TTL)Pattern: Use openapi-generator-cli or swagger-cli for validation
swagger-cli validate spec.yaml (200 tokens)Pattern: Use openapi-typescript or openapi-generator templates
openapi-typescript spec.yaml -o types.ts (300 tokens)Pattern: Detect if types already generated and current
Pattern: Analyze first 20 schemas for patterns
Pattern: Generate only changed schemas
Pattern: Cache openapi-typescript installation status
Pattern: Use openapi-typescript tool directly
Typical operation patterns:
Expected per-generation: 2,000-3,000 tokens (50% reduction from 4,000-6,000 baseline) Real-world average: 900 tokens (due to cached specs, early exit, tool-based generation)
#!/bin/bash
# Detect OpenAPI specifications
echo "=== Detecting OpenAPI Specifications ==="
echo ""
# Find OpenAPI spec files
find_openapi_specs() {
find . -type f \( \
-name "openapi*.yaml" -o \
-name "openapi*.yml" -o \
-name "swagger*.json" -o \
-name "swagger*.yaml" -o \
-name "api-spec*.yaml" \
\) ! -path "*/node_modules/*" 2>/dev/null
}
SPECS=$(find_openapi_specs)
if [ -z "$SPECS" ]; then
echo "❌ No OpenAPI specifications found"
echo ""
echo "Looking for files like:"
echo " - openapi.yaml"
echo " - swagger.json"
echo " - docs/api-spec.yaml"
echo ""
echo "💡 Generate OpenAPI spec with: claude \"/api-docs-generate\""
exit 1
fi
echo "✓ Found OpenAPI specifications:"
echo "$SPECS" | sed 's/^/ /'
echo ""
# Select spec file
if [ -n "" ];
SPEC_FILE=
SPEC_FILE=$( | -1)
[ ! -f ];
1
() {
-v swagger-cli &> /dev/null;
npx swagger-cli validate
}
validate_spec
// Generated TypeScript types from OpenAPI spec
// Auto-generated - do not edit manually
/**
* OpenAPI spec: ${SPEC_FILE}
* Generated: ${DATE}
*/
export namespace API {
/**
* Common types
*/
export type UUID = string;
export type ISODate = string;
export type Email = string;
/**
* User schema
*/
export interface User {
/** Unique user identifier */
id: UUID;
/** User's email address */
email: Email;
/** User's display name */
name: string;
/** User role for authorization */
role: 'admin' | 'user' | 'guest';
/** Account creation timestamp */
createdAt: ISODate;
/** Last update timestamp */
updatedAt: ISODate;
/** Optional user profile */
profile?: UserProfile;
}
/**
* User profile schema
*/
export {
?: ;
?: ;
?: ;
?: {
?: ;
?: ;
?: ;
};
}
{
: ;
: ;
: ;
?: | ;
}
{
?: ;
?: <>;
}
{
: ;
: ;
}
{
: ;
?: ;
}
{
: [];
: ;
}
{
: ;
: ;
: ;
}
{
: {
: ;
: ;
?: <, >;
};
: ;
}
{
: ;
: ;
: ;
: ;
: ;
: ;
}
{
?: ;
?: ;
?: ;
?: | | ;
?: | ;
}
{
: ;
}
{
= ;
= ;
= ;
= ;
= ;
= ;
= ;
}
}
// Zod schemas for runtime validation
import { z } from 'zod';
/**
* User schema
*/
export const UserSchema = z.object({
id: z.string().uuid(),
email: z.string().email(),
name: z.string().min(1).max(255),
role: z.enum(['admin', 'user', 'guest']),
createdAt: z.string().datetime(),
updatedAt: z.string().datetime(),
profile: z
.object({
bio: z.string().optional(),
avatarUrl: z.string().url().optional(),
location: z.string().optional(),
socialLinks: z
.object({
twitter: z.string().url().optional(),
github: z.().().(),
: z.().().(),
})
.(),
})
.(),
});
= z.< >;
= z.({
: z.().(),
: z.().().(),
: z.().().(),
: z.([, ]).(),
});
= z.< >;
= z.({
: z.().().().(),
: z
.({
: z.().(),
: z.().().(),
: z.().(),
})
.()
.(),
});
= z.< >;
= z.({
: z.().(),
: z.().(),
});
= z.< >;
= z.({
: ,
: z.().(),
});
= z.< >;
= z.({
: z.(),
: z.({
: z.().().(),
: z.().().(),
: z.().().(),
: z.().().(),
: z.(),
: z.(),
}),
});
= z.< >;
= z.({
: z.({
: z.(),
: z.(),
: z.(z.()).(),
}),
: z.().(),
});
= z.< >;
(): {
.(data);
}
(): {
.(data);
}
(): data is {
.(data).;
}
// Type-safe fetch client SDK
import type { API } from './types';
/**
* API client configuration
*/
export interface ClientConfig {
baseURL: string;
headers?: Record<string, string>;
timeout?: number;
}
/**
* API client error
*/
export class APIError extends Error {
constructor(
public status: number,
public code: string,
message: string,
public details?: unknown
) {
super(message);
this.name = 'APIError';
}
}
/**
* Type-safe API client
*/
export class APIClient {
private baseURL: string;
private headers: Record<string, string>;
: ;
() {
. = config..(, );
. = {
: ,
...config.,
};
. = config. || ;
}
(: ): {
.[] = ;
}
(): {
.[];
}
request<T>(
: ,
: ,
?: {
?: <, >;
?: ;
?: <, >;
}
): <T> {
url = ();
(options?.) {
.(options.).( {
(value !== && value !== ) {
url..(key, (value));
}
});
}
controller = ();
timeoutId = ( controller.(), .);
{
response = (url.(), {
method,
: { ...., ...options?. },
: options?. ? .(options.) : ,
: controller.,
});
(timeoutId);
(!response.) {
error = response.().( ({}));
(
response.,
error.?. || ,
error.?. || response.,
error.?.
);
}
(response. === ) {
T;
}
response.();
} (error) {
(timeoutId);
(error ) {
error;
}
(error && error. === ) {
(, , );
}
(
,
,
error ? error. :
);
}
}
users = {
:
.<.>(, , { params }),
:
.<.>(, ),
:
.<.>(, , { : data }),
:
.<.>(, , {
: data,
}),
:
.<>(, ),
};
auth = {
:
.<.>(, , {
: data,
}),
: .<>(, ),
};
}
(): {
(config);
}
apiClient = ({
: process.. || ,
});
// React hooks for data fetching
import { useQuery, useMutation, useQueryClient } from '@tanstack/react-query';
import type { API } from './types';
import { apiClient } from './client';
/**
* Hook to list users
*/
export function useUsers(params?: API.ListUsersParams) {
return useQuery({
queryKey: ['users', params],
queryFn: () => apiClient.users.list(params),
});
}
/**
* Hook to get user by ID
*/
export function useUser(userId: string) {
return useQuery({
queryKey: ['users', userId],
queryFn: () => apiClient.users.get(userId),
enabled: !!userId,
});
}
/**
* Hook to create user
*/
export function useCreateUser() {
const queryClient = useQueryClient();
return ({
:
apiClient..(data),
: {
queryClient.({ : [] });
},
});
}
() {
queryClient = ();
({
: apiClient..(userId, data),
: {
queryClient.({ : [, variables.] });
queryClient.({ : [] });
},
});
}
() {
queryClient = ();
({
: apiClient..(userId),
: {
queryClient.({ : [] });
},
});
}
() {
({
: apiClient..(data),
: {
apiClient.(response.);
.(, response.);
},
});
}
() {
queryClient = ();
({
: apiClient..(),
: {
apiClient.();
.();
queryClient.();
},
});
}
// Example: Using the generated client in a React component
import { useUsers, useCreateUser } from './api/hooks';
export function UsersPage() {
const { data, isLoading, error } = useUsers({ page: 1, limit: 10 });
const createUser = useCreateUser();
const handleCreateUser = async () => {
try {
await createUser.mutateAsync({
email: 'user@example.com',
name: 'John Doe',
password: 'secure-password',
});
alert('User created!');
} catch (error) {
console.error('Failed to create user:', error);
}
};
if (isLoading) return <div>Loading...</div>;
if (error) return <div>Error: {error.message}</div>;
return (
<div>
Users
Create User
{data?.data.map((user) => (
{user.name}
))}
);
}
// Example: Using the client directly (non-React)
import { apiClient } from './api/client';
async function fetchUsers() {
try {
const response = await apiClient.users.list({ page: 1, limit: 10 });
console.log('Users:', response.data);
console.log('Pagination:', response.pagination);
} catch (error) {
if (error instanceof APIError) {
console.error(`API Error (${error.status}):`, error.message);
} else {
console.error('Unknown error:', error);
}
}
}
echo ""
echo "=== ✓ OpenAPI Type Generation Complete ==="
echo ""
echo "📁 Generated files:"
echo " - src/api/types.ts # TypeScript types"
echo " - src/api/schemas.ts # Zod validation schemas"
echo " - src/api/client.ts # Fetch client SDK"
echo " - src/api/hooks.ts # React hooks"
echo ""
echo "📦 Install dependencies:"
echo " npm install zod @tanstack/react-query"
echo ""
echo "🚀 Usage:"
echo ""
echo "# In React components:"
echo "import { useUsers, useCreateUser } from './api/hooks';"
echo ""
echo "# Direct client usage:"
echo "import { apiClient } from './api/client';"
echo "const users = await apiClient.users.list();"
echo ""
echo "💡 Integration points:"
echo " - /api-docs-generate - Generate OpenAPI spec"
echo " - /api-test-generate - Generate API tests"
echo
Type Safety:
Client SDK:
Integration Points:
/api-docs-generate - OpenAPI spec generation/api-test-generate - API tests/mock-generate - Mock dataImportant: I will NEVER add AI attribution.
Credits: Based on openapi-typescript, Zod, React Query, and API client patterns from tRPC, GraphQL clients, and REST API best practices.