# OAuth application setup error

**URL:** <https://discuss.elastic.co/t/oauth-application-setup-error/235443>\
**Category:** Elastic Search\
**Tags:** elastic-workplace-search\
**Created:** [June 3, 2020, 1:59am UTC](https://discuss.elastic.co/t/oauth-application-setup-error/235443 "2020-06-03T01:59:13Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![oariel](https://avatars.discourse-cdn.com/v4/letter/o/3bc359/32.png) [@oariel](https://discuss.elastic.co/u/oariel)\
**Post date:** [June 3, 2020, 1:59am UTC](https://discuss.elastic.co/t/oauth-application-setup-error/235443/1 "2020-06-03T01:59:13Z")

</div>

Hi,

I have Workplace Search up and running on LTS 18 on AWS and it's working fine with a couple of data sources. I'm trying to configure a new oauth application (for a custom search UI application that we've built) and getting an error that reads "An unexpected error occurred". Any help would be highly appreciated.

Thanks!

---

<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:** [June 9, 2020, 2:38pm UTC](https://discuss.elastic.co/t/oauth-application-setup-error/235443/2 "2020-06-09T14:38:51Z")

</div>

Hi oariel,

I'm not totally sure that I'm following, so to clarify - you are configuring the [OAuth Application for Workplace Search](https://www.elastic.co/guide/en/workplace-search/current/workplace-search-search-oauth.html) (`/ws/org/settings/oauth`)? The goal being to use the [Search API](https://www.elastic.co/guide/en/workplace-search/current/workplace-search-search-api.html) to power a custom built UI?

If that's the case, can you share the Workplace Search server logs from when you get your "Unexpected Error?" It might also be helpful for you use CURL to demonstrate your current flow, so that we can see where in the flow you're having an issue.

---

<div class="post-metadata">

**Author:** ![oariel](https://avatars.discourse-cdn.com/v4/letter/o/3bc359/32.png) [@oariel](https://discuss.elastic.co/u/oariel)\
**Post date:** [June 24, 2020, 1:04am UTC](https://discuss.elastic.co/t/oauth-application-setup-error/235443/3 "2020-06-24T01:04:22Z")

</div>

We figured it out - thanks, Sean. The problem was related a reverse-proxy settings.

Question: Is there a way in EWS to add tags to documents which are indexed by the stock SharePoint/OneDrive connectors? We would like to add additional tags of our own so that our application will be able to filter them more effectively.

---

<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:** [June 25, 2020, 2:35pm UTC](https://discuss.elastic.co/t/oauth-application-setup-error/235443/4 "2020-06-25T14:35:22Z")

</div>

Hi Oren,

I'm glad to hear that you got it working.

There is not currently a way to index tags for either the Sharepoint or OneDrive source. However we will consider and evaluate that as a suggestion. In the mean time, organizing your documents into folders by tag might help.

---

<div class="post-metadata">

**Author:** ![oariel](https://avatars.discourse-cdn.com/v4/letter/o/3bc359/32.png) [@oariel](https://discuss.elastic.co/u/oariel)\
**Post date:** [June 25, 2020, 11:00pm UTC](https://discuss.elastic.co/t/oauth-application-setup-error/235443/5 "2020-06-25T23:00:34Z")

</div>

Hi Sean,

This functionality is pretty important for us. We want to associate documents by context (for example, location), and each document can apply to more than one, so the folder approach will be very limited unless we duplicate documents. This capability is built-in in other products and it would be great if you can support it in the very near future.

---

<div class="post-metadata">

**Author:** ![MadsOhm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/madsohm/32/69154_2.png) [@MadsOhm](https://discuss.elastic.co/u/MadsOhm)\
**Post date:** [June 26, 2020, 6:18am UTC](https://discuss.elastic.co/t/oauth-application-setup-error/235443/6 "2020-06-26T06:18:55Z")

</div>

Hi Oren

I'm not quite sure I know what you mean when you write "tags". I can't seem to find tags mentioned in the SharePoint API at a glance. Could you point me in the right direction?

---

<div class="post-metadata">

**Author:** ![oariel](https://avatars.discourse-cdn.com/v4/letter/o/3bc359/32.png) [@oariel](https://discuss.elastic.co/u/oariel)\
**Post date:** [June 26, 2020, 2:03pm UTC](https://discuss.elastic.co/t/oauth-application-setup-error/235443/7 "2020-06-26T14:03:53Z")

</div>

Sorry, this is how we refer to them internally. I was referring to fields in a schema. So just like you can define your own fields in a custom connector schema, we'd like to be able to add additional fields to the out-of-the-box connectors such as SharePoint, OneDrive etc.

---

<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:** [October 31, 2022, 2:48am UTC](https://discuss.elastic.co/t/oauth-application-setup-error/235443/8 "2022-10-31T02:48:05Z")

</div>

Closed on October 31, 2022, 2:48am UTC

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