# dev.knotless.getOrg

> The accounts an organization (any account keeping a dev.knotless.org record) invited, as the appview has indexed its records. To anyone, those who are members in public: named by a dev.knotless.orgMember record in its public records, taken in, and keeping a public dev.knotless.orgAcceptance record naming it. Optional authentication: to the organization itself and to its members, its invitations and hidden members too, from its space; to an account it invited, its own entry.

- Kind: query
- Authority: knotless.dev
- Lexicon: 1
- Published by [lexicons.knotless.dev](https://lexicon.garden/identity/did:plc:yqsg7znbbhfmj3a2nrpnaerk), the NSID's authority

## Links

- [Documentation](https://lexicon.garden/lexicon/did:plc:yqsg7znbbhfmj3a2nrpnaerk/dev.knotless.getOrg)
- [Schema JSON](https://lexicon.garden/lexicon/did:plc:yqsg7znbbhfmj3a2nrpnaerk/dev.knotless.getOrg/schema.json)
- [Analytics](https://lexicon.garden/lexicon/did:plc:yqsg7znbbhfmj3a2nrpnaerk/dev.knotless.getOrg/analytics)

## Query (`dev.knotless.getOrg`)

Type: query · GET

### Parameters (query string)

- `actor` (string · at-identifier, required): The organization, by DID or handle.

### Output (application/json)

- `gateway` (string · did): The gateway its public dev.knotless.org record names, which members join and leave through, and admins change its members through.
- `inside` (boolean, required): Whether the asker sees its invitations and hidden members: it is the organization, or one of its members.
- `members` (array, required): The first invited first: to an asker inside, every account it invited; to anyone else, its members in public.
  - `items` (ref)
    - Reference: `#memberView`
- `org` (ref, required)
  - Reference: `dev.knotless.defs#actorView`
- `organization` (boolean, required): Whether the account is an organization: it keeps a public dev.knotless.org record.

### Errors

- `ProfileNotFound`: No account by that DID or handle.

## #memberView (`dev.knotless.getOrg#memberView`)

Type: object

An account an organization invited, and where it stands.

### Properties

- `actor` (ref, required)
  - Reference: `dev.knotless.defs#actorView`
- `expiresAt` (string · datetime): When the invitation lapses, when its record says.
- `invitedAt` (string · datetime, required)
- `joinedAt` (string · datetime): When the organization took it in.
- `role` (string, required): What it may do: an admin also invites and removes members.
  - Constraints: knownValues: admin | member
- `standing` (string, required): Invited and not yet a member; invited, and the invitation lapsed; a member anyone may see; or a member only the organization's members see.
  - Constraints: knownValues: invited | lapsed | public | hidden

## Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "The accounts an organization (any account keeping a dev.knotless.org record) invited, as the appview has indexed its records. To anyone, those who are members in public: named by a dev.knotless.orgMember record in its public records, taken in, and keeping a public dev.knotless.orgAcceptance record naming it. Optional authentication: to the organization itself and to its members, its invitations and hidden members too, from its space; to an account it invited, its own entry.",
      "errors": [
        {
          "description": "No account by that DID or handle.",
          "name": "ProfileNotFound"
        }
      ],
      "output": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "gateway": {
              "description": "The gateway its public dev.knotless.org record names, which members join and leave through, and admins change its members through.",
              "format": "did",
              "type": "string"
            },
            "inside": {
              "description": "Whether the asker sees its invitations and hidden members: it is the organization, or one of its members.",
              "type": "boolean"
            },
            "members": {
              "description": "The first invited first: to an asker inside, every account it invited; to anyone else, its members in public.",
              "items": {
                "ref": "#memberView",
                "type": "ref"
              },
              "type": "array"
            },
            "org": {
              "ref": "dev.knotless.defs#actorView",
              "type": "ref"
            },
            "organization": {
              "description": "Whether the account is an organization: it keeps a public dev.knotless.org record.",
              "type": "boolean"
            }
          },
          "required": [
            "org",
            "organization",
            "inside",
            "members"
          ],
          "type": "object"
        }
      },
      "parameters": {
        "properties": {
          "actor": {
            "description": "The organization, by DID or handle.",
            "format": "at-identifier",
            "type": "string"
          }
        },
        "required": [
          "actor"
        ],
        "type": "params"
      },
      "type": "query"
    },
    "memberView": {
      "description": "An account an organization invited, and where it stands.",
      "properties": {
        "actor": {
          "ref": "dev.knotless.defs#actorView",
          "type": "ref"
        },
        "expiresAt": {
          "description": "When the invitation lapses, when its record says.",
          "format": "datetime",
          "type": "string"
        },
        "invitedAt": {
          "format": "datetime",
          "type": "string"
        },
        "joinedAt": {
          "description": "When the organization took it in.",
          "format": "datetime",
          "type": "string"
        },
        "role": {
          "description": "What it may do: an admin also invites and removes members.",
          "knownValues": [
            "admin",
            "member"
          ],
          "type": "string"
        },
        "standing": {
          "description": "Invited and not yet a member; invited, and the invitation lapsed; a member anyone may see; or a member only the organization's members see.",
          "knownValues": [
            "invited",
            "lapsed",
            "public",
            "hidden"
          ],
          "type": "string"
        }
      },
      "required": [
        "actor",
        "role",
        "standing",
        "invitedAt"
      ],
      "type": "object"
    }
  },
  "description": "An organization's members on knotless.",
  "id": "dev.knotless.getOrg",
  "lexicon": 1
}
```
