# attachmentKey

Canonical: https://docs.shumoku.dev/ja/library/api/attachmentKey
Language: ja

@shumoku/core · 0.4.0 · function

# attachmentKey

[ソース](https://github.com/konoe-akitoshi/shumoku/blob/main/libs/@shumoku/core/src/models/types.ts#L526)

APIの説明は英語のcanonical sourceを表示しています。

Stable merge / suppression key for an attachment. \`access\` is keyed per protocol (SNMP and SSH are distinct slots); \`metrics-binding\` is keyed per metrics source (two metrics sources can each bind one element — but ONE binding per (source, element) is the invariant; extend with a role segment if per-metric-role binding is ever needed, don't overload the slot); every other kind keys by its \`kind\`. The resolver merges attachments by this key (highest-priority contribution wins per key) and the human suppresses by it (\`suppressedAttachments\`). One definition so merge and suppression never disagree on what "the same attachment slot" means.

```
attachmentKey(a: Attachment): string
```

## パラメーター

| 名前 | 型 | 説明 | 既定値 |
| --- | --- | --- | --- |
| `a` | `Attachment` | 追加説明はありません。 | `—` |

## 戻り値

```
string
```

[`libs/@shumoku/core/src/models/types.ts:526`](https://github.com/konoe-akitoshi/shumoku/blob/main/libs/@shumoku/core/src/models/types.ts#L526)
