@@ -66,6 +66,62 @@ export SFCC_INTELLIJ_CREDENTIALS_KEY="your-24-byte-key"
6666b2c code deploy
6767```
6868
69+ ### macOS Keychain Plugin
70+
71+ ** Repository:** [ sfcc-solutions-share/b2c-plugin-macos-keychain] ( https://github.com/sfcc-solutions-share/b2c-plugin-macos-keychain )
72+
73+ Loads B2C credentials from the macOS Keychain. This allows secure storage of sensitive credentials without keeping them in files like ` dw.json ` .
74+
75+ ::: warning macOS Only
76+ This plugin only works on macOS.
77+ :::
78+
79+ #### Installation
80+
81+ ``` bash
82+ b2c plugins install sfcc-solutions-share/b2c-plugin-macos-keychain
83+ ```
84+
85+ #### Features
86+
87+ - Stores credentials as JSON blobs in the macOS Keychain
88+ - Supports global defaults via a ` * ` account (shared OAuth credentials)
89+ - Supports instance-specific credentials that override globals
90+ - Optional ` defaultInstance ` to auto-select an instance
91+ - Merges with other config sources (dw.json, environment variables)
92+
93+ #### Storing Credentials
94+
95+ ``` bash
96+ # Store global OAuth credentials (shared across all instances)
97+ security add-generic-password -s ' b2c-cli' -a ' *' \
98+ -w ' {"clientId":"shared-id","clientSecret":"shared-secret","defaultInstance":"staging"}' -U
99+
100+ # Store instance-specific credentials
101+ security add-generic-password -s ' b2c-cli' -a ' staging' \
102+ -w ' {"username":"user@example.com","password":"my-webdav-key"}' -U
103+ ```
104+
105+ #### Environment Variables
106+
107+ | Variable | Description | Default |
108+ | ----------| -------------| ---------|
109+ | ` SFCC_KEYCHAIN_SERVICE ` | Service name in keychain | ` b2c-cli ` |
110+ | ` SFCC_KEYCHAIN_INSTANCE ` | Fallback instance name | (none) |
111+
112+ #### Usage
113+
114+ ``` bash
115+ # Use with explicit instance
116+ b2c code deploy --instance staging
117+
118+ # Uses defaultInstance from * config if set
119+ b2c code deploy
120+
121+ # Global OAuth merges with dw.json for other settings
122+ b2c code deploy
123+ ```
124+
69125## Creating Your Own Plugin
70126
71127Want to create a plugin? See the [ Extending the CLI] ( ./extending ) guide for documentation on:
0 commit comments