# dev.knotless.removeOrgMember

> Published by [lexicons.knotless.dev](https://lexicon.garden/identity/did:plc:yqsg7znbbhfmj3a2nrpnaerk)

✓ This is the authoritative definition for this NSID.

## Description

Takes a member out of an organization, or withdraws an invitation, through the gateway the organization delegated writes to, which writes as the organization: out of its records, its space and its private repositories' spaces, but for repositories shared with them on their own. The caller must be an admin of it who joined. Requires a service token from the caller's PDS, audience the gateway's DID, for this method.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:yqsg7znbbhfmj3a2nrpnaerk/dev.knotless.removeOrgMember)
- [Documentation](https://lexicon.garden/lexicon/did:plc:yqsg7znbbhfmj3a2nrpnaerk/dev.knotless.removeOrgMember/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:yqsg7znbbhfmj3a2nrpnaerk/dev.knotless.removeOrgMember/examples)

## Definitions

### `dev.knotless.removeOrgMember`

**Type**: `procedure`

Answers where the account stood before: nothing changes for an account the organization did not invite.

#### Input

**Encoding**: `application/json`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `member` | `string` (did) | Yes | The account to take out. |
| `org` | `string` (did) | Yes | The organization. |

#### Output

**Encoding**: `application/json`

### `dev.knotless.removeOrgMember#removed`

**Type**: `object`

What taking an account out of an organization did.

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `org` | `string` | Yes | The organization's handle, or its DID when none resolves back to it. |
| `organization` | `boolean` | Yes | Whether the account is an organization. |
| `was` | `string` | No | Where they stood before: invited, lapsed (invited over 7 days ago), or a public or hidden member. Absent when they were not invited. |
| `who` | `string` | Yes | The account's handle, or its DID when none resolves back to it. |

## Raw Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "Answers where the account stood before: nothing changes for an account the organization did not invite.",
      "input": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "member": {
              "description": "The account to take out.",
              "format": "did",
              "type": "string"
            },
            "org": {
              "description": "The organization.",
              "format": "did",
              "type": "string"
            }
          },
          "required": [
            "org",
            "member"
          ],
          "type": "object"
        }
      },
      "output": {
        "encoding": "application/json",
        "schema": {
          "ref": "#removed",
          "type": "ref"
        }
      },
      "type": "procedure"
    },
    "removed": {
      "description": "What taking an account out of an organization did.",
      "properties": {
        "org": {
          "description": "The organization's handle, or its DID when none resolves back to it.",
          "maxLength": 300,
          "type": "string"
        },
        "organization": {
          "description": "Whether the account is an organization.",
          "type": "boolean"
        },
        "was": {
          "description": "Where they stood before: invited, lapsed (invited over 7 days ago), or a public or hidden member. Absent when they were not invited.",
          "knownValues": [
            "invited",
            "lapsed",
            "public",
            "hidden"
          ],
          "maxLength": 64,
          "type": "string"
        },
        "who": {
          "description": "The account's handle, or its DID when none resolves back to it.",
          "maxLength": 300,
          "type": "string"
        }
      },
      "required": [
        "org",
        "who",
        "organization"
      ],
      "type": "object"
    }
  },
  "description": "Takes a member out of an organization, or withdraws an invitation, through the gateway the organization delegated writes to, which writes as the organization: out of its records, its space and its private repositories' spaces, but for repositories shared with them on their own. The caller must be an admin of it who joined. Requires a service token from the caller's PDS, audience the gateway's DID, for this method.",
  "id": "dev.knotless.removeOrgMember",
  "lexicon": 1
}
```
