SharePoint Online invitation status incorrect?

Brass Contributor

We have a SharePoint Online site collection in-place, which we share with external service providers.

 

The user who manages this site collection has requested me to generate a report that contains information about the invitation status, and deliver it periodically. By this I mean, has the invitation been accepted by the external user? Is the invitation still pending? Has the invitation expired?

 

I found this article https://www.sharepointdiary.com/2019/04/sharepoint-online-check-if-external-user-accepted-invitation... stating that you can use PnP PowerShell to obtain this information from the Access Requests list within the site collection.

It states the status codes are:

Status codeStatus description
0The access request or invitation is pending.
1The access request has been approved.
2The invitation has been accepted.
3The access request has been denied.
4The invitation has expired.
5The invitation has been revoked.

 

I ran the script. However, when I look at the outputs of the script, I see several invitations that come back with status code 0 even though the invitation has expired 1 year ago. So, I would expect this status code value to be 4.

 

To me the status code seems to be incorrect, or am I interpreting this all wrong?

 

Thanks for all help provided.

Joost

0 Replies