Skip to main content
POST
Create an area type

Authorizations

Authorization
string
header
required

Organization-scoped bearer credential: a customer API key (1club_sk_live_...) or an MCP OAuth access token.

Headers

Idempotency-Key
string

Retry-safe key; a repeat of the same request replays the first response

Maximum string length: 255

Body

application/json

Fields accepted when creating an area type. Only name is required; slug is derived from it when omitted, and suffixed if that is taken. The defaults shown are what an omitted field becomes, and unknown fields are rejected.

name
string
required
Maximum string length: 255
slug
string

Stable key. Derived from the name when omitted; send one only when something outside 1club already refers to it. An explicit slug that clashes is a 409, and a rename never moves it.

Maximum string length: 120
Pattern: ^[a-z0-9]+(-[a-z0-9]+)*$
description
string | null
Maximum string length: 2000
revenueAccountId
integer | null

Where a booking on this kind of area posts, from GET /v1/platform/revenue-accounts. Leave it unset and the sale posts to whichever account the organization has marked default, resolved at the time of the sale.

sports
string[]

Canonical sport ids an area of this type can be booked for, e.g. ["padel"]. This is what makes the areas bookable for a sport at all; an unrecognised value is rejected rather than stored.

Maximum array length: 20
isBookable
boolean
default:true

False for a kind of space that is not booked at all (a storeroom, a corridor).

defaultPricePerHour
number | null

Hourly price an area of this type starts from. An area may override it.

Required range: x >= 0
defaultMaxPlayers
integer | null

How many people a slot on this type normally takes.

Required range: 1 <= x <= 1000
maxConcurrentBookings
integer
default:1

How many bookings may hold an area of this type at once. 1 for an ordinary court.

Required range: 1 <= x <= 100

Response

Area type created

A kind of area, and the defaults every area of that kind inherits. One shape for the list, get-by-id, create and update.

id
integer
name
string
slug
string

Stable key, derived from the name when a create does not send one. A rename never moves it.

description
string | null
revenueAccountId
integer | null

Where a booking on this kind of area posts. Null falls back to the organization's default account.

areaCount
integer

Areas currently of this type, whatever their status.

createdAt
string<date-time>
updatedAt
string<date-time>
sports
string[]

Sports an area of this type can be booked for.

isBookable
boolean

False for a type that is not booked at all (a storeroom, a corridor). Do not build bookable inventory on one.

defaultPricePerHour
number | null

Hourly price an area of this type starts from; an area may override it.

defaultMaxPlayers
integer | null

How many people a slot on this type normally takes.

maxConcurrentBookings
integer

How many bookings may hold an area of this type at once. 1 for an ordinary court.