# Add tag when push new topic by json api

**URL:** https://meta.discourse.org/t/add-tag-when-push-new-topic-by-json-api/127807
**Category:** Support
**Created:** [9월 6, 2019, 1:21오후 UTC](https://meta.discourse.org/t/add-tag-when-push-new-topic-by-json-api/127807 "2019-09-06T13:21:16Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![Hotfirenet](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/hotfirenet/32/120124_2.png) [@Hotfirenet](https://meta.discourse.org/u/Hotfirenet)
#### Post date: [9월 6, 2019, 1:21오후 UTC](https://meta.discourse.org/t/add-tag-when-push-new-topic-by-json-api/127807/1 "2019-09-06T13:21:17Z")

</div>

Hello,  
when i create new topic by json api, the tag is not taken, see exemple

```plaintext
{
   "api_username":"system",
   "title":"[Test officiel] test ",
   "raw":"Le Lorem Ipsum est simplement du faux texte employé dans la composition et la mise en page avant impression. Le Lorem Ipsum est le faux texte standard de l'imprimerie depuis les années 1500, quand un imprimeur anonyme assembla ensemble des morceaux de texte pour réaliser un livre spécimen de polices de texte. Il n'a pas fait que survivre cinq siècles, mais s'est aussi adapté à la bureautique informatique, sans que son contenu n'en soit modifié. Il a été popularisé dans les années 1960 grâce à la vente de feuilles Letraset contenant des passages du Lorem Ipsum, et, plus récemment, par son inclusion dans des applications de mise en page de texte, comme Aldus PageMaker.",
   "category":62,
   "embed_url":"https:\/\/dev.test.com\/index.php?plugin_id=2554",
   "skip_validations":"true",
   "auto_track":"true",
   "tags[]":"test-officiel"
}

```

Have you an idea ?  
Thanks

---

<div class="post-metadata">

### Author: ![eviltrout](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/eviltrout/32/5275_2.png) [@eviltrout](https://meta.discourse.org/u/eviltrout)
#### Post date: [9월 6, 2019, 8:42오후 UTC](https://meta.discourse.org/t/add-tag-when-push-new-topic-by-json-api/127807/2 "2019-09-06T20:42:40Z")

</div>

I just tried myself and the tags are working via the API when given the name `tags[]` as you did in your example. Are tags working when you browse your forum outside of the API?

---

<div class="post-metadata">

### Author: ![Hotfirenet](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/hotfirenet/32/120124_2.png) [@Hotfirenet](https://meta.discourse.org/u/Hotfirenet)
#### Post date: [9월 9, 2019, 8:17오전 UTC](https://meta.discourse.org/t/add-tag-when-push-new-topic-by-json-api/127807/3 "2019-09-09T08:17:46Z")

</div>

Yes that works with my browser.

 ![05](https://global.discourse-cdn.com/meta/original/3X/5/5/55e6116f026af4a9dbb3d60120f8bd4cf7cb748d.png)

And that works with content-type multiform/data, but i dont want use this method.  
Thanks

---

<div class="post-metadata">

### Author: ![eviltrout](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/eviltrout/32/5275_2.png) [@eviltrout](https://meta.discourse.org/u/eviltrout)
#### Post date: [9월 9, 2019, 2:02오후 UTC](https://meta.discourse.org/t/add-tag-when-push-new-topic-by-json-api/127807/4 "2019-09-09T14:02:33Z")

</div>

That might be your only choice right now. I would accept a PR to fix it though but it’s fairly low priority.

---

<div class="post-metadata">

### Author: ![Hotfirenet](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/hotfirenet/32/120124_2.png) [@Hotfirenet](https://meta.discourse.org/u/Hotfirenet)
#### Post date: [9월 10, 2019, 7:03오전 UTC](https://meta.discourse.org/t/add-tag-when-push-new-topic-by-json-api/127807/5 "2019-09-10T07:03:48Z")

</div>

Ok thanks. so we’ll see later.

---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [10월 10, 2019, 7:14오전 UTC](https://meta.discourse.org/t/add-tag-when-push-new-topic-by-json-api/127807/6 "2019-10-10T07:14:47Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
