# Add a user to a group via API?

**URL:** <https://meta.discourse.org/t/add-a-user-to-a-group-via-api/45077>\
**Category:** Development\
**Tags:** rest-api\
**Created:** [June 1, 2016, 9:42am UTC](https://meta.discourse.org/t/add-a-user-to-a-group-via-api/45077 "2016-06-01T09:42:55Z")\
**Posts on this page:** 1\
**Showing post:** 8

<div class="post-metadata">

**Author:** ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)\
**Post date:** [January 31, 2018, 7:03pm UTC](https://meta.discourse.org/t/add-a-user-to-a-group-via-api/45077/8 "2018-01-31T19:03:45Z")

</div>

This script will create a user and optionally add it to a group:

[https://github.com/pfaffman/discourse-user-creator](https://github.com/pfaffman/discourse-user-creator)

---

_[View the full topic](https://meta.discourse.org/t/add-a-user-to-a-group-via-api/45077)._
