# Is there API to create a new Elastic user to workplace Search?

**URL:** <https://discuss.elastic.co/t/is-there-api-to-create-a-new-elastic-user-to-workplace-search/358950>\
**Category:** Elastic Search\
**Tags:** elastic-workplace-search\
**Created:** [May 7, 2024, 3:39pm UTC](https://discuss.elastic.co/t/is-there-api-to-create-a-new-elastic-user-to-workplace-search/358950 "2024-05-07T15:39:56Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![m-amano](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/m-amano/32/62977_2.png) [@m-amano](https://discuss.elastic.co/u/m-amano)\
**Post date:** [May 7, 2024, 3:39pm UTC](https://discuss.elastic.co/t/is-there-api-to-create-a-new-elastic-user-to-workplace-search/358950/1 "2024-05-07T15:39:56Z")

</div>

Hi.  
I have a question if there is an API to create Elastic users to workplace Search.  
Therefore I don't have to create a user one by one via console.

> **[Manage users and access to Workplace Search | Workplace Search documentation...](https://www.elastic.co/guide/en/workplace-search/current/workplace-search-security.html#security-users-create)**

---

<div class="post-metadata">

**Author:** ![Sean\_Story](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/sean_story/32/69987_2.png) [@Sean\_Story](https://discuss.elastic.co/u/Sean_Story)\
**Post date:** [May 7, 2024, 3:48pm UTC](https://discuss.elastic.co/t/is-there-api-to-create-a-new-elastic-user-to-workplace-search/358950/2 "2024-05-07T15:48:42Z")

</div>

You can create Elasticsearch users through the [Elasticsearch User API](https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-put-user.html). If an Elasticsearch User has the requisite roles, it can access Workplace Search. See: [Manage users and access to Workplace Search | Workplace Search documentation [8.13] | Elastic](https://www.elastic.co/guide/en/workplace-search/current/workplace-search-security.html#security-role-mappings-default)

---

<div class="post-metadata">

**Author:** ![m-amano](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/m-amano/32/62977_2.png) [@m-amano](https://discuss.elastic.co/u/m-amano)\
**Post date:** [May 7, 2024, 4:09pm UTC](https://discuss.elastic.co/t/is-there-api-to-create-a-new-elastic-user-to-workplace-search/358950/3 "2024-05-07T16:09:32Z")

</div>

@Sean_Story  
Thanks for your reply.

> You can create Elasticsearch users through the [Elasticsearch User API](https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-put-user.html). If an Elasticsearch User has the requisite roles, it can access Workplace Search.

Does this mean that if the user has the right role access to Workplace Search, the user can login to Workplace Search via this URL?  
`https://<ENTERPRISE_SEARCH_BASE_URL>/ws/search`

---

<div class="post-metadata">

**Author:** ![Sean\_Story](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/sean_story/32/69987_2.png) [@Sean\_Story](https://discuss.elastic.co/u/Sean_Story)\
**Post date:** [May 7, 2024, 7:04pm UTC](https://discuss.elastic.co/t/is-there-api-to-create-a-new-elastic-user-to-workplace-search/358950/4 "2024-05-07T19:04:35Z")

</div>

Yes. All Workplace Search users are actually Elastic users under the hood. However, those Elastic users may not have access to any direct Elasticsearch APIs or Kibana UIs under the hood, if the only roles given to them allow only access to Workplace Search.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [June 4, 2024, 7:04pm UTC](https://discuss.elastic.co/t/is-there-api-to-create-a-new-elastic-user-to-workplace-search/358950/5 "2024-06-04T19:04:48Z")

</div>

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