# List possession conditions

`GET /api/v1/possession-conditions`

List every possession condition of your account, in the order the account keeps them.

A possession condition belongs to the account, not to a vault. Every account starts with six: New, Like new, Used, Worn, Damaged and Broken, in the language of the person who created it.

This endpoint also answers QUERY, with the same parameters sent in the request body. [How QUERY works](https://my.monicahq.com/docs/api/query-method).

## Query parameters

- `page` (integer, optional, defaults to 1): Which page to answer with.
- `per_page` (integer, optional, defaults to 25): How many conditions one page holds, between 1 and 100. A number outside the range is brought back into it.

## Returns

A page of possession condition objects, and how many there are in all. An account with none answers an empty list.

- `data` (array): The possession conditions on this page. An empty list rather than an error when there are none.
- `data[]` (object): One possession condition.
- `data[].type` (string): Always possession_condition. It names the kind of record, so a caller holding several kinds can tell them apart without looking at where they came from.
- `data[].id` (string): The id of this record, as a string even when it reads as a number. It is what every endpoint naming this record takes.
- `data[].attributes` (object): Everything the record holds.
- `data[].attributes.name` (string): What the condition reads, such as New or Broken.
- `data[].attributes.colour` (string): One of the eight vault colours, as a hexadecimal value.
- `data[].attributes.icon` (string): One of the glyphs of the catalogue, or null when the condition has none.
- `data[].attributes.position` (integer): Its place in the order the account keeps, from best to worst, counting from 1.
- `data[].attributes.created_at` (timestamp): When the condition was added, as a count of seconds since 1970.
- `data[].attributes.updated_at` (timestamp): When it last changed, as a count of seconds, or null.
- `data[].links` (object): Where to find this record.
- `data[].links.self` (string): The absolute address this record is read from.
- `data[].links.web` (string): The settings screen where the conditions of the account are managed, which opens for somebody signed in rather than for a key. It is the link to give a person.
- `meta` (object): Where you are in the collection.
- `meta.page` (integer): The page this is, counting from 1.
- `meta.per_page` (integer): How many one page holds, which is the size that was asked for once it has been brought into the allowed range.
- `meta.total` (integer): How many possession conditions there are in all, not how many are on this page.

## Rate limit

Sixty requests per minute, per user, shared by every key and device. Every answer carries the budget left in `X-RateLimit-Remaining`.

## Request

```sh
curl https://my.monicahq.com/api/v1/possession-conditions \
  -H "Authorization: Bearer $MONICA_TOKEN"
```

```javascript
const response = await fetch('https://my.monicahq.com/api/v1/possession-conditions', {
  headers: { Authorization: `Bearer ${token}` },
})
const data = await response.json()
```

```php
$response = Http::withToken($token)->get('https://my.monicahq.com/api/v1/possession-conditions');
```

## Response

`200`

```json
{
    "data": [
        {
            "type": "possession_condition",
            "id": "4c1e7a92-8d35-4f06-b2a9-e3f71c5d8b40",
            "attributes": {
                "name": "Like new",
                "colour": "#2f7f86",
                "icon": null,
                "position": 2,
                "created_at": 1761436800,
                "updated_at": 1761440400
            },
            "links": {
                "self": "https://my.monicahq.com/api/v1/possession-conditions/4c1e7a92-8d35-4f06-b2a9-e3f71c5d8b40",
                "web": "https://my.monicahq.com/settings/account/possession-conditions"
            }
        }
    ],
    "meta": {
        "page": 1,
        "per_page": 25,
        "total": 1
    }
}
```
