# fyi.opensocial.createAppPassword

> Published by [lexicons.opensocial.fyi](https://lexicon.garden/identity/did:plc:2gqnilpksz2e7faj3bwvo6qc)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:2gqnilpksz2e7faj3bwvo6qc/fyi.opensocial.createAppPassword)
- [Documentation](https://lexicon.garden/lexicon/did:plc:2gqnilpksz2e7faj3bwvo6qc/fyi.opensocial.createAppPassword/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:2gqnilpksz2e7faj3bwvo6qc/fyi.opensocial.createAppPassword/examples)

## Definitions

### `fyi.opensocial.createAppPassword`

**Type**: `procedure`

Make an app password for the group: what an app that signs in with a handle and a password, such as the Bluesky app, signs in to the group with (com.atproto.server.createSession). It stays the caller's: it stops working once they could no longer make it, and its sessions are listed as theirs among the group's connected apps. Its sessions may use the group's public repo, its blobs and other services, never its spaces, nor get service tokens for the account's own methods or this host's. Requires a role that may write every collection as the group.

#### Input

**Encoding**: `application/json`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `group` | `string` (did) | Yes | The group DID. Every method is served by the group's host and authorized against that group's roles. |
| `name` | `string` | Yes | What it's for, such as the device or app it signs in: unique in the group. |
| `privileged` | `boolean` | No | Whether its sessions may also use Bluesky's chat (DMs) as the group. |

#### Output

**Encoding**: `application/json`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `createdAt` | `string` (datetime) | Yes |  |
| `name` | `string` | Yes |  |
| `password` | `string` | Yes | The password, shown this once: the host keeps only its hash. |
| `privileged` | `boolean` | Yes |  |

#### Errors

- **Forbidden**
- **InvalidName**
- **DuplicateName**
- **TooManyAppPasswords**

## Raw Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "Make an app password for the group: what an app that signs in with a handle and a password, such as the Bluesky app, signs in to the group with (com.atproto.server.createSession). It stays the caller's: it stops working once they could no longer make it, and its sessions are listed as theirs among the group's connected apps. Its sessions may use the group's public repo, its blobs and other services, never its spaces, nor get service tokens for the account's own methods or this host's. Requires a role that may write every collection as the group.",
      "errors": [
        {
          "name": "Forbidden"
        },
        {
          "name": "InvalidName"
        },
        {
          "name": "DuplicateName"
        },
        {
          "name": "TooManyAppPasswords"
        }
      ],
      "input": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "group": {
              "description": "The group DID. Every method is served by the group's host and authorized against that group's roles.",
              "format": "did",
              "type": "string"
            },
            "name": {
              "description": "What it's for, such as the device or app it signs in: unique in the group.",
              "maxLength": 64,
              "type": "string"
            },
            "privileged": {
              "description": "Whether its sessions may also use Bluesky's chat (DMs) as the group.",
              "type": "boolean"
            }
          },
          "required": [
            "group",
            "name"
          ],
          "type": "object"
        }
      },
      "output": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "createdAt": {
              "format": "datetime",
              "type": "string"
            },
            "name": {
              "type": "string"
            },
            "password": {
              "description": "The password, shown this once: the host keeps only its hash.",
              "type": "string"
            },
            "privileged": {
              "type": "boolean"
            }
          },
          "required": [
            "name",
            "password",
            "privileged",
            "createdAt"
          ],
          "type": "object"
        }
      },
      "type": "procedure"
    }
  },
  "id": "fyi.opensocial.createAppPassword",
  "lexicon": 1
}
```
