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

# Creating an Action Type

![](https://usercontent.clueso.io/1f4455e0-789e-4beb-8cd9-4dac96bc47e4/95fc0fba-36b6-472a-857a-1b5a582c85b1/f163bc46-1a2e-43e3-9b51-dd57aa3fdd89/images/ff6bfae5-59f2-4006-8e9e-c4598fdc1b0b.gif)

To create a new action type in Bytebeam console,

**1. Access Actions Tab**

Click on the **Actions** tab at the top

**2. Go to Action Settings Tab and Initiate Action Type Creation**

Navigate to the **Action Settings** tab and click on the **Create Action Type** button

**3. Fill Details**

Enter the action type name, choose the [payload](#payload-in-action-types), select an icon, and optionally set a timeout duration from the dropdown. Then, click on the Submit button to create the metadata key.

## Payload for Action Types

There are 3 payload options in 4 variations available while creating the action type.

> [accordion] None
>
> You can choose this for action types like Shutdown which don't need any payload to be sent to the device while triggering the action.

> [accordion] JSON
>
> You can choose this for action types which need the JSON payload to be sent to the device while triggering the action.

> [accordion] JSON Data via form
>
> You can choose this for action types like **Update CAN Config**, which enables JSON data to be sent via a form to the device while triggering the action.
>
> To choose this option:
>
> 1. Select **JSON** from the dropdown.
>
> 2. Enable the **Allow user to input data via form** toggle.
>
> 3. Enter the **JSON Schema** along with the **JSON UI Schema** while creating or editing the action type.
>
> > [tab] JSON Schema Example
> >
> > ```json theme={null}
> > {
> >   "title": "",
> >   "type": "object",
> >   "required": [
> >     "can_bitrate",
> >     "can_filter_mask",
> >     "data_frequencies"
> >   ],
> >   "properties": {
> >     "can_bitrate": {
> >       "type": "string",
> >       "title": "CAN BitRate (kbps)",
> >       "default": "500"
> >     },
> >     "can_filter_mask": {
> >       "type": "string",
> >       "title": "CAN Filter Mask",
> >       "default": "0x00"
> >     },
> >     "data_frequencies": {
> >       "type": "array",
> >       "title": "Data Frequencies",
> >       "items": {
> >         "type": "object",
> >         "required": [
> >           "can_mask",
> >           "frequency"
> >         ],
> >         "properties": {
> >           "can_mask": {
> >             "type": "string",
> >             "title": "CAN Mask"
> >           },
> >           "frequency": {
> >             "type": "string",
> >             "title": "Frequency (Hz)"
> >           }
> >         }
> >       }
> >     }
> >   }
> > }
> > ```
>
> > [tab] JSON UI Schema Example
> >
> > ```json theme={null}
> > {
> >   "can_bitrate": {
> >     "ui:placeholder": "Eg: 250"
> >   },
> >   "can_filter_mask": {
> >     "ui:placeholder": "Eg: 0xffD",
> >     "ui:emptyValue": ""
> >   },
> >   "data_frequencies": {
> >     "ui:options": {
> >       "orderable": false,
> >       "inline": true
> >     },
> >     "items": {
> >       "can_mask": {
> >         "ui:inline": true,
> >         "ui:placeholder": "Eg: 0x7ff"
> >       },
> >       "frequency": {
> >         "ui:inline": true,
> >         "ui:placeholder": "Eg: 100"
> >       }
> >     }
> >   }
> > }
> > ```
>
> When the above configuration is used while creating the action type, it appears like this when triggering the action:
>
> ![](https://mintcdn.com/bytebeamio/ftUl6Tv5QMaNi0Gs/assets/update_can_config.jpg?fit=max\&auto=format\&n=ftUl6Tv5QMaNi0Gs\&q=85\&s=e5bdba82ce76b279524c0729c7c25cb6)

> [accordion] Text
>
> You can choose this for action types which need the payload in text format to be sent to the device while triggering the action.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.