agentleFS
greekr4greekr4/viruagent-cli/.claude/skills/provider-build/skill.md

provider-build

Skill39 starsChanged 8 months agoMITView on GitHub

viruagent-cli에 새 프로바이더를 추가하거나 기존 프로바이더를 수정한다. 프로바이더 코드 구현, 커맨드 등록, CLI 연결 작업을 수행. '프로바이더 추가', '프로바이더 수정', '새 기능 구현', '카페 프로바이더', 'provider' 등을 언급하면 이 스킬을 사용할 것.

The file

Files
skill.md

Provider Builder

viruagent-cli의 프로바이더를 구현/수정한다.

프로바이더 패턴

파일 구조

src/providers/{name}/
├── index.js          # createXxxProvider 팩토리
├── auth.js           # 인증 (HTTP or Playwright)
├── session.js        # 세션 영속화 + rate limit
├── apiClient.js      # API 호출 레이어
└── utils.js          # 유틸리티

팩토리 패턴

const createXxxProvider = ({ sessionPath } = {}) => {
  // 세션, API 클라이언트 초기화
  return {
    id: 'xxx',
    name: 'XXX',
    login: async (opts) => { /* ... */ },
    authStatus: async () => { /* ... */ },
    logout: async () => { /* ... */ },
    publish: async (opts) => { /* ... */ },
    // 프로바이더별 추가 메서드
  };
};
module.exports = { createXxxProvider };

등록 순서

  1. src/providers/{name}/ 디렉토리에 코드 생성
  2. src/services/providerManager.js에 프로바이더 등록
  3. src/runner.js에 커맨드 case 추가
  4. bin/index.js에 CLI 커맨드 정의

참고 프로바이더

패턴참고 대상
순수 HTTP (브라우저 불필요)src/providers/insta/, src/providers/reddit/
Playwright 브라우저src/providers/naver/, src/providers/tistory/
쿠키 기반 인증src/providers/x/
OAuth2 인증src/providers/reddit/

코드 규칙

  • CommonJS (require/module.exports)
  • Node.js 18+
  • 세션 저장: ~/.viruagent-cli/sessions/{name}-session.json
  • 에러: createError(code, message, hint) 패턴
  • 응답: { ok: true, data: {...} } 형식

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.