---
updatedAt: 2026-09-02T12:20:31.000Z
agentTools:
  projectIndex: https://docs.foxpass.com/llms.txt
---

# POST /groups/{groupname}/members/

Add a member to a group

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "api-instructions",
    "version": "3.2"
  },
  "servers": [
    {
      "url": "https://api.foxpass.com"
    }
  ],
  "components": {
    "securitySchemes": {
      "sec0": {
        "type": "apiKey",
        "in": "header",
        "name": "Authorization",
        "x-bearer-format": "token"
      }
    }
  },
  "security": [
    {
      "sec0": []
    }
  ],
  "paths": {
    "/v1/groups/{groupname}/members/": {
      "post": {
        "summary": "POST /groups/{groupname}/members/",
        "description": "Add a member to a group",
        "operationId": "groupsgroupnamemembers-post",
        "parameters": [
          {
            "name": "groupname",
            "in": "path",
            "description": "group name",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "username"
                ],
                "properties": {
                  "username": {
                    "type": "string",
                    "description": "username"
                  },
                  "expires": {
                    "type": "string",
                    "description": "expiration of group membership. 'YYYY-MM-DDTHH:MMZ' format",
                    "format": "date"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "200",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\"status\": \"ok\"}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "status": {
                      "type": "string",
                      "example": "ok"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "400",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {}
                }
              }
            }
          }
        },
        "deprecated": false,
        "x-readme": {
          "code-samples": [
            {
              "language": "curl",
              "code": "curl -H 'Authorization: Token API_KEY' -X POST -d '{\"username\": \"aren\"}' https://api.foxpass.com/v1/groups/engineers/members/"
            }
          ],
          "samples-languages": [
            "curl"
          ]
        }
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```