---
updatedAt: 2026-09-17T18:20:16.000Z
agentTools:
  projectIndex: https://docs.attentive.com/llms.txt
---

# Clear all members from a segment

Removes all members from a segment identified by its external ID. This operation is asynchronous — the response indicates that the clear request has been accepted for processing.

Only segments created via the Public API can be cleared using this endpoint.

Scopes Required: [segments:Write]

Default Rate Limit: 100 requests per second


# OpenAPI definition

```json
{
  "openapi": "3.0.3",
  "info": {
    "description": "For any questions, reach out to your Attentive point of contact (if applicable) or [api@attentivemobile.com](mailto:api@attentivemobile.com).",
    "title": "Attentive API V2",
    "version": "2.0.0"
  },
  "servers": [
    {
      "url": "https://api.attentivemobile.com/",
      "description": "Attentive API V2"
    }
  ],
  "security": [
    {
      "bearerAuth": []
    }
  ],
  "tags": [
    {
      "name": "Segments",
      "description": "Endpoints for submitting bulk segment member additions and removals. Use these endpoints to manage segment memberships in bulk and monitor the processing status asynchronously.\n\n## Processing Times\n\nThe Bulk API processes jobs with the following targets:\n- **Standard Processing**: The first 10,000 records per day per customer typically complete within 4 hours of request acceptance.\n- **High-Volume Processing**: Additional records beyond 10,000 per day typically complete within 12 hours.\n\n**Note**: For jobs with more than 1 million records, processing times may vary.\n",
      "x-beta": true
    }
  ],
  "paths": {
    "/v2/segments/external/{externalId}/clear-segment": {
      "x-external": "hidden",
      "x-requires-auth": true,
      "post": {
        "x-external": true,
        "x-requires-auth": true,
        "security": [
          {
            "bearerAuth": []
          },
          {
            "OAuthFlow": [
              "segments:write"
            ]
          }
        ],
        "summary": "Clear all members from a segment",
        "description": "Removes all members from a segment identified by its external ID. This operation is asynchronous — the response indicates that the clear request has been accepted for processing.\n\nOnly segments created via the Public API can be cleared using this endpoint.\n\nScopes Required: [segments:Write]\n\nDefault Rate Limit: 100 requests per second\n",
        "operationId": "clearSegmentMembers",
        "tags": [
          "Segments"
        ],
        "parameters": [
          {
            "name": "externalId",
            "in": "path",
            "description": "External ID of the segment whose members should be cleared",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            }
          }
        ],
        "responses": {
          "202": {
            "description": "Clear members request accepted for asynchronous processing",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClearSegmentMembersResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad request - segment is not a Public API segment"
          },
          "401": {
            "description": "Unauthorized - invalid or missing token"
          },
          "403": {
            "description": "Access denied - insufficient permissions"
          },
          "404": {
            "description": "Segment not found"
          },
          "429": {
            "description": "Too many requests - rate limit exceeded"
          },
          "500": {
            "description": "Internal server error"
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "JWT"
      },
      "OAuthFlow": {
        "type": "oauth2",
        "description": "This API uses OAuth 2 with the authorization code grant flow. [More info](https://docs.attentivemobile.com/pages/authentication/)",
        "flows": {
          "authorizationCode": {
            "authorizationUrl": "https://ui-devel.attentivemobile.com/integrations/oauth-install?client_id={clientId}&redirect_uri={redirectUri}&scope={scope}",
            "tokenUrl": "https://api.attentivemobile.com/v1/authorization-codes/tokens",
            "scopes": {
              "attributes:write": "read and write custom attributes",
              "subscriptions:write": "read and write subscriptions",
              "events:write": "read and write custom events",
              "ecommerce:write": "read and write ecommerce events",
              "segments:write": "read and write segments",
              "segments:read": "read segments",
              "content:write": "read and write content"
            }
          }
        }
      }
    },
    "schemas": {
      "ClearSegmentMembersResponse": {
        "type": "object",
        "properties": {
          "status": {
            "type": "string",
            "enum": [
              "ACCEPTED"
            ],
            "description": "The status of the request. `ACCEPTED` indicates the clear members request was received and will be processed asynchronously.\n",
            "example": "ACCEPTED"
          },
          "message": {
            "type": "string",
            "description": "A human-readable message about the request status",
            "example": "Clear members request accepted for processing"
          }
        }
      }
    }
  },
  "x-readme": {
    "explorer-enabled": false
  }
}
```