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

# deleteMetric

***

# Function: deleteMetric()

```ts theme={null}
function deleteMetric(
  params: DeleteMetricParams | DeleteMetricByNameParams,
): Promise<void>;
```

Defined in: [src/utils/metrics.ts](https://github.com/rungalileo/galileo-js/blob/main/src/utils/metrics.ts)

Deletes a metric by its name and type, or by name only.

## Parameters

### params

The parameters for deleting the metric.

[`DeleteMetricParams`](/sdk-api/typescript/reference/types/interfaces/DeleteMetricParams) | [`DeleteMetricByNameParams`](/sdk-api/typescript/reference/types/interfaces/DeleteMetricByNameParams)

## Returns

`Promise`\<`void`>

A promise that resolves when the scorer(s) are successfully deleted.

## Throws

Error if the scorer with the given name is not found.
