# Change what counts as a processed deal

Replace this workspace's processor@ criteria whole: intake, completeness, dealCreation (on_arrival or when_complete), emailsOff, dealStatus, defaultAssigneeAccountId. Strict — an unknown key, signal, check, document type, severity or status is a 400 naming it, and the default assignee must hold a seat. Admin only.

Access class: `workspace:admin`.

## Endpoint

`PUT /v1/workspace/processor/criteria`

## Request body

Content type: `application/json`.

```json
{
  "body": {
    "completeness": [
      {
        "productType": "string",
        "rules": [
          {
            "check": "string",
            "documentType": "string",
            "message": "string",
            "severity": "string",
            "value": 1.5
          }
        ]
      }
    ],
    "dealCreation": "string",
    "dealStatus": "string",
    "dealTypeChoices": [
      {
        "builtIn": "string",
        "key": "string",
        "label": "string"
      }
    ],
    "dealTypes": {},
    "defaultAssigneeAccountId": "",
    "emailsOff": [
      "string"
    ],
    "fileTypes": {},
    "intake": [
      {
        "comparison": "string",
        "onFail": "string",
        "signal": "string",
        "value": "string"
      }
    ],
    "isDefault": true,
    "presets": {
      "completeness": [
        "string"
      ],
      "intake": [
        "string"
      ]
    },
    "updatedAt": "string"
  },
  "params": {},
  "query": {}
}
```

## Responses

### 200

the action's answer

Content type: `application/json`.

```json
{
  "data": {
    "completeness": [
      {
        "productType": "string",
        "rules": [
          {
            "check": "string",
            "documentType": "string",
            "message": "string",
            "severity": "string",
            "value": 1.5
          }
        ]
      }
    ],
    "dealCreation": "string",
    "dealStatus": "string",
    "dealTypeChoices": [
      {
        "builtIn": true,
        "key": "string",
        "label": "string"
      }
    ],
    "dealTypes": {},
    "defaultAssigneeAccountId": "",
    "emailsOff": [
      "string"
    ],
    "fileTypes": {},
    "intake": [
      "string"
    ],
    "isDefault": true,
    "presets": {
      "completeness": [
        {
          "key": "string",
          "label": "string",
          "set": {
            "productType": "string",
            "rules": [
              {
                "check": "string",
                "documentType": "string",
                "message": "string",
                "severity": "string",
                "value": "string"
              }
            ]
          }
        }
      ],
      "intake": [
        {
          "description": "string",
          "key": "string",
          "label": "string",
          "rules": [
            {
              "comparison": "string",
              "onFail": "string",
              "signal": "string",
              "value": "string"
            }
          ]
        }
      ]
    },
    "updatedAt": "string"
  }
}
```

### 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"
}
```
