You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
> **Note:** Configuration is not currently required as all tools are placeholder implementations. This section will be relevant once tools are fully implemented.
258
245
259
-
Tools that interact with B2C Commerce instances (e.g., MRT, SCAPI, cartridge deployment) require credentials, which can be provided via **environment variables**, a **`.env` file**, a **`dw.json` file**, or the **`--config`** flag. Local tools (e.g., scaffolding, development guidelines) work without configuration.
260
-
261
-
**Priority order** (highest to lowest):
262
-
263
-
1. Environment variables (`SFCC_*`) — includes `.env` file if present (shell env vars override `.env`)
264
-
2.`dw.json` file (auto-discovered or via `--config`)
265
-
266
-
#### Option 1: Environment Variables
267
-
268
-
Set environment variables directly or create a `.env` file in your project root:
269
-
270
-
```bash
271
-
# .env file or shell exports
272
-
SFCC_HOSTNAME="your-sandbox.demandware.net"
273
-
SFCC_USERNAME="your.username"
274
-
SFCC_PASSWORD="your-access-key"
275
-
SFCC_CLIENT_ID="your-client-id"
276
-
SFCC_CLIENT_SECRET="your-client-secret"
277
-
SFCC_CODE_VERSION="version1"
278
-
```
279
-
280
-
#### Option 2: dw.json File
281
-
282
-
Create a `dw.json` file in your project root (auto-discovered by searching upward from current working directory):
246
+
Different tools require different types of configuration:
283
247
284
-
```json
285
-
{
286
-
"hostname": "your-sandbox.demandware.net",
287
-
"username": "your.username",
288
-
"password": "your-access-key",
289
-
"client-id": "your-client-id",
290
-
"client-secret": "your-client-secret",
291
-
"code-version": "version1"
292
-
}
293
-
```
294
-
295
-
> **Note:** Environment variables take precedence over `dw.json` values.
248
+
| Tool Type | Configuration Required |
249
+
|-----------|----------------------|
250
+
|**MRT tools** (e.g., `mrt_bundle_push`) | MRT API key |
@@ -348,12 +305,16 @@ The MCP server will automatically use this file as a fallback if no flag or envi
348
305
349
306
When using `~/.mobify` config files (i.e., no `--mrt-api-key` flag or `SFCC_MRT_API_KEY` env var), you can use `--mrt-cloud-origin` to select an environment-specific config file:
350
307
351
-
```bash
352
-
# Uses ~/.mobify--cloud-staging.mobify.com for API key
> **Note:**`--mrt-cloud-origin` is only relevant when the API key is resolved from a config file. If `--mrt-api-key` or `SFCC_MRT_API_KEY` is provided, this flag is ignored.
366
327
328
+
#### B2C Instance Config (dw.json)
329
+
330
+
Tools that interact with B2C Commerce instances (e.g., `cartridge_deploy`, SCAPI tools) require instance credentials.
331
+
332
+
**Priority order** (highest to lowest):
333
+
334
+
1. Environment variables (`SFCC_*`)
335
+
2.`dw.json` file (via `--config` flag or auto-discovery)
Create a `dw.json` file in your project root. The MCP server will auto-discover it by searching upward from the current working directory:
374
+
375
+
```json
376
+
{
377
+
"hostname": "your-sandbox.demandware.net",
378
+
"username": "your.username",
379
+
"password": "your-access-key",
380
+
"client-id": "your-client-id",
381
+
"client-secret": "your-client-secret",
382
+
"code-version": "version1"
383
+
}
384
+
```
385
+
386
+
> **Note:** Environment variables override values from `dw.json`. You can use env vars to override specific fields (e.g., secrets) while using dw.json for other settings.
0 commit comments