# Group API Reference

OpenAPI source: https://api.are.na/v3/openapi.json

## POST /v3/groups/{id}/invite

- Label: Create or reuse group invite
- Docs: https://www.are.na/developers/explore/group/post-invite
- Markdown: https://www.are.na/developers/explore/group/post-invite.md
- Requires resource id: yes
- Response content type: application/json

Creates the group's shareable invite code if it does not exist, or
returns the existing one. Only users who can manage the group may create
or view the reusable invite code.

**Authentication required.**

Path parameters:
- id: string (required) — Resource ID or slug

Response schema:
```json
{
  "type": "object",
  "description": "Shareable invite code for joining a group",
  "required": [
    "id",
    "type",
    "code",
    "url",
    "created_at",
    "updated_at",
    "_links"
  ],
  "properties": {
    "id": {
      "type": "integer",
      "nullable": false,
      "description": "Unique identifier for the invite code",
      "example": 12345
    },
    "type": {
      "type": "string",
      "nullable": false,
      "enum": [
        "GroupInvite"
      ],
      "example": "GroupInvite"
    },
    "code": {
      "type": "string",
      "nullable": false,
      "description": "Invite code required to join the group",
      "example": "abc123xyz"
    },
    "url": {
      "type": "string",
      "nullable": false,
      "description": "Public Are.na URL for accepting the group invite",
      "format": "uri",
      "example": "https://www.are.na/group/research-studio/invite/abc123xyz"
    },
    "created_at": {
      "type": "string",
      "nullable": false,
      "description": "When the invite code was created",
      "format": "date-time",
      "example": "2023-01-15T10:30:00Z"
    },
    "updated_at": {
      "type": "string",
      "nullable": false,
      "description": "When the invite code was last updated",
      "format": "date-time",
      "example": "2023-01-15T10:30:00Z"
    },
    "_links": {
      "type": "object",
      "description": "HATEOAS links for navigation and discovery.\nFollows HAL (Hypertext Application Language) format where link relationships \nare expressed as object keys (e.g., \"self\", \"user\", \"channels\").\n",
      "required": [
        "self"
      ],
      "properties": {
        "self": {
          "type": "object",
          "description": "A hypermedia link containing the URL of a linked resource.\nThe relationship type is expressed by the key in the parent _links object.\n",
          "required": [
            "href"
          ],
          "properties": {
            "href": {
              "type": "string",
              "nullable": false,
              "description": "The URL of the linked resource",
              "format": "uri",
              "example": "https://api.are.na/v3/blocks/12345"
            }
          },
          "refName": "Link"
        }
      },
      "additionalProperties": {
        "type": "object",
        "description": "A hypermedia link containing the URL of a linked resource.\nThe relationship type is expressed by the key in the parent _links object.\n",
        "required": [
          "href"
        ],
        "properties": {
          "href": {
            "type": "string",
            "nullable": false,
            "description": "The URL of the linked resource",
            "format": "uri",
            "example": "https://api.are.na/v3/blocks/12345"
          }
        },
        "refName": "Link"
      },
      "refName": "Links"
    }
  },
  "refName": "GroupInvite"
}
```