프로젝트 생성

Prev Next

개요

SourcePipeline 프로젝트를 생성합니다.

요청

API URL

POST  {SOURCEPIPELINE_API_URL}/project

요청 Parameter

없음

요청 Query

없음

요청 Body

{
    "name": "string",
    "description": "string",
    "tasks": [
        {
            "name": "string",
            "type": "string",
            "config": {
                "projectId": "number",
                "target": {
                    "info": {
                        "branch": "string"
                    }
                }
            },
            "linkedTasks": ["string"]
        }
    ],
    "trigger": {
        "repository": [
            {
                "type": "string",
                "name": "string",
                "branch": "string"
            }
        ],
        "sourcepipeline": [
            {
                "id" : "number"
            }
        ],
        "schedule": [
            {
                "day": ["string"],
                "time": "string",
                "timeZone": "string",
                "scheduleOnlyWithChange" : "boolean"
            }
        ]
    }
}
항목 타입 필수여부 설명 비고
name string Y 프로젝트 이름
description string N 프로젝트 설명
tasks.name string Y 태스크 이름
tasks.type string Y 태스크 타입 "SourceBuild" | "SourceDeploy"
tasks.config.projectId number Y 태스크 프로젝트 ID sourceBuildProjectList API 로 조회
sourceDeployProjectList API 로 조회
tasks.config.stageId number N
(tasks.type = SourceDeploy일때, 필수)
SourceDeploy stage ID sourceDeployStageList API 로 조회
tasks.config.scenarioId number N
(tasks.type = SourceDeploy 일때, 필수)
SourceDeploy scenario ID sourceDeployScenarioList API 로 조회
tasks.config.target.info.branch string N
( tasks.type= SourceBuild 일때, 선택 입력)
연결정보 - 브랜치 sourceCommitBranchList API 로 조회
tasks.linkedTasks string[] Y
선행 작업. 앞서 실행될 태스크의 이름
trigger.repository.type string N
(trigger.repository 가 있을 때, 필수)
Push 트리거 - 리파지토리 타입 "sourcecommit"
trigger.repository.name string N
(trigger.repository 가 있을 때, 필수)
Push 트리거 - 리파지토리 이름 sourceCommitRepoisotryList API 로 조회
trigger.repository.branch string N
(trigger.repository 가 있을 때, 필수)
Push 트리거 - 브랜치 sourceCommitBranchList API 로 조회
trigger.sourcepipeline.id number N
(trigger.sourcepipeline 이 있을 때, 필수)
파이프라인 트리거 - 파이프라인 ID sourcePipelineProjectList API 로 조회
trigger.schedule.day string[] N
(trigger.schedule 이 있을 때, 필수)
예약 트리거 - 요일 "MON" | "TUE" | "WED"| "THU" | "FRI" | "SAT" | "SUN"
trigger.schedule.time string N
(trigger.schedule 이 있을 때, 필수)
예약 트리거 - 시간 [HH:mm] 형태로 입력. 예시: "13:10"
trigger.schedule.timeZone string N
(trigger.schedule 이 있을 때, 필수)
예약 트리거 - 타임존 sourcePipelineTimeZone API 로 조회
trigger.schedule.scheduleOnlyWithChange boolean N
(trigger.schedule 이 있을 때, 필수)
예약 트리거 - 변경 시 실행 여부

응답

응답 Body

{
    "projectId": "integer"
}
항목 타입 설명 비고
projectId number 프로젝트 ID