# List Bulk Actions

> List the bulk actions created by filter-based message cancels

`GET /v2/bulkActions`

A bulk action is created for every filter-based [bulk cancel](/qstash/api-reference/messages/bulk-cancel-messages) request, and tracks the progress of the cancellation running in the background.

Bulk actions are kept for 7 days after they are created.

<Note>
The `state` filter is applied to each page separately. A page may contain fewer than `count` bulk actions, or none at all, even when there are more to list. Keep paginating until no `cursor` is returned.
</Note>

## OpenAPI

````yaml qstash/openapi.yaml get /v2/bulkActions
openapi: 3.1.0
info:
  title: QStash REST API
  description: |
    QStash is a message queue and scheduler built on top of Upstash Redis.
  version: 2.0.0
  contact:
    name: Upstash
    url: https://upstash.com
servers:
  - url: https://qstash-{region}.upstash.io
    description: Regional
    variables:
      region:
        default: eu-central-1
        enum:
          - us-east-1
          - eu-central-1
security:
  - bearerAuth: []
  - bearerAuthQuery: []
tags:
  - name: Messages
    description: Publish and manage messages
  - name: Queues
    description: Manage message queues
  - name: Schedules
    description: Create and manage scheduled messages
  - name: URL Groups
    description: Manage URL groups and endpoints
  - name: DLQ
    description: Dead Letter Queue operations
  - name: Logs
    description: Log operations
  - name: Signing Keys
    description: Manage signing keys
  - name: Flow Control
    description: Monitor flow control keys
  - name: Bulk Actions
    description: Track filter-based bulk operations
paths:
  /v2/bulkActions:
    get:
      summary: List Bulk Actions
      description: List the bulk actions created by filter-based message cancels
      tags:
        - Bulk Actions
      x-mint:
        content: >
          A bulk action is created for every filter-based [bulk
          cancel](/qstash/api-reference/messages/bulk-cancel-messages) request,
          and tracks the progress of the cancellation running in the background.


          Bulk actions are kept for 7 days after they are created.


          <Note>

          The `state` filter is applied to each page separately. A page may
          contain fewer than `count` bulk actions, or none at all, even when
          there are more to list. Keep paginating until no `cursor` is returned.

          </Note>
      parameters:
        - name: cursor
          in: query
          required: false
          schema:
            type: string
          description: By providing a cursor you can paginate through all of the bulk
            actions.
        - name: count
          in: query
          required: false
          schema:
            type: integer
            minimum: 1
            default: 100
            maximum: 1000
          description: The number of bulk actions to scan per page. Values above 1000 are
            treated as 1000.
        - name: state
          in: query
          required: false
          schema:
            type: string
            enum:
              - IN_PROGRESS
              - FINISHED
          description: Filter bulk actions by state.
      responses:
        "200":
          description: List of bulk actions
          content:
            application/json:
              schema:
                type: object
                properties:
                  bulkActions:
                    type: array
                    items:
                      $ref: "#/components/schemas/BulkAction"
                  cursor:
                    type: string
                    description: >
                      A cursor which you can use in subsequent requests to
                      paginate through all bulk actions.

                      If no cursor is returned, you have reached the end of the
                      bulk actions.
        "400":
          description: Invalid `count`, `cursor` or `state`
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Error"
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: QStash authentication token
    bearerAuthQuery:
      type: apiKey
      in: query
      name: qstash_token
      description: QStash authentication token passed as a query parameter
  schemas:
    Error:
      type: object
      required:
        - error
      properties:
        error:
          type: string
          description: Error message
    BulkAction:
      type: object
      properties:
        actionId:
          type: string
          description: The ID of the bulk action.
        kind:
          type: string
          enum:
            - cancel
          description: The kind of the bulk action.
        state:
          type: string
          enum:
            - IN_PROGRESS
            - FINISHED
          description: |
            The state of the bulk action.

            |Value	|Description|
            |-------|------------|
            | IN_PROGRESS	|The bulk action is running in the background.|
            | FINISHED	|The bulk action has finished.|
        total:
          type: integer
          format: int64
          description: The number of in-progress messages that matched the filter when the
            bulk action was created.
        processed:
          type: integer
          format: int64
          description: The number of messages processed by the bulk action so far.
        createdAt:
          type: integer
          format: int64
          description: The creation time of the bulk action, in milliseconds (Unix
            timestamp).
        completedAt:
          type: integer
          format: int64
          description: The completion time of the bulk action, in milliseconds (Unix
            timestamp). Only present once the bulk action has finished.
        filter:
          type: object
          additionalProperties:
            type: array
            items:
              type: string
          description: >
            The filter the bulk action was created with. Keys are the filter
            parameter names of the bulk cancel request, such as `queueName`,
            `label` or `fromDate`, and values are the given values.
          example:
            queueName:
              - my-queue
            label:
              - label_1
              - label_2
````
