# at.happyproto.admin.listCustomers

> Published by [happyproto.at](https://lexicon.garden/identity/did:plc:mo7vq4jbioxwafy5zkcc3eux)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:mo7vq4jbioxwafy5zkcc3eux/at.happyproto.admin.listCustomers)
- [Documentation](https://lexicon.garden/lexicon/did:plc:mo7vq4jbioxwafy5zkcc3eux/at.happyproto.admin.listCustomers/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:mo7vq4jbioxwafy5zkcc3eux/at.happyproto.admin.listCustomers/examples)

## Definitions

### `at.happyproto.admin.listCustomers#customer`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `did` | `string` (did) | Yes |  |
| `handle` | `string` (handle) | No | Present when the membership record carries one. |

### `at.happyproto.admin.listCustomers`

**Type**: `query`

The members of the customers space: everyone the customer endpoints admit. Staff only.

#### Output

**Encoding**: `application/json`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `customers` | `array` | Yes |  |

#### Errors

- **AuthRequired**: This endpoint requires an authenticated caller.
- **Forbidden**: The caller is not HappyProto staff.
- **Upstream**: The customers space is not configured or cannot be read.

## Raw Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "customer": {
      "properties": {
        "did": {
          "format": "did",
          "type": "string"
        },
        "handle": {
          "description": "Present when the membership record carries one.",
          "format": "handle",
          "type": "string"
        }
      },
      "required": [
        "did"
      ],
      "type": "object"
    },
    "main": {
      "description": "The members of the customers space: everyone the customer endpoints admit. Staff only.",
      "errors": [
        {
          "description": "This endpoint requires an authenticated caller.",
          "name": "AuthRequired"
        },
        {
          "description": "The caller is not HappyProto staff.",
          "name": "Forbidden"
        },
        {
          "description": "The customers space is not configured or cannot be read.",
          "name": "Upstream"
        }
      ],
      "output": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "customers": {
              "items": {
                "ref": "#customer",
                "type": "ref"
              },
              "type": "array"
            }
          },
          "required": [
            "customers"
          ],
          "type": "object"
        }
      },
      "type": "query"
    }
  },
  "id": "at.happyproto.admin.listCustomers",
  "lexicon": 1
}
```
