I need to know the Rest API to see the API Token of the current user espiry date. Do we have such Rest API. Please help me
Welcome @Naveen Kumar C
As Shannon has commented here: https://community.atlassian.com/t5/Confluence-questions/API-Token-expiration/qaq-p/1083429#:~:text=When%20referring%20to%20the%20API,Those%20expire%20after%207%20days , there is no expiration date for the API tokens.
Hi @Nikola Perisic
As per December 15 2024 now the APi tokens shall have a expiring date
See API tokens will now have a maximum one‑year expiry - Atlassian Community
From this prospective It would be useful to have a Rest API that can read the users API tokens and expiring date to be able to be notified and take actions
Do you know if Atlassian is thinking about this rest API?
Thanks
Alberto
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello @amo
Yes Atlassian did include the expiry date for the API token.
https://support.atlassian.com/atlassian-account/docs/manage-api-tokens-for-your-atlassian-account/
I am not aware that Atlassian will provide the REST API endpoint for this one, but it is a good idea indeed.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Nikola Perisic
Do you know if there is a place where we can suggest this new API to Atlassian? Something like a Jira Backlog for proposals.
BR
Alberto
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
For the next one searching the possibility to read the Jira API tokens there is actually already an API
The API Access REST API
You need to use an Jira API Key as Bearer token
e.g. in Powershell
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You need to use an Jira API Key as Bearer token
I think you're mistaken. Access to the API Access REST API is restricted to Org Admins and requires the use of an Organization API Key.
A 'plain' Jira (user) API Key will not work.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi @Sunny Ape
yes indeed. I have used the organisation API token as bearer token and it is working fine. Thanks for the info
the API I have mentioned is indeed a Org Rest API
but good point
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Naveen Kumar C ,
I'm not sure if API for this exists but you might want to check the following developer documentation: https://developer.atlassian.com/cloud/admin/organization/rest/intro/#About
Also, if you're using Atlassian Guard (Standard or Premium), from the Admin Hub you can view all API tokens for managed users. However, I've just tested this and it seems that you cannot see the token expiry date, whether from the Admin Hub or when you export that data into CSV. More about viewing user API tokens can be found here: https://support.atlassian.com/organization-administration/docs/view-user-api-tokens/
Might be worth a shot to try to reach out Atlassian Support and ask them directly about it.
Cheers,
Tom
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.