# Create status page group

Returns either a newly created status page group, or validation errors.

[endpoint]
base_url = "https://uptime.betterstack.com"
path = "/api/v2/status-page-groups"
method = "POST"

[[body_param]]
name = "team_name"
description = "Required if using a [global API token](https://betterstack.com/docs/uptime/api/getting-started-with-uptime-api/#get-a-global-api-token) to specify the team which should own the resource."
required = false
type = "string"

[[body_param]]
name = "name"
description = "A name for the group that you can see in the dashboard."
required = false
type = "string"

[[body_param]]
name = "sort_index"
description = "Set `sort_index` to specify how to sort your status page groups."
required = false
type = "integer"

[[header]]
name = "Authorization"
description = "Bearer `$TOKEN`"
required = true
type = "string"

[[header]]
name = "Content-Type"
description = "application/json"
required = false
type = "string"
[/endpoint]

[responses]
[[response]]
status = 201
description = '''Returns a newly created status page group.'''
body = '''{
  "data": {
    "id": "1372980",
    "type": "status_page_group",
    "attributes": {
      "name": "Production Status Pages",
      "sort_index": 1,
      "created_at": "2024-11-08T10:00:00.000Z",
      "updated_at": "2024-11-08T10:00:00.000Z",
      "team_name": "Test Team"
    }
  }
}'''
[/responses]

#### Example cURL

```shell
[label Example]
curl --request POST \
  --url https://uptime.betterstack.com/api/v2/status-page-groups \
  --header "Authorization: Bearer $TOKEN" \
  --header 'Content-Type: application/json' \
  --data '{
	"name": "Production Status Pages",
  "sort_index": 1
}'
```

[info]
#### Looking for the details of a specific parameter?
Explore [the list of all Status Page Group API parameters](https://betterstack.com/docs/uptime/api/status-page-groups-response-params/).
[/info]
