> ## Documentation Index
> Fetch the complete documentation index at: https://docs.platform.nora.my/llms.txt
> Use this file to discover all available pages before exploring further.

# nora actions

> Action 블록 관리 — 알림·로그·쓰기 같은 답변 후 부수 효과.

Action 이 Agent 결정 *후* 발화. Tool (Agent 가 실행 중 선택) 과 달리 Action 은 와이어링 기반 실행: Flow 가 *발화 여부* 결정, Agent 출력이 *무엇 전달할지* 결정.

Tool 과 같은 명령 모양, 파라미터 제외 (Action 은 LLM 선택 인자 없음).

## 명령

| 명령                                   | 설명              |
| ------------------------------------ | --------------- |
| `actions create --name <n>`          | Action 블록 추가.   |
| `actions update <action-id>`         | 필드 패치.          |
| `actions edit <action-id>`           | `$EDITOR` 에 열기. |
| `actions delete <action-id>`         | Action 제거.      |
| `actions headers list <action-id>`   | HTTP 헤더 인쇄.     |
| `actions headers add <action-id>`    | 헤더 추가.          |
| `actions headers remove <action-id>` | 헤더 제거.          |

## `actions create`

```bash theme={null}
nora actions create \
  --name notify_slack \
  --description "Agent 요약을 Slack 메시지로 게시" \
  --runtime '{"kind":"http","method":"POST","url":"https://hooks.slack.com/services/xxx"}'
```

플래그:

* `--name <n>` (필수).
* `--description <d>`.
* `--runtime <json>` — HTTP 나 인라인 런타임 스펙 (Tool 과 같은 모양).
* `--x <n>`, `--y <n>` — 캔버스 위치.

## `actions update`

```bash theme={null}
nora actions update ac_notify \
  --set-approval on \
  --set-http-url https://hooks.slack.com/services/new-url
```

### Update 플래그

**정체성**

* `--set-name <n>`
* `--set-description <d>`
* `--set-icon <name>`

**승인**

* `--set-approval on|off` — 발화 전 승인 요구.

**HTTP 런타임**

* `--set-runtime-kind http|inline`
* `--set-http-method <m>`
* `--set-http-url <url>`
* `--set-http-auth-kind <k>`
* `--set-http-auth-header <name>`
* `--set-http-auth-value <v>`

**Inline 런타임**

* `--set-inline-lang <lang>`
* `--set-inline-code <text>` / `--set-inline-code-file <path>`

**위치/크기**

* `--set-x <n>`, `--set-y <n>`, `--set-width <n>`

**벌크**

* `--patch <json>`

## `actions edit`

```bash theme={null}
nora actions edit ac_notify
```

## `actions delete`

```bash theme={null}
nora actions delete ac_notify
```

Action 제거; 와이어 가지치기.

## `actions headers`

Tool 과 같은 모양:

```bash theme={null}
nora actions headers list ac_notify
nora actions headers add ac_notify --name Authorization --value 'secrets://slack_bot_token'
nora actions headers remove ac_notify --name X-Old-Header
```

시크릿 값은 `secrets://<ref>` 로. 인터랙티브는 `--value ?`. [파이핑·시크릿](/ko/cli/piping-and-secrets) 참고.

## Tool vs. Action — 빠른 상기

|                   | Tool           | Action         |
| ----------------- | -------------- | -------------- |
| 호출 시점 결정          | Agent (LLM 통해) | Flow (와이어링 통해) |
| 인자 선택             | Agent          | Agent 출력에서 매핑  |
| 추론 중 실행           | 예              | 후              |
| Agent 의 다음 스텝에 영향 | 예              | 아니오            |

법칙: Agent 가 결과로 더 추론해야 할 수 있으면 Tool. 답변 후 fire-and-forget 이면 Action.

## 레시피

### 승인 게이트 있는 Slack 알림 추가

```bash theme={null}
AC=$(nora actions create \
  --name notify_slack \
  --description "Slack 요약 게시" \
  --runtime '{"kind":"http","method":"POST","url":"'$SLACK_WEBHOOK'"}' \
  | jq -r '.id')

nora actions update $AC --set-approval on
```

이제 모든 Slack 게시가 승인 기다림.

### 헤더 로테이션 마이그레이션

```bash theme={null}
new_token='secrets://slack_bot_token_v2'
for id in $(nora flows get support | jq -r '.blocks[] | select(.kind=="action").id'); do
  nora actions headers remove $id --name Authorization 2>/dev/null
  nora actions headers add $id --name Authorization --value "$new_token"
done
```
