@picked/client 0.0.70-next.6 → 0.0.70
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.
- package/dist/{api-ahdSBQ3Y.js → api-CPy9G49C.js} +1 -1
- package/dist/api-Ce6xYI--.cjs +1 -0
- package/dist/cjs/index.js +1 -1
- package/dist/cjs/plugins/dynamic-experiences/index.js +1 -1
- package/dist/cjs/server/index.js +1 -1
- package/dist/docs/actions.mdx +38 -18
- package/dist/docs/api/authentication.md +75 -48
- package/dist/docs/api/authorization-and-scopes.md +63 -47
- package/dist/docs/api/error-handling.md +70 -54
- package/dist/docs/api/index.md +41 -22
- package/dist/docs/api/pagination.md +30 -20
- package/dist/docs/api-keys.mdx +11 -6
- package/dist/docs/chrome-extension.md +22 -5
- package/dist/docs/conditions.mdx +32 -19
- package/dist/docs/content/asset-library.mdx +65 -34
- package/dist/docs/content/content-entries.mdx +8 -2
- package/dist/docs/content/layouts.mdx +45 -29
- package/dist/docs/content/pages.mdx +29 -14
- package/dist/docs/content/sections.mdx +19 -8
- package/dist/docs/delivery-api/experience-content.md +10 -5
- package/dist/docs/delivery-api/index.md +19 -12
- package/dist/docs/delivery-api/preview-caching-crawling.md +27 -14
- package/dist/docs/delivery-api/project-config.md +6 -4
- package/dist/docs/experiences.mdx +26 -10
- package/dist/docs/features.mdx +66 -25
- package/dist/docs/fields.mdx +42 -27
- package/dist/docs/flow-builder/building-flows.md +38 -20
- package/dist/docs/flow-builder/condition-builder.md +32 -21
- package/dist/docs/flow-builder/keyboard-shortcuts.md +18 -18
- package/dist/docs/flow-builder/nodes.md +26 -13
- package/dist/docs/flow-builder/overview.mdx +28 -15
- package/dist/docs/gtm-template.md +35 -26
- package/dist/docs/guides/build-a-personalized-page.mdx +36 -18
- package/dist/docs/image-optimisation-service.md +33 -17
- package/dist/docs/index.md +28 -17
- package/dist/docs/mcp.md +46 -38
- package/dist/docs/pickedql/data-sources.md +65 -43
- package/dist/docs/pickedql/dimensions.md +27 -12
- package/dist/docs/pickedql/examples.md +38 -26
- package/dist/docs/pickedql/filtering.md +10 -6
- package/dist/docs/pickedql/index.md +32 -14
- package/dist/docs/pickedql/schema.md +85 -76
- package/dist/docs/pickedql/virtual-functions.md +62 -36
- package/dist/docs/projects.mdx +14 -7
- package/dist/docs/reports.mdx +5 -3
- package/dist/docs/sdk/actions.md +33 -17
- package/dist/docs/sdk/conditions.md +8 -5
- package/dist/docs/sdk/content-security-policy.md +5 -4
- package/dist/docs/sdk/experiences.md +29 -11
- package/dist/docs/sdk/feature-allocation.md +79 -47
- package/dist/docs/sdk/features.md +130 -76
- package/dist/docs/sdk/fields.md +66 -42
- package/dist/docs/sdk/index.md +22 -13
- package/dist/docs/sdk/plugins/create-experience.md +18 -15
- package/dist/docs/sdk/plugins/dynamic-experiences.md +42 -16
- package/dist/docs/sdk/predicates.md +53 -37
- package/dist/docs/sdk/ssr/index.md +25 -8
- package/dist/docs/sdk/ssr/rendering-and-hydration.md +37 -16
- package/dist/docs/sdk/ssr/serialize.md +38 -20
- package/dist/docs/sdk/ssr/slots-and-placements.md +28 -10
- package/dist/docs/sdk/steps.md +100 -55
- package/dist/docs/steps.mdx +20 -11
- package/dist/docs/team-management.md +17 -11
- package/dist/docs/vite-plugin.md +26 -19
- package/dist/docs/workspace-versioning.mdx +14 -8
- package/dist/docs/workspaces.mdx +55 -24
- package/dist/esm/index.js +1 -1
- package/dist/esm/plugins/dynamic-experiences/index.js +2 -2
- package/dist/esm/server/index.js +1 -1
- package/dist/{plugin-BxMR7fOV.js → plugin-ChPkTj__.js} +1 -1
- package/dist/{plugin-CASdGtTX.cjs → plugin-DHn11gn6.cjs} +1 -1
- package/package.json +1 -1
- package/dist/api-CoUkIxIr.cjs +0 -1
|
@@ -2,60 +2,78 @@
|
|
|
2
2
|
layout: docs
|
|
3
3
|
---
|
|
4
4
|
|
|
5
|
-
#
|
|
5
|
+
# Build flows
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
To build a flow, drag a block onto the canvas. Connect your nodes with arrows. Then
|
|
8
|
+
set the options of each node in the inspector.
|
|
8
9
|
|
|
9
10
|
## Add nodes
|
|
10
11
|
|
|
11
|
-
Drag a step, action, or condition from the entity browser onto the canvas. A new
|
|
12
|
+
Drag a step, an action, or a condition from the entity browser onto the canvas. A new
|
|
13
|
+
node appears where you drop it.
|
|
12
14
|
|
|
13
|
-
You can also drop a block directly onto an
|
|
15
|
+
You can also drop a block directly onto an arrow that is there already. The flow
|
|
16
|
+
builder puts the node into the line. The first arrow splits into two arrows, with the
|
|
17
|
+
new node between them. A **+** indicator appears when you hold the pointer over a
|
|
18
|
+
valid arrow.
|
|
14
19
|
|
|
15
20
|
## Connect nodes
|
|
16
21
|
|
|
17
|
-
Click
|
|
22
|
+
Click the output handle of a node, on the right side. Drag to the input handle of
|
|
23
|
+
another node, on the left side. An arrow then joins the two nodes.
|
|
18
24
|
|
|
19
|
-
The flow follows arrows from left to right,
|
|
25
|
+
The flow follows the arrows from left to right, and it starts at the origin. Every
|
|
26
|
+
node after the origin is part of the experience flow.
|
|
20
27
|
|
|
21
28
|
## Branch with conditions
|
|
22
29
|
|
|
23
|
-
Connect the origin
|
|
30
|
+
Connect the origin, or any other node, to a condition node. The condition evaluates
|
|
31
|
+
its rule and sends the flow down one of two paths.
|
|
24
32
|
|
|
25
|
-
Connect the green
|
|
33
|
+
Connect the green handle, for a true result, to the nodes that must run when the
|
|
34
|
+
condition holds. Connect the red handle, for a false result, to the other path. Each
|
|
35
|
+
path can lead to more steps, more actions, and more conditions.
|
|
26
36
|
|
|
27
37
|
## Assign fields to steps
|
|
28
38
|
|
|
29
|
-
Drag a field from the entity browser
|
|
39
|
+
Drag a field from the entity browser onto a step node and drop it. That step then
|
|
40
|
+
holds the field.
|
|
30
41
|
|
|
31
|
-
You can assign
|
|
42
|
+
You can assign more than one field to one step. The step node gives the number of
|
|
43
|
+
assigned fields. To see which fields it holds, choose the step. Then read the
|
|
44
|
+
**Assigned Fields** section in the inspector.
|
|
32
45
|
|
|
33
|
-
##
|
|
46
|
+
## Choose nodes
|
|
34
47
|
|
|
35
|
-
Click a node to
|
|
48
|
+
Click a node to choose it. Its inspector opens in the right panel.
|
|
36
49
|
|
|
37
|
-
Drag on empty canvas to
|
|
50
|
+
Drag on empty canvas to choose every node inside a rectangle. Press `Cmd/Ctrl+A` to
|
|
51
|
+
choose every node.
|
|
38
52
|
|
|
39
|
-
When
|
|
53
|
+
When you choose more than one node, the inspector gives a count and a list in groups.
|
|
54
|
+
Click an item in that list to open its inspector.
|
|
40
55
|
|
|
41
56
|
## Move nodes
|
|
42
57
|
|
|
43
|
-
Drag a
|
|
58
|
+
Drag a node to move it. Each node snaps to the grid.
|
|
44
59
|
|
|
45
|
-
Use arrow keys to
|
|
60
|
+
Use the arrow keys to move a node a small distance. Hold `Shift` to move it further.
|
|
46
61
|
|
|
47
62
|
## Delete nodes
|
|
48
63
|
|
|
49
|
-
|
|
64
|
+
Choose one or more nodes. Press `Delete` or `Backspace`. The flow builder removes
|
|
65
|
+
those nodes and every arrow that joins them.
|
|
50
66
|
|
|
51
67
|
## Duplicate nodes
|
|
52
68
|
|
|
53
|
-
|
|
69
|
+
Choose one or more nodes. Press `Cmd/Ctrl+D`. A copy of each node appears next to the
|
|
70
|
+
first one.
|
|
54
71
|
|
|
55
72
|
## Undo and redo
|
|
56
73
|
|
|
57
|
-
Press `Cmd/Ctrl+Z` to undo. Press `Cmd/Ctrl+Shift+Z` to redo. The undo stack
|
|
74
|
+
Press `Cmd/Ctrl+Z` to undo. Press `Cmd/Ctrl+Shift+Z` to redo. The undo stack records
|
|
75
|
+
each node that you add, each node that you delete, each connection, and each move.
|
|
58
76
|
|
|
59
77
|
---
|
|
60
78
|
|
|
61
|
-
[Overview](/flow-builder/overview) · [Nodes](/flow-builder/nodes) · **
|
|
79
|
+
[Overview](/flow-builder/overview) · [Nodes](/flow-builder/nodes) · **Build Flows** · [Keyboard Shortcuts](/flow-builder/keyboard-shortcuts) · [Condition Builder](/flow-builder/condition-builder)
|
|
@@ -4,51 +4,62 @@ layout: docs
|
|
|
4
4
|
|
|
5
5
|
# Condition builder
|
|
6
6
|
|
|
7
|
-
The condition builder is a visual rule editor
|
|
7
|
+
The condition builder is a visual rule editor, and the dashboard uses it in several
|
|
8
|
+
places. With it you define a rule and you write no code.
|
|
8
9
|
|
|
9
10
|
## Where it appears
|
|
10
11
|
|
|
11
|
-
The
|
|
12
|
+
The dashboard uses the condition builder here:
|
|
12
13
|
|
|
13
|
-
- **Condition nodes** —
|
|
14
|
-
-
|
|
15
|
-
- **
|
|
16
|
-
- **
|
|
14
|
+
- **Condition nodes** — they set which branch the flow takes in the
|
|
15
|
+
[flow builder](/flow-builder/overview).
|
|
16
|
+
- **Experience conditions** — they control when an experience starts for a visitor.
|
|
17
|
+
- **Initialize open conditions** — they control when an experience opens by itself as
|
|
18
|
+
the page loads.
|
|
19
|
+
- **Field option conditions** — they show or hide one option, and the state of the
|
|
20
|
+
visitor decides which.
|
|
17
21
|
|
|
18
22
|
## Rule structure
|
|
19
23
|
|
|
20
|
-
|
|
24
|
+
The builder holds your rules in groups. Each group uses **AND** or **OR**. With
|
|
25
|
+
**AND**, every rule must match. With **OR**, one rule must match.
|
|
21
26
|
|
|
22
27
|
A single rule has three parts:
|
|
23
28
|
|
|
24
|
-
1. **Field** — the data source to evaluate
|
|
25
|
-
2. **Operator** — how to compare
|
|
26
|
-
|
|
29
|
+
1. **Field** — the data source to evaluate.
|
|
30
|
+
2. **Operator** — how to compare. Examples are equals, not equals, greater than, and
|
|
31
|
+
contains.
|
|
32
|
+
3. **Value** — the value to compare against.
|
|
27
33
|
|
|
28
|
-
You can
|
|
34
|
+
You can put a group inside another group to build a larger rule. An example is an AND
|
|
35
|
+
group that holds two OR groups.
|
|
29
36
|
|
|
30
|
-
##
|
|
37
|
+
## Data sources
|
|
31
38
|
|
|
32
|
-
|
|
39
|
+
A rule can point at these data sources:
|
|
33
40
|
|
|
34
|
-
**Responses** — values visitors
|
|
41
|
+
**Responses** — the values that your visitors send through the form fields of the
|
|
42
|
+
current experience. Each field that you create in your project appears here under its
|
|
43
|
+
name.
|
|
35
44
|
|
|
36
|
-
**Actions** —
|
|
45
|
+
**Actions** — the actions that ran during the flow.
|
|
37
46
|
|
|
38
|
-
**Feature flags** — the state of feature
|
|
47
|
+
**Feature flags** — the state of each feature flag in your project. Use it to take a
|
|
48
|
+
branch on whether Picked allocates a visitor to a flag.
|
|
39
49
|
|
|
40
|
-
**Location** —
|
|
50
|
+
**Location** — the parts of the current page URL of the visitor. These are the
|
|
51
|
+
pathname, the search parameters, the hostname, and the hash.
|
|
41
52
|
|
|
42
53
|
## Example
|
|
43
54
|
|
|
44
|
-
To show a step only to
|
|
55
|
+
To show a step only to a visitor who is on one page and who accepted marketing:
|
|
45
56
|
|
|
46
57
|
1. Create an AND group.
|
|
47
58
|
2. Add a rule: **Location → pathname** equals `/pricing`.
|
|
48
|
-
3. Add a rule: **Responses → marketing_opt_in
|
|
59
|
+
3. Add a rule: **Responses → `marketing_opt_in`** equals `true`.
|
|
49
60
|
|
|
50
|
-
|
|
61
|
+
The rule group matches only when both conditions are true.
|
|
51
62
|
|
|
52
63
|
---
|
|
53
64
|
|
|
54
|
-
[Overview](/flow-builder/overview) · [Nodes](/flow-builder/nodes) · [
|
|
65
|
+
[Overview](/flow-builder/overview) · [Nodes](/flow-builder/nodes) · [Build Flows](/flow-builder/building-flows) · [Keyboard Shortcuts](/flow-builder/keyboard-shortcuts) · **Condition Builder**
|
|
@@ -4,15 +4,15 @@ layout: docs
|
|
|
4
4
|
|
|
5
5
|
# Keyboard shortcuts
|
|
6
6
|
|
|
7
|
-
These shortcuts
|
|
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` |
|
|
14
|
-
| `H` | `H` |
|
|
15
|
-
| `Space
|
|
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
|
-
##
|
|
23
|
+
## Choice
|
|
24
24
|
|
|
25
25
|
| Shortcut (Mac) | Shortcut (PC) | Action |
|
|
26
26
|
| --- | --- | --- |
|
|
27
|
-
| `Cmd+A` | `Ctrl+A` |
|
|
28
|
-
| `Escape` | `Escape` |
|
|
27
|
+
| `Cmd+A` | `Ctrl+A` | Choose every node |
|
|
28
|
+
| `Escape` | `Escape` | Choose no node |
|
|
29
29
|
|
|
30
|
-
##
|
|
30
|
+
## Edits
|
|
31
31
|
|
|
32
32
|
| Shortcut (Mac) | Shortcut (PC) | Action |
|
|
33
33
|
| --- | --- | --- |
|
|
34
|
-
| `Cmd+D` | `Ctrl+D` |
|
|
35
|
-
| `Delete`
|
|
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 |
|
|
44
|
-
| `Shift
|
|
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
|
|
51
|
-
| Pinch | Pinch | Zoom in
|
|
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+\` |
|
|
62
|
-
| `?` | `?` |
|
|
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) · [
|
|
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
|
-
|
|
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
|
|
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
|
|
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
|
|
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
|
-
|
|
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
|
|
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
|
|
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
|
-
|
|
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
|
|
38
|
+
A condition node stands for a point where the flow splits. It appears as an amber
|
|
39
|
+
rectangle.
|
|
32
40
|
|
|
33
|
-
|
|
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
|
|
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
|
-
|
|
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** · [
|
|
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
|
|
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
|
|
20
|
+
The flow builder has three panels, from left to right.
|
|
19
21
|
|
|
20
|
-
**Entity browser
|
|
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
|
|
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
|
|
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
|
|
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
|
-
##
|
|
37
|
+
## Move around the canvas
|
|
31
38
|
|
|
32
|
-
**Zoom**:
|
|
39
|
+
**Zoom**: scroll to make the view larger or smaller.
|
|
33
40
|
|
|
34
|
-
**Pan**:
|
|
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
|
-
**
|
|
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
|
|
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
|
-
##
|
|
53
|
+
## Save your work
|
|
43
54
|
|
|
44
|
-
Click **Save** in the toolbar to save your flow. The button is
|
|
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
|
|
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) · [
|
|
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
|
|
5
|
+
# Template for Google Tag Manager
|
|
6
6
|
|
|
7
|
-
The Picked Ecommerce
|
|
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
|
|
17
|
-
5. Click **Add to workspace
|
|
18
|
-
6.
|
|
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
|
-

|
|
22
|
+

|
|
21
23
|
|
|
22
24
|
## Manual installation
|
|
23
25
|
|
|
24
|
-
|
|
26
|
+
To import the template file yourself:
|
|
25
27
|
|
|
26
|
-
1. Download the
|
|
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
|
|
30
|
-
5.
|
|
31
|
-
6.
|
|
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
|
|
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
|
-

|
|
40
46
|
|
|
41
47
|
### 2. Create an ecommerce data variable
|
|
42
48
|
|
|
43
|
-
Create a **Data Layer Variable** with the variable name
|
|
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
|
-

|
|
46
53
|
|
|
47
54
|
### 3. Create event triggers
|
|
48
55
|
|
|
49
|
-
Add a trigger for each ecommerce event you want to track
|
|
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
|
-

|
|
52
60
|
|
|
53
61
|
### 4. Create tags
|
|
54
62
|
|
|
55
|
-
Create a new tag for each event
|
|
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
|
-

|
|
58
67
|
|
|
59
|
-
##
|
|
68
|
+
## Options
|
|
60
69
|
|
|
61
70
|
| Option | Description |
|
|
62
71
|
| --- | --- |
|
|
63
|
-
| **Tag ID** |
|
|
64
|
-
| **Event** | The ecommerce event to track
|
|
65
|
-
| **Send ecommerce data** |
|
|
66
|
-
| **GA4 Enhanced Ecommerce Data** | The GTM variable
|
|
67
|
-
| **Additional data** |
|
|
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
|
-

|
|
@@ -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
|
|
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
|
|
25
|
-
2. Click **
|
|
26
|
-
3.
|
|
27
|
-
4.
|
|
28
|
-
5.
|
|
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
|
|
40
|
-
2.
|
|
41
|
-
3.
|
|
42
|
-
4.
|
|
43
|
-
5.
|
|
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
|
|
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.
|
|
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.
|
|
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.
|
|
141
|
-
|
|
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
|
-
|
|
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).
|