# How to add temporary tags

**URL:** <https://forum.genieacs.com/t/how-to-add-temporary-tags/3947>\
**Category:** Uncategorized\
**Created:** [May 16, 2023, 12:22pm UTC](https://forum.genieacs.com/t/how-to-add-temporary-tags/3947 "2023-05-16T12:22:50Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Felipe](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.genieacs.com/felipe/32/1949_2.png) [@Felipe](https://forum.genieacs.com/u/Felipe)\
**Post date:** [May 16, 2023, 12:22pm UTC](https://forum.genieacs.com/t/how-to-add-temporary-tags/3947/1 "2023-05-16T12:22:50Z")

</div>

Hi everyone,

I’m trying to add temporary tags, my idea is put a tag for a week, for exemple, any suggestion?

---

<div class="post-metadata">

**Author:** ![akcoder](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.genieacs.com/akcoder/32/11_2.png) [@akcoder](https://forum.genieacs.com/u/akcoder)\
**Post date:** [May 16, 2023, 9:10pm UTC](https://forum.genieacs.com/t/how-to-add-temporary-tags/3947/2 "2023-05-16T21:10:09Z")

</div>

This is not possible out of the box. You will need to manually track the tags you want to remove at a specific date. My suggestion is to use a VParam to track this and store the data in the vparam as encoded JSON. Then in your provision script read back the vparam, turn the string back into a json object, do what is needed and update your vparam as necessary. I’ve used this tactic to track which diagnostic comands are currently running on the CPE so I know which values to refresh, capture and send to the server when a `8 DIAGNOSTICS COMPLETE` message comes in.

Here is a vparam that will allow you to store any data.

```javascript
let value;

if ("value" in args[1]) {
    // Set declared value
    value = args[1].value;
} else if ("value" in args[3]) {
    // No declared value, keep current value
    value = args[3].value;
} else {
    // No current value, use default
    value = ['{}', 'xsd:string'];
}

return {writable: true, value: value};

```

---

<div class="post-metadata">

**Author:** ![Felipe](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.genieacs.com/felipe/32/1949_2.png) [@Felipe](https://forum.genieacs.com/u/Felipe)\
**Post date:** [May 31, 2023, 11:33am UTC](https://forum.genieacs.com/t/how-to-add-temporary-tags/3947/3 "2023-05-31T11:33:29Z")

</div>

where can I learn about VParam? GenieACS documentation is too generic

---

<div class="post-metadata">

**Author:** ![akcoder](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.genieacs.com/akcoder/32/11_2.png) [@akcoder](https://forum.genieacs.com/u/akcoder)\
**Post date:** [May 31, 2023, 5:06pm UTC](https://forum.genieacs.com/t/how-to-add-temporary-tags/3947/4 "2023-05-31T17:06:03Z")

</div>

VParams are a GenieACS concept, so you would need to read the documentation. I didn’t find the docs on vparams to be generic.

[https://docs.genieacs.com/en/latest/virtual-parameters.html](https://docs.genieacs.com/en/latest/virtual-parameters.html)

---

<div class="post-metadata">

**Author:** ![Felipe](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.genieacs.com/felipe/32/1949_2.png) [@Felipe](https://forum.genieacs.com/u/Felipe)\
**Post date:** [June 5, 2023, 1:29pm UTC](https://forum.genieacs.com/t/how-to-add-temporary-tags/3947/5 "2023-06-05T13:29:38Z")

</div>

Can you help me to do that? where should I start? I’m totally lost.  
How do I call my VParam to device?

 ![image](https://canada1.discourse-cdn.com/flex035/uploads/genieacs/original/2X/7/7a5cb0ac53bb903270c53543851af0d45c462088.png)

---

<div class="post-metadata">

**Author:** ![Felipe](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.genieacs.com/felipe/32/1949_2.png) [@Felipe](https://forum.genieacs.com/u/Felipe)\
**Post date:** [June 5, 2023, 2:12pm UTC](https://forum.genieacs.com/t/how-to-add-temporary-tags/3947/6 "2023-06-05T14:12:24Z")

</div>

I got it, thanks for you help
