# SlimProjectsResource

Canonical page: https://docs.ovok.com/java-sdk/reference/slim-projects-resource

```java
public final class SlimProjectsResource
```

Reads and updates Slim projects and their users. Get it from [`SlimResource.projects()`](/java-sdk/reference/slim-resource#projects).

## Methods [#methods]

### child [#child]

```java
public ChildProjectsResource child()
```

Returns the child-project routes.

**Returns:** the child-project routes

### retrieve [#retrieve]

```java
public JsonNode retrieve(
        String projectId,
        RequestOptions options) throws IOException, InterruptedException
```

Reads a project (`GET /v1/slim/project/{projectId}`).

**Parameters:**

- `projectId`: the project ID
- `options`: per-request options, such as the timeout

**Returns:** the response body

**Throws:**

- `IOException`: if the request cannot be sent or the response cannot be read
- `InterruptedException`: if the thread is interrupted while waiting for the response

### update [#update]

```java
public JsonNode update(
        String projectId,
        Object body,
        RequestOptions options) throws IOException, InterruptedException
```

Replaces a project (`PUT /v1/slim/project/{projectId}`).

**Parameters:**

- `projectId`: the project ID
- `body`: the updated project
- `options`: per-request options, such as the timeout

**Returns:** the response body

**Throws:**

- `IOException`: if the request cannot be sent or the response cannot be read
- `InterruptedException`: if the thread is interrupted while waiting for the response

### users [#users]

```java
public Page<JsonNode> users(
        String projectId,
        Map<String, ?> query,
        RequestOptions options) throws IOException, InterruptedException
```

Lists a project's users (`GET /v1/slim/project/{projectId}/users`).

**Parameters:**

- `projectId`: the project ID
- `query`: query parameters, sent as given
- `options`: per-request options, such as the timeout

**Returns:** the first page; iterating it loads the next pages

**Throws:**

- `IOException`: if the request cannot be sent or the response cannot be read
- `InterruptedException`: if the thread is interrupted while waiting for the response

### currentUsers [#currentusers]

```java
public Page<JsonNode> currentUsers(
        Map<String, ?> query,
        RequestOptions options) throws IOException, InterruptedException
```

Lists the current project's users (`GET /v1/slim/project/users`).

**Parameters:**

- `query`: query parameters, sent as given
- `options`: per-request options, such as the timeout

**Returns:** the first page; iterating it loads the next pages

**Throws:**

- `IOException`: if the request cannot be sent or the response cannot be read
- `InterruptedException`: if the thread is interrupted while waiting for the response

### deviceCounts [#devicecounts]

```java
public JsonNode deviceCounts(
        String projectId,
        RequestOptions options) throws IOException, InterruptedException
```

Reads a project's device counts (`GET /v1/slim/project/{projectId}/device-counts`).

**Parameters:**

- `projectId`: the project ID
- `options`: per-request options, such as the timeout

**Returns:** the response body

**Throws:**

- `IOException`: if the request cannot be sent or the response cannot be read
- `InterruptedException`: if the thread is interrupted while waiting for the response

### patientCounts [#patientcounts]

```java
public JsonNode patientCounts(
        String projectId,
        RequestOptions options) throws IOException, InterruptedException
```

Reads a project's patient counts (`GET /v1/slim/project/{projectId}/patient-counts`).

**Parameters:**

- `projectId`: the project ID
- `options`: per-request options, such as the timeout

**Returns:** the response body

**Throws:**

- `IOException`: if the request cannot be sent or the response cannot be read
- `InterruptedException`: if the thread is interrupted while waiting for the response
