---
title: 'ARC0005: Value produced by Provide is not consumed by Handle'
description: Consume every non-control value produced by a command's Provide method.
---


<a id="severity"></a>

## Rule

When a command declares `Provide()`, each produced value must have a compatible `Handle()` parameter. The analyzer unwraps `Task<T>`, `ValueTask<T>`, tuples, and OneOf-based result alternatives. It accepts identity or implicit conversions to a handler parameter. **Default severity: Warning.**

Control values that short-circuit execution instead of feeding `Handle` are exempt: `ValidationResult`, collections of `ValidationResult`, `AuthorizationResult`, and `CommandResult`.

<a id="example"></a>
<a id="violation"></a>

## Diagnostic example

Compile these alternatives separately with `Cratis.Arc.Core`. They illustrate data flow only; the first intentionally produces ARC0005.

```csharp
using Cratis.Arc.Commands.ModelBound;

[Command]
public record NormalizeName(string Name)
{
    public string Provide() => Name.Trim();

    public string Handle() => Name;
}
```

<a id="fix"></a>

`Provide()` produces a trimmed string, but the handler ignores it. Consume the provided value:

```csharp
using Cratis.Arc.Commands.ModelBound;

[Command]
public record NormalizeName(string Name)
{
    public string Provide() => Name.Trim();

    public string Handle(string normalizedName) => normalizedName;
}
```

The string is an ordinary response, not an event. See [Provide data to a command handler](/arc/scenarios/provide-data-to-a-command/) for dependency-backed examples and short-circuit behavior.
