---
title: "createRepoExtensionRoomBroadcast"
---

> Documentation Index
> Fetch the complete documentation index at: https://buildrforge.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# createRepoExtensionRoomBroadcast

Path: Forge API › events

`POST /repos/{repo_id}/extensions/{extension_name}/rooms/{room}/broadcasts`

Broadcast {"params":…,"data":…} to everyone in one room of an extension, the room its params name.

## Path parameters

- `repo_id` (`createRepoExtensionRoomBroadcast.path.repo_id`; string, required)
  - pattern: `^repo_[0-7][0-9a-hjkmnp-tv-z]{25}$`
- `extension_name` (`createRepoExtensionRoomBroadcast.path.extension_name`; string, required)
  - maxLength: `129` · pattern: `^[a-z0-9]+(?:-[a-z0-9]+)*\.[a-z0-9]+(?:-[a-z0-9]+)*$`
- `room` (`createRepoExtensionRoomBroadcast.path.room`; string, required)
  - minLength: `1`

## Request body

_Required._

- `params` (`createRepoExtensionRoomBroadcast.params`; unknown, required)
- `data` (`createRepoExtensionRoomBroadcast.data`; unknown, required)

## Example request

```json
{
  "params": null,
  "data": null
}
```

## Code samples

### cURL

```bash
curl --request POST \
  --url '<base-url>/repos/<repo_id>/extensions/<extension_name>/rooms/<room>/broadcasts' \
  --header 'Content-Type: application/json' \
  --data '
{
  "params": null,
  "data": null
}
'
```

### TypeScript

```typescript
const url = '<base-url>/repos/<repo_id>/extensions/<extension_name>/rooms/<room>/broadcasts';
const options = {
  method: 'POST',
  headers: {'Content-Type': 'application/json'},
  body: JSON.stringify({params: null, data: null})
};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "<base-url>/repos/<repo_id>/extensions/<extension_name>/rooms/<room>/broadcasts"

payload = {
    "params": None,
    "data": None
}
headers = {"Content-Type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
```

## Responses

### 201

RepoEvent

#### Example

```json
{
  "seq": -9007199254740991,
  "topic": "string",
  "type": "string",
  "payload": null,
  "actor_id": "string",
  "created_at": "string"
}
```

- `seq` (`createRepoExtensionRoomBroadcast.response.201.seq`; integer, required)
  - maximum: `9007199254740991` · minimum: `-9007199254740991`
- `topic` (`createRepoExtensionRoomBroadcast.response.201.topic`; string, required)
- `type` (`createRepoExtensionRoomBroadcast.response.201.type`; string, required)
- `payload` (`createRepoExtensionRoomBroadcast.response.201.payload`; unknown, required)
- `actor_id` (`createRepoExtensionRoomBroadcast.response.201.actor_id`; any of, required)
  - any of the following: `string`, `null`
- `created_at` (`createRepoExtensionRoomBroadcast.response.201.created_at`; string, required)

### 400

InvalidRequest | RequestBodyTooDeep

#### Example

```json
{
  "_tag": "InvalidRequest",
  "part": "path",
  "issues": [
    {
      "path": [
        "string"
      ],
      "message": "string"
    }
  ]
}
```

Any of the following:

- `InvalidRequestEncoded`
  - `_tag` (`InvalidRequestEncoded._tag`; string, required)
    - one of `"InvalidRequest"`
  - `part` (`InvalidRequestEncoded.part`; string, required)
    - one of `"path"`, `"query"`, `"headers"`, `"body"`
  - `issues` (`InvalidRequestEncoded.issues`; array of object, required)
    - `path` (`InvalidRequestEncoded.issues.path`; array\<any of\>, required)
      - any of the following: `string`, `integer`
    - `message` (`InvalidRequestEncoded.issues.message`; string, required)
- `RequestBodyTooDeepEncoded`
  - `_tag` (`RequestBodyTooDeepEncoded._tag`; string, required)
    - one of `"RequestBodyTooDeep"`
  - `max_depth` (`RequestBodyTooDeepEncoded.max_depth`; integer, required)
    - maximum: `9007199254740991` · minimum: `-9007199254740991`

### 401

InvalidCredentials

#### Example

```json
{
  "_tag": "InvalidCredentials"
}
```

- `_tag` (`createRepoExtensionRoomBroadcast.response.401._tag`; string, required)
  - one of `"InvalidCredentials"`

### 403

Forbidden | ForbiddenOrigin | RequiresPersonalSession | RunBranchRequired

#### Example

```json
{
  "_tag": "Forbidden",
  "message": "string"
}
```

Any of the following:

- `ForbiddenEncoded`
  - `_tag` (`ForbiddenEncoded._tag`; string, required)
    - one of `"Forbidden"`
  - `message` (`ForbiddenEncoded.message`; string, required)
- `ForbiddenOriginEncoded`
  - `_tag` (`ForbiddenOriginEncoded._tag`; string, required)
    - one of `"ForbiddenOrigin"`
- `RequiresPersonalSessionEncoded`
  - `_tag` (`RequiresPersonalSessionEncoded._tag`; string, required)
    - one of `"RequiresPersonalSession"`
- `RunBranchRequiredEncoded`
  - `_tag` (`RunBranchRequiredEncoded._tag`; string, required)
    - one of `"RunBranchRequired"`
  - `branch` (`RunBranchRequiredEncoded.branch`; string, required)
    - minLength: `1`
  - `message` (`RunBranchRequiredEncoded.message`; string, required)

### 404

RepoNotFound

#### Example

```json
{
  "_tag": "RepoNotFound"
}
```

- `_tag` (`createRepoExtensionRoomBroadcast.response.404._tag`; string, required)
  - one of `"RepoNotFound"`

### 409

RepoArchived

#### Example

```json
{
  "_tag": "RepoArchived"
}
```

- `_tag` (`createRepoExtensionRoomBroadcast.response.409._tag`; string, required)
  - one of `"RepoArchived"`

### 413

WriteTooLarge | RequestBodyTooLarge

#### Example

```json
{
  "_tag": "WriteTooLarge",
  "message": "string"
}
```

Any of the following:

- `WriteTooLargeEncoded`
  - `_tag` (`WriteTooLargeEncoded._tag`; string, required)
    - one of `"WriteTooLarge"`
  - `message` (`WriteTooLargeEncoded.message`; string, required)
- `RequestBodyTooLargeEncoded`
  - `_tag` (`RequestBodyTooLargeEncoded._tag`; string, required)
    - one of `"RequestBodyTooLarge"`
  - `max_bytes` (`RequestBodyTooLargeEncoded.max_bytes`; integer, required)
    - maximum: `9007199254740991` · minimum: `-9007199254740991`

### 429

RateLimited

#### Example

```json
{
  "_tag": "RateLimited"
}
```

- `_tag` (`createRepoExtensionRoomBroadcast.response.429._tag`; string, required)
  - one of `"RateLimited"`

### 500

RepoFailure

#### Example

```json
{
  "_tag": "RepoFailure",
  "reason": "string"
}
```

- `_tag` (`createRepoExtensionRoomBroadcast.response.500._tag`; string, required)
  - one of `"RepoFailure"`
- `reason` (`createRepoExtensionRoomBroadcast.response.500.reason`; string, required)

### 503

RepoBusy | SessionUnavailable | RateLimitUnavailable

#### Example

```json
{
  "_tag": "RepoBusy",
  "message": "string"
}
```

Any of the following:

- `RepoBusyEncoded`
  - `_tag` (`RepoBusyEncoded._tag`; string, required)
    - one of `"RepoBusy"`
  - `message` (`RepoBusyEncoded.message`; string, required)
- `SessionUnavailableEncoded`
  - `_tag` (`SessionUnavailableEncoded._tag`; string, required)
    - one of `"SessionUnavailable"`
- `RateLimitUnavailableEncoded`
  - `_tag` (`RateLimitUnavailableEncoded._tag`; string, required)
    - one of `"RateLimitUnavailable"`


Source: https://buildrforge.com/docs/api/create-repo-extension-room-broadcast/index.md
