> ## Documentation Index
> Fetch the complete documentation index at: https://docs.tamradar.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Bulk Deactivate Radars

> Synchronously deactivate up to 500 radars in one request.

Bulk deactivation is synchronous: the response already contains the final
outcome for every requested ID. Its `bulk_id` is a correlation value for logs;
it is not stored and cannot be used with the bulk-create status endpoint.

<Note>
  Each item is the same success or error response returned by
  [`DELETE /v1/radars/{radar_id}`](/api-reference/delete-radar), with only
  `bulk_id`, `item_index`, and the requested `radar_id` added. A mixed request
  still returns top-level HTTP `200`; inspect each item's `code` and the summary.
</Note>

The JSON body must contain only `radar_ids`. Supply 1–500 unique UUIDs.
Malformed JSON, empty strings, invalid UUIDs, duplicate UUIDs, unknown fields,
or an empty/oversized array reject the whole request with `400` before any
radar changes.

Monthly radars enter their paid grace period. Update-based radars deactivate
immediately. Missing, unowned, or already inactive radars appear as item-level
failures without preventing other valid items from being deactivated.

## Correlating items to your request

Every item carries a top-level `radar_id` and `item_index` — on **both**
successful and failed items. Use these two fields for all bulk correlation,
regardless of outcome:

* `radar_id` — the exact ID you requested for this item.
* `item_index` — the zero-based position of this item in your `radar_ids` array.

On a **successful** item, `data` is the unchanged single-DELETE resource
response, so `data.radar_id` repeats the same value. This duplication is
intentional: treat `data` as the returned radar resource, and the top-level
`radar_id` as the request correlation field.

On a **failed** item there is no `data` object, but the top-level `radar_id` is
still present — so you never have to branch on success vs. failure just to find
the identifier.

<Note>
  Always identify items through the top-level `radar_id` and `item_index`. Treat
  `data.radar_id` as part of the radar resource, not as the correlation key.
</Note>

<Warning>
  This endpoint accepts a JSON body on a `DELETE` request. Some generated SDKs,
  older HTTP clients, and proxies silently drop DELETE bodies — if `radar_ids`
  arrives empty you'll get a `400`. Verify your client preserves DELETE bodies
  before relying on it in production. (curl, modern `fetch`, and Python `requests` do.)
</Warning>


## OpenAPI

````yaml api_specs.yaml DELETE /v1/radars/bulk
openapi: 3.0.0
info:
  title: TAMradar API
  version: '1.0'
  description: Canonical OpenAPI spec for TAMradar customer-facing APIs.
servers:
  - url: https://api.tamradar.com
    description: Production API server
security: []
paths:
  /v1/radars/bulk:
    delete:
      tags:
        - Radars
      summary: Deactivate multiple radars
      description: >-
        Synchronously deactivates 1–500 radars. The response contains one item
        per requested ID in request order. Each item has the same success or
        error fields as `DELETE /v1/radars/{radar_id}`, plus `bulk_id`,
        `item_index`, and the requested `radar_id`. Expected item-level 400 and
        404 outcomes do not prevent other valid items from being deactivated.
        `bulk_id` is for request correlation only; bulk delete has no polling
        endpoint. Monthly radars enter their paid grace period and update-based
        radars deactivate immediately.
      operationId: deactivateBulkRadars
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BulkDeleteRequest'
      responses:
        '200':
          description: Bulk deactivation completed, including any item-level failures
          headers:
            X-RateLimit-Limit:
              schema:
                type: integer
            X-RateLimit-Remaining:
              schema:
                type: integer
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BulkDeleteResponse'
              example:
                status: completed
                code: 200
                message: Bulk radar deactivation completed
                timestamp: '2026-08-16T10:15:30.000Z'
                bulk_id: 5f9da22e-4778-427c-b7e4-dab2a8d9d709
                summary:
                  total: 2
                  deactivated: 1
                  failed: 1
                radars:
                  - bulk_id: 5f9da22e-4778-427c-b7e4-dab2a8d9d709
                    item_index: 0
                    radar_id: 223e4567-e89b-42d3-a456-426614174111
                    status: success
                    code: 200
                    message: Radar deactivated successfully
                    timestamp: '2026-08-16T10:15:30.000Z'
                    data:
                      radar_id: 223e4567-e89b-42d3-a456-426614174111
                      radar_type: contact_job_changes
                      domain: example.com
                      radar_status: inactive
                      created_at: '2026-08-01T10:00:00.000Z'
                      updates_since: null
                      deactivated_at: '2026-08-16T10:15:30.000Z'
                      next_charge_at: null
                      custom_fields:
                        account_id: acc_123
                  - bulk_id: 5f9da22e-4778-427c-b7e4-dab2a8d9d709
                    item_index: 1
                    radar_id: 323e4567-e89b-42d3-a456-426614174112
                    status: error
                    code: 404
                    message: Radar not found
                    errors:
                      - field: id
                        reason: Radar not found or you do not have access to it
                    timestamp: '2026-08-16T10:15:30.000Z'
                    error_id: f72ac8d3-4bca-4f4c-b14a-30af90e3eac2
        '400':
          description: Invalid JSON, envelope, UUID, duplicate, or item count
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '429':
          description: Shared bulk rate limit exceeded; no radar was changed
          headers:
            Retry-After:
              schema:
                type: integer
            X-RateLimit-Limit:
              schema:
                type: integer
            X-RateLimit-Remaining:
              schema:
                type: integer
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '500':
          description: Unexpected database error; the operation was rolled back
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - ApiKeyAuth: []
components:
  schemas:
    BulkDeleteRequest:
      type: object
      required:
        - radar_ids
      properties:
        radar_ids:
          type: array
          minItems: 1
          maxItems: 500
          uniqueItems: true
          items:
            type: string
            format: uuid
      additionalProperties: false
    BulkDeleteResponse:
      type: object
      required:
        - status
        - code
        - message
        - timestamp
        - bulk_id
        - summary
        - radars
      properties:
        status:
          type: string
          enum:
            - completed
        code:
          type: integer
          enum:
            - 200
        message:
          type: string
        timestamp:
          type: string
          format: date-time
        bulk_id:
          type: string
          format: uuid
          description: >-
            Correlation ID for this synchronous request; it is not persisted for
            polling.
        summary:
          $ref: '#/components/schemas/BulkDeleteSummary'
        radars:
          type: array
          items:
            oneOf:
              - $ref: '#/components/schemas/BulkDeleteSuccessItem'
              - $ref: '#/components/schemas/BulkDeleteErrorItem'
    ErrorResponse:
      type: object
      required:
        - status
        - code
        - message
        - errors
        - timestamp
        - error_id
      properties:
        status:
          type: string
          enum:
            - error
        code:
          type: integer
          enum:
            - 400
            - 401
            - 402
            - 403
            - 404
            - 409
            - 429
            - 500
            - 503
        message:
          type: string
        errors:
          type: array
          items:
            type: object
            required:
              - field
              - reason
            properties:
              field:
                type: string
              reason:
                type: string
              conflicting_radar_id:
                type: string
                format: uuid
                nullable: true
        timestamp:
          type: string
          format: date-time
        error_id:
          type: string
          format: uuid
    BulkDeleteSummary:
      type: object
      required:
        - total
        - deactivated
        - failed
      properties:
        total:
          type: integer
        deactivated:
          type: integer
        failed:
          type: integer
    BulkDeleteSuccessItem:
      type: object
      required:
        - bulk_id
        - item_index
        - radar_id
        - status
        - code
        - message
        - timestamp
        - data
      properties:
        bulk_id:
          type: string
          format: uuid
        item_index:
          type: integer
          minimum: 0
        radar_id:
          type: string
          format: uuid
        status:
          type: string
          enum:
            - success
        code:
          type: integer
          enum:
            - 200
        message:
          type: string
        timestamp:
          type: string
          format: date-time
        data:
          type: object
          description: Same transformed radar object returned by single DELETE.
          additionalProperties: true
    BulkDeleteErrorItem:
      type: object
      required:
        - bulk_id
        - item_index
        - radar_id
        - status
        - code
        - message
        - errors
        - timestamp
        - error_id
      properties:
        bulk_id:
          type: string
          format: uuid
        item_index:
          type: integer
          minimum: 0
        radar_id:
          type: string
          format: uuid
        status:
          type: string
          enum:
            - error
        code:
          type: integer
          enum:
            - 400
            - 404
        message:
          type: string
        errors:
          type: array
          items:
            type: object
            required:
              - field
              - reason
            properties:
              field:
                type: string
              reason:
                type: string
        timestamp:
          type: string
          format: date-time
        error_id:
          type: string
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key

````