PiAPI CLI Quick Start: 터미널에서 AI 이미지와 비디오 생성

멀티모달 AI 생성을 위한 PiAPI CLI 터미널 workflow
PiAPI
PiAPI

PiAPI CLI는 PiAPI의 공식 커맨드라인 인터페이스입니다. 터미널에서 이미지, 비디오, 오디오, 3D, LLM용 멀티모달 AI 모델을 바로 호출할 수 있습니다.

이 빠른 시작 가이드는 설치, API key 인증, 첫 이미지 생성, async 비디오 task, 사용 가능한 모델 확인까지 다룹니다.

PiAPI CLI란?

빠른 정의

PiAPI CLI는 웹 dashboard를 열지 않고 PiAPI 모델을 실행하는 Node.js 커맨드라인 도구입니다.

AI CLI는 생성 workflow가 터미널에서 시작될 때 유용합니다. 명령을 저장하고, 다시 실행하고, 파라미터를 바꾸고, script나 AI agent에 넣을 수 있습니다.

  • 반복 가능한 prompt로 asset 생성
  • 앱이나 prototype 개발 중 빠른 테스트
  • 프로젝트 폴더에서 로컬 파일 upload
  • 출력을 예측 가능한 폴더에 저장
  • script, CI, agent용 JSON 반환

PiAPI CLI 한눈에 보기

패키지piapi-cli
명령piapi
RuntimeNode.js 18+
주요 용도터미널 기반 멀티모달 AI 생성
유용한 대상개발자, 자동화 workflow, AI agents

준비 사항

  • Node.js 18 이상
  • PiAPI API key
  • 터미널 앱

PiAPI CLI 설치

선호하는 JavaScript package manager로 piapi-cli 패키지를 설치합니다.

Terminal
npm install -g piapi-cli
Terminal
pnpm add -g piapi-cli
Terminal
bun add -g piapi-cli
Terminal
yarn global add piapi-cli
Terminal
npx piapi-cli@latest --help

PiAPI API key로 인증

설치 후 CLI를 PiAPI 계정에 연결합니다.

Terminal
piapi auth login --api-key sk-xxxxx
Terminal
piapi auth status
Terminal
export PIAPI_API_KEY=sk-...

터미널에서 첫 AI 이미지 생성

인증 후 piapi run으로 터미널에서 AI 이미지를 생성할 수 있습니다.

Terminal
piapi run flux-dev prompt="a corgi in space"
Terminal
piapi run gpt-image-2 prompt="a corgi in space" size=1024x1024

Flux API

터미널에서 첫 AI 비디오 생성

비디오 생성은 보통 이미지보다 오래 걸리므로 비디오 모델은 async task로 시작하는 것이 좋습니다.

Terminal
piapi run sora2-pro prompt="ocean waves" --async
Terminal
piapi task get <id>

Sora 2 API / Kling API

로컬 파일 업로드 및 결과 다운로드

입력값이 @로 시작하면 PiAPI CLI가 로컬 파일을 upload하고 결과를 선택한 폴더에 download할 수 있습니다.

Terminal
piapi run remove-bg image=@./photo.png --download --out-dir ./out

모델 확인 및 quota 점검

model 명령으로 모델, schema, quota를 확인합니다.

Terminal
piapi model list
Terminal
piapi model list --type video
Terminal
piapi model schema flux-dev
Terminal
piapi quota

유용한 PiAPI CLI flags

자동화에 유용한 flags:

--asyncCLI workflow 옵션
--downloadCLI workflow 옵션
--out-dir <path>CLI workflow 옵션
--streamCLI workflow 옵션
--dry-runCLI workflow 옵션
--output jsonJSON output for scripts and automation
--webhook <url>CLI workflow 옵션
--quietCLI workflow 옵션
--non-interactiveCLI workflow 옵션

AI agents와 자동화에서 PiAPI CLI 사용

PiAPI CLI는 AI agent, shell script, CI job, 자동화 workflow에서도 사용할 수 있습니다.

Terminal
npx skills add PiAPI-1/piapi-cli
Terminal
piapi run flux-dev prompt="a product photo on a white background" --output json

Midjourney n8n integration guide

PiAPI CLI 일반 문제 해결

첫 명령이 작동하지 않으면 prompt나 model을 바꾸기 전에 다음 일반적인 문제를 확인하세요.

piapi 명령을 찾을 수 없음

npx piapi-cli@latest --help

API key가 없거나 유효하지 않음

piapi auth status

비디오 명령이 파일 대신 task ID를 반환함

piapi task get <id>

Web UI 대신 PiAPI CLI를 언제 사용할까요?

반복 가능하고 script화할 수 있거나 AI agent에 전달할 workflow가 필요하면 PiAPI CLI를 사용하세요. Web UI는 시각적 탐색에, CLI는 자동화에 더 적합합니다.

FAQ

PiAPI CLI란?

PiAPI CLI는 웹 dashboard를 열지 않고 PiAPI 모델을 실행하는 Node.js 커맨드라인 도구입니다.

PiAPI CLI는 어떻게 설치하나요?

npm install -g piapi-cli / npx piapi-cli@latest --help

터미널에서 AI 이미지와 비디오를 생성할 수 있나요?

piapi run flux-dev prompt="a corgi in space" / piapi run sora2-pro prompt="ocean waves" --async

PiAPI CLI로 시작하기

PiAPI CLI는 개발자와 AI agents가 명령줄에서 이미지, 비디오, 오디오, 3D assets, LLM responses를 생성하는 실용적인 방법입니다.

PiAPI CLI PiAPI docs

More Stories

Why Your AI Face Rating Changes: Photo Tips for More Consistent Face Scores

June 5, 2026

AI face ratings can change based on lighting, camera angle, expression, filters, blur, and face visibility. Learn the best selfie tips for more consistent AI face scores.

PiAPI
PiAPI

AI Face Rating Explained: What Face Scores and PSL Ratings Mean

June 4, 2026

Learn what AI face rating means, how PSL face scores became a social-media trend, what face rating AI tools measure, and how to interpret scores safely.

PiAPI
PiAPI