# social.grain.group.joinGroup

> Ask a group's group host to admit the viewer: Grain mints service auth for the host from the viewer's PDS and calls fyi.opensocial.requestJoin. Admitted immediately when the group is open; queued for its moderators when it takes requests.

- Kind: procedure
- Authority: group.grain.social
- Lexicon: 1
- Published by [grain.social](https://lexicon.garden/identity/did:plc:e7rftrdyz5e2rw4y6ocszew2), the NSID's authority

## Links

- [Documentation](https://lexicon.garden/lexicon/did:plc:e7rftrdyz5e2rw4y6ocszew2/social.grain.group.joinGroup)
- [Schema JSON](https://lexicon.garden/lexicon/did:plc:e7rftrdyz5e2rw4y6ocszew2/social.grain.group.joinGroup/schema.json)
- [Analytics](https://lexicon.garden/lexicon/did:plc:e7rftrdyz5e2rw4y6ocszew2/social.grain.group.joinGroup/analytics)

## Procedure (`social.grain.group.joinGroup`)

Type: procedure · POST

### Input (application/json)

- `group` (string · did, required)
- `message` (string)
  - Constraints: maxLength: 1000

### Output (application/json)

- `status` (string, required)
  - Constraints: knownValues: admitted | pending

## Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "Ask a group's group host to admit the viewer: Grain mints service auth for the host from the viewer's PDS and calls fyi.opensocial.requestJoin. Admitted immediately when the group is open; queued for its moderators when it takes requests.",
      "input": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "group": {
              "format": "did",
              "type": "string"
            },
            "message": {
              "maxLength": 1000,
              "type": "string"
            }
          },
          "required": [
            "group"
          ],
          "type": "object"
        }
      },
      "output": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "status": {
              "knownValues": [
                "admitted",
                "pending"
              ],
              "type": "string"
            }
          },
          "required": [
            "status"
          ],
          "type": "object"
        }
      },
      "type": "procedure"
    }
  },
  "id": "social.grain.group.joinGroup",
  "lexicon": 1
}
```
