# Change a service's autonomy

`PATCH /workspace/grants/{service}` · Rivier · connectors

Change a service's autonomy.

- Scope: connectors:admin
- Graphql: Mutation.connectorsGrantUpdate
- Sdk: connectors.grant.update
- Cli: connectors grant update

## Parameters

- `service` (path, required), string

## Request body

`application/json`

```json
{
  "type": "object",
  "properties": {
    "mode": {
      "type": "string",
      "enum": [
        "off",
        "watch",
        "ask",
        "auto"
      ]
    },
    "dailyCap": {
      "anyOf": [
        {
          "type": "integer",
          "minimum": 1,
          "maximum": 100000
        },
        {
          "type": "null"
        }
      ]
    },
    "valueCapCents": {
      "anyOf": [
        {
          "type": "integer",
          "minimum": 0,
          "maximum": 100000000
        },
        {
          "type": "null"
        }
      ]
    },
    "confidenceFloor": {
      "anyOf": [
        {
          "type": "integer",
          "minimum": 0,
          "maximum": 100
        },
        {
          "type": "null"
        }
      ]
    },
    "connectionId": {
      "anyOf": [
        {
          "type": "string",
          "format": "uuid"
        },
        {
          "type": "null"
        }
      ]
    }
  },
  "additionalProperties": false
}
```

## Responses

- `200`: Success
- `400`: The request was malformed
- `401`: No valid credential
- `403`: The credential lacks the scope, origin or address
- `429`: Over the key's rate limit; see Retry-After

## Example

```sh
curl -X PATCH 'https://api.rivier.ai/workspace/grants/{service}' \
  -H 'Authorization: Bearer $KEY' \
  -H 'Content-Type: application/json' \
  -d '{
  "mode": "off",
  "dailyCap": 0,
  "valueCapCents": 0,
  "confidenceFloor": 0,
  "connectionId": "string"
}'
```
