이 페이지는 공개 계약에서 생성하며 설명은 원문(한국어) 그대로 표시합니다.
stly apis create#
API 생성
- HTTP 요청:
POST /api/apis - 인증 모드: Agent 토큰, User 세션
- 기록 변경: 예
- 입력 JSON(
--input) 필수
입력 JSON 구조는 stly schema apis create로 확인합니다.
옵션
| 이름 | 타입 | 필수 | 설명 |
|---|---|---|---|
--input | string | 예 | JSON 원문 파일 또는 stdin(-) |
--fields | string | 아니요 | 응답 최상위 필드, 쉼표로 구분 값: base_urls, created_at, description, handle, id, name, security, summary, updated_at |
공통 옵션: --server, --env-file, --timeout, --auth-mode, --dry-run
예시
stly apis create --input input.jsonstly apis delete#
API 삭제
- HTTP 요청:
DELETE /api/apis/{id} - 인증 모드: Agent 토큰, User 세션
- 기록 변경: 예
--if-match필수
인수
id: ID
옵션
| 이름 | 타입 | 필수 | 설명 |
|---|---|---|---|
--if-match | string | 예 | 상세 GET에서 얻은 단일 strong ETag |
--fields | string | 아니요 | 응답 최상위 필드, 쉼표로 구분 |
공통 옵션: --server, --env-file, --timeout, --auth-mode, --dry-run
예시
stly apis delete 00000000-0000-0000-0000-000000000001 --if-match '"상세 GET의 ETag"'stly apis get#
API 상세 조회
- HTTP 요청:
GET /api/apis/{id} - 인증 모드: Agent 토큰, User 세션
- 기록 변경: 아니요
인수
id: ID
옵션
| 이름 | 타입 | 필수 | 설명 |
|---|---|---|---|
--fields | string | 아니요 | 응답 최상위 필드, 쉼표로 구분 값: base_urls, created_at, description, handle, id, name, security, summary, updated_at |
공통 옵션: --server, --env-file, --timeout, --auth-mode, --dry-run
예시
stly apis get 00000000-0000-0000-0000-000000000001stly apis list#
API 목록 조회
- HTTP 요청:
GET /api/apis - 인증 모드: Agent 토큰, User 세션
- 기록 변경: 아니요
옵션
| 이름 | 타입 | 필수 | 설명 |
|---|---|---|---|
--fields | string | 아니요 | 응답 최상위 필드, 쉼표로 구분 값: base_urls, created_at, description, handle, id, name, security, summary, updated_at |
--handle | string | 아니요 | Web 주소 이름 정확 일치 필터. 앞뒤 공백 제거·소문자 정규화 후 비교하며 결과는 최대 1건 |
--page | string | 아니요 | 1 이상 정수. page·per-page 중 하나라도 있으면 페이지 모드 |
--per-page | string | 아니요 | 1~500 정수, 생략 시 100 |
--q | string | 아니요 | name·summary·description 필드 중 하나의 대소문자 구분 리터럴 부분 일치 검색. 본문은 검색하지 않으며 정규식·와일드카드를 지원하지 않습니다 |
--sort | string | 아니요 | 리소스 기본 필드명 또는 - 접두 역순만 허용 |
공통 옵션: --server, --env-file, --timeout, --auth-mode, --dry-run
예시
stly apis list --q "검색어"stly apis service get#
API 제공 Service 조회
- HTTP 요청:
GET /api/apis/{api_id}/service - 인증 모드: Agent 토큰, User 세션
- 기록 변경: 아니요
인수
id: ID
옵션
| 이름 | 타입 | 필수 | 설명 |
|---|---|---|---|
--fields | string | 아니요 | 응답 최상위 필드, 쉼표로 구분 값: api_id, service_id, updated_at |
공통 옵션: --server, --env-file, --timeout, --auth-mode, --dry-run
예시
stly apis service get 00000000-0000-0000-0000-000000000001stly apis service update#
API 제공 Service 확정
- HTTP 요청:
PUT /api/apis/{api_id}/service - 인증 모드: Agent 토큰, User 세션
- 기록 변경: 예
- 입력 JSON(
--input) 필수 --if-match필수
입력 JSON 구조는 stly schema apis service update로 확인합니다.
인수
id: ID
옵션
| 이름 | 타입 | 필수 | 설명 |
|---|---|---|---|
--if-match | string | 예 | 상세 GET에서 얻은 단일 strong ETag |
--input | string | 예 | JSON 원문 파일 또는 stdin(-) |
--fields | string | 아니요 | 응답 최상위 필드, 쉼표로 구분 값: api_id, service_id, updated_at |
공통 옵션: --server, --env-file, --timeout, --auth-mode, --dry-run
예시
stly apis service update 00000000-0000-0000-0000-000000000001 --input input.json --if-match '"상세 GET의 ETag"'stly apis set-service#
API 제공 Service 선택 또는 미연결 확정
- HTTP 요청:
PUT /api/apis/{api_id}/service - 인증 모드: Agent 토큰, User 세션
- 기록 변경: 예
--if-match필수
인수
id: ID
옵션
| 이름 | 타입 | 필수 | 설명 |
|---|---|---|---|
--if-match | string | 예 | 상세 GET에서 얻은 단일 strong ETag |
--fields | string | 아니요 | 응답 최상위 필드, 쉼표로 구분 값: api_id, service_id, updated_at |
--none | boolean | 아니요 | 제공 Service를 명시적으로 미연결 |
--service | string | 아니요 | 제공 Service ID |
공통 옵션: --server, --env-file, --timeout, --auth-mode, --dry-run
예시
stly apis set-service <id> --service <id> --if-match '"제공 Service GET의 ETag"'stly apis systems#
API의 소속 System 조회
- HTTP 요청:
GET /api/apis/{id}/systems - 인증 모드: Agent 토큰, User 세션
- 기록 변경: 아니요
인수
id: ID
옵션
| 이름 | 타입 | 필수 | 설명 |
|---|---|---|---|
--fields | string | 아니요 | 응답 최상위 필드, 쉼표로 구분 값: description, id, inclusion, kind, name, summary |
--page | string | 아니요 | 1 이상 정수. page·per-page 중 하나라도 있으면 페이지 모드 |
--per-page | string | 아니요 | 1~500 정수, 생략 시 100 |
--q | string | 아니요 | name 필드의 대소문자 구분 리터럴 부분 일치 검색. summary·description·본문은 검색하지 않으며 정규식·와일드카드를 지원하지 않습니다 |
--scope | string | 아니요 | direct 또는 recursive 구성 범위 값: direct, recursive |
--sort | string | 아니요 | 리소스 기본 필드명 또는 - 접두 역순만 허용 |
공통 옵션: --server, --env-file, --timeout, --auth-mode, --dry-run
예시
stly apis systems 00000000-0000-0000-0000-000000000001 --q "검색어"stly apis update#
API 수정
- HTTP 요청:
PUT /api/apis/{id} - 인증 모드: Agent 토큰, User 세션
- 기록 변경: 예
- 입력 JSON(
--input) 필수 --if-match필수
입력 JSON 구조는 stly schema apis update로 확인합니다.
인수
id: ID
옵션
| 이름 | 타입 | 필수 | 설명 |
|---|---|---|---|
--if-match | string | 예 | 상세 GET에서 얻은 단일 strong ETag |
--input | string | 예 | JSON 원문 파일 또는 stdin(-) |
--fields | string | 아니요 | 응답 최상위 필드, 쉼표로 구분 값: base_urls, created_at, description, handle, id, name, security, summary, updated_at |
공통 옵션: --server, --env-file, --timeout, --auth-mode, --dry-run
예시
stly apis update 00000000-0000-0000-0000-000000000001 --input input.json --if-match '"상세 GET의 ETag"'stly apis validate#
API 생성·수정 후보 사전 검증(저장 없음)
- HTTP 요청:
--operation createPOST /api/apis/validate,--operation updatePUT /api/apis/{id}/validate - 인증 모드: Agent 토큰, User 세션
- 기록 변경: 아니요
- 입력 JSON(
--input) 필수
입력 JSON 구조는 stly schema apis validate --operation create|update로 확인합니다.
인수
id: ID
옵션
| 이름 | 타입 | 필수 | 설명 |
|---|---|---|---|
--input | string | 예 | JSON 원문 파일 또는 stdin(-) |
--operation | string | 예 | 검증할 작업 종류. 생성 후보는 create, 수정 후보는 update 값: create, update |
--fields | string | 아니요 | 응답 최상위 필드, 쉼표로 구분 |
--if-match | string | 아니요 | 상세 GET에서 얻은 단일 strong ETag |
공통 옵션: --server, --env-file, --timeout, --auth-mode, --dry-run
동작
- 실제 서버를 호출해 입력·참조·중복·If-Match를 검사하며 저장하지 않습니다. 도메인 규칙은 서버가 판단합니다.
- --operation create: 대상 id·If-Match 금지. update: 대상 id·단일 strong If-Match 필수, 부모 옵션 금지
- --dry-run: credential 접근·HTTP 요청·파일 변경 없이 요청 계획만 출력
- 성공은 관찰 시점의 유효성으로 저장 성공·ID 예약·충돌 방지를 보장하지 않습니다. 자동 저장·자동 재시도하지 않습니다.
예시
stly apis validate --operation create --input input.jsonstly apis validate 00000000-0000-0000-0000-000000000001 --operation update --input input.json --if-match '"상세 GET의 ETag"'