# Add a row action to a page

Adds a button to a record page's action bar. `kind` is add_row (the default), builtin or workflow, `label` is up to 60 characters, and `icon` and `config` carry what the kind needs — a workflow action's config names the workflow it runs. The new button goes last on the bar. Workspace admin.

Access class: `def:admin`.

## Endpoint

`POST /v1/definitions/{key}/actions`

## Parameters

| Name | In | Type | Required |
| --- | --- | --- | --- |
| key | path | string | Yes |

## Request body

Content type: `application/json`.

```json
{
  "body": {
    "config": {},
    "icon": "string",
    "kind": "string",
    "label": "string"
  },
  "params": {
    ":key": "string"
  },
  "query": {}
}
```

## Responses

### 201

the action's answer

Content type: `application/json`.

```json
{
  "data": {
    "config": {},
    "enabled": true,
    "icon": "string",
    "id": "",
    "kind": "string",
    "label": "string",
    "position": 1
  }
}
```

### default

a refusal: `{"error": "<what a person needs to read>"}`. 401 no credential, 402 the plan does not include this, 403 the seat does not, 404 the thing does not exist or is not yours to see.

Content type: `application/json`.

```json
{
  "error": "string"
}
```
