# `album.ownerStatus`

<span class="badge">bearer</span>

**Resolve owner management status**

Exactly one of id, token or alias must be supplied. Resolves only owned live folders, active tokens and current or held previous addresses.

## Parameters

Passed by name in the `params` object.

| Name | Type | Required | Description |
|---|---|---|---|
| `alias` | string | no |  |
| `id` | string | no |  |
| `token` | string | no |  |

## Result

Returns `ownerStatusResult`:

| Field | Type | Description |
|---|---|---|
| `album_id *` | string |  |
| `manage_url *` | string |  |
| `name *` | string |  |
| `state *` | string |  |

## Errors

| Code | Message | When |
|---|---|---|
| `2001` | `not_found` | No such resource owned by the caller. |
| `2002` | `validation_failed` | Malformed request; see error.data. |

See the [error reference](/docs/errors) for the full catalog, including the authentication codes.

## Example

Request:

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "album.ownerStatus",
  "params": {
    "id": "018f3a80-1c2d-7e00-9a00-0b1c2d3e4f50"
  }
}
```

Response:

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": {
    "album_id": "018f3a80-1c2d-7e00-9a00-0b1c2d3e4f50",
    "name": "Trip",
    "state": "private",
    "manage_url": "/photos/folder/018f3a80-1c2d-7e00-9a00-0b1c2d3e4f50/settings"
  }
}
```

**curl**

```bash
curl -s https://peinture.gumeniuk.com/rpc \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"jsonrpc":"2.0","id":1,"method":"album.ownerStatus","params":{"id":"018f3a80-1c2d-7e00-9a00-0b1c2d3e4f50"}}'
```

**JavaScript**

```js
const res = await fetch("https://peinture.gumeniuk.com/rpc", {
  method: "POST",
  headers: {
    "Content-Type": "application/json",
    "Authorization": `Bearer ${token}`,
  },
  body: JSON.stringify({
    jsonrpc: "2.0", id: 1, method: "album.ownerStatus", params: {"id":"018f3a80-1c2d-7e00-9a00-0b1c2d3e4f50"},
  }),
});
const { result, error } = await res.json();
```

**Go**

```go
body := []byte(`{"jsonrpc":"2.0","id":1,"method":"album.ownerStatus","params":{"id":"018f3a80-1c2d-7e00-9a00-0b1c2d3e4f50"}}`)
req, _ := http.NewRequest("POST", "https://peinture.gumeniuk.com/rpc", bytes.NewReader(body))
req.Header.Set("Content-Type", "application/json")
req.Header.Set("Authorization", "Bearer "+token)
resp, err := http.DefaultClient.Do(req)
```

