Skip to main content
POST
/
announcements
curl --request POST \
  --url https://api.roostedhr.com/api/1_12/announcements \
  --header 'Content-Type: application/json' \
  --header 'X-API-KEY: <api-key>' \
  --data '
{
  "subject": "Company-wide policy update",
  "message": "<p>Please review the updated attendance policy effective next Monday.</p>",
  "output": 1,
  "all": 1,
  "replies": [
    3158
  ]
}
'

Targeting workers

You can target announcement recipients in three ways:
  • All workers — set all to 1. The selected_workers and skillsets fields are ignored.
  • By skillset — set all to 0 and provide a skillsets ID. Only workers with that skillset receive the announcement.
  • Specific workers — set all to 0 and provide an array of worker IDs in selected_workers.

Delivery channels

The output field controls how the announcement is delivered:
ValueChannel
1Email only
2Text message only
3Both email and text message
The message field supports HTML formatting. Keep the content under 1,000 characters.

Authorizations

X-API-KEY
string
header
required

Body

application/json
subject
string
required

Subject line of the announcement.

Example:

"Schedule update for next week"

message
string
required

Body content of the announcement. Supports HTML formatting.

Required string length: 1 - 1000
Example:

"<p>Please review your updated shifts for next week.</p>"

output
enum<integer>
required

Delivery channel for the announcement. 1 — email only. 2 — text message only. 3 — both email and text message.

Available options:
1,
2,
3
Example:

3

all
enum<integer>
required

Whether to send the announcement to all workers. 1 — send to all workers. 0 — send to specific workers (use selected_workers or skillsets to specify recipients).

Available options:
0,
1
Example:

1

replies
integer[]
required

Admin IDs designated to receive worker replies to this announcement.

Example:
[3158]
skillsets
string

Skillset ID to filter recipients. When provided, only workers with this skillset receive the announcement. Ignored when all is 1.

selected_workers
integer[]

Specific worker IDs to send the announcement to. Ignored when all is 1.

Example:
[4521, 4587]

Response

Created