# social.colibri.beta.community.getInvitation

> Published by [colibri.social](https://lexicon.garden/identity/did:plc:mprdjqjluoswa7awzggaggj3)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:mprdjqjluoswa7awzggaggj3/social.colibri.beta.community.getInvitation)
- [Documentation](https://lexicon.garden/lexicon/did:plc:mprdjqjluoswa7awzggaggj3/social.colibri.beta.community.getInvitation/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:mprdjqjluoswa7awzggaggj3/social.colibri.beta.community.getInvitation/examples)

## Definitions

### `social.colibri.beta.community.getInvitation`

**Type**: `query`

Resolves an invitation code, so a client can show what it leads to before the user accepts. This is readable without membership.

#### Parameters

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `code` | `string` | Yes | The invitation code to resolve. |

#### Output

**Encoding**: `application/json`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `community` | `ref` → `social.colibri.beta.community.defs#communityView` | Yes | The community the invitation leads to. |
| `invitation` | `ref` → `social.colibri.beta.community.defs#invitationView` | Yes | The resolved invitation. |

#### Errors

- **InvitationNotFound**: No invitation exists with that code.

## Raw Schema

```json
{
  "id": "social.colibri.beta.community.getInvitation",
  "defs": {
    "main": {
      "type": "query",
      "errors": [
        {
          "name": "InvitationNotFound",
          "description": "No invitation exists with that code."
        }
      ],
      "output": {
        "schema": {
          "type": "object",
          "required": [
            "invitation",
            "community"
          ],
          "properties": {
            "community": {
              "ref": "social.colibri.beta.community.defs#communityView",
              "type": "ref",
              "description": "The community the invitation leads to."
            },
            "invitation": {
              "ref": "social.colibri.beta.community.defs#invitationView",
              "type": "ref",
              "description": "The resolved invitation."
            }
          }
        },
        "encoding": "application/json"
      },
      "parameters": {
        "type": "params",
        "required": [
          "code"
        ],
        "properties": {
          "code": {
            "type": "string",
            "description": "The invitation code to resolve."
          }
        }
      },
      "description": "Resolves an invitation code, so a client can show what it leads to before the user accepts. This is readable without membership."
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1
}
```
