---
type: api
title: Clear the archived repositories metering
description: Clear the archived repositories metering information in the cluster.
url: https://www.elastic.co/elastic/docs-builder/docs/4371/api/doc/elasticsearch/v8/operation/operation-nodes-clear-repositories-metering-archive
resource: https://www.elastic.co/elastic/docs-builder/docs/4371/api/doc/elasticsearch/v8/operation/operation-nodes-clear-repositories-metering-archive
products:
  - Elasticsearch
---

# Clear the archived repositories metering

Availability: 7.16+

## Paths

- `DELETE` `/_nodes/{node_id}/_repositories_metering/{max_archive_version}`

- [Api key auth](/elastic/docs-builder/docs/4371/api/doc/elasticsearch/v8/authentication#apikeyauth)
- [Basic auth](/elastic/docs-builder/docs/4371/api/doc/elasticsearch/v8/authentication#basicauth)
- [Bearer auth](/elastic/docs-builder/docs/4371/api/doc/elasticsearch/v8/authentication#bearerauth)

#### Path Parameters

- `node_id` (union NodeId | [] NodeId)
  Comma-separated list of node IDs or names used to limit returned information.
- `max_archive_version` (number)
  Specifies the maximum `archive_version` to be cleared from the archive.

## Description

Clear the archived repositories metering information in the cluster.

## Required authorization

* Cluster privileges: `monitor`,`manage`

## Response

`application/json`

- `_nodes` ({} NodeStatistics)
  Contains statistics about the number of nodes selected by the request’s node filters.
  - `failures` ([] ErrorCause)
    - `type` (string)
      The type of error
    - `reason` (union string) — nullable
      A human-readable explanation of the error, in English.
      One of: `string`
    - `stack_trace` (string)
      The server stack trace. Present only if the `error_trace=true` parameter was sent with the request.
    - `caused_by` ({} ErrorCause) — recursive
      Same fields as `failures` in `_nodes`
    - `root_cause` ([] ErrorCause) — recursive
      Same fields as `failures` in `_nodes`
    - `suppressed` ([] ErrorCause) — recursive
      Same fields as `failures` in `_nodes`
  - `total` (number)
    Total number of nodes selected by the request.
  - `successful` (number)
    Number of nodes that responded successfully to the request.
  - `failed` (number)
    Number of nodes that rejected the request or failed to respond. If this value is not 0, a reason for the rejection or failure is included in the response.
- `cluster_name` (string Name)
  Name of the cluster. Based on the `cluster.name` setting.
- `nodes` (map string to RepositoryMeteringInformation)
  Contains repositories metering information for the nodes selected by the request.
  Map values ({} RepositoryMeteringInformation)
  - `repository_name` (string Name)
    Repository name.
  - `repository_type` (string)
    Repository type.
  - `repository_location` ({} RepositoryLocation)
    Represents an unique location within the repository.
    - `base_path` (string)
    - `container` (string)
      Container name (Azure)
    - `bucket` (string)
      Bucket name (GCP, S3)
  - `repository_ephemeral_id` (string Id)
    An identifier that changes every time the repository is updated.
  - `repository_started_at` (EpochTimeUnitMillis)
    Time the repository was created or updated. Recorded in milliseconds since the Unix Epoch.
  - `repository_stopped_at` (EpochTimeUnitMillis)
    Time the repository was deleted or updated. Recorded in milliseconds since the Unix Epoch.
  - `archived` (boolean)
    A flag that tells whether or not this object has been archived. When a repository is closed or updated the
repository metering information is archived and kept for a certain period of time. This allows retrieving the
repository metering information of previous repository instantiations.
  - `cluster_version` (number VersionNumber)
    The cluster state version when this object was archived, this field can be used as a logical timestamp to delete
all the archived metrics up to an observed version. This field is only present for archived repository metering
information objects. The main purpose of this field is to avoid possible race conditions during repository metering
information deletions, i.e. deleting archived repositories metering information that we haven’t observed yet.
  - `request_counts` ({} RequestCounts)
    An object with the number of request performed against the repository grouped by request type.
    - `GetBlobProperties` (number)
      Number of Get Blob Properties requests (Azure)
    - `GetBlob` (number)
      Number of Get Blob requests (Azure)
    - `ListBlobs` (number)
      Number of List Blobs requests (Azure)
    - `PutBlob` (number)
      Number of Put Blob requests (Azure)
    - `PutBlock` (number)
      Number of Put Block (Azure)
    - `PutBlockList` (number)
      Number of Put Block List requests
    - `GetObject` (number)
      Number of get object requests (GCP, S3)
    - `ListObjects` (number)
      Number of list objects requests (GCP, S3)
    - `InsertObject` (number)
      Number of insert object requests, including simple, multipart and resumable uploads. Resumable uploads
can perform multiple http requests to insert a single object but they are considered as a single request
since they are billed as an individual operation. (GCP)
    - `PutObject` (number)
      Number of PutObject requests (S3)
    - `PutMultipartObject` (number)
      Number of Multipart requests, including CreateMultipartUpload, UploadPart and CompleteMultipartUpload requests (S3)
## Code Examples

#### Console

```console
DELETE /_nodes/{node_id}/_repositories_metering/{max_archive_version}
```

#### curl

```curl
curl -X DELETE "/_nodes/{node_id}/_repositories_metering/{max_archive_version}"
```

