# Ask the owner of a business to connect it to this platform

`POST /connected-businesses` · Rivier · workspace

Ask the owner of a business to connect it to this platform: name it, give their address and the scopes the platform asks for. They are mailed an invitation, accept it in their own organisation and choose what the platform may do. the platform hears platform.business.connected, .declined, .granted and .ended.

- Scope: workspace:admin
- Graphql: Mutation.workspaceConnectedBusinessCreate
- Sdk: workspace.connectedBusiness.create
- Cli: workspace connected business create

## Request body

`application/json`

```json
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "minLength": 1,
      "maxLength": 120
    },
    "email": {
      "type": "string",
      "format": "email",
      "maxLength": 254
    },
    "scopes": {
      "type": "array",
      "items": {
        "type": "string",
        "pattern": "^[a-z]+:(read|write|admin)$"
      },
      "minItems": 1,
      "maxItems": 30
    },
    "ref": {
      "type": "string",
      "maxLength": 120
    },
    "language": {
      "type": "string",
      "maxLength": 12
    }
  },
  "required": [
    "name",
    "email",
    "scopes"
  ],
  "additionalProperties": false
}
```

## Responses

- `201`: 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 POST 'https://api.rivier.ai/connected-businesses' \
  -H 'Authorization: Bearer $KEY' \
  -H 'Content-Type: application/json' \
  -d '{
  "name": "string",
  "email": "name@example.com",
  "scopes": [
    "string"
  ]
}'
```
