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

# Delete a MDR detailed report request

> Deletes a specific MDR detailed report request by ID



## OpenAPI

````yaml https://telnyx-openapi-ng.s3.us-east-1.amazonaws.com/account-billing/usage-reports.yml delete /legacy_reporting/batch_detail_records/messaging/{id}
openapi: 3.1.0
info:
  title: Telnyx Usage Reports API
  version: 2.0.0
  description: API for Usage reports.
  contact:
    email: support@telnyx.com
servers:
  - url: https://api.telnyx.com/v2
security:
  - bearerAuth: []
paths:
  /legacy_reporting/batch_detail_records/messaging/{id}:
    delete:
      tags:
        - MDR Detailed Reports
      summary: Delete a MDR detailed report request
      description: Deletes a specific MDR detailed report request by ID
      operationId: deleteMdrRequest
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
      responses:
        '200':
          description: MDR detailed report request deleted successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MdrDeleteDetailReportResponse'
        '401':
          description: Unauthorized
        '403':
          description: Forbidden
        '404':
          description: Report not found
        '500':
          description: Internal server error
      security:
        - bearerAuth: []
      x-codeSamples:
        - lang: JavaScript
          source: >-
            import Telnyx from 'telnyx';


            const client = new Telnyx({
              apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
            });


            const messaging = await
            client.legacy.reporting.batchDetailRecords.messaging.delete(
              '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
            );


            console.log(messaging.data);
        - lang: Python
          source: >-
            import os

            from telnyx import Telnyx


            client = Telnyx(
                api_key=os.environ.get("TELNYX_API_KEY"),  # This is the default and can be omitted
            )

            messaging =
            client.legacy.reporting.batch_detail_records.messaging.delete(
                "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
            )

            print(messaging.data)
        - lang: Go
          source: "package main\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\n\t\"github.com/team-telnyx/telnyx-go\"\n\t\"github.com/team-telnyx/telnyx-go/option\"\n)\n\nfunc main() {\n\tclient := telnyx.NewClient(\n\t\toption.WithAPIKey(\"My API Key\"),\n\t)\n\tmessaging, err := client.Legacy.Reporting.BatchDetailRecords.Messaging.Delete(context.TODO(), \"182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e\")\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tfmt.Printf(\"%+v\\n\", messaging.Data)\n}\n"
        - lang: Java
          source: >-
            package com.telnyx.sdk.example;


            import com.telnyx.sdk.client.TelnyxClient;

            import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;

            import
            com.telnyx.sdk.models.legacy.reporting.batchdetailrecords.messaging.MessagingDeleteParams;

            import
            com.telnyx.sdk.models.legacy.reporting.batchdetailrecords.messaging.MessagingDeleteResponse;


            public final class Main {
                private Main() {}

                public static void main(String[] args) {
                    TelnyxClient client = TelnyxOkHttpClient.fromEnv();

                    MessagingDeleteResponse messaging = client.legacy().reporting().batchDetailRecords().messaging().delete("182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e");
                }
            }
        - lang: Ruby
          source: >-
            require "telnyx"


            telnyx = Telnyx::Client.new(api_key: "My API Key")


            messaging =
            telnyx.legacy.reporting.batch_detail_records.messaging.delete("182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e")


            puts(messaging)
        - lang: PHP
          source: >-
            <?php


            require_once dirname(__DIR__) . '/vendor/autoload.php';


            use Telnyx\Client;

            use Telnyx\Core\Exceptions\APIException;


            $client = new Client(apiKey: getenv('TELNYX_API_KEY') ?: 'My API
            Key');


            try {
              $messaging = $client
                ->legacy
                ->reporting
                ->batchDetailRecords
                ->messaging
                ->delete('182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e');

              var_dump($messaging);
            } catch (APIException $e) {
              echo $e->getMessage();
            }
        - lang: CLI
          source: |-
            telnyx legacy:reporting:batch-detail-records:messaging delete \
              --api-key 'My API Key' \
              --id 182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e
components:
  schemas:
    MdrDeleteDetailReportResponse:
      type: object
      properties:
        data:
          $ref: '#/components/schemas/MdrDetailReportResponse'
    MdrDetailReportResponse:
      type: object
      properties:
        id:
          type: string
          description: Identifies the resource
          format: uuid
        start_date:
          type: string
          format: date-time
          example: '2020-07-01T00:00:00-06:00'
        end_date:
          type: string
          format: date-time
          example: '2020-07-01T00:00:00-06:00'
        directions:
          type: array
          items:
            type: string
            enum:
              - INBOUND
              - OUTBOUND
        record_types:
          type: array
          items:
            type: string
            enum:
              - INCOMPLETE
              - COMPLETED
              - ERRORS
        connections:
          type: array
          items:
            type: integer
            format: int64
        report_name:
          type: string
          example: report_name_8hvb45Gu
        status:
          type: string
          enum:
            - PENDING
            - COMPLETE
            - FAILED
            - EXPIRED
        report_url:
          type: string
          example: http://portal.telnyx.com/downloads/report_name_8hvb45Gu.csv
        filters:
          type: array
          items:
            $ref: '#/components/schemas/Filter'
        created_at:
          type: string
          format: date-time
          example: '2020-07-01T00:00:00-06:00'
        updated_at:
          type: string
          format: date-time
          example: '2020-07-01T00:00:00-06:00'
        profiles:
          type: array
          description: List of messaging profile IDs
          items:
            type: string
            format: uuid
          example:
            - 3fa85f64-5717-4562-b3fc-2c963f66afa6
            - 7d4e3f8a-9b2c-4e1d-8f5a-1a2b3c4d5e6f
        record_type:
          type: string
          example: mdr_report
    Filter:
      type: object
      description: >-
        Query filter criteria. Note: The first filter object must specify
        filter_type as 'and'. You cannot follow an 'or' with another 'and'.
      properties:
        filter_type:
          type: string
          description: Logical operator for combining filters
          enum:
            - and
            - or
        cli:
          type: string
          description: Calling line identification (caller ID)
          example: '+13129457420'
        cli_filter:
          type: string
          description: Filter type for CLI matching
          enum:
            - contains
            - starts_with
            - ends_with
        cld:
          type: string
          description: Called line identification (destination number)
          example: '+13129457420'
        cld_filter:
          type: string
          description: Filter type for CLD matching
          enum:
            - contains
            - starts_with
            - ends_with
        tags_list:
          type: string
          description: Tag name to filter by
          example: tag1
        billing_group:
          type: string
          description: Billing group UUID to filter by
          example: adfaa016-f921-4b6c-97bb-e4c1dad231c5
  securitySchemes:
    bearerAuth:
      scheme: bearer
      type: http

````