문서API 목록

API 목록

/api/ci/v1 엔드포인트 · 권한 · MCP 도구 · CLI 명령

AI로 연결하기 →

API 목록 직접 확인하기펼쳐보기

주소 https://xenoci.com/api/ci/v1, 인증 Authorization: Bearer 발급한_API_키. 요청 헤더 XenoCI-Error-Format: 2를 보내면 오류를 전체 봉투로 받습니다. 기계가 읽는 명세는 /openapi.json입니다.

권한은 세 단계입니다. read(보기): 모든 GET. build(빌드): 빌드 제출·취소, 폴더 업로드. manage(관리): Mac 리셋·Xcode·설정 변경, 연장 주문, 재입고 알림, 시크릿. 예전 키의 order·secrets는 그대로 쓰이고, manage가 둘을 포함합니다. 권한이 없으면 403 insufficient_scope와 required_level이 옵니다. 리셋·Xcode·설정 변경 요청에 Idempotency-Key 헤더를 붙이면 같은 요청을 다시 보내도 작업이 한 번만 생깁니다.

취소·환불, 결제 승인과 결제 수단은 어떤 키로도 할 수 없습니다. 임대는 시간이 끝나면 자동 종료됩니다.

키별 한도: 1분 요청 수(읽기 600·쓰기 120), 동시 빌드 20, 결제 대기 주문 3. 넘으면 429와 retry_after_s. 남은 양은 GET /me의 remaining.

요청권한MCP · CLI설명
GET /mereadaccount · xenoci whoami이 API 키의 계정·키 이름·권한(scopes)·한도(limits)·남은 요청 수(remaining). /account도 같음
GET /accountreadaccount · xenoci whoami/me와 같음
GET /catalogreadcatalog · xenoci catalog상품별 24시간 가격(원, VAT 포함)·사양·Xcode·지금 배정 가능한 대수(available_now)·sales_open·내 재입고 알림
POST /quotereadquote · xenoci order --tier ID --hours 24 --quote새 임대 견적(부작용 없음)
POST /ordersmanagecreate_order · xenoci order --tier ID --hours 24주문 생성 → 201 + pay_url(30분 유효). 사람이 같은 계정으로 열어 동의·결제. API는 동의·결제를 하지 않음
GET /ordersreadorder_status · xenoci orders주문 목록(?status=awaiting_payment 등)
GET /orders/{order_no}readorder_status · xenoci order RT-…주문 상태(awaiting_payment·paid·provisioning·ready·expired·canceled)·pay_url·rental_ids
GET /orders/{order_no}/waitreadwait_order · xenoci wait RT-…상태가 바뀌거나 ready·expired·canceled가 될 때까지 최대 60초 롱폴(timeout=초)
GET /rentalsreadlist_macs · xenoci macs빌린 맥(남은 시간·연장 가능 여부·현재 빌드)과 빌드 대기열
GET /rentals/{rental_id}readlist_macs · xenoci macs맥 한 대 상세. mac_state(preparing·ready·building·resetting·updating), setup, setup_options(바꿀 수 있는 Xcode·runtimes·tools), op(마지막 작업)
POST /rentals/{rental_id}/extend/quotereadextend (quote_only) · xenoci extend rt_… --hours 24 --quote연장 견적
POST /rentals/{rental_id}/extendmanageextend · xenoci extend rt_… --hours 24한 대 연장 주문 → pay_url
POST /rentals/extendmanageextend · xenoci extend rt_1 rt_2 --hours 24여러 대 한 번에 연장 → pay_url 하나. 하나라도 불가면 409 extension_unavailable + items
POST /rentals/resetmanagereset_macs · xenoci reset --all [--keep-cache]내 Mac 전체(all: true) 또는 일부(ids)의 VM을 재설정 → Mac마다 {rental_id, result: accepted|rejected, reason, job_id}. keep_cache: true는 작업 폴더만 비움(캐시 유지), false(기본)는 새 VM(10분에 1번·하루 20번). 빌드 중인 Mac은 when: after_build(끝난 뒤) 또는 now(빌드 취소 후)
POST /rentals/{rental_id}/resetmanagereset_macs · xenoci reset rt_… [--keep-cache]Mac 한 대 VM 재설정 → 202 {rental_id, result, job_id}. 진행은 GET /jobs/{job_id}
POST /rentals/xcodemanageset_xcode · xenoci xcode --all --version 27.0내 Mac 전체(all: true) 또는 일부(ids)의 Xcode를 바꿈. 그 등급에서 고를 수 없는 Mac만 rejected(reason xcode_not_available, detail.options)
POST /rentals/{rental_id}/xcodemanageset_xcode · xenoci xcode rt_… --version 27.0Mac 한 대 Xcode 변경 → 202 {rental_id, result, job_id}. 이미 그 버전이면 200 status: unchanged
PATCH /rentals/{rental_id}manageupdate_mac · xenoci setup rt_… --xcode 26.6 --runtimes "iOS 26.6" --tools fastlane,cocoapodsMac 한 대의 Xcode·시뮬레이터 런타임·도구·캐시 유지 설정 변경. 값은 rentals/{id}의 setup_options(카탈로그)에 있는 것만. 아니면 400 invalid_setup + options
GET /jobs/{job_id}readjob_status · xenoci job op_…리셋·Xcode·설정 작업 상태: queued(빌드가 끝나기를 기다림)·running·done·failed, error·message. Mac의 mac_state는 작업 중 resetting(리셋)·updating(Xcode·설정)
POST /rentals/batchmanage-콘솔용 일괄 작업({action: xcode|reset, rental_ids}). API에서는 /rentals/reset·/rentals/xcode를 쓰세요
GET /waitlistreadjoin_waitlist · xenoci waitlist재입고 알림 신청 목록
POST /waitlistmanagejoin_waitlist · xenoci waitlist --tier ID재입고 알림 신청
DELETE /waitlist/{id}managejoin_waitlist (leave) · xenoci waitlist --leave ID재입고 알림 취소
GET /poolreadlist_macs · xenoci pool빈 자리와 대기열
POST /uploadsbuildbuild · xenoci build폴더 업로드: gzip 매니페스트 → 서버에 없는 파일 목록
POST /uploads/{id}/blobsbuildbuild · xenoci build빠진 파일 묶음(gzip) 전송
POST /uploads/tarbuild-CLI 없이 tar.gz 한 번에 업로드(curl·PowerShell)
POST /buildsbuildbuild · xenoci build --script ./ci.sh빌드 제출. 소스는 upload_id·repo_url·repo 중 하나, rental_id로 맥 지정, queue_until_rental: true면 맥이 생길 때까지 대기. Idempotency-Key 지원
GET /buildsread-빌드 목록(rental·state·from·to·q·before·limit)
GET /builds/{build_id}readbuild_status · xenoci status rb_…빌드 상태·대기 순번(queue_position)·estimated_start_at·종료 코드·실패 요약(failure)
GET /builds/{build_id}/waitreadwait_build · xenoci wait rb_…빌드가 끝날 때까지 최대 60초 롱폴
GET /builds/{build_id}/logreadbuild_log · xenoci logs rb_… [--failure | --tail N]로그. offset=N이면 JSON 구간, format=text&wait=S면 텍스트 스트림
POST /builds/{build_id}/cancelbuildcancel_build · xenoci cancel rb_…빌드 취소
GET /secretsreadsecrets (list) · xenoci secrets빌드 시크릿 이름 목록(값은 돌려주지 않음)
PUT /secrets/{name}managesecrets (put) · xenoci secrets put NAME < 값시크릿 저장. 빌드에 환경 변수로 들어가고 로그에서 가려짐
DELETE /secrets/{name}managesecrets (delete) · xenoci secrets delete NAME시크릿 삭제
GET /errorsreadlist_errors · xenoci errors내 계정 최근 API 오류와 실패 빌드(?fault=&code=&kind=api|build&since=&key=self)
API 목록 - XenoCI