> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cocoondata.com/llms.txt
> Use this file to discover all available pages before exploring further.

# <access-service>/api/v1/organisations/{orgGroupId}/users/{userId}/itemCount

## URL structure&#x20;

```text theme={null}
https://access-service.xy-company.com/api/v1/organisations/{orgGroupId}/users/{userId}/itemCount
```

where `{orgGroupId}` is the ID of an organisation and `{userId}` is the ID of a Covata user account.

## Supported methods and overview&#x20;

* `GET` - retrieves the total number of file objects/[Secure Object](/3.5/api/working-with-files-and-folders-fundamentals.md#secure-object)s currently owned by a [Covata user](/3.5/api/authentication-and-authorisation.md) (specified by `userId`) within an organisation (specified by `orgGroupId`).

> [!NOTE]
>
> This method takes no parameters.

## Detailed description&#x20;

This API endpoint retrieves the total number of file objects/Secure Objects currently owned by a Covata user (specified by `userId`) within an organisation (specified by `orgGroupId`).

A Covata user's ID can be obtained by calling the `GET` method of the [\<access-service>/api/v1/organisations/\{orgGroupId}/users](/3.5/api/access-service-api-v1-organisations-orggroupid-users.md) API endpoint, which retrieves a list of information associated with existing users in an organisation (specified by `orgGroupId`), which can be filtered through a variety of 'search' criteria.

This endpoint is useful for determining the number of file objects that a Covata user owns, before [transferring the ownership of these items](/3.5/api/access-service-api-v1-organisations-orgid-items-transfer.md) over to another user.

> [!NOTE]
>
> Although this endpoint indicates [items](/3.5/api/working-with-files-and-folders-fundamentals.md#item) in its URL, calling it only returns the total number of file objects (i.e. folders/[collections](/3.5/api/working-with-files-and-folders-fundamentals.md#collection) are not counted). However, when actually transferring the ownership of items from one Covata user to another, all of the user's items (i.e. all their file objects and folders) are transferred.

## Supported roles and conditions&#x20;

This API endpoint supports requests utilising Covata user accounts with the following [roles](/3.5/admin-org/administering-users-within-an-organisation.md#an-organisation-users-roles) (as described in the [Organisation Administrator's Guide](/3.5/admin-org.md)) and conditions:

* [Organisation administrator](/3.5/admin-org/administering-users-within-an-organisation.md#organisation-administrator-role) - when this user is a member of the organisation specified by `{orgGroupId}` in the request's URL.

The Covata Platform's resources available to a Covata user meeting the criteria above is determined by the access token submitted in the [header](/3.5/api/access-service-api-v1-organisations-orggroupid-users-userid-itemcount.md#access-service-api-v1-organisations-orggroupid-users-userid-itemcount-required-headers) of requests to this endpoint.

## Required headers&#x20;

The appropriate access token as the `Bearer` token:

* `Authorisation: Bearer eyJhbGciOiJSUzI1NiJ9.eyJleHAiOjE0NjcwMTY2NjYsInVzZXJfbmFtZSI6ImFsZXgub...`

## Returns&#x20;

A JSON-formatted response containing the following members:

* **count** - The total number of file objects currently owned by the [Covata user](/3.5/api/authentication-and-authorisation.md) specified by `userId` in this endpoint's URL. \

  **Example (response):**

  ```json theme={null}
  {
      "count": 16
  }
  ```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.