@picked/client 0.0.70-next.6 → 0.0.71-next.1

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.
Files changed (177) hide show
  1. package/dist/.tsbuildinfo +1 -0
  2. package/dist/api-CH2FNa6S.cjs +1 -0
  3. package/dist/api-CgqRvuKL.js +38 -0
  4. package/dist/cjs/form/index.js +1 -1
  5. package/dist/cjs/index.js +2 -2
  6. package/dist/cjs/plugins/dom-observer/index.js +1 -1
  7. package/dist/cjs/plugins/dynamic-experiences/index.js +1 -1
  8. package/dist/cjs/server/index.js +1 -1
  9. package/dist/docs/actions.mdx +38 -18
  10. package/dist/docs/api/authentication.md +75 -48
  11. package/dist/docs/api/authorization-and-scopes.md +63 -47
  12. package/dist/docs/api/error-handling.md +70 -54
  13. package/dist/docs/api/index.md +41 -22
  14. package/dist/docs/api/pagination.md +30 -20
  15. package/dist/docs/api-keys.mdx +11 -6
  16. package/dist/docs/chrome-extension.md +22 -5
  17. package/dist/docs/conditions.mdx +32 -19
  18. package/dist/docs/content/asset-library.mdx +65 -34
  19. package/dist/docs/content/content-entries.mdx +8 -2
  20. package/dist/docs/content/layouts.mdx +45 -29
  21. package/dist/docs/content/pages.mdx +29 -14
  22. package/dist/docs/content/sections.mdx +19 -8
  23. package/dist/docs/delivery-api/experience-content.md +10 -5
  24. package/dist/docs/delivery-api/index.md +19 -12
  25. package/dist/docs/delivery-api/preview-caching-crawling.md +27 -14
  26. package/dist/docs/delivery-api/project-config.md +6 -4
  27. package/dist/docs/experiences.mdx +26 -10
  28. package/dist/docs/features.mdx +66 -25
  29. package/dist/docs/fields.mdx +42 -27
  30. package/dist/docs/flow-builder/building-flows.md +38 -20
  31. package/dist/docs/flow-builder/condition-builder.md +32 -21
  32. package/dist/docs/flow-builder/keyboard-shortcuts.md +18 -18
  33. package/dist/docs/flow-builder/nodes.md +26 -13
  34. package/dist/docs/flow-builder/overview.mdx +28 -15
  35. package/dist/docs/gtm-template.md +35 -26
  36. package/dist/docs/guides/build-a-personalized-page.mdx +36 -18
  37. package/dist/docs/image-optimisation-service.md +33 -17
  38. package/dist/docs/index.md +28 -17
  39. package/dist/docs/mcp.md +46 -38
  40. package/dist/docs/pickedql/data-sources.md +65 -43
  41. package/dist/docs/pickedql/dimensions.md +27 -12
  42. package/dist/docs/pickedql/examples.md +38 -26
  43. package/dist/docs/pickedql/filtering.md +10 -6
  44. package/dist/docs/pickedql/index.md +32 -14
  45. package/dist/docs/pickedql/schema.md +85 -76
  46. package/dist/docs/pickedql/virtual-functions.md +62 -36
  47. package/dist/docs/projects.mdx +14 -7
  48. package/dist/docs/reports.mdx +5 -3
  49. package/dist/docs/sdk/actions.md +33 -17
  50. package/dist/docs/sdk/conditions.md +8 -5
  51. package/dist/docs/sdk/content-security-policy.md +5 -4
  52. package/dist/docs/sdk/experiences.md +29 -11
  53. package/dist/docs/sdk/feature-allocation.md +79 -47
  54. package/dist/docs/sdk/features.md +130 -76
  55. package/dist/docs/sdk/fields.md +66 -42
  56. package/dist/docs/sdk/index.md +22 -13
  57. package/dist/docs/sdk/plugins/create-experience.md +18 -15
  58. package/dist/docs/sdk/plugins/dynamic-experiences.md +42 -16
  59. package/dist/docs/sdk/predicates.md +53 -37
  60. package/dist/docs/sdk/ssr/index.md +25 -8
  61. package/dist/docs/sdk/ssr/rendering-and-hydration.md +37 -16
  62. package/dist/docs/sdk/ssr/serialize.md +38 -20
  63. package/dist/docs/sdk/ssr/slots-and-placements.md +28 -10
  64. package/dist/docs/sdk/steps.md +100 -55
  65. package/dist/docs/steps.mdx +20 -11
  66. package/dist/docs/team-management.md +17 -11
  67. package/dist/docs/vite-plugin.md +26 -19
  68. package/dist/docs/workspace-versioning.mdx +14 -8
  69. package/dist/docs/workspaces.mdx +55 -24
  70. package/dist/{dom-BwmTHeT7.js → dom-BqcToNL0.js} +1 -3
  71. package/dist/{dom-CDrHc_j9.cjs → dom-DlLH3FxV.cjs} +1 -1
  72. package/dist/esm/form/index.js +2 -4
  73. package/dist/esm/index.js +50 -45
  74. package/dist/esm/plugins/dom-observer/index.js +1 -1
  75. package/dist/esm/plugins/dynamic-experiences/index.js +2 -2
  76. package/dist/esm/preview/index.js +1 -1
  77. package/dist/esm/server/index.js +12 -10
  78. package/dist/{experience-instance-DOJShRk5.js → experience-instance-DGk11d8a.js} +3 -3
  79. package/dist/experience-instance-Dej3P1sE.cjs +1 -0
  80. package/dist/{plugin-BxMR7fOV.js → plugin-D2UqFikQ.js} +2 -2
  81. package/dist/plugin-DCW-tnjO.cjs +1 -0
  82. package/dist/{preview-channel-DW9J8t4B.js → preview-channel-CSr96XAo.js} +1 -1
  83. package/dist/{protocol-DSqOlW2r.js → protocol-C5KkkiZc.js} +1 -1
  84. package/dist/types/client.d.ts +7 -6
  85. package/dist/types/entities/action/action.d.ts +5 -4
  86. package/dist/types/entities/action/action.d.ts.map +1 -1
  87. package/dist/types/entities/component/component.d.ts +6 -5
  88. package/dist/types/entities/component/component.d.ts.map +1 -1
  89. package/dist/types/entities/condition/condition.d.ts +5 -5
  90. package/dist/types/entities/content/content.d.ts +4 -3
  91. package/dist/types/entities/experience/experience.d.ts +11 -10
  92. package/dist/types/entities/experience/experience.d.ts.map +1 -1
  93. package/dist/types/entities/experience-instance/experience-instance.d.ts +10 -9
  94. package/dist/types/entities/feature/feature.d.ts +3 -2
  95. package/dist/types/entities/feature/feature.d.ts.map +1 -1
  96. package/dist/types/entities/field/field.d.ts +7 -6
  97. package/dist/types/entities/framework/framework.d.ts +7 -6
  98. package/dist/types/entities/framework/framework.d.ts.map +1 -1
  99. package/dist/types/entities/history/history.d.ts +6 -6
  100. package/dist/types/entities/plugin/plugin.d.ts +3 -2
  101. package/dist/types/entities/plugin/plugin.d.ts.map +1 -1
  102. package/dist/types/entities/predicate/predicate.d.ts +4 -3
  103. package/dist/types/entities/predicate/predicate.d.ts.map +1 -1
  104. package/dist/types/entities/response/response-validation.d.ts +3 -2
  105. package/dist/types/entities/response/response.d.ts +12 -11
  106. package/dist/types/entities/session/session.d.ts +2 -1
  107. package/dist/types/entities/step/step.d.ts +6 -5
  108. package/dist/types/exports.d.ts +2 -1
  109. package/dist/types/exports.d.ts.map +1 -1
  110. package/dist/types/form/build-responses.d.ts +2 -1
  111. package/dist/types/form/create-field-evaluator.d.ts +4 -3
  112. package/dist/types/form/create-field-validation.d.ts +5 -4
  113. package/dist/types/form/create-form.d.ts +7 -6
  114. package/dist/types/form/create-submit-pipeline.d.ts +7 -6
  115. package/dist/types/form/get-step-fields.d.ts +3 -2
  116. package/dist/types/lifecycle/condition-selection.d.ts +14 -4
  117. package/dist/types/lifecycle/lifecycle.d.ts +4 -3
  118. package/dist/types/lifecycle/rules-logic.d.ts +4 -3
  119. package/dist/types/lifecycle/state-snapshot.d.ts +4 -3
  120. package/dist/types/picked.d.ts +64 -62
  121. package/dist/types/picked.d.ts.map +1 -1
  122. package/dist/types/ping.d.ts +1 -1
  123. package/dist/types/ping.d.ts.map +1 -1
  124. package/dist/types/plugins/create-experience/create-experience.d.ts +9 -8
  125. package/dist/types/plugins/create-experience/create-experience.d.ts.map +1 -1
  126. package/dist/types/plugins/create-experience/plugin.d.ts +3 -2
  127. package/dist/types/plugins/create-experience/plugin.d.ts.map +1 -1
  128. package/dist/types/plugins/create-experience/serialization.d.ts.map +1 -1
  129. package/dist/types/plugins/dom-observer/plugin.d.ts +1 -1
  130. package/dist/types/plugins/dynamic-experiences/plugin.d.ts +3 -3
  131. package/dist/types/plugins/dynamic-experiences/types.d.ts +8 -5
  132. package/dist/types/plugins/experience-browser-storage/plugin.d.ts +1 -1
  133. package/dist/types/plugins/experience-browser-storage/plugin.d.ts.map +1 -1
  134. package/dist/types/plugins/history-browser-storage/plugin.d.ts +1 -1
  135. package/dist/types/plugins/history-browser-storage/plugin.d.ts.map +1 -1
  136. package/dist/types/plugins/responses-browser-storage/plugin.d.ts +1 -1
  137. package/dist/types/plugins/responses-browser-storage/plugin.d.ts.map +1 -1
  138. package/dist/types/plugins/responses-indexeddb/plugin.d.ts +1 -1
  139. package/dist/types/plugins/single-page-app/plugin.d.ts +1 -1
  140. package/dist/types/plugins/single-page-app/plugin.d.ts.map +1 -1
  141. package/dist/types/plugins/web-components/plugin.d.ts +2 -1
  142. package/dist/types/plugins/window-object/plugin.d.ts +2 -2
  143. package/dist/types/preview-channel.d.ts +5 -1
  144. package/dist/types/preview-receiver/index.d.ts +18 -1
  145. package/dist/types/preview-receiver/protocol.d.ts +10 -1
  146. package/dist/types/server/index.d.ts +3 -3
  147. package/dist/types/server/serialize.d.ts +2 -2
  148. package/dist/types/utils/dom.d.ts +2 -1
  149. package/dist/types/utils/events.d.ts +6 -6
  150. package/dist/types/utils/events.d.ts.map +1 -1
  151. package/dist/types/utils/global-obj.d.ts +1 -1
  152. package/dist/types/utils/global-obj.d.ts.map +1 -1
  153. package/dist/types/utils/id.d.ts.map +1 -1
  154. package/dist/types/utils/logger.d.ts +2 -1
  155. package/dist/types/utils/logger.d.ts.map +1 -1
  156. package/dist/types/utils/node-tree/get-next-node-from-action.d.ts +2 -1
  157. package/dist/types/utils/node-tree/get-next-node-from-condition.d.ts +2 -1
  158. package/dist/types/utils/node-tree/get-next-node.d.ts +1 -1
  159. package/dist/types/utils/node-tree/get-next-node.d.ts.map +1 -1
  160. package/dist/types/utils/node-tree/get-origin-node.d.ts +1 -1
  161. package/dist/types/utils/node-tree/get-origin-node.d.ts.map +1 -1
  162. package/dist/types/utils/node-tree/min-max-steps-to-leaf.d.ts +1 -1
  163. package/dist/types/utils/node-tree/min-max-steps-to-leaf.d.ts.map +1 -1
  164. package/dist/types/utils/node-tree/min-max-steps-to-origin.d.ts +1 -1
  165. package/dist/types/utils/node-tree/min-max-steps-to-origin.d.ts.map +1 -1
  166. package/dist/types/utils/node-tree/next-reachable-step-nodes.d.ts +1 -1
  167. package/dist/types/utils/node-tree/next-reachable-step-nodes.d.ts.map +1 -1
  168. package/dist/types/utils/nodes.d.ts +1 -1
  169. package/dist/types/utils/picked-config.d.ts +2 -1
  170. package/dist/types/utils/rules-logic.d.ts +6 -2
  171. package/dist/types/utils/storage.d.ts +1 -1
  172. package/dist/types/utils/storage.d.ts.map +1 -1
  173. package/package.json +22 -23
  174. package/dist/api-CoUkIxIr.cjs +0 -1
  175. package/dist/api-ahdSBQ3Y.js +0 -40
  176. package/dist/experience-instance-DurC3pE-.cjs +0 -1
  177. package/dist/plugin-CASdGtTX.cjs +0 -1
@@ -4,15 +4,15 @@ layout: docs
4
4
 
5
5
  # Keyboard shortcuts
6
6
 
7
- These shortcuts are available when the flow builder canvas is focused.
7
+ These shortcuts work when the canvas of the flow builder holds the keyboard input.
8
8
 
9
9
  ## Canvas tools
10
10
 
11
11
  | Shortcut (Mac) | Shortcut (PC) | Action |
12
12
  | --- | --- | --- |
13
- | `V` | `V` | Select tool |
14
- | `H` | `H` | Hand tool (pan) |
15
- | `Space` (hold) | `Space` (hold) | Temporary hand tool |
13
+ | `V` | `V` | The choose tool |
14
+ | `H` | `H` | The hand tool, which pans the view |
15
+ | `Space`, held | `Space`, held | The hand tool, while you hold the key |
16
16
 
17
17
  ## Layout
18
18
 
@@ -20,19 +20,19 @@ These shortcuts are available when the flow builder canvas is focused.
20
20
  | --- | --- | --- |
21
21
  | `Shift+L` | `Shift+L` | Auto-layout |
22
22
 
23
- ## Selection
23
+ ## Choice
24
24
 
25
25
  | Shortcut (Mac) | Shortcut (PC) | Action |
26
26
  | --- | --- | --- |
27
- | `Cmd+A` | `Ctrl+A` | Select all nodes |
28
- | `Escape` | `Escape` | Deselect all |
27
+ | `Cmd+A` | `Ctrl+A` | Choose every node |
28
+ | `Escape` | `Escape` | Choose no node |
29
29
 
30
- ## Editing
30
+ ## Edits
31
31
 
32
32
  | Shortcut (Mac) | Shortcut (PC) | Action |
33
33
  | --- | --- | --- |
34
- | `Cmd+D` | `Ctrl+D` | Duplicate selected nodes |
35
- | `Delete` / `Backspace` | `Delete` / `Backspace` | Delete selected nodes |
34
+ | `Cmd+D` | `Ctrl+D` | Make a copy of each chosen node |
35
+ | `Delete` or `Backspace` | `Delete` or `Backspace` | Delete each chosen node |
36
36
  | `Cmd+Z` | `Ctrl+Z` | Undo |
37
37
  | `Cmd+Shift+Z` | `Ctrl+Shift+Z` | Redo |
38
38
 
@@ -40,27 +40,27 @@ These shortcuts are available when the flow builder canvas is focused.
40
40
 
41
41
  | Shortcut (Mac) | Shortcut (PC) | Action |
42
42
  | --- | --- | --- |
43
- | Arrow keys | Arrow keys | Nudge selected nodes |
44
- | `Shift`+Arrow keys | `Shift`+Arrow keys | Large nudge |
43
+ | Arrow keys | Arrow keys | Move each chosen node a small distance |
44
+ | `Shift` and an arrow key | `Shift` and an arrow key | Move each chosen node further |
45
45
 
46
46
  ## Zoom
47
47
 
48
48
  | Shortcut (Mac) | Shortcut (PC) | Action |
49
49
  | --- | --- | --- |
50
- | Scroll | Scroll | Zoom in/out |
51
- | Pinch | Pinch | Zoom in/out (trackpad) |
50
+ | Scroll | Scroll | Zoom in or out |
51
+ | Pinch | Pinch | Zoom in or out, on a trackpad |
52
52
  | `Cmd+=` | `Ctrl+=` | Zoom in |
53
53
  | `Cmd+-` | `Ctrl+-` | Zoom out |
54
- | `Shift+1` | `Shift+1` | Fit view |
54
+ | `Shift+1` | `Shift+1` | Fit the flow to the view |
55
55
  | `Shift+0` | `Shift+0` | Zoom to 100% |
56
56
 
57
57
  ## Panels
58
58
 
59
59
  | Shortcut (Mac) | Shortcut (PC) | Action |
60
60
  | --- | --- | --- |
61
- | `Cmd+\` | `Ctrl+\` | Toggle both side panels |
62
- | `?` | `?` | Toggle shortcuts |
61
+ | `Cmd+\` | `Ctrl+\` | Turn both side panels on or off |
62
+ | `?` | `?` | Turn this shortcut list on or off |
63
63
 
64
64
  ---
65
65
 
66
- [Overview](/flow-builder/overview) · [Nodes](/flow-builder/nodes) · [Building Flows](/flow-builder/building-flows) · **Keyboard Shortcuts** · [Condition Builder](/flow-builder/condition-builder)
66
+ [Overview](/flow-builder/overview) · [Nodes](/flow-builder/nodes) · [Build Flows](/flow-builder/building-flows) · **Keyboard Shortcuts** · [Condition Builder](/flow-builder/condition-builder)
@@ -4,40 +4,53 @@ layout: docs
4
4
 
5
5
  # Nodes
6
6
 
7
- Nodes are the building blocks of a flow. Each node represents a block in your experience. There are four node types.
7
+ A node is one part of a flow. Each node stands for a block in your experience. There
8
+ are four node types.
8
9
 
9
10
  ## Origin
10
11
 
11
- Every flow starts with an origin node. It's a gray circle on the left side of the canvas. It has one output handle on its right side.
12
+ Every flow starts with an origin node. It is a gray circle on the left side of the
13
+ canvas, and it has one output handle on its right side.
12
14
 
13
- You can't move, delete, or duplicate the origin. It's always present.
15
+ You cannot move the origin, delete it, or make a copy of it. It is always there.
14
16
 
15
17
  ## Step
16
18
 
17
- A step node represents a screen shown to visitors. It appears as a blue rectangle on the canvas.
19
+ A step node stands for a screen that a visitor sees. It appears as a blue rectangle
20
+ on the canvas.
18
21
 
19
- Steps hold fields. Drag a field from the entity browser onto a step node to assign it. The node subtitle shows how many fields are assigned.
22
+ A step holds fields. Drag a field from the entity browser onto a step node to assign
23
+ it. The subtitle of the node gives the number of assigned fields.
20
24
 
21
- Each step has a `layoutName` that tells the SDK which visual layout to use when rendering this step. Configure the layout name in the inspector.
25
+ Each step has a `layoutName`. It tells the SDK which visual layout to use for this
26
+ step. Set the layout name in the inspector.
22
27
 
23
28
  ## Action
24
29
 
25
- An action node represents a side effect — something that happens behind the scenes. It appears as a green rectangle.
30
+ An action node stands for a side effect. A side effect happens where the visitor
31
+ cannot see it. The node appears as a green rectangle.
26
32
 
27
- Actions trigger when the flow reaches them. Use actions for tasks like tracking events, sending data, or triggering integrations.
33
+ An action runs when the flow reaches it. Use an action to record an event, to send
34
+ data, or to start an integration.
28
35
 
29
36
  ## Condition
30
37
 
31
- A condition node represents a branching point. It appears as an amber rectangle.
38
+ A condition node stands for a point where the flow splits. It appears as an amber
39
+ rectangle.
32
40
 
33
- Condition nodes have two output handles instead of one. The green handle (top-right) connects to the path taken when the condition is true. The red handle (bottom-right) connects to the path taken when it's false.
41
+ A condition node has two output handles, and not one. The green handle at the top
42
+ right connects to the path for a true result. The red handle at the bottom right
43
+ connects to the path for a false result.
34
44
 
35
- Define the condition logic in the inspector using the visual condition builder. See [Conditions](/conditions) for details.
45
+ Define the rule in the inspector, with the visual condition builder. See
46
+ [Conditions](/conditions) for more detail.
36
47
 
37
48
  ## Handles
38
49
 
39
- Handles are the connection points on nodes. Input handles sit on the left. Output handles sit on the right. Drag from an output handle to an input handle to connect two nodes.
50
+ A handle is a connection point on a node. An input handle is on the left. An output
51
+ handle is on the right. Drag from an output handle to an input handle to connect two
52
+ nodes.
40
53
 
41
54
  ---
42
55
 
43
- [Overview](/flow-builder/overview) · **Nodes** · [Building Flows](/flow-builder/building-flows) · [Keyboard Shortcuts](/flow-builder/keyboard-shortcuts) · [Condition Builder](/flow-builder/condition-builder)
56
+ [Overview](/flow-builder/overview) · **Nodes** · [Build Flows](/flow-builder/building-flows) · [Keyboard Shortcuts](/flow-builder/keyboard-shortcuts) · [Condition Builder](/flow-builder/condition-builder)
@@ -6,7 +6,9 @@ import { Screenshot } from '../../../components/Screenshot'
6
6
 
7
7
  # Flow builder
8
8
 
9
- The flow builder is a visual editor for designing experience flows. You drag blocks onto a canvas, connect them with arrows, and configure each node in an inspector panel.
9
+ The flow builder is a visual editor for an experience flow. You drag a block onto a
10
+ canvas, connect the blocks with arrows, and set the options of each node in an
11
+ inspector panel.
10
12
 
11
13
  <Screenshot
12
14
  route="/{orgSlug}/{projectId}/workspaces/{workspaceId}/experiences/{experienceId}"
@@ -15,36 +17,47 @@ The flow builder is a visual editor for designing experience flows. You drag blo
15
17
 
16
18
  ## Layout
17
19
 
18
- The flow builder has three panels arranged left to right.
20
+ The flow builder has three panels, from left to right.
19
21
 
20
- **Entity browser** (left): Lists all steps, actions, conditions, and fields in your project. Drag items from here onto the canvas.
22
+ **Entity browser**, on the left: it lists every step, action, condition, and field in
23
+ your project. Drag an item from here onto the canvas.
21
24
 
22
- **Canvas** (center): The workspace where you build your flow. Nodes represent blocks. Arrows represent connections between them.
25
+ **Canvas**, in the middle: the area where you build your flow. A node stands for a
26
+ block. An arrow stands for a connection between two blocks.
23
27
 
24
- **Inspector** (right): Shows configuration for the selected node. When nothing is selected, it shows experience-level settings.
28
+ **Inspector**, on the right: it shows the options of the node that you choose. When
29
+ you choose no node, it shows the settings of the experience.
25
30
 
26
31
  ## Panel controls
27
32
 
28
- Drag the dividers between panels to resize them. Press `Cmd/Ctrl+\` to toggle both side panels. Press `Cmd/Ctrl+Shift+\` to toggle just the inspector.
33
+ Drag a divider between two panels to change their size. Press `Cmd/Ctrl+\` to turn
34
+ both side panels on and off. Press `Cmd/Ctrl+Shift+\` to turn the inspector on and
35
+ off.
29
36
 
30
- ## Navigating the canvas
37
+ ## Move around the canvas
31
38
 
32
- **Zoom**: Scroll to zoom in and out.
39
+ **Zoom**: scroll to make the view larger or smaller.
33
40
 
34
- **Pan**: Select the hand tool (press `H`) and drag. Or hold `Space` while dragging. Middle-click drag also pans.
41
+ **Pan**: choose the hand tool with `H`, then drag. You can also hold `Space` and
42
+ drag. A drag with the middle mouse button also pans.
35
43
 
36
- **Select tool**: Press `V` to switch back to the select tool. This is the default — click to select nodes, drag on empty space to marquee-select.
44
+ **Choose tool**: press `V` to go back to the default tool.
45
+ Click to choose a node. Drag on empty space to choose every node inside a rectangle.
37
46
 
38
47
  ## Auto-layout
39
48
 
40
- Click the auto-layout button in the toolbar to automatically arrange all nodes in a clean hierarchy. Useful after adding many nodes or when the canvas gets messy.
49
+ Click the auto-layout button in the toolbar. The flow builder then arranges every
50
+ node into a clean hierarchy. This is useful after you add many nodes, and when the
51
+ canvas becomes messy.
41
52
 
42
- ## Saving
53
+ ## Save your work
43
54
 
44
- Click **Save** in the toolbar to save your flow. The button is enabled when you have unsaved changes.
55
+ Click **Save** in the toolbar to save your flow. The button is active when you have
56
+ an unsaved change.
45
57
 
46
- The flow builder also auto-saves after a period of inactivity. A dot indicator appears on the save button when there are unsaved changes.
58
+ The flow builder also saves by itself after a period of inactivity. A dot on the save
59
+ button means that you have an unsaved change.
47
60
 
48
61
  ---
49
62
 
50
- **Flow Builder** · [Nodes](/flow-builder/nodes) · [Building Flows](/flow-builder/building-flows) · [Keyboard Shortcuts](/flow-builder/keyboard-shortcuts) · [Condition Builder](/flow-builder/condition-builder)
63
+ **Flow Builder** · [Nodes](/flow-builder/nodes) · [Build Flows](/flow-builder/building-flows) · [Keyboard Shortcuts](/flow-builder/keyboard-shortcuts) · [Condition Builder](/flow-builder/condition-builder)
@@ -2,9 +2,10 @@
2
2
  layout: docs
3
3
  ---
4
4
 
5
- # Google Tag Manager template
5
+ # Template for Google Tag Manager
6
6
 
7
- The Picked Ecommerce GTM Tag Template lets you track ecommerce events and send them to Picked directly from Google Tag Manager.
7
+ The Picked Ecommerce template for Google Tag Manager lets you track an ecommerce
8
+ event and send it to Picked.
8
9
 
9
10
  ## Automatic installation
10
11
 
@@ -13,57 +14,65 @@ Install the template from the GTM Community Gallery:
13
14
  1. In Tag Manager, click **Templates**.
14
15
  2. In the **Tag Templates** section, click **Search Gallery**.
15
16
  3. Search for `Picked Ecommerce`.
16
- 4. Click the Picked Ecommerce template to view details.
17
- 5. Click **Add to workspace**.
18
- 6. Review the required permissions and click **Add**.
17
+ 4. Click the Picked Ecommerce template to read its detail.
18
+ 5. Click the **Add to workspace** button.
19
+ 6. Read the permissions that it needs.
20
+ 7. Click **Add**.
19
21
 
20
- ![Picked Ecommerce template in the GTM Community Gallery](/gtm/picked-ecommerce-gtm.png)
22
+ ![The Picked Ecommerce template in the GTM Community Gallery](/gtm/picked-ecommerce-gtm.png)
21
23
 
22
24
  ## Manual installation
23
25
 
24
- If you prefer to import the template file directly:
26
+ To import the template file yourself:
25
27
 
26
- 1. Download the [template file](https://github.com/picked-app/gtm-template/blob/main/template.tpl) from GitHub (use the download icon).
28
+ 1. Download the
29
+ [template file](https://github.com/picked-app/gtm-template/blob/main/template.tpl)
30
+ from GitHub with the download icon.
27
31
  2. In Google Tag Manager, go to **Templates**.
28
32
  3. Click **New**.
29
- 4. Open the three-dot menu and click **Import**.
30
- 5. Select the downloaded template file.
31
- 6. Click **Save**.
33
+ 4. Open the three-dot menu.
34
+ 5. Click **Import**.
35
+ 6. Choose the file that you downloaded.
36
+ 7. Click **Save**.
32
37
 
33
38
  ## Setup
34
39
 
35
40
  ### 1. Create a Tag ID variable
36
41
 
37
- Sign in to the [Picked Dashboard](https://dashboard.picked.app) and copy your project Tag ID. Save it as a constant variable in GTM (e.g. `Picked Tag ID`).
42
+ Sign in to the [Picked Dashboard](https://dashboard.picked.app) and copy the Tag ID of
43
+ your project. Save it as a constant variable in GTM, for example `Picked Tag ID`.
38
44
 
39
- ![Creating a Picked Tag ID variable in GTM](/gtm/gtm-variable.png)
45
+ ![How to create a variable in GTM for the Picked Tag ID](/gtm/gtm-variable.png)
40
46
 
41
47
  ### 2. Create an ecommerce data variable
42
48
 
43
- Create a **Data Layer Variable** with the variable name set to `ecommerce`. This captures the GA4 Enhanced Ecommerce data layer.
49
+ Create a **Data Layer Variable** with the variable name `ecommerce`. It captures what
50
+ GA4 Enhanced Ecommerce writes to the data layer.
44
51
 
45
- ![GA4 Enhanced Ecommerce data layer variable](/gtm/gtm-ecommerce-variable.png)
52
+ ![The variable for the data layer of GA4 Enhanced Ecommerce](/gtm/gtm-ecommerce-variable.png)
46
53
 
47
54
  ### 3. Create event triggers
48
55
 
49
- Add a trigger for each ecommerce event you want to track (e.g. `add_to_cart`, `purchase`, `view_item`).
56
+ Add a trigger for each ecommerce event that you want to track, for example
57
+ `add_to_cart`, `purchase`, or `view_item`.
50
58
 
51
- ![Event triggers for ecommerce tracking](/gtm/gtm-triggers.png)
59
+ ![The event triggers that record an ecommerce event](/gtm/gtm-triggers.png)
52
60
 
53
61
  ### 4. Create tags
54
62
 
55
- Create a new tag for each event, selecting the **Picked Ecommerce** tag template. Assign the matching trigger and configure the options below.
63
+ Create a new tag for each event. Choose the tag template called **Picked Ecommerce**. Assign
64
+ the trigger that matches. Then set the options below.
56
65
 
57
- ![Tags using the Picked Ecommerce template](/gtm/gtm-tags.png)
66
+ ![The tags that use the Picked Ecommerce template](/gtm/gtm-tags.png)
58
67
 
59
- ## Configuration options
68
+ ## Options
60
69
 
61
70
  | Option | Description |
62
71
  | --- | --- |
63
- | **Tag ID** | Your Picked project Tag ID. Find it in the [Picked Dashboard](https://dashboard.picked.app). |
64
- | **Event** | The ecommerce event to track (e.g. `add_to_cart`, `purchase`). |
65
- | **Send ecommerce data** | Enable this to send GA4 Enhanced Ecommerce data to Picked. Should be enabled for all ecommerce events. |
66
- | **GA4 Enhanced Ecommerce Data** | The GTM variable containing GA4 ecommerce data. Use the data layer variable created in step 2. |
67
- | **Additional data** | Optional GTM variable for sending extra metadata with the event. |
72
+ | **Tag ID** | The Tag ID of your Picked project. Find it in the [Picked Dashboard](https://dashboard.picked.app). |
73
+ | **Event** | The ecommerce event to track, for example `add_to_cart` or `purchase`. |
74
+ | **Send ecommerce data** | Turn this on to send the data from GA4 Enhanced Ecommerce to Picked. Turn it on for every ecommerce event. |
75
+ | **GA4 Enhanced Ecommerce Data** | The GTM variable that holds the data from GA4 Enhanced Ecommerce. Use the data layer variable from step 2. |
76
+ | **Additional data** | An optional GTM variable, for more metadata with the event. |
68
77
 
69
- ![Picked Ecommerce tag configuration](/gtm/gtm-tag.png)
78
+ ![The options on a Picked Ecommerce tag](/gtm/gtm-tag.png)
@@ -10,7 +10,10 @@ Build a personalized landing page with Picked: model it in the dashboard, publis
10
10
 
11
11
  ## What you will build
12
12
 
13
- A standalone, SEO-critical landing page whose content lives in Picked's CMS and renders on your server. You model the page's shape once, fill it with content, publish it, then fetch and render it in React or Svelte. The lifecycle from authoring to a hydrated page:
13
+ A standalone landing page where the search rank matters. Its content lives in the
14
+ Picked CMS, and your server renders it. You describe the shape of the page one time,
15
+ fill it with content, and publish it. Your server then reads it and renders it in
16
+ React or in Svelte. These are the stages, from the first draft to a hydrated page:
14
17
 
15
18
  ```
16
19
  Author (dashboard) -> Publish -> Delivery API (config + content)
@@ -21,11 +24,15 @@ Author (dashboard) -> Publish -> Delivery API (config + content)
21
24
 
22
25
  A [Page Layout](/content/layouts) defines the fields your page can hold.
23
26
 
24
- 1. Open your workspace and click **Models** in the sidebar.
25
- 2. Click **New Model** and choose **Page Layout**.
26
- 3. Enter a name and a **Key**, for example `page-hero`. The Key is a unique, stable identifier you use in SDK code and API references.
27
- 4. Add a few fields: a **Single-line text** field `title`, a **Markdown** field `body`, and an **Asset** field `image`.
28
- 5. Save the layout.
27
+ 1. Open your workspace.
28
+ 2. Click **Models** in the sidebar.
29
+ 3. Click **New Model**.
30
+ 4. Choose **Page Layout**.
31
+ 5. Enter a name and a **Key**, for example `page-hero`. The Key is a unique, stable
32
+ identifier. Your SDK code and your API calls both use it.
33
+ 6. Add three fields: a **Single-line text** field `title`, a **Markdown** field
34
+ `body`, and an **Asset** field `image`.
35
+ 7. Save the layout.
29
36
 
30
37
  <Screenshot
31
38
  route="/{orgSlug}/{projectId}/workspaces/{workspaceId}/models"
@@ -36,23 +43,29 @@ See [Page & Step Layouts](/content/layouts) for every field type.
36
43
 
37
44
  ## Create and fill the page
38
45
 
39
- 1. Click **Experiences** in the sidebar, then **New Experience**.
40
- 2. Choose the **Page** type and pick your `page-hero` layout.
41
- 3. On the **Properties** tab, fill in `title`, `body`, and `image`. A [Content Entry](/content/content-entries) is created and linked on first save.
42
- 4. Fix any per-field validation errors.
43
- 5. Publish the workspace to make the page live.
46
+ 1. Click **Experiences** in the sidebar.
47
+ 2. Click **New Experience**.
48
+ 3. Choose the **Page** type.
49
+ 4. Choose your `page-hero` layout.
50
+ 5. On the **Properties** tab, fill in `title`, `body`, and `image`. On the first save,
51
+ Picked creates a [Content Entry](/content/content-entries) and links it to the
52
+ page.
53
+ 6. Correct every field error.
54
+ 7. Publish the workspace to make the page live.
44
55
 
45
56
  See [Pages](/content/pages) for the full editor reference.
46
57
 
47
58
  ## Fetch the config and content
48
59
 
49
- Your server fetches two things from the [Delivery API](/delivery-api): the project config (which experiences and steps exist) and the content for the matching experience.
60
+ Your server reads two things from the [Delivery API](/delivery-api). The first is the
61
+ options of the project, which give the experiences and the steps. The second is the
62
+ content of the experience that matches.
50
63
 
51
64
  ```bash
52
- # 1. Project config: find the steps and their content links
65
+ # 1. The project options: find the steps and their content links.
53
66
  curl https://api.picked.app/api/v1/projects/proj_123
54
67
 
55
- # 2. Experience content: the entry data backing the page
68
+ # 2. The experience content: the entry data of the page.
56
69
  curl https://api.picked.app/api/v1/projects/proj_123/experiences/exp_123/content
57
70
  ```
58
71
 
@@ -63,7 +76,7 @@ In practice you fetch the config, then let `serialize()` fetch the content for y
63
76
  On the server, create a per-request client, call `serialize()` to produce a snapshot, render your app, and embed the snapshot. On the client, seed from the snapshot and hydrate.
64
77
 
65
78
  ```ts
66
- // server.ts
79
+ // `server.ts`
67
80
  import { createClient } from '@picked/client'
68
81
  import { serialize } from '@picked/client/server'
69
82
 
@@ -137,7 +150,12 @@ The provider seeds synchronously, so the server HTML and the client's first pain
137
150
 
138
151
  Confirm the page is crawlable end to end:
139
152
 
140
- 1. View the server response (for example with `curl` or your browser's view-source) and check the rendered HTML contains your `title` and `body`, not an empty shell.
141
- 2. Confirm the content endpoint is reachable anonymously and returns your entry data.
153
+ 1. Read the response from your server. Use `curl`, or the view-source command of
154
+ your browser.
155
+ 2. Check that the HTML holds your `title` and your `body`, and that it is not an
156
+ empty shell.
157
+ 3. Check that the content endpoint answers an anonymous request.
158
+ 4. Check that it returns your entry data.
142
159
 
143
- Published Delivery API responses are crawlable; preview URLs are disallowed. See [Preview, Caching & Crawling](/delivery-api/preview-caching-crawling).
160
+ A crawler can read a published Delivery API response. A preview URL is disallowed.
161
+ See [Preview, cache, and crawlers](/delivery-api/preview-caching-crawling).
@@ -4,7 +4,10 @@ layout: docs
4
4
 
5
5
  # Image optimisation service
6
6
 
7
- The Picked image optimisation service is a hosted endpoint at `https://img.picked-content.com`. It fetches images from allowed source domains, resizes them, re-encodes to modern formats (WebP or AVIF), and caches the result.
7
+ The Picked service for image optimisation is a hosted endpoint at
8
+ `https://img.picked-content.com`. It reads an image from an allowed source domain and
9
+ resizes it. It then encodes the image again to a modern format, WebP or AVIF, and
10
+ caches the result.
8
11
 
9
12
  ## Endpoint
10
13
 
@@ -14,35 +17,39 @@ GET https://img.picked-content.com/_next/image?url={source}&w={width}&q={quality
14
17
 
15
18
  | Parameter | Description |
16
19
  |-----------|-------------|
17
- | `url` | URL-encoded URL of the source image. Must point to an allowed source domain (see below). |
18
- | `w` | Target width in pixels. Must match one of the supported widths. |
19
- | `q` | Target quality (`25`, `50`, `75`, or `100`). |
20
+ | `url` | The URL of the source image, URL-encoded. It must point at an allowed source domain. See below. |
21
+ | `w` | The width in pixels. It must be one of the supported widths. |
22
+ | `q` | The quality: `25`, `50`, `75`, or `100`. |
20
23
 
21
- The service performs content negotiation: if the requesting browser advertises `image/avif` or `image/webp` in its `Accept` header, the response uses that format. Otherwise the response uses the source format.
24
+ The service chooses the response format. When the browser advertises `image/avif` or
25
+ `image/webp` in its `Accept` header, the response uses that format. If it does not,
26
+ the response uses the source format.
22
27
 
23
28
  ## Allowed source domains
24
29
 
25
- The service only fetches from these hostnames:
30
+ The service reads only from these hostnames:
26
31
 
27
32
  - `**.picked.app`
28
33
 
29
- A request whose `url` parameter resolves to any other hostname returns `400 Bad Request`.
34
+ A request with a `url` parameter for any other hostname returns `400 Bad Request`.
30
35
 
31
36
  ## Supported widths
32
37
 
33
- Device sizes, for responsive images that span the viewport width:
38
+ Device sizes, for a responsive image that spans the width of the viewport:
34
39
 
35
40
  ```
36
41
  640, 750, 828, 1080, 1200, 1920, 2048, 3840
37
42
  ```
38
43
 
39
- Image sizes, for fixed-size UI elements such as icons, avatars, and thumbnails:
44
+ Image sizes, for a UI element of fixed size such as an icon, an avatar, or a
45
+ thumbnail:
40
46
 
41
47
  ```
42
48
  16, 32, 48, 64, 96, 128, 256, 384
43
49
  ```
44
50
 
45
- Requests with any other width return `400 Bad Request`. Pick the smallest width that covers your target rendering size at the user's device pixel ratio.
51
+ A request with any other width returns `400 Bad Request`. Choose the smallest width
52
+ that covers the size you render at the device pixel ratio of the visitor.
46
53
 
47
54
  ## Supported qualities
48
55
 
@@ -50,11 +57,13 @@ Requests with any other width return `400 Bad Request`. Pick the smallest width
50
57
  25, 50, 75, 100
51
58
  ```
52
59
 
53
- Lower values reduce bandwidth significantly. `75` is a good default for most images; use `25` or `50` for thumbnails on slow networks.
60
+ A lower value reduces the bandwidth by a large amount. `75` is a good default for
61
+ most images. Use `25` or `50` for a thumbnail on a slow network.
54
62
 
55
63
  ## Responsive images
56
64
 
57
- Combine the endpoint with the standard `srcset` attribute to let browsers pick the right width per viewport:
65
+ Use the endpoint together with the standard `srcset` attribute. The browser then
66
+ picks the correct width for each viewport:
58
67
 
59
68
  ```html
60
69
  <img
@@ -69,12 +78,19 @@ Combine the endpoint with the standard `srcset` attribute to let browsers pick t
69
78
  />
70
79
  ```
71
80
 
72
- ## Caching
81
+ ## Cache
73
82
 
74
- Optimised responses are cached by the upstream CDN. The minimum cache TTL is 60 seconds; the actual lifetime depends on the CDN's eviction policy. If you change the source image at the same URL, expect the optimised variant to remain cached for at least that interval.
83
+ The upstream CDN caches each optimised response. The smallest cache TTL is 60
84
+ seconds. The real lifetime depends on the eviction policy of the CDN. When you change
85
+ the source image at the same URL, the optimised copy stays in the cache for at least
86
+ that time.
75
87
 
76
88
  ## Security
77
89
 
78
- - SVG sources are not optimised. Requests for SVG return the original bytes if the source is allowed; the service never executes embedded scripts.
79
- - Optimised responses carry a strict `Content-Security-Policy` (`default-src *; script-src 'none'; sandbox;`) so even a compromised source cannot run scripts in a viewing browser.
80
- - The response uses `Content-Disposition: inline`, never `attachment`.
90
+ - The service does not optimise an SVG source. A request for an SVG returns the
91
+ original bytes when the source is allowed. The service never runs an embedded
92
+ script.
93
+ - Each optimised response carries a strict `Content-Security-Policy`
94
+ (`default-src *; script-src 'none'; sandbox;`). A compromised source therefore
95
+ cannot run a script in the browser that shows the image.
96
+ - The response uses `Content-Disposition: inline`, and never `attachment`.
@@ -2,25 +2,29 @@
2
2
  layout: docs
3
3
  ---
4
4
 
5
- # Getting Started
5
+ # Start here
6
6
 
7
- Picked lets you build personalized UI flows in a visual editor and deliver them to visitors on your site with a lightweight SDK.
7
+ Picked lets you build personalized UI flows in a visual editor. The SDK then serves
8
+ them to the visitors on your site.
8
9
 
9
10
  ## How it works
10
11
 
11
- You design experiences in the dashboard using a drag-and-drop flow builder. The SDK fetches your published experiences and renders them on your site.
12
+ You build experiences in the dashboard with a drag-and-drop flow builder. The SDK
13
+ reads your published experiences and renders them on your site.
12
14
 
13
15
  ## Quick start
14
16
 
15
17
  ### 1. Create a project
16
18
 
17
- Sign in to the dashboard and create a project. A project represents one website or app.
19
+ Sign in to the dashboard and create a project. A project is one site or one
20
+ application.
18
21
 
19
- See [Projects](/projects) for details.
22
+ See [Projects](/projects) for more detail.
20
23
 
21
24
  ### 2. Install the SDK
22
25
 
23
- Add the SDK to your site and initialize the client. Copy the snippet from your project home page.
26
+ Add the SDK to your site and start the client. Copy the snippet from your project
27
+ home page.
24
28
 
25
29
  ```typescript
26
30
  import { createClient } from '@picked/client'
@@ -33,11 +37,12 @@ const picked = createClient({
33
37
  picked.start()
34
38
  ```
35
39
 
36
- See [SDK Installation](/sdk) for full setup options.
40
+ See [SDK Installation](/sdk) for all setup options.
37
41
 
38
42
  ### 3. Register a component
39
43
 
40
- Register components when creating the client. Each key in the `components` object must match a component name you set in the dashboard.
44
+ Register your components when you create the client. Each key in the `components`
45
+ object must match a component name that you set in the dashboard.
41
46
 
42
47
  ```typescript
43
48
  import { createClient } from '@picked/client'
@@ -52,26 +57,32 @@ const picked = createClient({
52
57
  picked.start()
53
58
  ```
54
59
 
55
- See [SDK Experiences](/sdk/experiences) for targeting, conditions, and component adapters.
60
+ See [SDK Experiences](/sdk/experiences) for conditions, adapters, and the rules that
61
+ put an experience in a slot.
56
62
 
57
63
  ### 4. Create an experience
58
64
 
59
- In the dashboard, open your project and click **Experiences** > **New Experience**. Enter a name and set the component name to match your registered component (e.g., `welcome-survey`).
65
+ In the dashboard, open your project. Click **Experiences**, then **New Experience**.
66
+ Enter a name. Set the component name to match your registered component, for example
67
+ `welcome-survey`.
60
68
 
61
- See [Experiences](/experiences) for configuration options.
69
+ See [Experiences](/experiences) for the options.
62
70
 
63
71
  ### 5. Build the flow
64
72
 
65
- Open the flow builder and drag steps, actions, and conditions onto the canvas. Connect nodes to define the visitor's path through the experience.
73
+ Open the flow builder. Drag steps, actions, and conditions onto the canvas. Connect
74
+ the nodes to define the path that a visitor takes through the experience.
66
75
 
67
- See [Flow Builder](/flow-builder/overview) for a full walkthrough.
76
+ See [Flow Builder](/flow-builder/overview) for a full guide.
68
77
 
69
78
  ### 6. Save and publish
70
79
 
71
- Click **Save** in the flow builder toolbar. The SDK picks up the published experience and renders it to matching visitors on your site.
80
+ Click **Save** in the flow builder toolbar. The SDK reads the published experience
81
+ and renders it to each visitor who matches.
72
82
 
73
83
  ## Next steps
74
84
 
75
- - [Flow Builder](/flow-builder/overview) — Build experience flows visually
76
- - [Steps](/steps), [Fields](/fields), [Actions](/actions), [Conditions](/conditions) — Configure the building blocks of experiences
77
- - [SDK Installation](/sdk) — Full SDK setup and configuration
85
+ - [Flow Builder](/flow-builder/overview) — Build experience flows in a visual editor
86
+ - [Steps](/steps), [Fields](/fields), [Actions](/actions), [Conditions](/conditions)
87
+ — Set up the parts of an experience
88
+ - [SDK Installation](/sdk) — Full SDK setup and options