# social.colibri.beta.community.getHosting

> Describes where a community's account lives and whether the AppView can still act for it. Only administrators of the community can read it.

- Kind: query
- Authority: community.beta.colibri.social
- Lexicon: 1
- Published by [colibri.social](https://lexicon.garden/identity/did:plc:mprdjqjluoswa7awzggaggj3), the NSID's authority

## Links

- [Documentation](https://lexicon.garden/lexicon/did:plc:mprdjqjluoswa7awzggaggj3/social.colibri.beta.community.getHosting)
- [Schema JSON](https://lexicon.garden/lexicon/did:plc:mprdjqjluoswa7awzggaggj3/social.colibri.beta.community.getHosting/schema.json)
- [Analytics](https://lexicon.garden/lexicon/did:plc:mprdjqjluoswa7awzggaggj3/social.colibri.beta.community.getHosting/analytics)

## Query (`social.colibri.beta.community.getHosting`)

Type: query · GET

### Parameters (query string)

- `community` (string · did, required): The community.

### Output (application/json)

- `hosting` (ref, required): Where the community's account lives.
  - Reference: `#hostingView`

### Errors

- `AuthRequired`: The request is missing, malformed, or unverifiable service auth.
- `Forbidden`: The requesting user lacks permission for this community.
- `CommunityNotFound`: No community exists at that identifier.

## #hostingView (`social.colibri.beta.community.getHosting#hostingView`)

Type: object

Where a community's account lives and whether the AppView can act for it.

### Properties

- `account` (string, required): The account's handle, or its DID when it has none.
- `connectedAt` (string · datetime): When the AppView was last connected to the account.
- `connectedBy` (string · did): The user who signed in as the account, for kind own.
- `handOverExpiresAt` (string · datetime): When the password from handOverHost stops working, while a hand-over is active.
- `kind` (string, required): colibri when the account lives on this AppView's server and the AppView holds its password. own when the account belongs to the community's owner and the AppView acts through a sign-in.
  - Constraints: knownValues: colibri | own
- `needsSignIn` (boolean, required): Whether the AppView lost access and needs the owner to sign in again. New writes fail until then.
- `needsSignInSince` (string · datetime): When the AppView lost access.
- `server` (string · uri, required): The server the account lives on, as the AppView last reached it.

## Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "hostingView": {
      "description": "Where a community's account lives and whether the AppView can act for it.",
      "properties": {
        "account": {
          "description": "The account's handle, or its DID when it has none.",
          "type": "string"
        },
        "connectedAt": {
          "description": "When the AppView was last connected to the account.",
          "format": "datetime",
          "type": "string"
        },
        "connectedBy": {
          "description": "The user who signed in as the account, for kind own.",
          "format": "did",
          "type": "string"
        },
        "handOverExpiresAt": {
          "description": "When the password from handOverHost stops working, while a hand-over is active.",
          "format": "datetime",
          "type": "string"
        },
        "kind": {
          "description": "colibri when the account lives on this AppView's server and the AppView holds its password. own when the account belongs to the community's owner and the AppView acts through a sign-in.",
          "knownValues": [
            "colibri",
            "own"
          ],
          "type": "string"
        },
        "needsSignIn": {
          "description": "Whether the AppView lost access and needs the owner to sign in again. New writes fail until then.",
          "type": "boolean"
        },
        "needsSignInSince": {
          "description": "When the AppView lost access.",
          "format": "datetime",
          "type": "string"
        },
        "server": {
          "description": "The server the account lives on, as the AppView last reached it.",
          "format": "uri",
          "type": "string"
        }
      },
      "required": [
        "kind",
        "account",
        "server",
        "needsSignIn"
      ],
      "type": "object"
    },
    "main": {
      "description": "Describes where a community's account lives and whether the AppView can still act for it. Only administrators of the community can read it.",
      "errors": [
        {
          "description": "The request is missing, malformed, or unverifiable service auth.",
          "name": "AuthRequired"
        },
        {
          "description": "The requesting user lacks permission for this community.",
          "name": "Forbidden"
        },
        {
          "description": "No community exists at that identifier.",
          "name": "CommunityNotFound"
        }
      ],
      "output": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "hosting": {
              "description": "Where the community's account lives.",
              "ref": "#hostingView",
              "type": "ref"
            }
          },
          "required": [
            "hosting"
          ],
          "type": "object"
        }
      },
      "parameters": {
        "properties": {
          "community": {
            "description": "The community.",
            "format": "did",
            "type": "string"
          }
        },
        "required": [
          "community"
        ],
        "type": "params"
      },
      "type": "query"
    }
  },
  "id": "social.colibri.beta.community.getHosting",
  "lexicon": 1
}
```
