# <a id="bitdrift_public.protobuf.workflow.v1.SaveField"></a>SaveField

**Source definition:** [`src/bitdrift_public/protobuf/workflow/v1/save_field.proto#L14-L31`](<https://github.com/bitdriftlabs/api/blob/main/src/bitdrift_public/protobuf/workflow/v1/save_field.proto#L14-L31>)

The log's field value, if available, will be snapped, and persisted to the workflow state.
 This can be looked up by ID by further transitions.

<section class="proto-fields-table" markdown>
| Field | Type | Description |
|---|---|---|
| id | <span class="proto-type proto-type-primitive">string</span> |  |
| field_name | <span class="proto-type proto-type-primitive">string</span><span class="proto-field-annotation">only one of <em>field_name</em>, or <em>message</em> can be set</span> | Saves the value of a specified field from the log. If the field is not present, nothing  is saved. |
| message | <span class="proto-type proto-type-primitive">bool</span><span class="proto-field-annotation">only one of <em>message</em>, or <em>field_name</em> can be set</span> | Saves the message of the log. |
| regex_capture | <span class="proto-type proto-type-primitive">optional string</span> | If provided, this must specify a regex with a single capture group. The value of the  captured group will be saved instead of the whole field value. If not provided, the whole  field value will be saved. If the regex doesn't match the field value, nothing will be  saved. |

</section>
<p class="h4">Example</p>
```json
{
  "field_name": "",
  "id": "",
  "regex_capture": ""
}
```

