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

# Infractions

Punish staff members using action workflows, Roblox integration and more.

Infractions allow you to manage your staff members more efficiently, which also integrates well with other established modules such as *Quota* and *Staff Database*.

<Frame caption="Infraction Approval Discord Message">
  <img src="https://mintcdn.com/astrobirb/mFKF5se1yY8I3dVJ/images/image-1.png?fit=max&auto=format&n=mFKF5se1yY8I3dVJ&q=85&s=2d2048e6dd901a3194856a1ce1a072be" alt="Image" width="1076" height="392" data-path="images/image-1.png" />
</Frame>

## How to setup

### Approval

<Steps>
  <Step title="Infraction Settings">
    <Frame>
      <img src="https://mintcdn.com/astrobirb/mFKF5se1yY8I3dVJ/images/image-2.png?fit=max&auto=format&n=mFKF5se1yY8I3dVJ&q=85&s=0f106ea92060a73d5bccb728587d0a90" alt="Image" width="1076" height="472" data-path="images/image-2.png" />
    </Frame>

    On the infractions settings page, press the \`infraction approval\` button, this will bring up a menu.
  </Step>

  <Step title="Approval Settings">
    <Frame>
      <img src="https://mintcdn.com/astrobirb/mFKF5se1yY8I3dVJ/images/image-3.png?fit=max&auto=format&n=mFKF5se1yY8I3dVJ&q=85&s=59a7ef30a44e179311587ee9d2cb148d" alt="Image" width="1076" height="170" data-path="images/image-3.png" />
    </Frame>

    On the approval settings, select a channel *(required)*, and if you want select a Approval Ping *(optional)* use the Approval Ping drop-down.

    * Channel: This is the channel the approval message with be sent to.
    * Approval Ping: People with this role will be pinged, with the message sent to the channel.<br />
  </Step>
</Steps>

### Actions & Types

<Steps>
  <Step title="Infraction Settings">
    <Frame>
      <img src="https://mintcdn.com/astrobirb/mFKF5se1yY8I3dVJ/images/image-4.png?fit=max&auto=format&n=mFKF5se1yY8I3dVJ&q=85&s=06ba6aec28ab688f1735a9704aca1c40" alt="Image" width="1076" height="473" data-path="images/image-4.png" />
    </Frame>

    On the infractions settings page, press the \`Infraction Types\` button, this will bring up a menu.
  </Step>

  <Step title="Infraction Types Menu">
    <Frame>
      <img src="https://mintcdn.com/astrobirb/mFKF5se1yY8I3dVJ/images/image-5.png?fit=max&auto=format&n=mFKF5se1yY8I3dVJ&q=85&s=0494ba3267e5bfab79176bf21e5953d6" alt="Image" width="1092" height="217" data-path="images/image-5.png" />
    </Frame>

    Click 'Add'!
  </Step>

  <Step title="Infraction Type Modal">
    <Frame>
      <img src="https://mintcdn.com/astrobirb/mFKF5se1yY8I3dVJ/images/image-6.png?fit=max&auto=format&n=mFKF5se1yY8I3dVJ&q=85&s=165e46eab2de6a17d3d370c4e79db4f5" alt="Image" width="1092" height="391" data-path="images/image-6.png" />
    </Frame>

    Name your infraction type.
  </Step>

  <Step title="Infraction Types Menu">
    <Frame>
      <img src="https://mintcdn.com/astrobirb/mFKF5se1yY8I3dVJ/images/image-7.png?fit=max&auto=format&n=mFKF5se1yY8I3dVJ&q=85&s=fd6d2fd20ff77d271a44fdadd0e83d29" alt="Image" width="1079" height="325" data-path="images/image-7.png" />
    </Frame>

    1. Send to channel: Deviates from your original set infraction channel.
    2. Required Permissions: Elevates permissions for the type.
    3. Use Hierarchy (PREMIUM): Requires the Hierarchy configuration, will allow for demotions with the Hierarchy feature.
    4. Remove Roles: Using discord roles, it'll prompt a role dropdown. Any role selected in the configuration will be removed from a staff member.
    5. Give Roles: Using discord roles, it'll prompt a role dropdown. Any role selected in the configuration will be given to the staff member.
    6. Escalate: If the action hits a threshold of X, it'll escalate to another infraction type.
  </Step>
</Steps>

### Commands

| Command              | Permissions | Purpose<br />                                                                                         |
| -------------------- | ----------- | ----------------------------------------------------------------------------------------------------- |
| /infraction issue    | Admin       | This is how you infract people using the bot, currently the primary way of infracting people.         |
| /infraction view     | Admin       | This allows you to view, manage & void infractions.                                                   |
| /infraction list     | Admin       | This allows you to list of infractions based on staff members or global & expired/voided infractions. |
| /infraction multiple | Admin       | This is how you infract multi people at once using the bot.                                           |

### Variables

| Variable           | Value                                 |
| ------------------ | ------------------------------------- |
| `{staff.name}`     | The targets name.                     |
| `{staff.mention}`  | The targets mention. (@User)          |
| `{staff.avatar}`   | The targets avatar.                   |
| `{author.mention}` | The authors mention. (@User)          |
| `{author.avatar}`  | The authors avatar.                   |
| `{author.name}`    | The authors name.                     |
| `{action}`         | The type of infraction that was used. |
| `{reason}`         | The reason for the infraction.        |
| `{notes}`          | What was noted on the infraction.     |
