Site updated at 2018-01-15 11:59:29 UTC
This commit is contained in:
parent
bd22e4b200
commit
bf18f14fe7
772 changed files with 16363 additions and 3384 deletions
|
@ -111,9 +111,81 @@
|
|||
<p>After that click on the “login completed” button. This will tell Home Assistant that you have completed the login process on the Remember The Milk page and Home Assistant should try to register with this account.</p>
|
||||
<p>If the registration was successful, the Configuration panel will disappear from your Home Assistant screen and a Remember The Milk panel should appear. This completes the setup process.</p>
|
||||
<p>In the background Home Assistant downloaded a “token” from the Remember The Milk server which is stored in the <code class="highlighter-rouge">remember_the_milk.conf</code> file locally. So you only need to register once. After that the token is used to authenticate with the server.</p>
|
||||
<h2><a class="title-link" name="creating-tasks" href="#creating-tasks"></a> Creating tasks</h2>
|
||||
<p>This component offers a new service domain <code class="highlighter-rouge">remember_the_milk</code> with the service <code class="highlighter-rouge">create_task</code>. You can call this service with the argument <code class="highlighter-rouge">name</code> to create a new task in your Remember The Milk account. You can call this service from your usual automations.</p>
|
||||
<h2><a class="title-link" name="creatingupdating-tasks-with-service-create_task" href="#creatingupdating-tasks-with-service-create_task"></a> Creating/updating tasks with service <code class="highlighter-rouge">create_task</code></h2>
|
||||
<p>This component offers a new service domain <code class="highlighter-rouge">remember_the_milk</code> with the services <code class="highlighter-rouge"><account>_create_task</code>. You can call this service with the argument <code class="highlighter-rouge">name</code> and the optional parameter <code class="highlighter-rouge">id</code> to create a new task in your Remember The Milk account. You can call this service from your usual automations.</p>
|
||||
<p>If you set an <code class="highlighter-rouge">id</code> and a task with that id exists already, the existing task is updated, rather than creating a new task. This way you can change the name of the task. If you do not set an <code class="highlighter-rouge">id</code>, a new task is created with every call. If you’re using this from an automation, you could use the name of your automation as id or the entity that triggered the task to be created. This way you can later on update or complete this task.</p>
|
||||
<p>The task creation supports the “smart syntax”, so to create a task with the tag “from_hass” which is due today you can create a task with the name <code class="highlighter-rouge">test task created in Home Assistant ^today #from_hass</code>. More info about the smart syntax is available on the <a href="https://www.rememberthemilk.com/help/answer/basics-smartadd-howdoiuse">Remember The Milk documentation</a>.</p>
|
||||
<p><strong>Note:</strong>
|
||||
At the moment, smart syntax is <em>not</em> supported when updating tasks. All smart syntax commands are ignored during the update and will end up as normal text in the name of the task.</p>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Service data attribute</th>
|
||||
<th>Optional</th>
|
||||
<th>Description</th>
|
||||
<th>Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>name</td>
|
||||
<td>no</td>
|
||||
<td>Name of the new task, you can use the smart syntax here.</td>
|
||||
<td>“do this ^today #from_hass”</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>id</td>
|
||||
<td>yes</td>
|
||||
<td>Identifier for the task you’re creating, can be used to update or complete the task later on</td>
|
||||
<td>“myid”</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<h2><a class="title-link" name="completing-tasks-with-service--complete_task" href="#completing-tasks-with-service--complete_task"></a> Completing tasks with service <code class="highlighter-rouge">complete_task</code></h2>
|
||||
<p>Complete a tasks that was privously created from Home Assistant. You can not complete tasks that were created outside of Home Assistant.</p>
|
||||
<p>If you have created your task with an <code class="highlighter-rouge">id</code>, calling <code class="highlighter-rouge"><account>_complete_task</code> with the parameter <code class="highlighter-rouge">id</code> will then complete your task.</p>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Service data attribute</th>
|
||||
<th>Optional</th>
|
||||
<th>Description</th>
|
||||
<th>Example</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>id</td>
|
||||
<td>no</td>
|
||||
<td>Identifier that was defined when creating the task</td>
|
||||
<td>“myid”</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<h2><a class="title-link" name="automation-example" href="#automation-example"></a> Automation example</h2>
|
||||
<p>Here’s an example for an automation that creates a new task whenever <code class="highlighter-rouge">sensor.mysensor</code> is <code class="highlighter-rouge">on</code> and completes it when the sensor reports <code class="highlighter-rouge">off</code>. This way it reminds you to switch it off. By using the <code class="highlighter-rouge">entity_id</code> as id for the task, you can use the same rule also for multiple sensors.</p>
|
||||
<div class="language-yaml highlighter-rouge"><pre class="highlight"><code><span class="pi">-</span> <span class="s">id</span><span class="pi">:</span> <span class="s">mysensor_on</span>
|
||||
<span class="s">trigger</span><span class="pi">:</span>
|
||||
<span class="s">platform</span><span class="pi">:</span> <span class="s">state</span>
|
||||
<span class="s">entity_id</span><span class="pi">:</span> <span class="s">sensor.mysensor</span>
|
||||
<span class="s">to</span><span class="pi">:</span> <span class="s">on</span>
|
||||
<span class="s">action</span><span class="pi">:</span>
|
||||
<span class="pi">-</span> <span class="s">service</span><span class="pi">:</span> <span class="s">remember_the_milk.myaccount_create_task</span>
|
||||
<span class="s">data_template</span><span class="pi">:</span>
|
||||
<span class="s">name</span><span class="pi">:</span> <span class="s2">"</span><span class="s">Please</span><span class="nv"> </span><span class="s">switch</span><span class="nv"> </span><span class="s">of</span><span class="nv"> </span><span class="s">"</span>
|
||||
<span class="s">id</span><span class="pi">:</span> <span class="s2">"</span><span class="s">"</span>
|
||||
<span class="pi">-</span> <span class="s">id</span><span class="pi">:</span> <span class="s">mysensor_off</span>
|
||||
<span class="s">trigger</span><span class="pi">:</span>
|
||||
<span class="s">platform</span><span class="pi">:</span> <span class="s">state</span>
|
||||
<span class="s">entity_id</span><span class="pi">:</span> <span class="s">sensor.mysensor</span>
|
||||
<span class="s">to</span><span class="pi">:</span> <span class="s">off</span>
|
||||
<span class="s">action</span><span class="pi">:</span>
|
||||
<span class="pi">-</span> <span class="s">service</span><span class="pi">:</span> <span class="s">remember_the_milk.myaccount_complete_task</span>
|
||||
<span class="s">data_template</span><span class="pi">:</span>
|
||||
<span class="s">id</span><span class="pi">:</span> <span class="s2">"</span><span class="s">"</span>
|
||||
|
||||
</code></pre>
|
||||
</div>
|
||||
<h2><a class="title-link" name="disclaimer" href="#disclaimer"></a> Disclaimer</h2>
|
||||
<p>This product uses the Remember The Milk API but is not endorsed or certified by Remember The Milk.</p>
|
||||
</article>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue