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

# Project and model mutations

> Manage models and projects: baselines, tags, mappings, metrics, costs, filters. Arguments, return types and a validated example for each of the 18 mutations.

Manage models and projects: baselines, tags, mappings, metrics, costs, filters.

For task-oriented walkthroughs of these operations, see the [Project and model guide](/docs/ax/graphql-reference/guides/projects-and-models). Every mutation below is sent as a `POST` to `https://app.arize.com/graphql` with an `x-api-key` header; see [Forming calls](/docs/ax/graphql-reference/overview/how-to-use-graphql/forming-calls).

## Mutations in this page

* [`deleteModel`](#deletemodel): Delete model.
* [`deleteData`](#deletedata): Delete data for a specific time period.
* [`setModelBaseline`](#setmodelbaseline): Sets the primary baseline for a model
* [`setModelAutoBaselineConfig`](#setmodelautobaselineconfig): Set model auto baseline config.
* [`addTagsToModel`](#addtagstomodel): Add tags to model.
* [`removeTagsFromModel`](#removetagsfrommodel): Remove tags from model.
* [`updateModelColumnMappingConfig`](#updatemodelcolumnmappingconfig): Update column mapping configuration for a model
* [`updateProjectSourceMappingConfig`](#updateprojectsourcemappingconfig): Update source mapping configuration for a project.
* [`updateDimensionConfig`](#updatedimensionconfig): Updates an existing dimension config or creates a new one.
* [`createTraceFilter`](#createtracefilter): Create a trace filter
* [`updateTraceFilter`](#updatetracefilter): Updates a trace filter
* [`deleteTraceFilter`](#deletetracefilter): Deletes a traceFilter
* [`createCustomMetric`](#createcustommetric): Creates a new custom metric scoped to a space.
* [`updateCustomMetric`](#updatecustommetric): Updates an existing custom metric.
* [`deleteCustomMetric`](#deletecustommetric): Deletes a custom metric.
* [`createCostConfig`](#createcostconfig): Create a cost config
* [`updateCostConfig`](#updatecostconfig): Update a cost config
* [`deleteCostConfig`](#deletecostconfig): Deletes a cost config

## Reference

### deleteModel

`deleteModel(input: DeleteModelMutationInput!): DeleteModelMutationPayload`

#### Arguments

<ParamField body="input" type="DeleteModelMutationInput!" required>
  <Expandable title="DeleteModelMutationInput fields">
    <ParamField body="modelId" type="ID!" required />

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="model" type="Model">
  <Expandable title="Model fields">
    Scalar fields: `id`, `name`, `uri`, `createdAt`, `isDemoModel`, `isRestricted`, `modelType`, `modelEnvironmentNames`, `averagePerformanceMetric`, `totalTraffic`, `taskVariables`, `annotationsEnabled`, `isAgentExperimentTraceProject`, `projectType`, `annotationsDisabled`, `defaultAnnotationConfigIds`.

    Object fields (select subfields): `projectRoleBindings`, `space`, `volumeGateVisibility`, `modelVersions`, `modelBatches`, `modelPredictionVolume`, `modelEnvironments`, `dimension`, `dimensionValues`, `tracingSchema`, `modelSchema`, `modelPrimaryBaseline`, `modelReferenceDataset`, `modelDashboards`, `monitors`, `signalStatus`, `signalIssues`, `signalIssueActivityBounds`, `signalIssueCountsByEntity`, `signalIssueTimeSeries`, `monitorAggregations`, `driftConfigs`, `performanceConfigs`, `dataQualityConfigs`, `modelColumnMappingConfigs`, `projectSourceMappingConfigs`, `performanceMetrics`, `performanceStatus`, `performanceMetricOverTime`, `customMetrics`, `driftStatus`, `dataQualityStatus`, `UMAPPoints`, `spanRecordsPublic`, `costOverTime`, `tokensOverTime`, `costByModel`, `llmTracingStats`, `network`, `tags`, `_access`.
  </Expandable>
</ResponseField>

<ResponseField name="space" type="Space">
  <Expandable title="Space fields">
    Scalar fields: `id`, `name`, `description`, `uuid`, `createdAt`, `liveEnabled`, `isLLMOnlySpace`, `playgroundTracingModelId`, `evalTracingModelId`, `sandboxTracingModelId`, `mlModelsEnabled`, `private`, `gradientStartColor`, `gradientEndColor`, `hasDashboardsCreated`.

    Object fields (select subfields): `organization`, `models`, `monitors`, `dashboards`, `spaceUsers`, `byobConnectors`, `importJobs`, `tableJobs`, `sandboxJobs`, `signalInsightSummary`, `signalEnabledProjectSummary`, `signalIssues`, `agentIssues`, `automations`, `datasets`, `experiments`, `customMetrics`, `onlineTasks`, `prompts`, `tags`, `evaluators`, `annotationQueues`, `playgroundViews`, `annotationConfigs`, `traceFilters`, `llmIntegrations`, `defaultLlmIntegration`, `defaultAgentRuntime`, `gates`, `_access`.
  </Expandable>
</ResponseField>

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation DeleteModel($input: DeleteModelMutationInput!) {
    deleteModel(input: $input) {
      model { id name }
      space { id name }
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "modelId": "<ID>"
    }
  }
  ```
</CodeGroup>

### deleteData

Delete data for a specific time period. Note that the deletion process may take up to an hour to complete.

`deleteData(input: DeleteDataMutationInput!): DeleteDataMutationPayload`

#### Arguments

<ParamField body="input" type="DeleteDataMutationInput!" required>
  <Expandable title="DeleteDataMutationInput fields">
    <ParamField body="modelId" type="ID!" required />

    <ParamField body="startDate" type="Date!" required>
      UTC date for the start of the period to delete. Note that this date is inclusive
    </ParamField>

    <ParamField body="endDate" type="Date!" required>
      UTC date for the end of the period to delete. Note that this date is exclusive
    </ParamField>

    <ParamField body="deleteType" type="ModelDeleteDataType!" required>
      PRODUCTION will delete predictions, joined actuals, and shap data for ML models; spans for generative models. PREPRODUCTION will delete training and validation data. One of: `PRODUCTION`, `PREPRODUCTION`.
    </ParamField>

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="model" type="Model">
  <Expandable title="Model fields">
    Scalar fields: `id`, `name`, `uri`, `createdAt`, `isDemoModel`, `isRestricted`, `modelType`, `modelEnvironmentNames`, `averagePerformanceMetric`, `totalTraffic`, `taskVariables`, `annotationsEnabled`, `isAgentExperimentTraceProject`, `projectType`, `annotationsDisabled`, `defaultAnnotationConfigIds`.

    Object fields (select subfields): `projectRoleBindings`, `space`, `volumeGateVisibility`, `modelVersions`, `modelBatches`, `modelPredictionVolume`, `modelEnvironments`, `dimension`, `dimensionValues`, `tracingSchema`, `modelSchema`, `modelPrimaryBaseline`, `modelReferenceDataset`, `modelDashboards`, `monitors`, `signalStatus`, `signalIssues`, `signalIssueActivityBounds`, `signalIssueCountsByEntity`, `signalIssueTimeSeries`, `monitorAggregations`, `driftConfigs`, `performanceConfigs`, `dataQualityConfigs`, `modelColumnMappingConfigs`, `projectSourceMappingConfigs`, `performanceMetrics`, `performanceStatus`, `performanceMetricOverTime`, `customMetrics`, `driftStatus`, `dataQualityStatus`, `UMAPPoints`, `spanRecordsPublic`, `costOverTime`, `tokensOverTime`, `costByModel`, `llmTracingStats`, `network`, `tags`, `_access`.
  </Expandable>
</ResponseField>

<ResponseField name="space" type="Space">
  <Expandable title="Space fields">
    Scalar fields: `id`, `name`, `description`, `uuid`, `createdAt`, `liveEnabled`, `isLLMOnlySpace`, `playgroundTracingModelId`, `evalTracingModelId`, `sandboxTracingModelId`, `mlModelsEnabled`, `private`, `gradientStartColor`, `gradientEndColor`, `hasDashboardsCreated`.

    Object fields (select subfields): `organization`, `models`, `monitors`, `dashboards`, `spaceUsers`, `byobConnectors`, `importJobs`, `tableJobs`, `sandboxJobs`, `signalInsightSummary`, `signalEnabledProjectSummary`, `signalIssues`, `agentIssues`, `automations`, `datasets`, `experiments`, `customMetrics`, `onlineTasks`, `prompts`, `tags`, `evaluators`, `annotationQueues`, `playgroundViews`, `annotationConfigs`, `traceFilters`, `llmIntegrations`, `defaultLlmIntegration`, `defaultAgentRuntime`, `gates`, `_access`.
  </Expandable>
</ResponseField>

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation DeleteData($input: DeleteDataMutationInput!) {
    deleteData(input: $input) {
      model { id name }
      space { id name }
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "modelId": "<ID>",
      "startDate": "2026-01-01",
      "endDate": "2026-01-01",
      "deleteType": "PRODUCTION"
    }
  }
  ```
</CodeGroup>

### setModelBaseline

Sets the primary baseline for a model

`setModelBaseline(input: SetModelBaselineMutationInput!): SetModelBaselineMutationPayload`

#### Arguments

<ParamField body="input" type="SetModelBaselineMutationInput!" required>
  <Expandable title="SetModelBaselineMutationInput fields">
    <ParamField body="modelId" type="ID!" required>
      The modelId for which you are configuring the baseline
    </ParamField>

    <ParamField body="referenceType" type="BaselineReferenceType!" required>
      The reference type of model baseline. Values describe how a baseline is referenced(e.g. via a formal model\_version\_environment dataset, or via a set of filters) One of: `model_version_environment_metadata`, `filtered`.
    </ParamField>

    <ParamField body="filteredBaseline" type="SetModelFilteredBaselineInput">
      <Expandable title="SetModelFilteredBaselineInput fields">
        <ParamField body="modelEnvironmentName" type="ModelEnvironmentName">
          The model environment on the plot, ex. production, training, validation. Defaulted to production. One of: `production`, `validation`, `training`, `tracing`.
        </ParamField>

        <ParamField body="filteredMovingWindowSeconds" type="Float">
          The evaluation window length of the moving window.
        </ParamField>

        <ParamField body="filteredMovingWindowDelaySeconds" type="Float">
          The evaluation window delay length of the moving window.
        </ParamField>

        <ParamField body="filteredStartDate" type="DateTime">
          The start bookend of the baseline's time range. If set, this time should be used for the baseline
        </ParamField>

        <ParamField body="filteredEndDate" type="DateTime">
          The end bookend of the baseline's time range. If set, this time should be used for the baseline
        </ParamField>

        <ParamField body="batchId" type="ID">
          The batchId that you are tagging as the baseline
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField body="datasetBaseline" type="SetModelDataSetBaselineInput">
      <Expandable title="SetModelDataSetBaselineInput fields">
        <ParamField body="batchId" type="ID!" required>
          The batchId that you are tagging as the baseline
        </ParamField>

        <ParamField body="startDateOverride" type="DateTime">
          The override start bookend of the baseline's time range.
        </ParamField>

        <ParamField body="endDateOverride" type="DateTime">
          The override end bookend of the baseline's time range
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="modelBaseline" type="ModelBaseline">
  <Expandable title="ModelBaseline fields">
    Scalar fields: `id`, `referenceType`, `baselineType`, `startDateOverride`, `endDateOverride`, `userId`.

    Object fields (select subfields): `filteredBaseline`, `modelVersionEnvironmentBatch`, `trafficOverTime`.
  </Expandable>
</ResponseField>

<ResponseField name="model" type="Model">
  <Expandable title="Model fields">
    Scalar fields: `id`, `name`, `uri`, `createdAt`, `isDemoModel`, `isRestricted`, `modelType`, `modelEnvironmentNames`, `averagePerformanceMetric`, `totalTraffic`, `taskVariables`, `annotationsEnabled`, `isAgentExperimentTraceProject`, `projectType`, `annotationsDisabled`, `defaultAnnotationConfigIds`.

    Object fields (select subfields): `projectRoleBindings`, `space`, `volumeGateVisibility`, `modelVersions`, `modelBatches`, `modelPredictionVolume`, `modelEnvironments`, `dimension`, `dimensionValues`, `tracingSchema`, `modelSchema`, `modelPrimaryBaseline`, `modelReferenceDataset`, `modelDashboards`, `monitors`, `signalStatus`, `signalIssues`, `signalIssueActivityBounds`, `signalIssueCountsByEntity`, `signalIssueTimeSeries`, `monitorAggregations`, `driftConfigs`, `performanceConfigs`, `dataQualityConfigs`, `modelColumnMappingConfigs`, `projectSourceMappingConfigs`, `performanceMetrics`, `performanceStatus`, `performanceMetricOverTime`, `customMetrics`, `driftStatus`, `dataQualityStatus`, `UMAPPoints`, `spanRecordsPublic`, `costOverTime`, `tokensOverTime`, `costByModel`, `llmTracingStats`, `network`, `tags`, `_access`.
  </Expandable>
</ResponseField>

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation SetModelBaseline($input: SetModelBaselineMutationInput!) {
    setModelBaseline(input: $input) {
      modelBaseline { id }
      model { id name }
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "modelId": "<ID>",
      "referenceType": "model_version_environment_metadata"
    }
  }
  ```
</CodeGroup>

### setModelAutoBaselineConfig

`setModelAutoBaselineConfig(input: SetAutoBaselineConfigMutationInput!): SetAutoBaselineConfigMutationPayload`

#### Arguments

<ParamField body="input" type="SetAutoBaselineConfigMutationInput!" required>
  <Expandable title="SetAutoBaselineConfigMutationInput fields">
    <ParamField body="modelId" type="ID!" required />

    <ParamField body="environmentName" type="ModelPreProductionEnvironmentName!" required>
      One of: `validation`, `training`.
    </ParamField>

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="modelAutoBaselineConfig" type="ModelAutoBaselineConfig!">
  <Expandable title="ModelAutoBaselineConfig fields">
    Scalar fields: `id`, `modelId`, `environmentName`.
  </Expandable>
</ResponseField>

<ResponseField name="model" type="Model!">
  <Expandable title="Model fields">
    Scalar fields: `id`, `name`, `uri`, `createdAt`, `isDemoModel`, `isRestricted`, `modelType`, `modelEnvironmentNames`, `averagePerformanceMetric`, `totalTraffic`, `taskVariables`, `annotationsEnabled`, `isAgentExperimentTraceProject`, `projectType`, `annotationsDisabled`, `defaultAnnotationConfigIds`.

    Object fields (select subfields): `projectRoleBindings`, `space`, `volumeGateVisibility`, `modelVersions`, `modelBatches`, `modelPredictionVolume`, `modelEnvironments`, `dimension`, `dimensionValues`, `tracingSchema`, `modelSchema`, `modelPrimaryBaseline`, `modelReferenceDataset`, `modelDashboards`, `monitors`, `signalStatus`, `signalIssues`, `signalIssueActivityBounds`, `signalIssueCountsByEntity`, `signalIssueTimeSeries`, `monitorAggregations`, `driftConfigs`, `performanceConfigs`, `dataQualityConfigs`, `modelColumnMappingConfigs`, `projectSourceMappingConfigs`, `performanceMetrics`, `performanceStatus`, `performanceMetricOverTime`, `customMetrics`, `driftStatus`, `dataQualityStatus`, `UMAPPoints`, `spanRecordsPublic`, `costOverTime`, `tokensOverTime`, `costByModel`, `llmTracingStats`, `network`, `tags`, `_access`.
  </Expandable>
</ResponseField>

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation SetModelAutoBaselineConfig($input: SetAutoBaselineConfigMutationInput!) {
    setModelAutoBaselineConfig(input: $input) {
      modelAutoBaselineConfig { id }
      model { id name }
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "modelId": "<ID>",
      "environmentName": "validation"
    }
  }
  ```
</CodeGroup>

### addTagsToModel

`addTagsToModel(input: AddTagsToModelInput!): AddTagsToModelPayload`

#### Arguments

<ParamField body="input" type="AddTagsToModelInput!" required>
  <Expandable title="AddTagsToModelInput fields">
    <ParamField body="modelId" type="ID!" required />

    <ParamField body="tagIds" type="[ID!]!" required />

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="result" type="AddTagsToModelResult!">
  Union of `TagAssociationSuccess`, `TagAssociationError`. Use inline fragments (`... on TypeName`).
</ResponseField>

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation AddTagsToModel($input: AddTagsToModelInput!) {
    addTagsToModel(input: $input) {
      result { __typename }
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "modelId": "<ID>",
      "tagIds": [
        "<ID>"
      ]
    }
  }
  ```
</CodeGroup>

### removeTagsFromModel

`removeTagsFromModel(input: RemoveTagsFromModelInput!): RemoveTagsFromModelPayload`

#### Arguments

<ParamField body="input" type="RemoveTagsFromModelInput!" required>
  <Expandable title="RemoveTagsFromModelInput fields">
    <ParamField body="modelId" type="ID!" required />

    <ParamField body="tagIds" type="[ID!]!" required />

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="result" type="RemoveTagsFromModelResult!">
  Union of `TagAssociationSuccess`, `TagAssociationError`. Use inline fragments (`... on TypeName`).
</ResponseField>

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation RemoveTagsFromModel($input: RemoveTagsFromModelInput!) {
    removeTagsFromModel(input: $input) {
      result { __typename }
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "modelId": "<ID>",
      "tagIds": [
        "<ID>"
      ]
    }
  }
  ```
</CodeGroup>

### updateModelColumnMappingConfig

Update column mapping configuration for a model

`updateModelColumnMappingConfig(input: UpdateModelColumnMappingConfigInput!): UpdateModelColumnMappingConfigPayload`

#### Arguments

<ParamField body="input" type="UpdateModelColumnMappingConfigInput!" required>
  <Expandable title="UpdateModelColumnMappingConfigInput fields">
    <ParamField body="modelId" type="ID!" required>
      The model ID of the model to be updated
    </ParamField>

    <ParamField body="columnMapping" type="JSON!" required>
      The column mapping configuration as a JSON object with shortcut keys mapped to column paths
    </ParamField>

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="model" type="Model">
  <Expandable title="Model fields">
    Scalar fields: `id`, `name`, `uri`, `createdAt`, `isDemoModel`, `isRestricted`, `modelType`, `modelEnvironmentNames`, `averagePerformanceMetric`, `totalTraffic`, `taskVariables`, `annotationsEnabled`, `isAgentExperimentTraceProject`, `projectType`, `annotationsDisabled`, `defaultAnnotationConfigIds`.

    Object fields (select subfields): `projectRoleBindings`, `space`, `volumeGateVisibility`, `modelVersions`, `modelBatches`, `modelPredictionVolume`, `modelEnvironments`, `dimension`, `dimensionValues`, `tracingSchema`, `modelSchema`, `modelPrimaryBaseline`, `modelReferenceDataset`, `modelDashboards`, `monitors`, `signalStatus`, `signalIssues`, `signalIssueActivityBounds`, `signalIssueCountsByEntity`, `signalIssueTimeSeries`, `monitorAggregations`, `driftConfigs`, `performanceConfigs`, `dataQualityConfigs`, `modelColumnMappingConfigs`, `projectSourceMappingConfigs`, `performanceMetrics`, `performanceStatus`, `performanceMetricOverTime`, `customMetrics`, `driftStatus`, `dataQualityStatus`, `UMAPPoints`, `spanRecordsPublic`, `costOverTime`, `tokensOverTime`, `costByModel`, `llmTracingStats`, `network`, `tags`, `_access`.
  </Expandable>
</ResponseField>

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation UpdateModelColumnMappingConfig($input: UpdateModelColumnMappingConfigInput!) {
    updateModelColumnMappingConfig(input: $input) {
      model { id name }
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "modelId": "<ID>",
      "columnMapping": {}
    }
  }
  ```
</CodeGroup>

### updateProjectSourceMappingConfig

Update source mapping configuration for a project. Maps target columns (input/output) to dot-notation attribute paths.

`updateProjectSourceMappingConfig(input: UpdateProjectSourceMappingConfigInput!): UpdateProjectSourceMappingConfigPayload`

#### Arguments

<ParamField body="input" type="UpdateProjectSourceMappingConfigInput!" required>
  <Expandable title="UpdateProjectSourceMappingConfigInput fields">
    <ParamField body="modelId" type="ID!" required>
      The model/project ID to update
    </ParamField>

    <ParamField body="sourceMappings" type="JSON!" required>
      Source mapping configuration as a JSON object. Keys must be "input" or "output", values are dot-notation attribute paths (e.g. \{"input": "input.value.actions.-1"})
    </ParamField>

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="model" type="Model">
  <Expandable title="Model fields">
    Scalar fields: `id`, `name`, `uri`, `createdAt`, `isDemoModel`, `isRestricted`, `modelType`, `modelEnvironmentNames`, `averagePerformanceMetric`, `totalTraffic`, `taskVariables`, `annotationsEnabled`, `isAgentExperimentTraceProject`, `projectType`, `annotationsDisabled`, `defaultAnnotationConfigIds`.

    Object fields (select subfields): `projectRoleBindings`, `space`, `volumeGateVisibility`, `modelVersions`, `modelBatches`, `modelPredictionVolume`, `modelEnvironments`, `dimension`, `dimensionValues`, `tracingSchema`, `modelSchema`, `modelPrimaryBaseline`, `modelReferenceDataset`, `modelDashboards`, `monitors`, `signalStatus`, `signalIssues`, `signalIssueActivityBounds`, `signalIssueCountsByEntity`, `signalIssueTimeSeries`, `monitorAggregations`, `driftConfigs`, `performanceConfigs`, `dataQualityConfigs`, `modelColumnMappingConfigs`, `projectSourceMappingConfigs`, `performanceMetrics`, `performanceStatus`, `performanceMetricOverTime`, `customMetrics`, `driftStatus`, `dataQualityStatus`, `UMAPPoints`, `spanRecordsPublic`, `costOverTime`, `tokensOverTime`, `costByModel`, `llmTracingStats`, `network`, `tags`, `_access`.
  </Expandable>
</ResponseField>

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation UpdateProjectSourceMappingConfig($input: UpdateProjectSourceMappingConfigInput!) {
    updateProjectSourceMappingConfig(input: $input) {
      model { id name }
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "modelId": "<ID>",
      "sourceMappings": {}
    }
  }
  ```
</CodeGroup>

### updateDimensionConfig

Updates an existing dimension config or creates a new one.

`updateDimensionConfig(input: UpdateDimensionConfigMutationInput!): UpdateDimensionConfigMutationPayload`

#### Arguments

<ParamField body="input" type="UpdateDimensionConfigMutationInput!" required>
  <Expandable title="UpdateDimensionConfigMutationInput fields">
    <ParamField body="modelId" type="ID!" required>
      The ID of the model the dimension config belongs to
    </ParamField>

    <ParamField body="dimensionName" type="String!" required />

    <ParamField body="dimensionCategory" type="DimensionCategory!" required>
      One of: `featureLabel`, `prediction`, `actuals`, `actualScore`, `actualClass`, `predictionClass`, `predictionScore`, `tag`, `spanProperty`, `llmEval`, `annotation`, `userAnnotation`, `modelVersion`, `batchId`.
    </ParamField>

    <ParamField body="binOption" type="DimensionBinOption!" required>
      One of: `equalWidth`, `custom`, `medianCentered`, `discrete`, `decile`, `quantiles`, `discreteTopN`.
    </ParamField>

    <ParamField body="numBins" type="Int">
      A positive integer representing the number of bins to return. Compatible with the equalWidth binOption.
    </ParamField>

    <ParamField body="customBins" type="[Float!]">
      An array of thresholds that represent the cut points E.x. \[1, 20, 50, 90]. Compatible with the custom binOption.
    </ParamField>

    <ParamField body="quantiles" type="[Float!]">
      An array of thresholds that represent the custom quantiles E.x. \[0 (min), 0.3 (30th percentile), 0.5 (50th percentile), 1 (max)]. Compatible with the quantiles binOption.
    </ParamField>

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="dimensionConfig" type="DimensionConfig">
  <Expandable title="DimensionConfig fields">
    Scalar fields: `id`, `modelId`, `dimensionName`, `dimensionCategory`, `binOption`, `numBins`, `bins`.
  </Expandable>
</ResponseField>

<ResponseField name="model" type="Model!">
  The model on which the dimension config was created.

  <Expandable title="Model fields">
    Scalar fields: `id`, `name`, `uri`, `createdAt`, `isDemoModel`, `isRestricted`, `modelType`, `modelEnvironmentNames`, `averagePerformanceMetric`, `totalTraffic`, `taskVariables`, `annotationsEnabled`, `isAgentExperimentTraceProject`, `projectType`, `annotationsDisabled`, `defaultAnnotationConfigIds`.

    Object fields (select subfields): `projectRoleBindings`, `space`, `volumeGateVisibility`, `modelVersions`, `modelBatches`, `modelPredictionVolume`, `modelEnvironments`, `dimension`, `dimensionValues`, `tracingSchema`, `modelSchema`, `modelPrimaryBaseline`, `modelReferenceDataset`, `modelDashboards`, `monitors`, `signalStatus`, `signalIssues`, `signalIssueActivityBounds`, `signalIssueCountsByEntity`, `signalIssueTimeSeries`, `monitorAggregations`, `driftConfigs`, `performanceConfigs`, `dataQualityConfigs`, `modelColumnMappingConfigs`, `projectSourceMappingConfigs`, `performanceMetrics`, `performanceStatus`, `performanceMetricOverTime`, `customMetrics`, `driftStatus`, `dataQualityStatus`, `UMAPPoints`, `spanRecordsPublic`, `costOverTime`, `tokensOverTime`, `costByModel`, `llmTracingStats`, `network`, `tags`, `_access`.
  </Expandable>
</ResponseField>

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation UpdateDimensionConfig($input: UpdateDimensionConfigMutationInput!) {
    updateDimensionConfig(input: $input) {
      dimensionConfig { id }
      model { id name }
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "modelId": "<ID>",
      "dimensionName": "<string>",
      "dimensionCategory": "featureLabel",
      "binOption": "equalWidth"
    }
  }
  ```
</CodeGroup>

### createTraceFilter

Create a trace filter

`createTraceFilter(input: CreateTraceFilterInput!): CreateTraceFilterPayload`

#### Arguments

<ParamField body="input" type="CreateTraceFilterInput!" required>
  <Expandable title="CreateTraceFilterInput fields">
    <ParamField body="name" type="String!" required>
      The name of the trace filter
    </ParamField>

    <ParamField body="description" type="String">
      The description of the trace filter
    </ParamField>

    <ParamField body="expression" type="String!" required>
      The expression of the trace filter
    </ParamField>

    <ParamField body="subqueries" type="[SpanFilterInput!]!" required>
      The span queries of the trace filter

      <Expandable title="SpanFilterInput fields">
        <ParamField body="name" type="String!" required>
          The name of the span filter
        </ParamField>

        <ParamField body="description" type="String">
          The description of the span filter
        </ParamField>

        <ParamField body="query" type="String!" required>
          The query of the span filter
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField body="spaceId" type="ID!" required>
      The space id of the trace filter
    </ParamField>

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="traceFilter" type="TraceFilter!">
  The created trace filter

  <Expandable title="TraceFilter fields">
    Scalar fields: `id`, `name`, `description`, `expression`, `spaceId`, `createdAt`, `updatedAt`.

    Object fields (select subfields): `subqueries`, `user`.
  </Expandable>
</ResponseField>

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation CreateTraceFilter($input: CreateTraceFilterInput!) {
    createTraceFilter(input: $input) {
      traceFilter { id name }
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "name": "<string>",
      "expression": "<string>",
      "subqueries": [
        {
          "name": "<string>",
          "query": "<string>"
        }
      ],
      "spaceId": "<ID>"
    }
  }
  ```
</CodeGroup>

### updateTraceFilter

Updates a trace filter

`updateTraceFilter(input: UpdateTraceFilterInput!): UpdateTraceFilterPayload`

#### Arguments

<ParamField body="input" type="UpdateTraceFilterInput!" required>
  <Expandable title="UpdateTraceFilterInput fields">
    <ParamField body="id" type="ID!" required>
      The id of the trace filter to update
    </ParamField>

    <ParamField body="spaceId" type="ID!" required>
      The space id of the trace filter
    </ParamField>

    <ParamField body="name" type="String">
      The name of the trace filter
    </ParamField>

    <ParamField body="description" type="String">
      The description of the trace filter
    </ParamField>

    <ParamField body="expression" type="String">
      The expression of the trace filter
    </ParamField>

    <ParamField body="subqueries" type="[SpanFilterInput!]">
      The span queries of the trace filter

      <Expandable title="SpanFilterInput fields">
        <ParamField body="name" type="String!" required>
          The name of the span filter
        </ParamField>

        <ParamField body="description" type="String">
          The description of the span filter
        </ParamField>

        <ParamField body="query" type="String!" required>
          The query of the span filter
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="traceFilter" type="TraceFilter!">
  The updated trace filter

  <Expandable title="TraceFilter fields">
    Scalar fields: `id`, `name`, `description`, `expression`, `spaceId`, `createdAt`, `updatedAt`.

    Object fields (select subfields): `subqueries`, `user`.
  </Expandable>
</ResponseField>

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation UpdateTraceFilter($input: UpdateTraceFilterInput!) {
    updateTraceFilter(input: $input) {
      traceFilter { id name }
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "id": "<ID>",
      "spaceId": "<ID>"
    }
  }
  ```
</CodeGroup>

### deleteTraceFilter

Deletes a traceFilter

`deleteTraceFilter(input: DeleteTraceFilterInput!): DeleteTraceFilterPayload`

#### Arguments

<ParamField body="input" type="DeleteTraceFilterInput!" required>
  <Expandable title="DeleteTraceFilterInput fields">
    <ParamField body="id" type="ID!" required />

    <ParamField body="spaceId" type="ID!" required>
      The space id
    </ParamField>

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="success" type="Boolean!" />

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation DeleteTraceFilter($input: DeleteTraceFilterInput!) {
    deleteTraceFilter(input: $input) {
      success
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "id": "<ID>",
      "spaceId": "<ID>"
    }
  }
  ```
</CodeGroup>

### createCustomMetric

Creates a new custom metric scoped to a space.

`createCustomMetric(input: CreateCustomMetricMutationInput!): CreateCustomMetricMutationPayload`

#### Arguments

<ParamField body="input" type="CreateCustomMetricMutationInput!" required>
  <Expandable title="CreateCustomMetricMutationInput fields">
    <ParamField body="spaceId" type="ID!" required>
      The id of the space to create the custom metric in.
    </ParamField>

    <ParamField body="modelId" type="ID">
      Optional model id used to validate the SQL against a specific model schema.
    </ParamField>

    <ParamField body="name" type="String!" required>
      A name that describes the custom metric
    </ParamField>

    <ParamField body="description" type="String!" required>
      The description of the custom metric
    </ParamField>

    <ParamField body="metric" type="String!" required>
      The custom metric query. E.x. select AVG(scorePredictionLabel) from model
    </ParamField>

    <ParamField body="modelEnvironmentName" type="ModelEnvironmentName">
      Model environment used to validate the metric. Defaults to production when modelId is provided. One of: `production`, `validation`, `training`, `tracing`.
    </ParamField>

    <ParamField body="includeStartDate" type="String">
      Optional ISO start time to widen model schema discovery to match the active dataset window
    </ParamField>

    <ParamField body="includeEndDate" type="String">
      Optional ISO end time to widen model schema discovery to match the active dataset window
    </ParamField>

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="customMetric" type="CustomMetric!">
  The newly created custom metric.

  <Expandable title="CustomMetric fields">
    Scalar fields: `id`, `createdAt`, `name`, `description`, `metric`, `requiresPositiveClass`, `spaceId`, `modelName`, `modelId`, `modelType`.
  </Expandable>
</ResponseField>

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation CreateCustomMetric($input: CreateCustomMetricMutationInput!) {
    createCustomMetric(input: $input) {
      customMetric { id name }
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "spaceId": "<ID>",
      "name": "<string>",
      "description": "<string>",
      "metric": "<string>"
    }
  }
  ```
</CodeGroup>

### updateCustomMetric

Updates an existing custom metric.

`updateCustomMetric(input: UpdateCustomMetricMutationInput!): UpdateCustomMetricMutationPayload`

#### Arguments

<ParamField body="input" type="UpdateCustomMetricMutationInput!" required>
  <Expandable title="UpdateCustomMetricMutationInput fields">
    <ParamField body="customMetricId" type="ID!" required>
      The id of the custom metric to update.
    </ParamField>

    <ParamField body="modelId" type="ID">
      Optional model id used to validate the SQL against a specific model schema.
    </ParamField>

    <ParamField body="name" type="String!" required>
      A name that describes the custom metric
    </ParamField>

    <ParamField body="description" type="String!" required>
      The description of the custom metric
    </ParamField>

    <ParamField body="customMetric" type="String!" required>
      The custom metric query. E.x. select AVG(scorePredictionLabel) from model
    </ParamField>

    <ParamField body="modelEnvironmentName" type="ModelEnvironmentName">
      Model environment used to validate the metric. Defaults to production when modelId is provided. One of: `production`, `validation`, `training`, `tracing`.
    </ParamField>

    <ParamField body="includeStartDate" type="String">
      Optional ISO start time to widen model schema discovery to match the active dataset window
    </ParamField>

    <ParamField body="includeEndDate" type="String">
      Optional ISO end time to widen model schema discovery to match the active dataset window
    </ParamField>

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="customMetric" type="CustomMetric!">
  The updated custom metric.

  <Expandable title="CustomMetric fields">
    Scalar fields: `id`, `createdAt`, `name`, `description`, `metric`, `requiresPositiveClass`, `spaceId`, `modelName`, `modelId`, `modelType`.
  </Expandable>
</ResponseField>

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation UpdateCustomMetric($input: UpdateCustomMetricMutationInput!) {
    updateCustomMetric(input: $input) {
      customMetric { id name }
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "customMetricId": "<ID>",
      "name": "<string>",
      "description": "<string>",
      "customMetric": "<string>"
    }
  }
  ```
</CodeGroup>

### deleteCustomMetric

Deletes a custom metric.

`deleteCustomMetric(input: DeleteCustomMetricMutationInput!): DeleteCustomMetricMutationPayload`

#### Arguments

<ParamField body="input" type="DeleteCustomMetricMutationInput!" required>
  <Expandable title="DeleteCustomMetricMutationInput fields">
    <ParamField body="spaceId" type="ID!" required>
      The id of the space the custom metric belongs to.
    </ParamField>

    <ParamField body="modelId" type="ID">
      Deprecated: formerly required model id. No longer used. **Deprecated:** Custom metrics are now space-scoped.
    </ParamField>

    <ParamField body="customMetricId" type="ID!" required>
      The id of the custom metric to delete.
    </ParamField>

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation DeleteCustomMetric($input: DeleteCustomMetricMutationInput!) {
    deleteCustomMetric(input: $input) {
      clientMutationId
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "spaceId": "<ID>",
      "customMetricId": "<ID>"
    }
  }
  ```
</CodeGroup>

### createCostConfig

Create a cost config

`createCostConfig(input: CreateCostConfigInput!): CreateCostConfigPayload`

#### Arguments

<ParamField body="input" type="CreateCostConfigInput!" required>
  <Expandable title="CreateCostConfigInput fields">
    <ParamField body="modelName" type="String!" required>
      The name of the LLM model to create a cost config for
    </ParamField>

    <ParamField body="modelRegex" type="String">
      The regex of the LLM model to create a cost config for
    </ParamField>

    <ParamField body="llmProvider" type="String">
      The provider of the LLM model
    </ParamField>

    <ParamField body="accountOrganizationId" type="ID">
      Legacy org anchor for the flag-off surface. Optional: the account-level surface omits it and the server derives the legacy column from the scopings or the account's org.
    </ParamField>

    <ParamField body="scopings" type="[CostConfigScopingInput!]">
      Scopes this cost config applies to (account-wide/org/space). Defaults to the account organization when omitted.

      <Expandable title="CostConfigScopingInput fields">
        <ParamField body="accountOrganizationId" type="ID">
          The account organization this scope applies to
        </ParamField>

        <ParamField body="spaceId" type="ID">
          The space this scope applies to
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField body="tokenConfigs" type="[InputTokenConfig]!" required>
      The token configs for the cost config

      <Expandable title="InputTokenConfig fields">
        <ParamField body="tokenName" type="String!" required />

        <ParamField body="tokenCostDollars" type="Float!" required />

        <ParamField body="tokenAppliesTo" type="TokenAppliesTo!" required>
          Whether the token applies to the prompt or completion One of: `prompt`, `completion`.
        </ParamField>

        <ParamField body="pricingStartsAtTokenCount" type="Int">
          Token count threshold at which this pricing tier applies (default 0)
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="success" type="Boolean!">
  Whether or not the cost config was successfully created or updated.
</ResponseField>

<ResponseField name="costConfig" type="CostConfig!">
  The created cost config

  <Expandable title="CostConfig fields">
    Scalar fields: `id`, `createdAt`, `accountOrganizationId`, `updatedAt`, `modelName`, `modelRegex`, `llmProvider`, `isDefault`, `hasUnauthorizedScopings`.

    Object fields (select subfields): `user`, `tokenConfigs`, `scopings`.
  </Expandable>
</ResponseField>

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation CreateCostConfig($input: CreateCostConfigInput!) {
    createCostConfig(input: $input) {
      success
      costConfig { id }
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "modelName": "<string>",
      "tokenConfigs": [
        {
          "tokenName": "<string>",
          "tokenCostDollars": 1,
          "tokenAppliesTo": "prompt"
        }
      ]
    }
  }
  ```
</CodeGroup>

### updateCostConfig

Update a cost config

`updateCostConfig(input: UpdateCostConfigInput!): UpdateCostConfigPayload`

#### Arguments

<ParamField body="input" type="UpdateCostConfigInput!" required>
  <Expandable title="UpdateCostConfigInput fields">
    <ParamField body="costConfigId" type="ID!" required>
      The id of the cost config to update
    </ParamField>

    <ParamField body="accountOrganizationId" type="ID">
      Unused by the resolver (auth derives from the config's own scopings); kept optional for the legacy flag-off surface.
    </ParamField>

    <ParamField body="modelName" type="String">
      The name of the updated
    </ParamField>

    <ParamField body="modelRegex" type="String">
      The regex of the model to update the cost config for
    </ParamField>

    <ParamField body="llmProvider" type="String">
      The provider of the LLM model
    </ParamField>

    <ParamField body="scopings" type="[CostConfigScopingInput!]">
      When provided, replaces the scopes this cost config applies to (account-wide/org/space). Omit to leave scopes unchanged.

      <Expandable title="CostConfigScopingInput fields">
        <ParamField body="accountOrganizationId" type="ID">
          The account organization this scope applies to
        </ParamField>

        <ParamField body="spaceId" type="ID">
          The space this scope applies to
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField body="tokenConfigs" type="[InputTokenConfig]!" required>
      The token configs for the cost config

      <Expandable title="InputTokenConfig fields">
        <ParamField body="tokenName" type="String!" required />

        <ParamField body="tokenCostDollars" type="Float!" required />

        <ParamField body="tokenAppliesTo" type="TokenAppliesTo!" required>
          Whether the token applies to the prompt or completion One of: `prompt`, `completion`.
        </ParamField>

        <ParamField body="pricingStartsAtTokenCount" type="Int">
          Token count threshold at which this pricing tier applies (default 0)
        </ParamField>
      </Expandable>
    </ParamField>

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="costConfig" type="CostConfig!">
  The updated cost config

  <Expandable title="CostConfig fields">
    Scalar fields: `id`, `createdAt`, `accountOrganizationId`, `updatedAt`, `modelName`, `modelRegex`, `llmProvider`, `isDefault`, `hasUnauthorizedScopings`.

    Object fields (select subfields): `user`, `tokenConfigs`, `scopings`.
  </Expandable>
</ResponseField>

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation UpdateCostConfig($input: UpdateCostConfigInput!) {
    updateCostConfig(input: $input) {
      costConfig { id }
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "costConfigId": "<ID>",
      "tokenConfigs": [
        {
          "tokenName": "<string>",
          "tokenCostDollars": 1,
          "tokenAppliesTo": "prompt"
        }
      ]
    }
  }
  ```
</CodeGroup>

### deleteCostConfig

Deletes a cost config

`deleteCostConfig(input: DeleteCostConfigInput!): DeleteCostConfigPayload`

#### Arguments

<ParamField body="input" type="DeleteCostConfigInput!" required>
  <Expandable title="DeleteCostConfigInput fields">
    <ParamField body="id" type="ID!" required />

    <ParamField body="accountOrganizationId" type="ID">
      Unused by the resolver (lookup + auth are by config id); kept optional for the legacy flag-off surface.
    </ParamField>

    <ParamField body="clientMutationId" type="String" />
  </Expandable>
</ParamField>

#### Returns

<ResponseField name="success" type="Boolean!" />

#### Example

Only required input fields are shown. Replace `<ID>` and `<string>` placeholders with real values; the [object graph](/docs/ax/graphql-reference/queries/object-graph) page shows how to look IDs up.

<CodeGroup>
  ```graphql Mutation theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  mutation DeleteCostConfig($input: DeleteCostConfigInput!) {
    deleteCostConfig(input: $input) {
      success
    }
  }
  ```

  ```json Variables theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
  {
    "input": {
      "id": "<ID>"
    }
  }
  ```
</CodeGroup>
