# `DocuSign.Api.EnvelopeWorkflowDefinition`
[🔗](https://github.com/neilberkman/docusign_elixir/blob/v3.4.0/lib/docusign/api/envelope_workflow_definition.ex#L5)

API calls for all endpoints tagged `EnvelopeWorkflowDefinition`.

# `envelope_workflow_definition_v2_delete_envelope_workflow_definition`

```elixir
@spec envelope_workflow_definition_v2_delete_envelope_workflow_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, nil} | {:error, Req.Response.t()}
```

Delete the workflow definition for an envelope.
Deletes the specified envelope's workflow definition if it has one.  **Note:** If the envelope was scheduled to be sent, this endpoint will cancel the scheduled send and the envelope status will be reset to  `created`. To resend the envelope, call the update the status to `sent` with the [Envelopes::Update](/docs/esign-rest-api/reference/envelopes/envelopes/update/) method. 

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `envelope_id` (String.t): The envelope's GUID.   Example: `93be49ab-xxxx-xxxx-xxxx-f752070d71ec` 
- `opts` (keyword): Optional parameters

### Returns

- `{:ok, nil}` on success
- `{:error, Req.Response.t}` on failure

# `envelope_workflow_definition_v2_get_envelope_workflow_definition`

```elixir
@spec envelope_workflow_definition_v2_get_envelope_workflow_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.Workflow.t()} | {:error, Req.Response.t()}
```

Returns the workflow definition for an envelope.
Returns the workflow definition for the envelope specified by `envelopeId`. If the envelope does not have a workflow object, this method returns a 404. 

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `envelope_id` (String.t): The envelope's GUID.   Example: `93be49ab-xxxx-xxxx-xxxx-f752070d71ec` 
- `opts` (keyword): Optional parameters

### Returns

- `{:ok, DocuSign.Model.Workflow.t}` on success
- `{:error, Req.Response.t}` on failure

# `envelope_workflow_definition_v2_put_envelope_workflow_definition`

```elixir
@spec envelope_workflow_definition_v2_put_envelope_workflow_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.Workflow.t()} | {:error, Req.Response.t()}
```

Updates the workflow definition for an envelope.
Updates the specified envelope's workflow.  You can use this endpoint to add scheduled sending to a draft envelope. You can also update the scheduled sending for a sent envelope if the scheduled sending countdown is in progress. In that case, the envelope will be reset to a draft state.  You can also add delayed routing to a draft envelope or a sent envelope that has not started workflow processing.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `envelope_id` (String.t): The envelope's GUID.   Example: `93be49ab-xxxx-xxxx-xxxx-f752070d71ec` 
- `opts` (keyword): Optional parameters
  - `:body` (Workflow): 

### Returns

- `{:ok, DocuSign.Model.Workflow.t}` on success
- `{:error, Req.Response.t}` on failure

# `envelope_workflow_delayed_routing_delete_envelope_delayed_routing_definition`

```elixir
@spec envelope_workflow_delayed_routing_delete_envelope_delayed_routing_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, nil} | {:error, Req.Response.t()}
```

Deletes the delayed routing rules for the specified envelope workflow step.
Delete the delayed routing object for an envelope's workflow step. You cannot call this endpoint once the delay is in progress. As a workaround, you can update the delay or send time to one minute in the future using the [updateEnvelopeDelayedRoutingDefinition](/docs/esign-rest-api/reference/envelopes/envelopeworkflowdefinition/updateEnvelopeDelayedRoutingDefinition/) endpoint.   **Note:** After deleting the delayed routing object, the workflow step still contains the `pause_before` action. Once the workflow step is reached, you will need to [unpause the envelope](/docs/esign-rest-api/how-to/unpause-workflow/). If you want to delete the step entirely, use [deleteEnvelopeWorkflowStepDefinition](/docs/esign-rest-api/reference/envelopes/envelopeworkflowdefinition/deleteenvelopeworkflowstepdefinition/) instead. 

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `envelope_id` (String.t): The envelope's GUID.   Example: `93be49ab-xxxx-xxxx-xxxx-f752070d71ec` 
- `workflow_step_id` (String.t): The ID of the workflow step.
- `opts` (keyword): Optional parameters

### Returns

- `{:ok, nil}` on success
- `{:error, Req.Response.t}` on failure

# `envelope_workflow_delayed_routing_get_envelope_delayed_routing_definition`

```elixir
@spec envelope_workflow_delayed_routing_get_envelope_delayed_routing_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.DelayedRouting.t()} | {:error, Req.Response.t()}
```

Returns the delayed routing rules for an envelope's workflow step definition.
Given an envelope and a workflow step, returns the delayed routing rules for that workflow step.  **Note:** If the workflow step does not have a delayed routing object, this method returns a 404.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `envelope_id` (String.t): The envelope's GUID.   Example: `93be49ab-xxxx-xxxx-xxxx-f752070d71ec` 
- `workflow_step_id` (String.t): The ID of the workflow step.
- `opts` (keyword): Optional parameters

### Returns

- `{:ok, DocuSign.Model.DelayedRouting.t}` on success
- `{:error, Req.Response.t}` on failure

# `envelope_workflow_delayed_routing_put_envelope_delayed_routing_definition`

```elixir
@spec envelope_workflow_delayed_routing_put_envelope_delayed_routing_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.DelayedRouting.t()} | {:error, Req.Response.t()}
```

Updates the delayed routing rules for an envelope's workflow step definition.
Updates the delayed routing rules for an envelope's workflow step definition.  You can use this endpoint to add delayed routing to a draft envelope or a sent envelope (as long as the previous workflow step has not yet been completed). You can also update the delayed routing rule for an envelope, as long as the delay is not yet complete. If you update the delayed routing rule while the delay is already in progress, the countdown will reset.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `envelope_id` (String.t): The envelope's GUID.   Example: `93be49ab-xxxx-xxxx-xxxx-f752070d71ec` 
- `workflow_step_id` (String.t): The ID of the workflow step.
- `opts` (keyword): Optional parameters
  - `:body` (DelayedRouting): A complex element that specifies the delayed routing settings for the workflow step.

### Returns

- `{:ok, DocuSign.Model.DelayedRouting.t}` on success
- `{:error, Req.Response.t}` on failure

# `envelope_workflow_scheduled_sending_delete_envelope_scheduled_sending_definition`

```elixir
@spec envelope_workflow_scheduled_sending_delete_envelope_scheduled_sending_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, nil} | {:error, Req.Response.t()}
```

Deletes the scheduled sending rules for the envelope's workflow.
Deletes the scheduled sending rules for an envelope's workflow. You cannot call this endpoint once the scheduled sending countdown has begun.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `envelope_id` (String.t): The envelope's GUID.   Example: `93be49ab-xxxx-xxxx-xxxx-f752070d71ec` 
- `opts` (keyword): Optional parameters

### Returns

- `{:ok, nil}` on success
- `{:error, Req.Response.t}` on failure

# `envelope_workflow_scheduled_sending_get_envelope_scheduled_sending_definition`

```elixir
@spec envelope_workflow_scheduled_sending_get_envelope_scheduled_sending_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.ScheduledSending.t()} | {:error, Req.Response.t()}
```

Returns the scheduled sending rules for an envelope's workflow definition.
Given a template and a workflow step, returns the scheduled sending rules for that workflow step.  **Note:** If the workflow step does not have a scheduled sending object, this method returns a 404.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `envelope_id` (String.t): The envelope's GUID.   Example: `93be49ab-xxxx-xxxx-xxxx-f752070d71ec` 
- `opts` (keyword): Optional parameters

### Returns

- `{:ok, DocuSign.Model.ScheduledSending.t}` on success
- `{:error, Req.Response.t}` on failure

# `envelope_workflow_scheduled_sending_put_envelope_scheduled_sending_definition`

```elixir
@spec envelope_workflow_scheduled_sending_put_envelope_scheduled_sending_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.ScheduledSending.t()} | {:error, Req.Response.t()}
```

Updates the scheduled sending rules for an envelope's workflow.
Updates the scheduled sending rules for an envelope's workflow. The envelope must have an existing workflow object.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `envelope_id` (String.t): The envelope's GUID.   Example: `93be49ab-xxxx-xxxx-xxxx-f752070d71ec` 
- `opts` (keyword): Optional parameters
  - `:body` (ScheduledSending): An object that describes the settings for scheduled sending.

### Returns

- `{:ok, DocuSign.Model.ScheduledSending.t}` on success
- `{:error, Req.Response.t}` on failure

# `envelope_workflow_step_delete_envelope_workflow_step_definition`

```elixir
@spec envelope_workflow_step_delete_envelope_workflow_step_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, nil} | {:error, Req.Response.t()}
```

Deletes a workflow step from an envelope's workflow definition.
Deletes the workflow step specified by `workflowStepId` from an envelope specified by `envelopeId`.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `envelope_id` (String.t): The envelope's GUID.   Example: `93be49ab-xxxx-xxxx-xxxx-f752070d71ec` 
- `workflow_step_id` (String.t): The ID of the workflow step.
- `opts` (keyword): Optional parameters

### Returns

- `{:ok, nil}` on success
- `{:error, Req.Response.t}` on failure

# `envelope_workflow_step_get_envelope_workflow_step_definition`

```elixir
@spec envelope_workflow_step_get_envelope_workflow_step_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.WorkflowStep.t()} | {:error, Req.Response.t()}
```

Returns a specified workflow step for a specified template.
Returns a workflow step specified by `workflowStepId` for an envelope specified by `envelopeId`.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `envelope_id` (String.t): The envelope's GUID.   Example: `93be49ab-xxxx-xxxx-xxxx-f752070d71ec` 
- `workflow_step_id` (String.t): The ID of the workflow step.
- `opts` (keyword): Optional parameters

### Returns

- `{:ok, DocuSign.Model.WorkflowStep.t}` on success
- `{:error, Req.Response.t}` on failure

# `envelope_workflow_step_post_envelope_workflow_step_definition`

```elixir
@spec envelope_workflow_step_post_envelope_workflow_step_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.WorkflowStep.t()} | {:error, Req.Response.t()}
```

Adds a new step to an envelope's workflow.
Adds a new step to an envelope's workflow.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `envelope_id` (String.t): The envelope's GUID.   Example: `93be49ab-xxxx-xxxx-xxxx-f752070d71ec` 
- `opts` (keyword): Optional parameters
  - `:body` (WorkflowStep): 

### Returns

- `{:ok, DocuSign.Model.WorkflowStep.t}` on success
- `{:error, Req.Response.t}` on failure

# `envelope_workflow_step_put_envelope_workflow_step_definition`

```elixir
@spec envelope_workflow_step_put_envelope_workflow_step_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.WorkflowStep.t()} | {:error, Req.Response.t()}
```

Updates the specified workflow step for an envelope.
Updates the workflow step specified by `workflowStepId` for an envelope.  You can use this endpoint to add or update delayed routing for a draft envelope. You can add or update delayed routing for a sent envelope as long as the previous workflow step has not been completed.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `envelope_id` (String.t): The envelope's GUID.   Example: `93be49ab-xxxx-xxxx-xxxx-f752070d71ec` 
- `workflow_step_id` (String.t): The ID of the workflow step.
- `opts` (keyword): Optional parameters
  - `:body` (WorkflowStep): 

### Returns

- `{:ok, DocuSign.Model.WorkflowStep.t}` on success
- `{:error, Req.Response.t}` on failure

# `template_workflow_definition_delete_template_workflow_definition`

```elixir
@spec template_workflow_definition_delete_template_workflow_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, nil} | {:error, Req.Response.t()}
```

Delete the workflow definition for a template.
Deletes the specified template's workflow definition if it has one.  **Note:** If the specified template does not have a workflow definition, this endpoint returns a 200 response.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `template_id` (String.t): The ID of the template.
- `opts` (keyword): Optional parameters

### Returns

- `{:ok, nil}` on success
- `{:error, Req.Response.t}` on failure

# `template_workflow_definition_get_template_workflow_definition`

```elixir
@spec template_workflow_definition_get_template_workflow_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.Workflow.t()} | {:error, Req.Response.t()}
```

Returns the workflow definition for a template.
Returns the workflow definition for the template specified by `templateId`. If the template does not have a workflow object, this method returns a 404. 

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `template_id` (String.t): The ID of the template.
- `opts` (keyword): Optional parameters

### Returns

- `{:ok, DocuSign.Model.Workflow.t}` on success
- `{:error, Req.Response.t}` on failure

# `template_workflow_definition_put_template_workflow_definition`

```elixir
@spec template_workflow_definition_put_template_workflow_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.Workflow.t()} | {:error, Req.Response.t()}
```

Updates the workflow definition for a template.
Updates the specified template's workflow definition.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `template_id` (String.t): The ID of the template.
- `opts` (keyword): Optional parameters
  - `:body` (Workflow): 

### Returns

- `{:ok, DocuSign.Model.Workflow.t}` on success
- `{:error, Req.Response.t}` on failure

# `template_workflow_delayed_routing_delete_template_delayed_routing_definition`

```elixir
@spec template_workflow_delayed_routing_delete_template_delayed_routing_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, nil} | {:error, Req.Response.t()}
```

Deletes the delayed routing rules for the specified template workflow step.
Deletes the delayed routing rules for the specified template workflow step.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `template_id` (String.t): The ID of the template.
- `workflow_step_id` (String.t): The ID of the workflow step.
- `opts` (keyword): Optional parameters

### Returns

- `{:ok, nil}` on success
- `{:error, Req.Response.t}` on failure

# `template_workflow_delayed_routing_get_template_delayed_routing_definition`

```elixir
@spec template_workflow_delayed_routing_get_template_delayed_routing_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.DelayedRouting.t()} | {:error, Req.Response.t()}
```

Returns the delayed routing rules for a template's workflow step definition.
Given a template and a workflow step, returns the delayed routing rules for that workflow step.  **Note:** If the workflow step does not have a delayed routing object, this method returns a 404.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `template_id` (String.t): The ID of the template.
- `workflow_step_id` (String.t): The ID of the workflow step.
- `opts` (keyword): Optional parameters

### Returns

- `{:ok, DocuSign.Model.DelayedRouting.t}` on success
- `{:error, Req.Response.t}` on failure

# `template_workflow_delayed_routing_put_template_delayed_routing_definition`

```elixir
@spec template_workflow_delayed_routing_put_template_delayed_routing_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.DelayedRouting.t()} | {:error, Req.Response.t()}
```

Updates the delayed routing rules for a template's workflow step.
Updates the scheduled sending rules for a template's workflow.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `template_id` (String.t): The ID of the template.
- `workflow_step_id` (String.t): The ID of the workflow step.
- `opts` (keyword): Optional parameters
  - `:body` (DelayedRouting): A complex element that specifies the delayed routing settings for the workflow step.

### Returns

- `{:ok, DocuSign.Model.DelayedRouting.t}` on success
- `{:error, Req.Response.t}` on failure

# `template_workflow_scheduled_sending_delete_template_scheduled_sending_definition`

```elixir
@spec template_workflow_scheduled_sending_delete_template_scheduled_sending_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, nil} | {:error, Req.Response.t()}
```

Deletes the scheduled sending rules for the template's workflow.
Deletes the scheduled sending rules for the template's workflow.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `template_id` (String.t): The ID of the template.
- `opts` (keyword): Optional parameters

### Returns

- `{:ok, nil}` on success
- `{:error, Req.Response.t}` on failure

# `template_workflow_scheduled_sending_get_template_scheduled_sending_definition`

```elixir
@spec template_workflow_scheduled_sending_get_template_scheduled_sending_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.ScheduledSending.t()} | {:error, Req.Response.t()}
```

Returns the scheduled sending rules for a template's workflow definition.
Given a template specified by `templateId`, returns the scheduled sending rules for that template's workflow object.  **Note:** If the template's workflow does not have a scheduled sending object, this method returns a 404.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `template_id` (String.t): The ID of the template.
- `opts` (keyword): Optional parameters

### Returns

- `{:ok, DocuSign.Model.ScheduledSending.t}` on success
- `{:error, Req.Response.t}` on failure

# `template_workflow_scheduled_sending_put_template_scheduled_sending_definition`

```elixir
@spec template_workflow_scheduled_sending_put_template_scheduled_sending_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.ScheduledSending.t()} | {:error, Req.Response.t()}
```

Updates the scheduled sending rules for a template's workflow definition.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `template_id` (String.t): The ID of the template.
- `opts` (keyword): Optional parameters
  - `:body` (ScheduledSending): An object that describes the settings for scheduled sending.

### Returns

- `{:ok, DocuSign.Model.ScheduledSending.t}` on success
- `{:error, Req.Response.t}` on failure

# `template_workflow_step_delete_template_workflow_step_definition`

```elixir
@spec template_workflow_step_delete_template_workflow_step_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, nil} | {:error, Req.Response.t()}
```

Deletes a workflow step from an template's workflow definition.
Deletes a workflow step from an template's workflow definition.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `template_id` (String.t): The ID of the template.
- `workflow_step_id` (String.t): The ID of the workflow step.
- `opts` (keyword): Optional parameters

### Returns

- `{:ok, nil}` on success
- `{:error, Req.Response.t}` on failure

# `template_workflow_step_get_template_workflow_step_definition`

```elixir
@spec template_workflow_step_get_template_workflow_step_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.WorkflowStep.t()} | {:error, Req.Response.t()}
```

Returns a specified workflow step for a specified envelope.
Returns a workflow step specified by `workflowStepId` for a template specified by `templateId`.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `template_id` (String.t): The ID of the template.
- `workflow_step_id` (String.t): The ID of the workflow step.
- `opts` (keyword): Optional parameters

### Returns

- `{:ok, DocuSign.Model.WorkflowStep.t}` on success
- `{:error, Req.Response.t}` on failure

# `template_workflow_step_post_template_workflow_step_definition`

```elixir
@spec template_workflow_step_post_template_workflow_step_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.WorkflowStep.t()} | {:error, Req.Response.t()}
```

Adds a new step to a template's workflow.
Adds a new step to a template's workflow.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `template_id` (String.t): The ID of the template.
- `opts` (keyword): Optional parameters
  - `:body` (WorkflowStep): 

### Returns

- `{:ok, DocuSign.Model.WorkflowStep.t}` on success
- `{:error, Req.Response.t}` on failure

# `template_workflow_step_put_template_workflow_step_definition`

```elixir
@spec template_workflow_step_put_template_workflow_step_definition(
  DocuSign.Connection.t(),
  String.t(),
  String.t(),
  String.t(),
  keyword()
) :: {:ok, DocuSign.Model.WorkflowStep.t()} | {:error, Req.Response.t()}
```

Updates a specified workflow step for a template.
Updates a specified workflow step for a template.

### Parameters

- `connection` (DocuSign.Connection): Connection to server
- `account_id` (String.t): The external account number (int) or account ID GUID.
- `template_id` (String.t): The ID of the template.
- `workflow_step_id` (String.t): The ID of the workflow step.
- `opts` (keyword): Optional parameters
  - `:body` (WorkflowStep): 

### Returns

- `{:ok, DocuSign.Model.WorkflowStep.t}` on success
- `{:error, Req.Response.t}` on failure

---

*Consult [api-reference.md](api-reference.md) for complete listing*
