---
agentTools:
  projectIndex: https://seafile-api.readme.io/llms.txt
---

# Delete repo user/group share

Stop sharing a library to a group or user.

# OpenAPI definition

```json
{
  "openapi": "3.0.3",
  "info": {
    "title": "Account Operations - System Admin",
    "description": "The official SeaTable API Reference (OpenAPI 3.0). - Part 'User Account Operations'.",
    "version": "13.0"
  },
  "servers": [
    {
      "url": "https://{server}",
      "variables": {
        "server": {
          "default": "cloud.seafile.com"
        }
      }
    }
  ],
  "x-readme": {
    "explorer-enabled": true,
    "metrics-enabled": false,
    "proxy-enabled": false
  },
  "components": {
    "securitySchemes": {
      "AccountTokenAuth": {
        "type": "http",
        "scheme": "bearer",
        "description": "This is the [Account-Token](/reference/authentication).",
        "bearerFormat": "Account-Token"
      }
    },
    "schemas": {
      "repo_id": {
        "type": "string",
        "description": "The unique identifier of a library",
        "example": "d5620899-1e9b-4a8c-b9af-b00a26324407"
      },
      "share_type": {
        "type": "string",
        "description": "`user` or `group`",
        "enum": [
          "user",
          "group"
        ],
        "example": "user"
      }
    }
  },
  "paths": {
    "/api/v2.1/admin/shares/": {
      "delete": {
        "tags": [
          "Share"
        ],
        "summary": "Delete repo user/group share",
        "description": "Stop sharing a library to a group or user.",
        "security": [
          {
            "AccountTokenAuth": []
          }
        ],
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "type": "object",
                "properties": {
                  "repo_id": {
                    "$ref": "#/components/schemas/repo_id"
                  },
                  "share_type": {
                    "$ref": "#/components/schemas/share_type"
                  },
                  "share_to": {
                    "type": "string",
                    "description": "User email/Group id"
                  }
                },
                "required": [
                  "repo_id",
                  "share_type",
                  "share_to"
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean",
                      "description": "Success state"
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "_id": {
    "buffer": {
      "0": 103,
      "1": 183,
      "2": 248,
      "3": 230,
      "4": 103,
      "5": 20,
      "6": 160,
      "7": 0,
      "8": 41,
      "9": 50,
      "10": 176,
      "11": 75
    }
  }
}
```