---
title: "Config - Attribute"
description: ""
url: "https://docs.itrsgroup.com/docs/opsview/6.11.7/rest-api/config/api-config-attribute/index.html"
---
Object type: attribute

Request URL: `/rest/config/attribute`

## Example GET

```
$ opsview_rest --token-file /path/to/opsview_restapi_token --pretty GET 'config/attribute?s.name=DISK'
{
  list => [
    {
      arg1          => "-w 5% -c 2%",
....
      id            => 172,
      label1        => "Warning/Critical values",
....
      name          => "DISK",
      ref           => "/rest/config/attribute/172",
....
      servicechecks => [
                         { name => "Disk", ref => "/rest/config/servicecheck/1308" },
                         {
                           name => "Read-only Partitions",
                           ref  => "/rest/config/servicecheck/1304",
                         },
                       ],
      uncommitted   => 0,
      value         => "",
    },
  ],
  summary => { allrows => 169, page => 1, rows => 1, totalpages => 1, totalrows => 1 },
}
```

## Example minimal PUT (with changelog enabled)

```
$ opsview_rest --token-file /path/to/opsview_restapi_token --pretty --data-format=json PUT 'config/attribute' --data '{"name":"NEWNAME","changelog":"A new attribute"}'
{
   "object" : {
      "arg1" : "",
      "arg2" : "",
      "arg3" : "",
      "arg4" : "",
      "id" : "174",
      "label1" : "",
      "label2" : "",
      "label3" : "",
      "label4" : "",
      "name" : "NEWNAME",
      "secured1" : "0",
      "secured2" : "0",
      "secured3" : "0",
      "secured4" : "0",
      "servicechecks" : [],
      "uncommitted" : "1",
      "value" : ""
   }
}
```


**Note**


When saving attributes, you cannot add a host attribute nor amend the list of service checks using an attribute. If you want to amend a service check so that it is no longer using multiple attributes, you have to edit the service check itself.



For more information on how to generate and use the token file, see [opsview_rest](https://docs.itrsgroup.com/docs/opsview/6.11.7/rest-api/rest-api-background/api-common-examples/index.html#opsview_rest) documentation.


