@microsoft/rayfin-guide 1.36.0-alpha.1818 → 1.36.0-alpha.1917

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5,10 +5,14 @@ sidebar_position: 2
5
5
  # connector add
6
6
 
7
7
  ```bash
8
- npx rayfin connector add --type <type> --workspace-id <ws-id> --item-id <item-id> [--name <name>] [--operations <ops>]
8
+ npx rayfin connector add --type <type> --workspace-id <ws-id> --item-id <item-id> [--name <name>] [--operations <ops>] [--auth <type>]
9
9
  ```
10
10
 
11
11
  > **`kusto` authoring is held in this release**, so `connector add --type kusto` refuses before writing anything. Kusto examples below describe the authoring path for when it ships. See [Connectors](./index.md) for what a project that already declares Kusto can still do.
12
+ >
13
+ > **`fabric-dataagent` authoring is held in this release** too.
14
+ > `connector add --type fabric-dataagent` refuses before writing a YAML entry or scaffold directory, even with `--yes` or `--operations`.
15
+ > The connector remains experimental; its existing configuration and runtime contract are preserved.
12
16
 
13
17
  `connector add` declares a connector in `rayfin/rayfin.yml` and scaffolds its supporting files.
14
18
 
@@ -25,6 +29,7 @@ If you do not already know the workspace and item IDs, run [`connector search`](
25
29
  | `--item-id <id>` | yes (Fabric) | Fabric item or artifact ID. Must be a literal. |
26
30
  | `--name <name>` | no | Connector name. Derived from the item display name when omitted. |
27
31
  | `--operations <ops>` | no | Comma-separated subset of the type's allowed operations, for example `read,update`. Narrows the emitted `operations:` at add time. Omit for all allowed operations. Each value must be in the type's catalog allowlist. |
32
+ | `--auth <type>` | no | Identity each call runs as: `delegated` (the signed-in caller) or `application` (the app owner). Omit to use the connector type's catalog default. Must be in the type's allowed auth types. |
28
33
  | `-y, --yes` | no | Auto-accept overwrite and confirmation prompts (non-interactive). |
29
34
  | `-v, --verbose` | no | Verbose diagnostics. |
30
35
 
@@ -72,7 +77,7 @@ Rules:
72
77
  For `kusto` and `fabric-semanticmodel`, `connector add` writes the `rayfin.yml` entry and generates a complete typed `schema.ts`, but there are no GraphQL entities to discover, so no entity files are generated and no row-level security applies:
73
78
 
74
79
  - `fabric-semanticmodel` allows `executeQuery`; `kusto` allows `executeQuery` and `executeCommand`. Check `rayfin connector types --json` for the current set.
75
- - `auth.type` must be `delegated`.
80
+ - `auth.type` is `delegated` for `fabric-semanticmodel` and `application` for `kusto` — see [Category B](./category-b-function-bridge.md). Set it with `--auth`.
76
81
  - The connector is pinned to an adapter version.
77
82
  - There is no `metadata.json` entity list to generate from.
78
83
 
@@ -4,15 +4,20 @@ sidebar_position: 6
4
4
 
5
5
  # Category B — function-bridge connectors
6
6
 
7
- Reference for `fabric-semanticmodel` (Power BI semantic model) and the experimental `kusto` (the **Eventhouse** connector — a Fabric Eventhouse KQL Database).
7
+ Reference for `fabric-semanticmodel` (Power BI semantic model), the experimental `fabric-dataagent` (Fabric Data Agent), and the experimental `kusto` (the **Eventhouse** connector — a Fabric Eventhouse KQL Database).
8
8
  Eventhouse is the Fabric product name; `kusto` is the type id you pass to `--type`, and KQL is its query language.
9
9
 
10
10
  > **`kusto` authoring is held in this release**, so `connector add --type kusto` refuses and search omits KQL databases. Everything below about `kusto` stays accurate for a project that **already declares** one — which still validates, deploys and invokes — and describes the authoring path for when it ships. Only `fabric-semanticmodel` can be added today. See [Connectors](./index.md).
11
+ >
12
+ > **`fabric-dataagent` authoring is held in this release**, and the connector remains experimental, not generally available.
13
+ > `connector add --type fabric-dataagent` refuses before writing files; `connector types` and `connector search` omit it.
14
+ > Data Agent examples describe the contract for existing configurations and the authoring path for when it is released, not an available setup flow.
15
+ > The hold does not disable existing validation, deployment, or invocation paths; live use still requires the backend adapter.
11
16
 
12
17
  A Category B connector is a named-operation surface backed by a small, platform-owned function (UDF).
13
18
  The Builder never writes or sees the function code.
14
19
 
15
- The Builder declares the connector and calls a typed method; the Fabric app backend injects connector configuration and delegated authentication before forwarding to the function.
20
+ The Builder declares the connector and calls a typed method; the Fabric app backend injects connector configuration and authentication before forwarding to the function.
16
21
  There are no GraphQL entities, so do **not** generate entity files, `@role` policies, or `metadata.json` entities for these connector types.
17
22
 
18
23
  For the entity-generating types (`fabric-sqlanalytics`, `fabric-warehouse`, `fabric-sqldatabase`), read the package-owned Category A docs in `@microsoft/rayfin-connector-fabric-graphql` (`rayfin docs search` / `search_docs`) instead.
@@ -22,10 +27,17 @@ For the entity-generating types (`fabric-sqlanalytics`, `fabric-warehouse`, `fab
22
27
  | Type | Operations | Query language | Auth |
23
28
  | --- | --- | --- | --- |
24
29
  | `fabric-semanticmodel` | `executeQuery` | DAX | `delegated` only |
25
- | `kusto` (**experimental**) | `executeQuery`, `executeCommand` | KQL | `delegated` only |
30
+ | `kusto` (**experimental**) | `executeQuery`, `executeCommand` | KQL | `application` only |
31
+ | `fabric-dataagent` (**experimental**) | `getInfo`, `startTask`, `getTask`, `getTaskResult`, `cancelTask` | Natural language (MCP) | `delegated` only |
26
32
 
27
- Both are pinned to an adapter version (`version: '1'` today).
28
- Delegated authentication runs every call as the signed-in user through the on-behalf-of flow.
33
+ All three are pinned to an adapter version (`version: '1'` today).
34
+ `delegated` runs every call as the signed-in user through the on-behalf-of flow; `application` runs it as the app owner.
35
+
36
+ Kusto's adapter authorizes as the app owner and rejects a delegated caller token, so it takes `application` only — `auth.type: delegated` is refused at validation rather than failing at the data plane. Row-level security is therefore evaluated against the owner, not the caller.
37
+
38
+ The experimental `fabric-dataagent` SDK package also provides an `ask` helper.
39
+ `ask` is a client-side convenience composed from the task operations, not a connector operation, so it never appears in `rayfin.yml`.
40
+ See [Calling a Data Agent connector](#calling-a-data-agent-connector).
29
41
 
30
42
  ## Add the connector
31
43
 
@@ -37,7 +49,7 @@ rayfin connector add \
37
49
  --name telemetry
38
50
  ```
39
51
 
40
- `--item-id` identifies the Fabric item to query: a KQL Database for `kusto`, a semantic model for `fabric-semanticmodel`.
52
+ `--item-id` identifies the Fabric item to query: a KQL Database for `kusto`, a semantic model for `fabric-semanticmodel`, a published Data Agent for experimental `fabric-dataagent`.
41
53
  Omit `--name` to derive the connector name from the Fabric item's display name.
42
54
 
43
55
  The CLI verifies the item, writes the `rayfin.yml` entry, and scaffolds `rayfin/connectors/<name>/schema.ts`.
@@ -53,21 +65,22 @@ connectors:
53
65
  workspaceId: <ws-id>
54
66
  itemId: <kql-database-item-id>
55
67
  auth:
56
- type: delegated
68
+ type: application
57
69
  operations:
58
70
  - name: executeQuery
59
71
  - name: executeCommand
60
72
  ```
61
73
 
62
74
  The `config` block is the single source of truth for what to query and is not sent on the client wire.
63
- `kusto` allows `executeQuery` and `executeCommand`; `fabric-semanticmodel` allows `executeQuery`.
64
- In every case `auth.type` must be `delegated`.
75
+ `kusto` allows `executeQuery` and `executeCommand`; `fabric-semanticmodel` allows `executeQuery`; experimental `fabric-dataagent` allows `getInfo`, `startTask`, `getTask`, `getTaskResult` and `cancelTask`.
76
+ `auth.type` is `application` for `kusto` and `delegated` for the other two.
65
77
 
66
78
  ## The generated schema.ts
67
79
 
68
80
  `connector add` writes `rayfin/connectors/<name>/schema.ts` with a `// @generated — do not edit.` banner.
69
81
  Do not hand-edit it.
70
- Regenerate it by removing and re-adding the connector (`rayfin connector remove <name>`, then `rayfin connector add ...`).
82
+ For released types, regenerate it by removing and re-adding the connector (`rayfin connector remove <name>`, then `rayfin connector add ...`).
83
+ Do not remove a held connector to regenerate its files: `connector add` will refuse to recreate it.
71
84
 
72
85
  For `fabric-semanticmodel` the file exports the typed marker plus a generic runtime config:
73
86
 
@@ -110,6 +123,19 @@ If the resolved values look wrong, re-add the connector rather than editing the
110
123
 
111
124
  The Eventhouse scaffold imports both its marker and `KustoConnectorConfig` from `@microsoft/rayfin-connector-kusto`, so it does not import `@microsoft/rayfin-connectors` at all.
112
125
 
126
+ ### The experimental Data Agent scaffold uses the generic config shape
127
+
128
+ Experimental `fabric-dataagent` needs no client-side routing values.
129
+ An existing `schema.ts` uses the generic `ConnectorConfig` shape shown for semantic models above, and a marker whose type argument is the operations declared in `rayfin.yml`:
130
+
131
+ ```ts
132
+ import type { FabricDataAgent } from '@microsoft/rayfin-connector-fabric-dataagent';
133
+
134
+ export type SalesAgentSchema = FabricDataAgent<'getInfo' | 'startTask' | 'getTask' | 'getTaskResult' | 'cancelTask'>;
135
+ ```
136
+
137
+ The AppBackend resolves the workspace and Data Agent item from `rayfin.yml`; app code and `fabricDataAgent()` never supply an MCP endpoint.
138
+
113
139
  ## Install the packages the generated file imports
114
140
 
115
141
  `connector add` scaffolds files but installs nothing. It prints the exact pinned command — copy it from that output, or rebuild it from the `packages` array in `rayfin connector types --json`, which carries both the package names and the version:
@@ -122,6 +148,9 @@ npm install @microsoft/rayfin-connector-kusto@1.35.0-alpha
122
148
 
123
149
  # fabric-semanticmodel
124
150
  npm install @microsoft/rayfin-connector-fabric-semanticmodel@1.35.0-alpha @microsoft/rayfin-connectors@1.35.0-alpha
151
+
152
+ # fabric-dataagent (experimental, authoring held) — existing configurations only
153
+ npm install @microsoft/rayfin-connector-fabric-dataagent@1.35.0-alpha @microsoft/rayfin-connectors@1.35.0-alpha
125
154
  ```
126
155
 
127
156
  **Always pin the version.** Connector packages ship in lockstep with the CLI, but their npm `latest` and `preview` tags lag behind, so an unversioned install pulls an older release and its own mismatched `@microsoft/rayfin-data`.
@@ -136,6 +165,7 @@ This is not optional: the runtime is what injects the generated routing and deco
136
165
 
137
166
  - `kusto()` merges the generated `queryServiceUri` and `databaseName` into the outbound payload. Without it, `executeQuery` and `executeCommand` cannot route to the cluster.
138
167
  - `fabricSemanticModel()` decodes the Arrow response. Without it, `executeQuery` results cannot be read.
168
+ - `fabricDataAgent()` (experimental) normalizes each operation's result and supplies the client-side `ask` helper. Without it, results arrive as raw, un-normalized payloads and `client.connectors.<name>.ask(...)` is posted to the host as an operation it does not know.
139
169
 
140
170
  Key the runtime map by the same connector name, and call the factory once per connector:
141
171
 
@@ -261,6 +291,69 @@ Exceeding it fails the query with an `'overflow'` error, so a truncated result a
261
291
 
262
292
  Run `rayfin docs search "resultSetRowCountLimit"` for version-locked details, since this behavior is owned by the connector package rather than the CLI.
263
293
 
294
+ ## Calling a Data Agent connector
295
+
296
+ > **Experimental; new authoring is held.**
297
+ > The API below describes an already-configured connector, not a currently available `connector add` flow.
298
+ > It may change substantially in a future release.
299
+
300
+ A Data Agent answers natural-language questions over the data sources its publisher configured.
301
+ Questions can take minutes, so the Data Agent MCP endpoint runs them as tasks.
302
+ The connector exposes that lifecycle as named operations — `startTask`, `getTask`, `getTaskResult`, `cancelTask` — plus `getInfo` for the agent's metadata.
303
+
304
+ Use the `ask` helper for the common case.
305
+ `ask` is a client-side convenience, not a connector operation: it calls `startTask`, polls `getTask` while reporting progress, honours cancellation, applies an overall deadline (5 minutes by default), and returns `getTaskResult`.
306
+ It is only typed on `client.connectors.<name>` when the connector allows `startTask`, `getTask`, `getTaskResult` and `cancelTask`.
307
+
308
+ ```ts
309
+ import { FabricDataAgentError } from '@microsoft/rayfin-connector-fabric-dataagent';
310
+
311
+ const controller = new AbortController();
312
+
313
+ try {
314
+ const answer = await client.connectors.salesAgent.ask({
315
+ question: 'What were sales by region last quarter?',
316
+ onProgress: (p) => setStatus(p.statusMessage ?? p.status),
317
+ signal: controller.signal,
318
+ });
319
+ render(answer.text);
320
+ if (answer.deepLinkUrl) showLink('Open in Data Agent', answer.deepLinkUrl);
321
+ } catch (err) {
322
+ if (err instanceof FabricDataAgentError && err.code === 'DATA_AGENT_FORBIDDEN') {
323
+ showAccessRequest();
324
+ } else {
325
+ throw err;
326
+ }
327
+ }
328
+ ```
329
+
330
+ `answer.text` joins the text blocks; `answer.content`, `answer.structuredContent`, and `answer.meta` preserve everything the server returned.
331
+ `onProgress` and `signal` never leave the browser — the SDK consumes them.
332
+
333
+ Read the agent's name, description, and tool contract with `getInfo()`; the result is cached per client for five minutes.
334
+
335
+ Call the task operations directly when the app needs to own the task lifecycle, for example to resume polling after a page reload:
336
+
337
+ ```ts
338
+ const started = await client.connectors.salesAgent.startTask({ question });
339
+ if (started.kind === 'answer') {
340
+ render(started.answer.text);
341
+ } else {
342
+ const { taskId } = started.task;
343
+ // Persist taskId, then later:
344
+ const status = await client.connectors.salesAgent.getTask({ taskId });
345
+ if (status.status === 'completed') {
346
+ const answer = await client.connectors.salesAgent.getTaskResult({ taskId });
347
+ render(answer.text);
348
+ }
349
+ }
350
+ ```
351
+
352
+ Every operation throws `FabricDataAgentError` with a stable `code` (`DATA_AGENT_FORBIDDEN`, `DATA_AGENT_NOT_PUBLISHED`, `DATA_AGENT_TIMEOUT`, `DATA_AGENT_THROTTLED`, ...), a `retryable` flag, a `category` of `user` or `system`, and a `correlationId` when the service supplied one.
353
+
354
+ The endpoint is stateless.
355
+ To give the agent context from earlier turns, pass them in `history`; the app owns any persisted chat transcript.
356
+
264
357
  ## Exercising a Category B connector from the CLI
265
358
 
266
359
  `rayfin connector invoke <name> <operation>` is the loop for Category B.
@@ -268,6 +361,9 @@ See [`connector invoke`](./invoke.md) for payload input, transports, token handl
268
361
 
269
362
  - `connector inspect` supports `fabric-semanticmodel` but **not** experimental `kusto` — a `kusto` connector errors with `Unsupported connector type: kusto`.
270
363
  There is no ad-hoc query path for Kusto connectors today.
364
+ - `connector inspect` does not support experimental `fabric-dataagent` either.
365
+ Use `rayfin connector invoke <name> getInfo` to read the agent's metadata.
366
+ `connector invoke` accepts the connector's named operations only; `ask` is a client-side SDK helper, so it is not an operation `invoke` can call.
271
367
  - `connector invoke` on `fabric-semanticmodel` calls Fabric/Power BI directly under the developer's identity, so it works with or without `rayfin up`.
272
368
  Every other type, including experimental `kusto`, POSTs to the deployed item and requires a prior `rayfin up`.
273
369
  - `connector invoke` on `fabric-semanticmodel` returns an already-normalized result, because that connector normalizes inside its `invoke` middleware.
@@ -288,8 +384,12 @@ A real `executeQuery` requires `rayfin up`.
288
384
  | `connector inspect` errors with `Unsupported connector type: kusto` | `connector inspect` has no Kusto path | Use `rayfin connector invoke <name> executeQuery` instead. |
289
385
  | `Cannot find module '@microsoft/rayfin-connector-kusto'` | `connector add` scaffolds but does not install | Run the pinned `npm install` command `connector add` printed; never install unversioned. |
290
386
  | The generated `schema.ts` has `queryServiceUri` / `databaseName` you did not expect | Expected — Kusto cluster routing is resolved at add time and baked in | Do not edit the file. Re-add the connector to re-resolve. |
291
- | `rayfin up` rejects `auth.type: application` | Category B connectors are delegated-only | Set `auth.type: delegated`. |
387
+ | `rayfin up` rejects `auth.type: application` on `fabric-semanticmodel` | `fabric-semanticmodel` is delegated-only | Set `auth.type: delegated`. |
388
+ | A Kusto query returns the app owner's data instead of the caller's | Kusto is application-only, so the call runs as the owner and row-level security is evaluated against them | Expected. Enforce per-user access in your app. |
292
389
  | A Kusto query fails to reach the cluster, or the request carries no `queryServiceUri` | The runtime map was omitted, so nothing injected the generated routing | Pass `{ <name>: kusto() }` as the client's second constructor argument. |
293
390
  | A semantic-model `executeQuery` result cannot be read or decoded | `fabricSemanticModel()` was not registered, so the Arrow response is never decoded | Pass `{ <name>: fabricSemanticModel() }` as the client's second constructor argument. |
391
+ | `client.connectors.<name>.ask` is not typed on an experimental `fabric-dataagent` connector | The connector does not allow every operation `ask` is composed from | Allow `startTask`, `getTask`, `getTaskResult` and `cancelTask` in `rayfin.yml`, and list them in the generated marker's type argument. |
392
+ | `client.connectors.<name>.ask` fails with an unknown or unsupported operation | `fabricDataAgent()` was not registered, so `ask` was posted to the host instead of being composed client-side | Pass `{ <name>: fabricDataAgent() }` as the client's second constructor argument. |
393
+ | `ask` throws `DATA_AGENT_NOT_PUBLISHED` | The Data Agent has a draft but no published configuration | Publish the Data Agent in Fabric, then retry. |
294
394
  | `client.connectors.<name>` is not typed | Connector key differs between `rayfin.yml`, `AppConnectorsSchema`, and the `connectors` option | Use the `rayfin.yml` `name` in all three. |
295
395
  | A Category B call works locally under `rayfin dev` | It does not — `rayfin dev` only parses the block | Deploy with `rayfin up` and retest. |
@@ -13,6 +13,10 @@ It can read SQL-visible tables and views, but it cannot directly open files from
13
13
  This connector is read-only; the Warehouse and SQL Database connectors also support write operations.
14
14
 
15
15
  > **`kusto` authoring is held in this release.** `connector types` and `connector search` omit it, and `connector add --type kusto` refuses it. A project that **already declares** a Kusto connector is unaffected: it still validates, deploys through `rayfin up`, and answers `connector invoke`. Kusto material in these docs describes that preserved runtime contract and the authoring path for when it ships.
16
+ >
17
+ > **`fabric-dataagent` authoring is held in this release**, and the connector remains experimental, not generally available.
18
+ > `connector types` and `connector search` omit it, and `connector add --type fabric-dataagent` refuses before writing files.
19
+ > Existing configurations remain valid and retain their deployment and invocation paths; live use still requires the Data Agent backend adapter.
16
20
 
17
21
  Each command has its own reference page:
18
22
 
@@ -24,7 +28,7 @@ Each command has its own reference page:
24
28
  Each category has its own contract page — read the one that matches your connector type, not both:
25
29
 
26
30
  - [Category A — GraphQL entity connectors](./category-a-entities.md) — now **package-owned**; the full reference (entity generation, `@role` policies, the aggregate schema, and the per-dialect read/write matrix) ships in `@microsoft/rayfin-connector-fabric-graphql` (`rayfin docs search` / `search_docs`).
27
- - [Category B — function-bridge connectors](./category-b-function-bridge.md) — the `fabric-semanticmodel` and experimental `kusto` contract, including the Kusto cluster routing baked into the generated `schema.ts`.
31
+ - [Category B — function-bridge connectors](./category-b-function-bridge.md) — the `fabric-semanticmodel`, experimental `fabric-dataagent` and experimental `kusto` contract, including the Kusto cluster routing baked into the generated `schema.ts`.
28
32
  - [Eventhouse (`kusto`) usage guide](./eventhouse.md) — the experimental `kusto` supplement, now **package-owned**; when to reach for the type, its streaming model, shaping KQL, safe query construction, and reading results all ship in `@microsoft/rayfin-connector-kusto` (`rayfin docs search` / `search_docs`).
29
33
 
30
34
  A typical loop is search → add → inspect (Category A) or search → add → invoke (Category B).
@@ -35,10 +39,10 @@ The commands available to a connector, and the code you write against it, depend
35
39
 
36
40
  | | Category A — GraphQL entity connectors | Category B — function-bridge connectors |
37
41
  | ------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------ |
38
- | **Types** | `fabric-sqlanalytics`, `fabric-warehouse`, `fabric-sqldatabase` | `fabric-semanticmodel`; `kusto` (**experimental**) |
42
+ | **Types** | `fabric-sqlanalytics`, `fabric-warehouse`, `fabric-sqldatabase` | `fabric-semanticmodel`; `fabric-dataagent` (**experimental**); `kusto` (**experimental**) |
39
43
  | **App surface** | Generated entity files with typed CRUD through the data client | Named operations carrying raw queries |
40
- | **Operations** | `read` only for `fabric-sqlanalytics` (Lakehouse SQL endpoints are read-only); `read`, `create`, `update`, `delete` for `fabric-warehouse` and `fabric-sqldatabase` (narrowable) | `executeQuery` only |
41
- | **Auth** | `delegated` or configured per project | Must be `delegated` |
44
+ | **Operations** | `read` only for `fabric-sqlanalytics` (Lakehouse SQL endpoints are read-only); `read`, `create`, `update`, `delete` for `fabric-warehouse` and `fabric-sqldatabase` (narrowable) | `executeQuery`; experimental `fabric-dataagent` uses named task operations instead |
45
+ | **Auth** | `delegated` or configured per project | `application` for `kusto`; `delegated` for the others |
42
46
  | **Entity files and `@role` policies** | Yes | No |
43
47
  | **`metadata.json` entities** | Yes | No |
44
48
  | **`connector inspect`** | Supported | `fabric-semanticmodel` only — experimental `kusto` is not supported |
@@ -33,6 +33,10 @@ Two transports, chosen by connector type:
33
33
  - **Every other type, including `kusto`** — POSTs to the deployed item at `<remote-endpoint>/__private/connectors/<name>/invoke`, so it requires a prior `npx rayfin up`.
34
34
 
35
35
  > `kusto` authoring is held in this release, but invocation is deliberately preserved: a project that already declares a Kusto connector can still invoke it. Only `connector add`, `types` and `search` withdraw the type. See [Connectors](./index.md).
36
+ >
37
+ > Experimental `fabric-dataagent` follows the same authoring-only hold.
38
+ > An existing configuration can still invoke its named operations, such as `getInfo`; the hold does not bypass backend availability, authentication, or operation checks.
39
+ > `ask` is an SDK helper, not a CLI-invokable operation.
36
40
 
37
41
  `--transport deployed` overrides the type-based choice and forces the deployed route. That route authenticates the **app**, not the developer, so it needs an app-session token in `RAYFIN_TOKEN`; `npx rayfin login` cannot mint one.
38
42
 
@@ -9,6 +9,10 @@ npx rayfin connector search [query] [--workspace-id <id> --type <types> | --all-
9
9
  ```
10
10
 
11
11
  > **`kusto` authoring is held in this release**, so search does not return KQL databases and `--type kusto` is not accepted. Search exists to feed `connector add`, which would refuse the type — surfacing a source the Builder could not then attach. See [Connectors](./index.md).
12
+ >
13
+ > **`fabric-dataagent` authoring is held in this release** too.
14
+ > Search omits Data Agent items, and an explicit `--type fabric-dataagent` is rejected before authentication or discovery.
15
+ > The connector remains experimental and cannot be added yet.
12
16
 
13
17
  `connector search` finds Fabric data sources — warehouses, SQL databases, Lakehouses, and semantic models — that the signed-in identity can add as connectors, before you know exact workspace or item IDs.
14
18
 
@@ -56,6 +56,7 @@ Set `RAYFIN_WORKSPACE_ID` to target a specific workspace; otherwise the active r
56
56
  The CLI starts `npm run dev:frontend` when that script exists and falls back to `npm run dev` for existing projects.
57
57
  This lets bundled templates expose `npm run dev` as the complete session without recursively starting the CLI.
58
58
  When migrating an existing project to `"dev": "rayfin dev"`, also add a non-recursive child such as `"dev:frontend": "vite"`; otherwise the CLI fails with an actionable recursion error.
59
+ `rayfin init` does this automatically for a from-scratch scaffold, when `@microsoft/rayfin-cli` is installed or already declared as a dependency.
59
60
  Scripts are resolved from `services.staticHosting.path` when configured, otherwise from the project root.
60
61
  For a nested frontend package, declare `dev:frontend` (or the legacy `dev` fallback) in that package's `package.json`.
61
62
 
@@ -73,7 +74,7 @@ The proxy is reachable wherever the Vite dev server is reachable, so keep Vite b
73
74
  The local functions setup makes these workspace changes:
74
75
 
75
76
  - Merges backend coordinates and the Node inspector argument into the configured functions package's `local.settings.json`.
76
- - Adds a `Functions: Attach` configuration to the root `.vscode/launch.json` after the Functions host becomes ready.
77
+ - Adds a `Functions: Attach` configuration to the root `.vscode/launch.json` after the Functions host becomes ready. If the entry already exists and the inspector moved to another port, only its `port` is updated.
77
78
  - Leaves JSON-with-comments launch files unchanged and reports that the attach configuration must be added manually.
78
79
  - Patches recognized existing `src/services/rayfinClient.ts` and `src/services/bootstrap.ts` files once so non-adapter projects read `VITE_RAYFIN_FUNCTIONS_URL` only during Vite development.
79
80
  - Regenerates the framework `.env.local` file unless `--no-emit-env` is set.
@@ -35,6 +35,14 @@ Run `npx rayfin up` at least once first. This command deploys to an existing rem
35
35
  1. Builds and packages the functions project (unless `--skip-build`).
36
36
  2. Deploys the package to the remote Rayfin item resolved from your active deployment.
37
37
 
38
+ ## Troubleshooting
39
+
40
+ ### `404` on deploy
41
+
42
+ A `404` from the deploy endpoint usually means Functions are not enabled on the **remote** item, not that the endpoint is unavailable.
43
+ The workload hides every Functions route behind the deployed project's `services.functions.enabled` setting, and this command uploads code without applying project settings.
44
+ If you enabled Functions (for example by running `npx rayfin functions init`) after your last full deployment, run `npx rayfin up` once to sync `rayfin.yml`, then retry.
45
+
38
46
  ## Related
39
47
 
40
48
  - [`functions init`](./init.md) — scaffold and enable functions.
@@ -68,7 +68,7 @@ If the response remains stale after compilation finishes, restart the dev sessio
68
68
 
69
69
  ## Debugging
70
70
 
71
- With debugging enabled (default), attach your debugger to the inspector port (`9229` by default) using the generated **"Functions: Attach"** launch configuration in VS Code. Pass `--no-debug` to run without the inspector.
71
+ With debugging enabled (default), attach your debugger to the inspector port (`9229` by default) using the generated **"Functions: Attach"** launch configuration in VS Code. If you pass a different `--inspect-port`, the existing configuration's port is updated to match. Pass `--no-debug` to run without the inspector.
72
72
 
73
73
  ## Secrets in local development
74
74
 
@@ -140,6 +140,7 @@ Other standalone subcommands and Docker maintenance flags such as `dev --stop` d
140
140
 
141
141
  Local Functions sessions show function endpoints, the debugger address, application output, and warnings or errors by default.
142
142
  Recognized host startup and configuration detail, HTTP request metadata, and successful initial build output are kept in diagnostics; use `--verbose` to mirror that detail to the terminal.
143
+ When the host restarts after a watched file change, such as `node_modules` updates after an install, the terminal shows a single `Functions host restarted.` line and the debugger address only when it changes.
143
144
  When the initial build fails, human output includes a bounded tail of compiler output, and JSON errors include it in `buildOutput`.
144
145
  The tail retains up to 100 complete lines and 64 KiB, with an explicit marker when earlier output is omitted.
145
146
  Verbose mode does not replay the same compiler output a second time.
@@ -28,6 +28,7 @@ This command:
28
28
  - Runs health checks and waits for all services to be healthy.
29
29
  - Applies the project's declared data configuration to the local backend.
30
30
  - Starts the frontend with `npm run dev:frontend` when that script exists, falling back to `npm run dev` for existing projects.
31
+ `rayfin init` sets this up automatically for a from-scratch scaffold, when `@microsoft/rayfin-cli` is installed or already declared as a dependency.
31
32
  - Resolves that script from `services.staticHosting.path` when the frontend lives in a nested package, otherwise from the project root.
32
33
  - Builds and starts the configured local Functions host when `services.functions.enabled` is `true`.
33
34
 
@@ -48,7 +49,7 @@ The command also:
48
49
 
49
50
  - Merges local backend settings into the configured functions package's `local.settings.json`.
50
51
  - Reserves a Node inspector port starting at `9229`.
51
- - Adds `Functions: Attach` to the root `.vscode/launch.json` after the Functions host is ready.
52
+ - Adds `Functions: Attach` to the root `.vscode/launch.json` after the Functions host is ready. If the entry already exists and the inspector moved to another port, only its `port` is updated.
52
53
  - Patches recognized existing `src/services/rayfinClient.ts` and `src/services/bootstrap.ts` files to pass `VITE_RAYFIN_FUNCTIONS_URL` directly only during Vite development.
53
54
 
54
55
  If `.vscode/launch.json` contains JSON with comments, Rayfin leaves it unchanged to avoid losing those comments and asks you to add the attach configuration manually.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@microsoft/rayfin-guide",
3
- "version": "1.36.0-alpha.1818",
3
+ "version": "1.36.0-alpha.1917",
4
4
  "description": "Cross-cutting Builder guides for the Rayfin platform — discovered by `@microsoft/rayfin-docs` via the `rayfinDocs` package.json field convention.",
5
5
  "type": "module",
6
6
  "files": [