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

# Update Commando Mode control set

> Update a specific Commando Mode control set.

PUT/commandomodes/\{token}

Update a specific Commando Mode control set.

Include the modified details in JSON format in the body of the request. Only values of parameters included in the request are modified; all others are left unchanged.

## URL path parameters

| Fields | Description |
| - | - |
| token string  Required | The unique identifier of the Commando Mode control set. **Allowable Values:**  Existing Commando Mode control set token. |

## Body field details

| Fields | Description |
| - | - |
| token string  Optional | The unique identifier of the Commando Mode control set. If you do not include a token, the system will generate one automatically. This token is necessary for use in other API calls, so we recommend that rather than let the system generate one, you use a simple string that is easy to remember. This value cannot be updated. **Allowable Values:**  36 char max |
| program\_gateway\_funding\_source\_token string  Required | The unique identifier of the associated program gateway funding source. **Allowable Values:**  Existing program gateway funding source token. |
| commando\_mode\_enables object  Required | Defines what happens when Commando Mode is enabled. **Allowable Values:**  Existing `commando_mode_enables` object. |
| real\_time\_standin\_criteria object  Optional | Specifies which event types automatically enable Commando Mode. **Allowable Values:**  Existing `real_time_standin_criteria` object. |

## The commando\_mode\_enables object

| Fields | Description |
| - | - |
| program\_funding\_source string  Required | The unique identifier of the program funding source that substitutes for the program gateway funding source upon Commando Mode enablement. **Allowable Values:**  36 char max |
| velocity\_controls array  Optional | The velocity controls enabled while in Commando Mode. **Allowable Values:**  One or more existing velocity control tokens. |
| auth\_controls array  Optional | The authorization controls enabled while in Commando Mode. **Allowable Values:**  One or more existing authorization control tokens. |
| ignore\_card\_suspended\_state boolean  Optional | If `true`, transactions conducted while in Commando Mode proceed even when the card is suspended; if `false`, transactions conducted while Commando Mode is enabled are declined if the card is suspended. **Allowable Values:**  `true`, `false` **Default value:** `false` |

## The real\_time\_standin\_criteria object

| Fields | Description |
| - | - |
| enabled boolean  Optional | If `true`, Commando Mode is automatically enabled by events defined in the `real_time_standin_criteria` object; if `false`, Auto Commando Mode is not enabled. **Allowable Values:**  `true`, `false` **Default value:** `false` |
| include\_connection\_errors boolean  Optional | If `true`, a non-timeout connection error automatically enables Commando Mode when `real_time_standin_criteria.enabled` is also `true`. **Allowable Values:**  `true`, `false` **Default value:** `true` |
| include\_response\_timeouts boolean  Optional | If `true`, a gateway response slower than 3000ms automatically enables Commando Mode when `real_time_standin_criteria.enabled` is also `true`. **Allowable Values:**  `true`, `false` **Default value:** `true` |
| include\_application\_errors boolean  Optional | If `true`, an application error (any non-connection, non-timeout error) automatically enables Commando Mode when `real_time_standin_criteria.enabled` is also `true`. **Allowable Values:**  `true`, `false` **Default value:** `false` |

## The current\_state object (response)

The Marqeta platform returns the `current_state` object of the Commando Mode control set in the response.

| Name | Description | Allowable Values |
| - | - | - |
| commando\_enabled | Indicates whether Commando Mode is enabled. | `true`, `false` |
| reason | Describes the reason the current state of the Commando Mode control set was changed. | |
| channel | The mechanism that changed the Commando Mode control set's state. | `API`, `SYSTEM`, `ADMIN` |
| user\_name | Identifies the user who changed the Commando Mode control set's state. | |

## Sample request body

```json JSON lines wrap theme={null}
{
  "token": "commando_mode_1",
  "program_gateway_funding_source_token": "pgm_gateway_src_1",
  "commando_mode_enables": {
    "program_funding_source": "pgm_funding_src_1",
    "velocity_controls": [
      "vel_control_2"
    ]
  }
}
```

## Sample response body

```json JSON lines wrap theme={null}
{
  "token": "commando_mode_1",
  "program_gateway_funding_source_token": "pgm_gateway_src_1",
  "current_state": {
    "commando_enabled": false,
    "reason": "New commandomode created",
    "channel": "SYSTEM"
  },
  "commando_mode_enables": {
    "program_funding_source": "pgm_funding_src_1",
    "velocity_controls": [
      "vel_control_2"
    ]
  },
  "created_time": "2021-02-14T18:48:10Z",
  "last_modified_time": "2021-02-14T18:48:10Z"
}
```


## Related topics

- [Commando Mode Addendum Overview](https://www.marqeta.com/docs/core-api/commando-mode-addendum.md)
- [Create Commando Mode control set](https://www.marqeta.com/docs/core-api/commando-mode-addendum/create-control-set.md)
- [Retrieve Commando Mode control set](https://www.marqeta.com/docs/core-api/commando-mode/retrieve-control-set.md)
- [List Commando Mode control sets](https://www.marqeta.com/docs/core-api/commando-mode/list-control-sets.md)
- [List Commando Mode transitions set](https://www.marqeta.com/docs/core-api/commando-mode/list-transitions-set.md)
