# lol.dids.admin.listSpaces

> Published by [ngerakines.me](https://lexicon.garden/identity/did:plc:cbkjy5n7bk3ax2wplmtjofq2)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:cbkjy5n7bk3ax2wplmtjofq2/lol.dids.admin.listSpaces)
- [Documentation](https://lexicon.garden/lexicon/did:plc:cbkjy5n7bk3ax2wplmtjofq2/lol.dids.admin.listSpaces/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:cbkjy5n7bk3ax2wplmtjofq2/lol.dids.admin.listSpaces/examples)

## Definitions

### `lol.dids.admin.listSpaces`

**Type**: `query`

Every connected space with its sync state, access expiry, and registration expiry.

#### Parameters

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `limit` | `integer` | No | Maximum entries to return. |
| `state` | `string` | No | Filter by sync state — one of the values of lol.dids.defs#spaceSyncState. |
| `cursor` | `string` | No | Pagination cursor from a previous response. |

#### Output

**Encoding**: `application/json`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `cursor` | `string` | No | Present when more entries exist. |
| `spaces` | `array` | Yes |  |

## Raw Schema

```json
{
  "id": "lol.dids.admin.listSpaces",
  "defs": {
    "main": {
      "type": "query",
      "output": {
        "schema": {
          "type": "object",
          "required": [
            "spaces"
          ],
          "properties": {
            "cursor": {
              "type": "string",
              "description": "Present when more entries exist."
            },
            "spaces": {
              "type": "array",
              "items": {
                "ref": "lol.dids.defs#spaceView",
                "type": "ref"
              }
            }
          }
        },
        "encoding": "application/json"
      },
      "parameters": {
        "type": "params",
        "properties": {
          "limit": {
            "type": "integer",
            "default": 50,
            "maximum": 100,
            "minimum": 1,
            "description": "Maximum entries to return."
          },
          "state": {
            "type": "string",
            "description": "Filter by sync state — one of the values of lol.dids.defs#spaceSyncState."
          },
          "cursor": {
            "type": "string",
            "description": "Pagination cursor from a previous response."
          }
        }
      },
      "description": "Every connected space with its sync state, access expiry, and registration expiry."
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1
}
```
