# How to fix "key expires\_in " error

This error is caused by incorrect endpoint URLs.

In this case, you should open the app in Azure and copy the first two URLs from the list:

![](/files/hqXYEBdyzDGJbRmUVF3b)

And paste them into Auth endpoint URL and Token endpoint Url, respectively:

![](/files/mTpgfvkzMu85qLZw3kj2)

Please keep in mind that Email This Issue can only work with the v2.0 URL, so if you can't see that in the URL(s), the connections won't work.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.meta-inf.hu/email-this-issue/email-this-issue-for-jira-server-data-center/documentation/administration/mail-server-connections/microsoft-with-oauth2/troubleshooting-guides-for-microsoft-oauth2-connections/how-to-fix-key-expires_in-error.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
