@plotday/twister 0.30.0 → 0.31.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.
- package/bin/commands/deploy.js +9 -10
- package/bin/commands/deploy.js.map +1 -1
- package/bin/utils/network-error.js +2 -2
- package/bin/utils/network-error.js.map +1 -1
- package/dist/common/calendar.d.ts +28 -11
- package/dist/common/calendar.d.ts.map +1 -1
- package/dist/common/messaging.d.ts +4 -5
- package/dist/common/messaging.d.ts.map +1 -1
- package/dist/common/projects.d.ts +4 -5
- package/dist/common/projects.d.ts.map +1 -1
- package/dist/docs/assets/hierarchy.js +1 -1
- package/dist/docs/assets/navigation.js +1 -1
- package/dist/docs/assets/search.js +1 -1
- package/dist/docs/classes/tool.ITool.html +1 -1
- package/dist/docs/classes/tools_ai.AI.html +1 -1
- package/dist/docs/classes/tools_callbacks.Callbacks.html +1 -1
- package/dist/docs/classes/tools_integrations.Integrations.html +1 -1
- package/dist/docs/classes/tools_network.Network.html +1 -1
- package/dist/docs/classes/tools_plot.Plot.html +32 -25
- package/dist/docs/classes/tools_store.Store.html +1 -1
- package/dist/docs/classes/tools_tasks.Tasks.html +1 -1
- package/dist/docs/classes/tools_twists.Twists.html +1 -1
- package/dist/docs/classes/twist.Twist.html +25 -17
- package/dist/docs/enums/plot.ActivityKind.html +14 -0
- package/dist/docs/enums/plot.ActivityLinkType.html +5 -5
- package/dist/docs/enums/plot.ActorType.html +4 -4
- package/dist/docs/enums/plot.ConferencingProvider.html +6 -6
- package/dist/docs/enums/tools_plot.ActivityAccess.html +3 -3
- package/dist/docs/enums/tools_plot.ContactAccess.html +3 -3
- package/dist/docs/enums/tools_plot.PriorityAccess.html +3 -3
- package/dist/docs/hierarchy.html +1 -1
- package/dist/docs/modules/index.html +1 -1
- package/dist/docs/modules/plot.html +1 -1
- package/dist/docs/types/common_calendar.CalendarTool.html +30 -10
- package/dist/docs/types/plot.Activity.html +3 -7
- package/dist/docs/types/plot.ActivityCommon.html +8 -8
- package/dist/docs/types/plot.ActivityLink.html +1 -1
- package/dist/docs/types/plot.ActivityMeta.html +1 -1
- package/dist/docs/types/plot.ActivityOccurrence.html +22 -0
- package/dist/docs/types/plot.ActivityOccurrenceUpdate.html +3 -0
- package/dist/docs/types/plot.ActivityUpdate.html +9 -2
- package/dist/docs/types/plot.ActivityWithNotes.html +1 -1
- package/dist/docs/types/plot.Actor.html +5 -5
- package/dist/docs/types/plot.ContentType.html +1 -1
- package/dist/docs/types/plot.NewActivity.html +11 -3
- package/dist/docs/types/plot.NewActivityOccurrence.html +20 -0
- package/dist/docs/types/plot.NewActivityWithNotes.html +1 -1
- package/dist/docs/types/plot.NewActor.html +1 -1
- package/dist/docs/types/plot.NewContact.html +4 -4
- package/dist/docs/types/plot.NewNote.html +1 -1
- package/dist/docs/types/plot.NewTags.html +1 -1
- package/dist/docs/types/plot.Note.html +1 -1
- package/dist/docs/types/plot.NoteUpdate.html +1 -1
- package/dist/docs/types/plot.PickPriorityConfig.html +2 -2
- package/dist/docs/types/plot.Tags.html +1 -1
- package/dist/docs/types/tools_plot.NoteIntentHandler.html +4 -4
- package/dist/llm-docs/common/calendar.d.ts +1 -1
- package/dist/llm-docs/common/calendar.d.ts.map +1 -1
- package/dist/llm-docs/common/calendar.js +1 -1
- package/dist/llm-docs/common/calendar.js.map +1 -1
- package/dist/llm-docs/common/messaging.d.ts +1 -1
- package/dist/llm-docs/common/messaging.d.ts.map +1 -1
- package/dist/llm-docs/common/messaging.js +1 -1
- package/dist/llm-docs/common/messaging.js.map +1 -1
- package/dist/llm-docs/common/projects.d.ts +1 -1
- package/dist/llm-docs/common/projects.d.ts.map +1 -1
- package/dist/llm-docs/common/projects.js +1 -1
- package/dist/llm-docs/common/projects.js.map +1 -1
- package/dist/llm-docs/plot.d.ts +1 -1
- package/dist/llm-docs/plot.d.ts.map +1 -1
- package/dist/llm-docs/plot.js +1 -1
- package/dist/llm-docs/plot.js.map +1 -1
- package/dist/llm-docs/tools/plot.d.ts +1 -1
- package/dist/llm-docs/tools/plot.d.ts.map +1 -1
- package/dist/llm-docs/tools/plot.js +1 -1
- package/dist/llm-docs/tools/plot.js.map +1 -1
- package/dist/llm-docs/twist.d.ts +1 -1
- package/dist/llm-docs/twist.d.ts.map +1 -1
- package/dist/llm-docs/twist.js +1 -1
- package/dist/llm-docs/twist.js.map +1 -1
- package/dist/plot.d.ts +165 -49
- package/dist/plot.d.ts.map +1 -1
- package/dist/plot.js +18 -0
- package/dist/plot.js.map +1 -1
- package/dist/tools/plot.d.ts +24 -11
- package/dist/tools/plot.d.ts.map +1 -1
- package/dist/tools/plot.js.map +1 -1
- package/dist/twist.d.ts +1 -0
- package/dist/twist.d.ts.map +1 -1
- package/dist/twist.js +0 -14
- package/dist/twist.js.map +1 -1
- package/package.json +1 -1
- package/dist/docs/types/plot.SyncUpdate.html +0 -15
|
@@ -5,7 +5,7 @@ for twists to persist data and interact with the Plot database.</p>
|
|
|
5
5
|
</div><div class="tsd-comment tsd-typography"><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example">Example<a href="#example" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-4">class</span><span class="hl-1"> </span><span class="hl-5">MyTwist</span><span class="hl-1"> </span><span class="hl-4">extends</span><span class="hl-1"> </span><span class="hl-5">Twist</span><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-4">private</span><span class="hl-1"> </span><span class="hl-2">plot</span><span class="hl-1">: </span><span class="hl-5">Plot</span><span class="hl-1">;</span><br/><br/><span class="hl-1"> </span><span class="hl-4">constructor</span><span class="hl-1">(</span><span class="hl-2">id</span><span class="hl-1">: </span><span class="hl-5">string</span><span class="hl-1">, </span><span class="hl-2">tools</span><span class="hl-1">: </span><span class="hl-5">ToolBuilder</span><span class="hl-1">) {</span><br/><span class="hl-1"> </span><span class="hl-4">super</span><span class="hl-1">();</span><br/><span class="hl-1"> </span><span class="hl-4">this</span><span class="hl-1">.</span><span class="hl-2">plot</span><span class="hl-1"> = </span><span class="hl-2">tools</span><span class="hl-1">.</span><span class="hl-6">get</span><span class="hl-1">(</span><span class="hl-2">Plot</span><span class="hl-1">);</span><br/><span class="hl-1"> }</span><br/><br/><span class="hl-1"> </span><span class="hl-4">async</span><span class="hl-1"> </span><span class="hl-6">activate</span><span class="hl-1">(</span><span class="hl-2">priority</span><span class="hl-1">) {</span><br/><span class="hl-1"> </span><span class="hl-7">// Create a welcome activity</span><br/><span class="hl-1"> </span><span class="hl-0">await</span><span class="hl-1"> </span><span class="hl-4">this</span><span class="hl-1">.</span><span class="hl-2">plot</span><span class="hl-1">.</span><span class="hl-6">createActivity</span><span class="hl-1">({</span><br/><span class="hl-1"> </span><span class="hl-2">type:</span><span class="hl-1"> </span><span class="hl-2">ActivityType</span><span class="hl-1">.</span><span class="hl-2">Note</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">title:</span><span class="hl-1"> </span><span class="hl-3">"Welcome to Plot!"</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">links:</span><span class="hl-1"> [{</span><br/><span class="hl-1"> </span><span class="hl-2">title:</span><span class="hl-1"> </span><span class="hl-3">"Get Started"</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">type:</span><span class="hl-1"> </span><span class="hl-2">ActivityLinkType</span><span class="hl-1">.</span><span class="hl-2">external</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">url:</span><span class="hl-1"> </span><span class="hl-3">"https://plot.day/docs"</span><br/><span class="hl-1"> }]</span><br/><span class="hl-1"> });</span><br/><span class="hl-1"> }</span><br/><span class="hl-1">}</span>
|
|
6
6
|
</code><button type="button">Copy</button></pre>
|
|
7
7
|
|
|
8
|
-
</div></div></section><section class="tsd-panel tsd-hierarchy" data-refl="
|
|
8
|
+
</div></div></section><section class="tsd-panel tsd-hierarchy" data-refl="791"><h4>Hierarchy (<a href="../hierarchy.html#tools/plot.Plot">View Summary</a>)</h4><ul class="tsd-hierarchy"><li class="tsd-hierarchy-item"><a href="tool.ITool.html" class="tsd-signature-type tsd-kind-class">ITool</a><ul class="tsd-hierarchy"><li class="tsd-hierarchy-item"><span class="tsd-hierarchy-target">Plot</span></li></ul></li></ul></section><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#L101">tools/plot.ts:101</a></li></ul></aside><section class="tsd-panel-group tsd-index-group"><section class="tsd-panel tsd-index-panel"><details class="tsd-index-content tsd-accordion" open><summary class="tsd-accordion-summary tsd-index-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h5 class="tsd-index-heading uppercase">Index</h5></summary><div class="tsd-accordion-details"><section class="tsd-index-section"><h3 class="tsd-index-heading">Constructors</h3><div class="tsd-index-list"><a href="#constructor" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Constructor"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a>
|
|
9
9
|
</div></section><section class="tsd-index-section"><h3 class="tsd-index-heading">Methods</h3><div class="tsd-index-list"><a href="#createactivity" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Activity</span></a>
|
|
10
10
|
<a href="#createactivities" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Activities</span></a>
|
|
11
11
|
<a href="#updateactivity" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>update<wbr/>Activity</span></a>
|
|
@@ -21,19 +21,22 @@ for twists to persist data and interact with the Plot database.</p>
|
|
|
21
21
|
<a href="#addcontacts" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>add<wbr/>Contacts</span></a>
|
|
22
22
|
<a href="#getactors" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Actors</span></a>
|
|
23
23
|
</div></section><section class="tsd-index-section"><h3 class="tsd-index-heading">Properties</h3><div class="tsd-index-list"><a href="#options" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>Options</span></a>
|
|
24
|
-
</div></section></div></details></section></section><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Constructors</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="constructor"><span>constructor</span><a href="#constructor" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="constructorplot"><span class="tsd-signature-keyword">new</span> <span class="tsd-kind-constructor-signature">Plot</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">Plot</a><a href="#constructorplot" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><h4 class="tsd-returns-title">Returns <a href="" class="tsd-signature-type tsd-kind-class">Plot</a></h4><aside class="tsd-sources"><p>Inherited from <a href="tool.ITool.html">ITool</a>.<a href="tool.ITool.html#constructor">constructor</a></p></aside></div></li></ul></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Methods"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Methods</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createactivity"><code class="tsd-tag">Abstract</code><span>create<wbr/>Activity</span><a href="#createactivity" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createactivity-1"><span class="tsd-kind-call-signature">createActivity</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">activity</span><span class="tsd-signature-symbol">:</span> <a href="../types/plot.NewActivity.html" class="tsd-signature-type tsd-kind-type-alias">NewActivity</a> <span class="tsd-signature-symbol">|</span> <a href="../types/plot.NewActivityWithNotes.html" class="tsd-signature-type tsd-kind-type-alias">NewActivityWithNotes</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/
|
|
24
|
+
</div></section></div></details></section></section><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Constructors</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="constructor"><span>constructor</span><a href="#constructor" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="constructorplot"><span class="tsd-signature-keyword">new</span> <span class="tsd-kind-constructor-signature">Plot</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">Plot</a><a href="#constructorplot" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><h4 class="tsd-returns-title">Returns <a href="" class="tsd-signature-type tsd-kind-class">Plot</a></h4><aside class="tsd-sources"><p>Inherited from <a href="tool.ITool.html">ITool</a>.<a href="tool.ITool.html#constructor">constructor</a></p></aside></div></li></ul></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Methods"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Methods</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createactivity"><code class="tsd-tag">Abstract</code><span>create<wbr/>Activity</span><a href="#createactivity" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createactivity-1"><span class="tsd-kind-call-signature">createActivity</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">activity</span><span class="tsd-signature-symbol">:</span> <a href="../types/plot.NewActivity.html" class="tsd-signature-type tsd-kind-type-alias">NewActivity</a> <span class="tsd-signature-symbol">|</span> <a href="../types/plot.NewActivityWithNotes.html" class="tsd-signature-type tsd-kind-type-alias">NewActivityWithNotes</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/index.Uuid.html" class="tsd-signature-type tsd-kind-type-alias">Uuid</a><span class="tsd-signature-symbol">></span><a href="#createactivity-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a new activity in the Plot system.</p>
|
|
25
25
|
<p>The activity will be automatically assigned an ID and author information
|
|
26
26
|
based on the current execution context. All other fields from NewActivity
|
|
27
27
|
will be preserved in the created activity.</p>
|
|
28
28
|
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">activity</span>: <a href="../types/plot.NewActivity.html" class="tsd-signature-type tsd-kind-type-alias">NewActivity</a> <span class="tsd-signature-symbol">|</span> <a href="../types/plot.NewActivityWithNotes.html" class="tsd-signature-type tsd-kind-type-alias">NewActivityWithNotes</a></span><div class="tsd-comment tsd-typography"><p>The activity data to create</p>
|
|
29
|
-
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/
|
|
30
|
-
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#
|
|
29
|
+
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/index.Uuid.html" class="tsd-signature-type tsd-kind-type-alias">Uuid</a><span class="tsd-signature-symbol">></span></h4><p>Promise resolving to the created activity's ID</p>
|
|
30
|
+
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#L225">tools/plot.ts:225</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createactivities"><code class="tsd-tag">Abstract</code><span>create<wbr/>Activities</span><a href="#createactivities" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createactivities-1"><span class="tsd-kind-call-signature">createActivities</span><span class="tsd-signature-symbol">(</span><br/> <span class="tsd-kind-parameter">activities</span><span class="tsd-signature-symbol">:</span> (<a href="../types/plot.NewActivity.html" class="tsd-signature-type tsd-kind-type-alias">NewActivity</a> <span class="tsd-signature-symbol">|</span> <a href="../types/plot.NewActivityWithNotes.html" class="tsd-signature-type tsd-kind-type-alias">NewActivityWithNotes</a>)<span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/index.Uuid.html" class="tsd-signature-type tsd-kind-type-alias">Uuid</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">></span><a href="#createactivities-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates multiple activities in a single batch operation.</p>
|
|
31
31
|
<p>This method efficiently creates multiple activities at once, which is
|
|
32
32
|
more performant than calling createActivity() multiple times individually.
|
|
33
33
|
All activities are created with the same author and access control rules.</p>
|
|
34
34
|
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">activities</span>: (<a href="../types/plot.NewActivity.html" class="tsd-signature-type tsd-kind-type-alias">NewActivity</a> <span class="tsd-signature-symbol">|</span> <a href="../types/plot.NewActivityWithNotes.html" class="tsd-signature-type tsd-kind-type-alias">NewActivityWithNotes</a>)<span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Array of activity data to create</p>
|
|
35
|
-
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/
|
|
36
|
-
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#
|
|
35
|
+
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/index.Uuid.html" class="tsd-signature-type tsd-kind-type-alias">Uuid</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">></span></h4><p>Promise resolving to array of created activity IDs</p>
|
|
36
|
+
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#L240">tools/plot.ts:240</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="updateactivity"><code class="tsd-tag">Abstract</code><span>update<wbr/>Activity</span><a href="#updateactivity" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="updateactivity-1"><span class="tsd-kind-call-signature">updateActivity</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">activity</span><span class="tsd-signature-symbol">:</span> <a href="../types/plot.ActivityUpdate.html" class="tsd-signature-type tsd-kind-type-alias">ActivityUpdate</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">></span><a href="#updateactivity-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Updates an existing activity in the Plot system.</p>
|
|
37
|
+
<p><strong>Important</strong>: This method only updates existing activities. It will throw an error
|
|
38
|
+
if the activity does not exist. Use <code>createActivity()</code> to create or update (upsert)
|
|
39
|
+
activities.</p>
|
|
37
40
|
<p>Only the fields provided in the update object will be modified - all other fields
|
|
38
41
|
remain unchanged. This enables partial updates without needing to fetch and resend
|
|
39
42
|
the entire activity object.</p>
|
|
@@ -43,85 +46,89 @@ Tags not included in the update remain unchanged.</p>
|
|
|
43
46
|
maintain the correct hierarchical structure.</p>
|
|
44
47
|
<p>When updating scheduling fields (start, end, recurrence*), the database will
|
|
45
48
|
automatically recalculate duration and range values to maintain consistency.</p>
|
|
46
|
-
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">activity</span>: <a href="../types/plot.ActivityUpdate.html" class="tsd-signature-type tsd-kind-type-alias">ActivityUpdate</a></span><div class="tsd-comment tsd-typography"><p>The activity update containing the ID and fields to change</p>
|
|
49
|
+
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">activity</span>: <a href="../types/plot.ActivityUpdate.html" class="tsd-signature-type tsd-kind-type-alias">ActivityUpdate</a></span><div class="tsd-comment tsd-typography"><p>The activity update containing the ID or source and fields to change</p>
|
|
47
50
|
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">></span></h4><p>Promise that resolves when the update is complete</p>
|
|
48
|
-
<div class="tsd-comment tsd-typography"><div class="tsd-tag-
|
|
51
|
+
<div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws">Throws<a href="#throws" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>Error if the activity does not exist</p>
|
|
52
|
+
</div><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example-1">Example<a href="#example-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-7">// Mark a task as complete</span><br/><span class="hl-0">await</span><span class="hl-1"> </span><span class="hl-4">this</span><span class="hl-1">.</span><span class="hl-2">plot</span><span class="hl-1">.</span><span class="hl-6">updateActivity</span><span class="hl-1">({</span><br/><span class="hl-1"> </span><span class="hl-2">id:</span><span class="hl-1"> </span><span class="hl-3">"task-123"</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">done:</span><span class="hl-1"> </span><span class="hl-4">new</span><span class="hl-1"> </span><span class="hl-6">Date</span><span class="hl-1">()</span><br/><span class="hl-1">});</span><br/><br/><span class="hl-7">// Reschedule an event</span><br/><span class="hl-0">await</span><span class="hl-1"> </span><span class="hl-4">this</span><span class="hl-1">.</span><span class="hl-2">plot</span><span class="hl-1">.</span><span class="hl-6">updateActivity</span><span class="hl-1">({</span><br/><span class="hl-1"> </span><span class="hl-2">id:</span><span class="hl-1"> </span><span class="hl-3">"event-456"</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">start:</span><span class="hl-1"> </span><span class="hl-4">new</span><span class="hl-1"> </span><span class="hl-6">Date</span><span class="hl-1">(</span><span class="hl-3">"2024-03-15T10:00:00Z"</span><span class="hl-1">),</span><br/><span class="hl-1"> </span><span class="hl-2">end:</span><span class="hl-1"> </span><span class="hl-4">new</span><span class="hl-1"> </span><span class="hl-6">Date</span><span class="hl-1">(</span><span class="hl-3">"2024-03-15T11:00:00Z"</span><span class="hl-1">)</span><br/><span class="hl-1">});</span><br/><br/><span class="hl-7">// Add and remove tags</span><br/><span class="hl-0">await</span><span class="hl-1"> </span><span class="hl-4">this</span><span class="hl-1">.</span><span class="hl-2">plot</span><span class="hl-1">.</span><span class="hl-6">updateActivity</span><span class="hl-1">({</span><br/><span class="hl-1"> </span><span class="hl-2">id:</span><span class="hl-1"> </span><span class="hl-3">"activity-789"</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">tags:</span><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-14">1</span><span class="hl-2">:</span><span class="hl-1"> </span><span class="hl-4">true</span><span class="hl-1">, </span><span class="hl-7">// Add tag with ID 1</span><br/><span class="hl-1"> </span><span class="hl-14">2</span><span class="hl-2">:</span><span class="hl-1"> </span><span class="hl-4">false</span><span class="hl-1"> </span><span class="hl-7">// Remove tag with ID 2</span><br/><span class="hl-1"> }</span><br/><span class="hl-1">});</span><br/><br/><span class="hl-7">// Update a recurring event exception</span><br/><span class="hl-0">await</span><span class="hl-1"> </span><span class="hl-4">this</span><span class="hl-1">.</span><span class="hl-2">plot</span><span class="hl-1">.</span><span class="hl-6">updateActivity</span><span class="hl-1">({</span><br/><span class="hl-1"> </span><span class="hl-2">id:</span><span class="hl-1"> </span><span class="hl-3">"exception-123"</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">occurrence:</span><span class="hl-1"> </span><span class="hl-4">new</span><span class="hl-1"> </span><span class="hl-6">Date</span><span class="hl-1">(</span><span class="hl-3">"2024-03-20T09:00:00Z"</span><span class="hl-1">),</span><br/><span class="hl-1"> </span><span class="hl-2">title:</span><span class="hl-1"> </span><span class="hl-3">"Rescheduled meeting"</span><br/><span class="hl-1">});</span>
|
|
49
53
|
</code><button type="button">Copy</button></pre>
|
|
50
54
|
|
|
51
|
-
</div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#
|
|
55
|
+
</div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#L301">tools/plot.ts:301</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getnotes"><code class="tsd-tag">Abstract</code><span>get<wbr/>Notes</span><a href="#getnotes" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getnotes-1"><span class="tsd-kind-call-signature">getNotes</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">activity</span><span class="tsd-signature-symbol">:</span> <a href="../types/plot.Activity.html" class="tsd-signature-type tsd-kind-type-alias">Activity</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/plot.Note.html" class="tsd-signature-type tsd-kind-type-alias">Note</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">></span><a href="#getnotes-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Retrieves all notes within an activity.</p>
|
|
52
56
|
<p>Notes are detailed entries within an activity, ordered by creation time.
|
|
53
57
|
Each note can contain markdown content, links, and other detailed information
|
|
54
58
|
related to the parent activity.</p>
|
|
55
59
|
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">activity</span>: <a href="../types/plot.Activity.html" class="tsd-signature-type tsd-kind-type-alias">Activity</a></span><div class="tsd-comment tsd-typography"><p>The activity whose notes to retrieve</p>
|
|
56
60
|
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/plot.Note.html" class="tsd-signature-type tsd-kind-type-alias">Note</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">></span></h4><p>Promise resolving to array of notes in the activity</p>
|
|
57
|
-
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#
|
|
61
|
+
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#L314">tools/plot.ts:314</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createnote"><code class="tsd-tag">Abstract</code><span>create<wbr/>Note</span><a href="#createnote" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createnote-1"><span class="tsd-kind-call-signature">createNote</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">note</span><span class="tsd-signature-symbol">:</span> <a href="../types/plot.NewNote.html" class="tsd-signature-type tsd-kind-type-alias">NewNote</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/index.Uuid.html" class="tsd-signature-type tsd-kind-type-alias">Uuid</a><span class="tsd-signature-symbol">></span><a href="#createnote-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a new note in an activity.</p>
|
|
58
62
|
<p>Notes provide detailed content within an activity, supporting markdown,
|
|
59
63
|
links, and other rich content. The note will be automatically assigned
|
|
60
64
|
an ID and author information based on the current execution context.</p>
|
|
61
65
|
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">note</span>: <a href="../types/plot.NewNote.html" class="tsd-signature-type tsd-kind-type-alias">NewNote</a></span><div class="tsd-comment tsd-typography"><p>The note data to create</p>
|
|
62
|
-
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/
|
|
66
|
+
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/index.Uuid.html" class="tsd-signature-type tsd-kind-type-alias">Uuid</a><span class="tsd-signature-symbol">></span></h4><p>Promise resolving to the created note's ID</p>
|
|
63
67
|
<div class="tsd-comment tsd-typography"><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example-2">Example<a href="#example-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-7">// Create a note with content</span><br/><span class="hl-0">await</span><span class="hl-1"> </span><span class="hl-4">this</span><span class="hl-1">.</span><span class="hl-2">plot</span><span class="hl-1">.</span><span class="hl-6">createNote</span><span class="hl-1">({</span><br/><span class="hl-1"> </span><span class="hl-2">activity:</span><span class="hl-1"> { </span><span class="hl-2">id:</span><span class="hl-1"> </span><span class="hl-3">"activity-123"</span><span class="hl-1"> },</span><br/><span class="hl-1"> </span><span class="hl-2">note:</span><span class="hl-1"> </span><span class="hl-3">"Discussion notes from the meeting..."</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">contentType:</span><span class="hl-1"> </span><span class="hl-3">"markdown"</span><br/><span class="hl-1">});</span><br/><br/><span class="hl-7">// Create a note with links</span><br/><span class="hl-0">await</span><span class="hl-1"> </span><span class="hl-4">this</span><span class="hl-1">.</span><span class="hl-2">plot</span><span class="hl-1">.</span><span class="hl-6">createNote</span><span class="hl-1">({</span><br/><span class="hl-1"> </span><span class="hl-2">activity:</span><span class="hl-1"> { </span><span class="hl-2">id:</span><span class="hl-1"> </span><span class="hl-3">"activity-456"</span><span class="hl-1"> },</span><br/><span class="hl-1"> </span><span class="hl-2">note:</span><span class="hl-1"> </span><span class="hl-3">"Meeting recording available"</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">links:</span><span class="hl-1"> [{</span><br/><span class="hl-1"> </span><span class="hl-2">type:</span><span class="hl-1"> </span><span class="hl-2">ActivityLinkType</span><span class="hl-1">.</span><span class="hl-2">external</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">title:</span><span class="hl-1"> </span><span class="hl-3">"View Recording"</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">url:</span><span class="hl-1"> </span><span class="hl-3">"https://example.com/recording"</span><br/><span class="hl-1"> }]</span><br/><span class="hl-1">});</span>
|
|
64
68
|
</code><button type="button">Copy</button></pre>
|
|
65
69
|
|
|
66
|
-
</div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#
|
|
70
|
+
</div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#L348">tools/plot.ts:348</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createnotes"><code class="tsd-tag">Abstract</code><span>create<wbr/>Notes</span><a href="#createnotes" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createnotes-1"><span class="tsd-kind-call-signature">createNotes</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">notes</span><span class="tsd-signature-symbol">:</span> <a href="../types/plot.NewNote.html" class="tsd-signature-type tsd-kind-type-alias">NewNote</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/index.Uuid.html" class="tsd-signature-type tsd-kind-type-alias">Uuid</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">></span><a href="#createnotes-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates multiple notes in a single batch operation.</p>
|
|
67
71
|
<p>This method efficiently creates multiple notes at once, which is
|
|
68
72
|
more performant than calling createNote() multiple times individually.
|
|
69
73
|
All notes are created with the same author and access control rules.</p>
|
|
70
74
|
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">notes</span>: <a href="../types/plot.NewNote.html" class="tsd-signature-type tsd-kind-type-alias">NewNote</a><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Array of note data to create</p>
|
|
71
|
-
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/
|
|
75
|
+
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/index.Uuid.html" class="tsd-signature-type tsd-kind-type-alias">Uuid</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">></span></h4><p>Promise resolving to array of created note IDs</p>
|
|
72
76
|
<div class="tsd-comment tsd-typography"><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example-3">Example<a href="#example-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-7">// Create multiple notes in one batch</span><br/><span class="hl-0">await</span><span class="hl-1"> </span><span class="hl-4">this</span><span class="hl-1">.</span><span class="hl-2">plot</span><span class="hl-1">.</span><span class="hl-6">createNotes</span><span class="hl-1">([</span><br/><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-2">activity:</span><span class="hl-1"> { </span><span class="hl-2">id:</span><span class="hl-1"> </span><span class="hl-3">"activity-123"</span><span class="hl-1"> },</span><br/><span class="hl-1"> </span><span class="hl-2">note:</span><span class="hl-1"> </span><span class="hl-3">"First message in thread"</span><br/><span class="hl-1"> },</span><br/><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-2">activity:</span><span class="hl-1"> { </span><span class="hl-2">id:</span><span class="hl-1"> </span><span class="hl-3">"activity-123"</span><span class="hl-1"> },</span><br/><span class="hl-1"> </span><span class="hl-2">note:</span><span class="hl-1"> </span><span class="hl-3">"Second message in thread"</span><br/><span class="hl-1"> }</span><br/><span class="hl-1">]);</span>
|
|
73
77
|
</code><button type="button">Copy</button></pre>
|
|
74
78
|
|
|
75
|
-
</div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#
|
|
79
|
+
</div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#L376">tools/plot.ts:376</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="updatenote"><code class="tsd-tag">Abstract</code><span>update<wbr/>Note</span><a href="#updatenote" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="updatenote-1"><span class="tsd-kind-call-signature">updateNote</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">note</span><span class="tsd-signature-symbol">:</span> <a href="../types/plot.NoteUpdate.html" class="tsd-signature-type tsd-kind-type-alias">NoteUpdate</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">></span><a href="#updatenote-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Updates an existing note in the Plot system.</p>
|
|
80
|
+
<p><strong>Important</strong>: This method only updates existing notes. It will throw an error
|
|
81
|
+
if the note does not exist. Use <code>createNote()</code> to create or update (upsert) notes.</p>
|
|
76
82
|
<p>Only the fields provided in the update object will be modified - all other fields
|
|
77
83
|
remain unchanged. This enables partial updates without needing to fetch and resend
|
|
78
84
|
the entire note object.</p>
|
|
79
|
-
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">note</span>: <a href="../types/plot.NoteUpdate.html" class="tsd-signature-type tsd-kind-type-alias">NoteUpdate</a></span><div class="tsd-comment tsd-typography"><p>The note update containing the ID and fields to change</p>
|
|
85
|
+
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">note</span>: <a href="../types/plot.NoteUpdate.html" class="tsd-signature-type tsd-kind-type-alias">NoteUpdate</a></span><div class="tsd-comment tsd-typography"><p>The note update containing the ID or key and fields to change</p>
|
|
80
86
|
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">></span></h4><p>Promise that resolves when the update is complete</p>
|
|
81
|
-
<div class="tsd-comment tsd-typography"><div class="tsd-tag-
|
|
87
|
+
<div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-1">Throws<a href="#throws-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>Error if the note does not exist</p>
|
|
88
|
+
</div><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example-4">Example<a href="#example-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-7">// Update note content</span><br/><span class="hl-0">await</span><span class="hl-1"> </span><span class="hl-4">this</span><span class="hl-1">.</span><span class="hl-2">plot</span><span class="hl-1">.</span><span class="hl-6">updateNote</span><span class="hl-1">({</span><br/><span class="hl-1"> </span><span class="hl-2">id:</span><span class="hl-1"> </span><span class="hl-3">"note-123"</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">note:</span><span class="hl-1"> </span><span class="hl-3">"Updated content with more details"</span><br/><span class="hl-1">});</span><br/><br/><span class="hl-7">// Add tags to a note</span><br/><span class="hl-0">await</span><span class="hl-1"> </span><span class="hl-4">this</span><span class="hl-1">.</span><span class="hl-2">plot</span><span class="hl-1">.</span><span class="hl-6">updateNote</span><span class="hl-1">({</span><br/><span class="hl-1"> </span><span class="hl-2">id:</span><span class="hl-1"> </span><span class="hl-3">"note-456"</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">twistTags:</span><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-2">[Tag.Important]:</span><span class="hl-1"> </span><span class="hl-4">true</span><br/><span class="hl-1"> }</span><br/><span class="hl-1">});</span>
|
|
82
89
|
</code><button type="button">Copy</button></pre>
|
|
83
90
|
|
|
84
|
-
</div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#
|
|
91
|
+
</div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#L410">tools/plot.ts:410</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getactivity"><code class="tsd-tag">Abstract</code><span>get<wbr/>Activity</span><a href="#getactivity" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getactivity-1"><span class="tsd-kind-call-signature">getActivity</span><span class="tsd-signature-symbol">(</span><br/> <span class="tsd-kind-parameter">activity</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">id</span><span class="tsd-signature-symbol">:</span> <a href="../types/index.Uuid.html" class="tsd-signature-type tsd-kind-type-alias">Uuid</a> <span class="tsd-signature-symbol">}</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">source</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/plot.Activity.html" class="tsd-signature-type tsd-kind-type-alias">Activity</a> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol">></span><a href="#getactivity-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Retrieves an activity by ID or source.</p>
|
|
85
92
|
<p>This method enables lookup of activities either by their unique ID or by their
|
|
86
93
|
source identifier (canonical URL from an external system). Archived activities
|
|
87
94
|
are included in the results.</p>
|
|
88
95
|
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">activity</span>: <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">id</span><span class="tsd-signature-symbol">:</span> <a href="../types/index.Uuid.html" class="tsd-signature-type tsd-kind-type-alias">Uuid</a> <span class="tsd-signature-symbol">}</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">source</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span></span><div class="tsd-comment tsd-typography"><p>Activity lookup by ID or source</p>
|
|
89
96
|
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/plot.Activity.html" class="tsd-signature-type tsd-kind-type-alias">Activity</a> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol">></span></h4><p>Promise resolving to the matching activity or null if not found</p>
|
|
90
|
-
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#
|
|
97
|
+
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#L423">tools/plot.ts:423</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getnote"><code class="tsd-tag">Abstract</code><span>get<wbr/>Note</span><a href="#getnote" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getnote-1"><span class="tsd-kind-call-signature">getNote</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">note</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">id</span><span class="tsd-signature-symbol">:</span> <a href="../types/index.Uuid.html" class="tsd-signature-type tsd-kind-type-alias">Uuid</a> <span class="tsd-signature-symbol">}</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">key</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/plot.Note.html" class="tsd-signature-type tsd-kind-type-alias">Note</a> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol">></span><a href="#getnote-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Retrieves a note by ID or key.</p>
|
|
91
98
|
<p>This method enables lookup of notes either by their unique ID or by their
|
|
92
99
|
key (unique identifier within the activity). Archived notes are included
|
|
93
100
|
in the results.</p>
|
|
94
101
|
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">note</span>: <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">id</span><span class="tsd-signature-symbol">:</span> <a href="../types/index.Uuid.html" class="tsd-signature-type tsd-kind-type-alias">Uuid</a> <span class="tsd-signature-symbol">}</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">key</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span></span><div class="tsd-comment tsd-typography"><p>Note lookup by ID or key</p>
|
|
95
102
|
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/plot.Note.html" class="tsd-signature-type tsd-kind-type-alias">Note</a> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol">></span></h4><p>Promise resolving to the matching note or null if not found</p>
|
|
96
|
-
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#
|
|
103
|
+
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#L438">tools/plot.ts:438</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createpriority"><code class="tsd-tag">Abstract</code><span>create<wbr/>Priority</span><a href="#createpriority" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createpriority-1"><span class="tsd-kind-call-signature">createPriority</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">priority</span><span class="tsd-signature-symbol">:</span> <a href="../types/plot.NewPriority.html" class="tsd-signature-type tsd-kind-type-alias">NewPriority</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/plot.Priority.html" class="tsd-signature-type tsd-kind-type-alias">Priority</a><span class="tsd-signature-symbol">></span><a href="#createpriority-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a new priority in the Plot system.</p>
|
|
97
104
|
<p>Priorities serve as organizational containers for activities and twists.
|
|
98
105
|
The created priority will be automatically assigned a unique ID.</p>
|
|
99
106
|
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">priority</span>: <a href="../types/plot.NewPriority.html" class="tsd-signature-type tsd-kind-type-alias">NewPriority</a></span><div class="tsd-comment tsd-typography"><p>The priority data to create</p>
|
|
100
107
|
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/plot.Priority.html" class="tsd-signature-type tsd-kind-type-alias">Priority</a><span class="tsd-signature-symbol">></span></h4><p>Promise resolving to the complete created priority</p>
|
|
101
|
-
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#
|
|
108
|
+
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#L450">tools/plot.ts:450</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getpriority"><code class="tsd-tag">Abstract</code><span>get<wbr/>Priority</span><a href="#getpriority" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getpriority-1"><span class="tsd-kind-call-signature">getPriority</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">priority</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">id</span><span class="tsd-signature-symbol">:</span> <a href="../types/index.Uuid.html" class="tsd-signature-type tsd-kind-type-alias">Uuid</a> <span class="tsd-signature-symbol">}</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">key</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/plot.Priority.html" class="tsd-signature-type tsd-kind-type-alias">Priority</a> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol">></span><a href="#getpriority-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Retrieves a priority by ID or key.</p>
|
|
102
109
|
<p>Archived priorities are included in the results.</p>
|
|
103
110
|
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">priority</span>: <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">id</span><span class="tsd-signature-symbol">:</span> <a href="../types/index.Uuid.html" class="tsd-signature-type tsd-kind-type-alias">Uuid</a> <span class="tsd-signature-symbol">}</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">key</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span></span><div class="tsd-comment tsd-typography"><p>Priority lookup by ID or key</p>
|
|
104
111
|
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/plot.Priority.html" class="tsd-signature-type tsd-kind-type-alias">Priority</a> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol">></span></h4><p>Promise resolving to the matching priority or null if not found</p>
|
|
105
|
-
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#
|
|
112
|
+
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#L461">tools/plot.ts:461</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="updatepriority"><code class="tsd-tag">Abstract</code><span>update<wbr/>Priority</span><a href="#updatepriority" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="updatepriority-1"><span class="tsd-kind-call-signature">updatePriority</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">update</span><span class="tsd-signature-symbol">:</span> <a href="../types/plot.PriorityUpdate.html" class="tsd-signature-type tsd-kind-type-alias">PriorityUpdate</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">></span><a href="#updatepriority-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Updates an existing priority in the Plot system.</p>
|
|
106
113
|
<p>The priority is identified by either its ID or key.
|
|
107
114
|
Only the fields specified in the update will be changed.</p>
|
|
108
115
|
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">update</span>: <a href="../types/plot.PriorityUpdate.html" class="tsd-signature-type tsd-kind-type-alias">PriorityUpdate</a></span><div class="tsd-comment tsd-typography"><p>Priority update containing ID/key and fields to change</p>
|
|
109
116
|
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">></span></h4><p>Promise that resolves when the update is complete</p>
|
|
110
|
-
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#
|
|
117
|
+
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#L475">tools/plot.ts:475</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="addcontacts"><code class="tsd-tag">Abstract</code><span>add<wbr/>Contacts</span><a href="#addcontacts" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="addcontacts-1"><span class="tsd-kind-call-signature">addContacts</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">contacts</span><span class="tsd-signature-symbol">:</span> <a href="../types/plot.NewContact.html" class="tsd-signature-type tsd-kind-type-alias">NewContact</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/plot.Actor.html" class="tsd-signature-type tsd-kind-type-alias">Actor</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">></span><a href="#addcontacts-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Adds contacts to the Plot system.</p>
|
|
111
118
|
<p>Contacts are used for associating people with activities, such as
|
|
112
119
|
event attendees or task assignees. Duplicate contacts (by email)
|
|
113
120
|
will be merged or updated as appropriate.
|
|
114
121
|
This method requires ContactAccess.Write permission.</p>
|
|
115
122
|
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">contacts</span>: <a href="../types/plot.NewContact.html" class="tsd-signature-type tsd-kind-type-alias">NewContact</a><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Array of contact information to add</p>
|
|
116
123
|
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/plot.Actor.html" class="tsd-signature-type tsd-kind-type-alias">Actor</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">></span></h4><p>Promise resolving to array of created/updated actors</p>
|
|
117
|
-
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#
|
|
124
|
+
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#L489">tools/plot.ts:489</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getactors"><code class="tsd-tag">Abstract</code><span>get<wbr/>Actors</span><a href="#getactors" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getactors-1"><span class="tsd-kind-call-signature">getActors</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">ids</span><span class="tsd-signature-symbol">:</span> <a href="../types/plot.ActorId.html" class="tsd-signature-type tsd-kind-type-alias">ActorId</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/plot.Actor.html" class="tsd-signature-type tsd-kind-type-alias">Actor</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">></span><a href="#getactors-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Retrieves actors by their IDs.</p>
|
|
118
125
|
<p>Actors represent users, contacts, or twists in the Plot system.
|
|
119
126
|
This method requires ContactAccess.Read permission.</p>
|
|
120
127
|
</div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">ids</span>: <a href="../types/plot.ActorId.html" class="tsd-signature-type tsd-kind-type-alias">ActorId</a><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Array of actor IDs to retrieve</p>
|
|
121
128
|
</div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><a href="../types/plot.Actor.html" class="tsd-signature-type tsd-kind-type-alias">Actor</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">></span></h4><p>Promise resolving to array of actors</p>
|
|
122
|
-
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#
|
|
129
|
+
<aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#L501">tools/plot.ts:501</a></li></ul></aside></div></li></ul></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Properties"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Properties</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="options"><code class="tsd-tag">Static</code> <code class="tsd-tag">Readonly</code><span>Options</span><a href="#options" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">Options</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{</span><br/> <span class="tsd-kind-property">activity</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-symbol">{</span><br/> <span class="tsd-kind-property">access</span><span class="tsd-signature-symbol">?:</span> <a href="../enums/tools_plot.ActivityAccess.html" class="tsd-signature-type tsd-kind-enum">ActivityAccess</a><span class="tsd-signature-symbol">;</span><br/> <span class="tsd-kind-property">updated</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-symbol">(</span><br/> <span class="tsd-kind-parameter">activity</span><span class="tsd-signature-symbol">:</span> <a href="../types/plot.Activity.html" class="tsd-signature-type tsd-kind-type-alias">Activity</a><span class="tsd-signature-symbol">,</span><br/> <span class="tsd-kind-parameter">changes</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{</span><br/> <span class="tsd-kind-property">tagsAdded</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Record</span><span class="tsd-signature-symbol"><</span><a href="../enums/tag.Tag.html" class="tsd-signature-type tsd-kind-enum">Tag</a><span class="tsd-signature-symbol">,</span> <a href="../types/plot.ActorId.html" class="tsd-signature-type tsd-kind-type-alias">ActorId</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">></span><span class="tsd-signature-symbol">;</span><br/> <span class="tsd-kind-property">tagsRemoved</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Record</span><span class="tsd-signature-symbol"><</span><a href="../enums/tag.Tag.html" class="tsd-signature-type tsd-kind-enum">Tag</a><span class="tsd-signature-symbol">,</span> <a href="../types/plot.ActorId.html" class="tsd-signature-type tsd-kind-type-alias">ActorId</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">></span><span class="tsd-signature-symbol">;</span><br/> <span class="tsd-kind-property">occurrence</span><span class="tsd-signature-symbol">?:</span> <a href="../types/plot.ActivityOccurrence.html" class="tsd-signature-type tsd-kind-type-alias">ActivityOccurrence</a><span class="tsd-signature-symbol">;</span><br/> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">,</span><br/> <span class="tsd-signature-symbol">)</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">></span><span class="tsd-signature-symbol">;</span><br/> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">;</span><br/> <span class="tsd-kind-property">note</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-symbol">{</span><br/> <span class="tsd-kind-property">intents</span><span class="tsd-signature-symbol">?:</span> <a href="../types/tools_plot.NoteIntentHandler.html" class="tsd-signature-type tsd-kind-type-alias">NoteIntentHandler</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/> <span class="tsd-kind-property">created</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">note</span><span class="tsd-signature-symbol">:</span> <a href="../types/plot.Note.html" class="tsd-signature-type tsd-kind-type-alias">Note</a><span class="tsd-signature-symbol">)</span> <span class="tsd-signature-symbol">=></span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">></span><span class="tsd-signature-symbol">;</span><br/> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">;</span><br/> <span class="tsd-kind-property">priority</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">access</span><span class="tsd-signature-symbol">?:</span> <a href="../enums/tools_plot.PriorityAccess.html" class="tsd-signature-type tsd-kind-enum">PriorityAccess</a> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">;</span><br/> <span class="tsd-kind-property">contact</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">access</span><span class="tsd-signature-symbol">?:</span> <a href="../enums/tools_plot.ContactAccess.html" class="tsd-signature-type tsd-kind-enum">ContactAccess</a> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">;</span><br/><span class="tsd-signature-symbol">}</span></div><div class="tsd-comment tsd-typography"><p>Configuration options for the Plot tool.</p>
|
|
123
130
|
<p><strong>Important</strong>: All permissions must be explicitly requested. There are no default permissions.</p>
|
|
124
131
|
</div><div class="tsd-comment tsd-typography"><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example-5">Example<a href="#example-5" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-7">// Minimal configuration with required permissions</span><br/><span class="hl-6">build</span><span class="hl-1">(</span><span class="hl-2">build</span><span class="hl-1">: </span><span class="hl-2">ToolBuilder</span><span class="hl-1">) {</span><br/><span class="hl-1"> </span><span class="hl-0">return</span><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-2">plot:</span><span class="hl-1"> </span><span class="hl-6">build</span><span class="hl-1">(</span><span class="hl-2">Plot</span><span class="hl-1">, {</span><br/><span class="hl-1"> </span><span class="hl-2">activity:</span><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-2">access:</span><span class="hl-1"> </span><span class="hl-2">ActivityAccess</span><span class="hl-1">.</span><span class="hl-2">Create</span><br/><span class="hl-1"> }</span><br/><span class="hl-1"> })</span><br/><span class="hl-1"> };</span><br/><span class="hl-1">}</span><br/><br/><span class="hl-7">// Full configuration with callbacks</span><br/><span class="hl-6">build</span><span class="hl-1">(</span><span class="hl-2">build</span><span class="hl-1">: </span><span class="hl-2">ToolBuilder</span><span class="hl-1">) {</span><br/><span class="hl-1"> </span><span class="hl-0">return</span><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-2">plot:</span><span class="hl-1"> </span><span class="hl-6">build</span><span class="hl-1">(</span><span class="hl-2">Plot</span><span class="hl-1">, {</span><br/><span class="hl-1"> </span><span class="hl-2">activity:</span><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-2">access:</span><span class="hl-1"> </span><span class="hl-2">ActivityAccess</span><span class="hl-1">.</span><span class="hl-2">Create</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">updated:</span><span class="hl-1"> </span><span class="hl-4">this</span><span class="hl-1">.</span><span class="hl-2">onActivityUpdated</span><br/><span class="hl-1"> },</span><br/><span class="hl-1"> </span><span class="hl-2">note:</span><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-2">intents:</span><span class="hl-1"> [{</span><br/><span class="hl-1"> </span><span class="hl-2">description:</span><span class="hl-1"> </span><span class="hl-3">"Schedule meetings"</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">examples:</span><span class="hl-1"> [</span><span class="hl-3">"Schedule a meeting tomorrow"</span><span class="hl-1">],</span><br/><span class="hl-1"> </span><span class="hl-2">handler:</span><span class="hl-1"> </span><span class="hl-4">this</span><span class="hl-1">.</span><span class="hl-2">onSchedulingIntent</span><br/><span class="hl-1"> }],</span><br/><span class="hl-1"> </span><span class="hl-2">created:</span><span class="hl-1"> </span><span class="hl-4">this</span><span class="hl-1">.</span><span class="hl-2">onNoteCreated</span><br/><span class="hl-1"> },</span><br/><span class="hl-1"> </span><span class="hl-2">priority:</span><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-2">access:</span><span class="hl-1"> </span><span class="hl-2">PriorityAccess</span><span class="hl-1">.</span><span class="hl-2">Full</span><br/><span class="hl-1"> },</span><br/><span class="hl-1"> </span><span class="hl-2">contact:</span><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-2">access:</span><span class="hl-1"> </span><span class="hl-2">ContactAccess</span><span class="hl-1">.</span><span class="hl-2">Write</span><br/><span class="hl-1"> }</span><br/><span class="hl-1"> })</span><br/><span class="hl-1"> };</span><br/><span class="hl-1">}</span>
|
|
125
132
|
</code><button type="button">Copy</button></pre>
|
|
126
133
|
|
|
127
|
-
</div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#
|
|
134
|
+
</div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/plotday/plot/blob/main/twist/twister/src/tools/plot.ts#L147">tools/plot.ts:147</a></li></ul></aside></section></section></details></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div><details open class="tsd-accordion tsd-page-navigation"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>On This Page</h3></summary><div class="tsd-accordion-details"><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Constructors</summary><div><a href="#constructor"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Constructor"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a></div></details><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Methods"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Methods</summary><div><a href="#createactivity"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Activity</span></a><a href="#createactivities"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Activities</span></a><a href="#updateactivity"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>update<wbr/>Activity</span></a><a href="#getnotes"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Notes</span></a><a href="#createnote"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Note</span></a><a href="#createnotes"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Notes</span></a><a href="#updatenote"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>update<wbr/>Note</span></a><a href="#getactivity"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Activity</span></a><a href="#getnote"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Note</span></a><a href="#createpriority"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Priority</span></a><a href="#getpriority"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Priority</span></a><a href="#updatepriority"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>update<wbr/>Priority</span></a><a href="#addcontacts"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>add<wbr/>Contacts</span></a><a href="#getactors"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Actors</span></a></div></details><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Properties"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Properties</summary><div><a href="#options"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>Options</span></a></div></details></div></details></div><div class="site-menu"><nav id="tsd-sidebar-links" class="tsd-navigation"><a href="https://plot.day" class="tsd-nav-link">Plot</a><a href="https://github.com/plotday/plot" class="tsd-nav-link">GitHub</a><a href="https://www.npmjs.com/package/@plotday/twister" class="tsd-nav-link">NPM</a></nav><nav class="tsd-navigation"><a href="../modules.html">Creating Plot Twists</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"><li>Loading...</li></ul></nav></div></div></div><footer><p class="tsd-generator">Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></footer><div class="overlay"></div></body></html>
|