# \_setArchived

Sets whether the Appointment Type is archived or not.

### Parameters

#### id

The ID of the Appointment Type.

#### val

Decides if the Appointment Type is archived or not:\
0 => No,\
1 => Yes

### Example

```
FM_api(
    'AppointmentType_setArchived',[
        'id' => '122041',
        'val' => '0'
    ]
);
```

### Result

#### On Success

```
{'ok':1}
```

#### On Failure

If there is no "id" value set or it is less than 1

```
{"error":"missing or invalid parameter: id"}
```

If there is no "val" variable set

```
{"error":"missing or invalid parameter: val"}
```
