---
# [샘플] 알림 (Slack / Mattermost)

property:
  workspace: /path/to/project
  appName: MyApp
  version: 1.0.0
  downloadURL: https://example.com/download/MyApp.ipa

pipeline:
  id: main
  workflow:
  - exe: slack-message
  - exe: slack-build-report
  - exe: mattermost-message
  - exe: mattermost-build-report

commands:
# Slack 텍스트 메시지
- command: Slack
  id: slack-message
  param:
    token: xoxb-your-slack-bot-token
    channel: "#ci-builds"
    message: "배포 시작: <!property.appName> v<!property.version>"

# Slack 파일 업로드
# - command: SlackFile
#   id: slack-file
#   param:
#     token: xoxb-your-slack-bot-token
#     channel: "#ci-builds"
#     filePath: <!property.workspace>/output/result.txt
#     message: "빌드 결과 로그"

# Slack 빌드 결과 리포트 (구조화된 메시지)
- command: SlackBuild
  id: slack-build-report
  param:
    token: xoxb-your-slack-bot-token
    channel: "#ci-builds"
    appName: <!property.appName>
    type: ios
    version: <!property.version>
    downloadURL: <!property.downloadURL>

# Mattermost 텍스트 메시지
- command: Mattermost
  id: mattermost-message
  param:
    url: https://mattermost.example.com/api/v4/posts
    token: your-mattermost-token
    channelId: your-channel-id
    message: "배포 완료: <!property.appName> v<!property.version>"

# Mattermost 빌드 결과 리포트
- command: MattermostBuild
  id: mattermost-build-report
  param:
    url: https://mattermost.example.com/api/v4/posts
    token: your-mattermost-token
    channelId: your-channel-id
    appName: <!property.appName>
    type: ios
    color: 45C45E
    version: <!property.version>
    downloadURL: <!property.downloadURL>
