# rsvp.atmo.space.defs

> Published by [atmo.rsvp](https://lexicon.garden/identity/did:plc:b63bmauox6z5rbibwrhxrdnw)

✓ This is the authoritative definition for this NSID.

## Description

Shared types for permissioned-space XRPC methods.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:b63bmauox6z5rbibwrhxrdnw/rsvp.atmo.space.defs)
- [Documentation](https://lexicon.garden/lexicon/did:plc:b63bmauox6z5rbibwrhxrdnw/rsvp.atmo.space.defs/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:b63bmauox6z5rbibwrhxrdnw/rsvp.atmo.space.defs/examples)

## Definitions

### `rsvp.atmo.space.defs#appPolicy`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `apps` | `array` | Yes |  |
| `mode` | `string` | Yes | 'allow' = default-allow with apps[] as denylist; 'deny' = default-deny with apps[] as allowlist. |

### `rsvp.atmo.space.defs#spaceView`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `key` | `string` | Yes |  |
| `uri` | `string` (at-uri) | Yes |  |
| `type` | `string` (nsid) | Yes |  |
| `ownerDid` | `string` (did) | Yes |  |
| `appPolicy` | `ref` → `#appPolicy` | No | Owner-only |
| `createdAt` | `integer` | Yes |  |
| `serviceDid` | `string` | Yes |  |
| `appPolicyRef` | `string` (at-uri) | No |  |
| `memberListRef` | `string` (at-uri) | No |  |

### `rsvp.atmo.space.defs#inviteView`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `note` | `string` | No |  |
| `perms` | `string` | Yes |  |
| `maxUses` | `integer` | No |  |
| `spaceUri` | `string` (at-uri) | Yes |  |
| `createdAt` | `integer` | Yes |  |
| `createdBy` | `string` (did) | Yes |  |
| `expiresAt` | `integer` | No |  |
| `revokedAt` | `integer` | No |  |
| `tokenHash` | `string` | Yes |  |
| `usedCount` | `integer` | Yes |  |

### `rsvp.atmo.space.defs#memberView`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `did` | `string` (did) | Yes |  |
| `perms` | `string` | Yes | 'write' implies 'read'. Space owner is always implicit write. |
| `addedAt` | `integer` | Yes |  |
| `addedBy` | `string` (did) | No |  |

### `rsvp.atmo.space.defs#recordView`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `cid` | `string` (cid) | No |  |
| `rkey` | `string` | Yes |  |
| `record` | `unknown` | Yes |  |
| `spaceUri` | `string` (at-uri) | Yes |  |
| `authorDid` | `string` (did) | Yes |  |
| `createdAt` | `integer` | Yes |  |
| `collection` | `string` (nsid) | Yes |  |

## Raw Schema

```json
{
  "id": "rsvp.atmo.space.defs",
  "defs": {
    "appPolicy": {
      "type": "object",
      "required": [
        "mode",
        "apps"
      ],
      "properties": {
        "apps": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "mode": {
          "type": "string",
          "description": "'allow' = default-allow with apps[] as denylist; 'deny' = default-deny with apps[] as allowlist.",
          "knownValues": [
            "allow",
            "deny"
          ]
        }
      }
    },
    "spaceView": {
      "type": "object",
      "required": [
        "uri",
        "ownerDid",
        "type",
        "key",
        "serviceDid",
        "createdAt"
      ],
      "properties": {
        "key": {
          "type": "string"
        },
        "uri": {
          "type": "string",
          "format": "at-uri"
        },
        "type": {
          "type": "string",
          "format": "nsid"
        },
        "ownerDid": {
          "type": "string",
          "format": "did"
        },
        "appPolicy": {
          "ref": "#appPolicy",
          "type": "ref",
          "description": "Owner-only"
        },
        "createdAt": {
          "type": "integer"
        },
        "serviceDid": {
          "type": "string"
        },
        "appPolicyRef": {
          "type": "string",
          "format": "at-uri"
        },
        "memberListRef": {
          "type": "string",
          "format": "at-uri"
        }
      }
    },
    "inviteView": {
      "type": "object",
      "required": [
        "tokenHash",
        "spaceUri",
        "perms",
        "usedCount",
        "createdBy",
        "createdAt"
      ],
      "properties": {
        "note": {
          "type": "string"
        },
        "perms": {
          "type": "string",
          "knownValues": [
            "read",
            "write"
          ]
        },
        "maxUses": {
          "type": "integer"
        },
        "spaceUri": {
          "type": "string",
          "format": "at-uri"
        },
        "createdAt": {
          "type": "integer"
        },
        "createdBy": {
          "type": "string",
          "format": "did"
        },
        "expiresAt": {
          "type": "integer"
        },
        "revokedAt": {
          "type": "integer"
        },
        "tokenHash": {
          "type": "string"
        },
        "usedCount": {
          "type": "integer"
        }
      }
    },
    "memberView": {
      "type": "object",
      "required": [
        "did",
        "perms",
        "addedAt"
      ],
      "properties": {
        "did": {
          "type": "string",
          "format": "did"
        },
        "perms": {
          "type": "string",
          "description": "'write' implies 'read'. Space owner is always implicit write.",
          "knownValues": [
            "read",
            "write"
          ]
        },
        "addedAt": {
          "type": "integer"
        },
        "addedBy": {
          "type": "string",
          "format": "did"
        }
      }
    },
    "recordView": {
      "type": "object",
      "required": [
        "spaceUri",
        "collection",
        "authorDid",
        "rkey",
        "record",
        "createdAt"
      ],
      "properties": {
        "cid": {
          "type": "string",
          "format": "cid"
        },
        "rkey": {
          "type": "string"
        },
        "record": {
          "type": "unknown"
        },
        "spaceUri": {
          "type": "string",
          "format": "at-uri"
        },
        "authorDid": {
          "type": "string",
          "format": "did"
        },
        "createdAt": {
          "type": "integer"
        },
        "collection": {
          "type": "string",
          "format": "nsid"
        }
      }
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1,
  "description": "Shared types for permissioned-space XRPC methods."
}
```
