Skip to content

PerfectGym Next API (1.13.2)

  • Appointment, bookable appointment and slots operations
  • Redeem checkin vouchers
  • Class and slots operations
  • Cross studio operations
  • Get customers and contracts
  • Retrieve customer accounting details
  • Retrieve customer communication details
  • Get device information
  • Employee operations
  • Debt collection operations
  • Leads operations
  • Manage membership contracts
  • Membership operations
  • Online offer operations
  • Payment operations
  • Get studio information
  • Get trial offers information
Download OpenAPI description
Languages
Servers
Demo tenant

https://open-api-demo.open-api.perfectgym.com/

Mock server

https://redocly.sportalliance.com/_mock/apis/perfectgym/openapi/openapi/

Appointments

Appointment, bookable appointment and slots operations

Operations

Checkin vouchers

Redeem checkin vouchers

Operations
Operations

Cross Studio

Cross studio operations

Operations

Customers

Get customers and contracts

Operations

Customers Account

Retrieve customer accounting details

Operations

Customers Communication

Retrieve customer communication details

Operations
Operations
Operations
Operations
Operations
Operations

Membership Self-service

Manage membership contracts

Operations
Operations

Online offers

Online offer operations

Operations

Request

Required Scopes: ONLINE_OFFER_READ

Returns paginated purchasable online offers.

Security
ApiKeyAuth
Query
offsetstring

Offset from last request (last ID of the class)

Default "0"
sliceSizeinteger(int32)[ 10 .. 100 ]

Desired size of data chunk

Default 50
curl -i -X GET \
  'https://open-api-demo.open-api.perfectgym.com/v1/online-offers/purchasable?offset=0&sliceSize=50' \
  -H 'X-API-KEY: YOUR_API_KEY_HERE'

Responses

OK

Bodyapplication/json
resultArray of objects(OnlineOffer)required

List of online offers

result[].​onlineOfferIdinteger(int64)required

Unique ID of the online offer.

Example: 12345
result[].​namestringrequired

Name of the online offer.

Example: "Day Ticket Adult"
result[].​scopeOfUsageinteger(int32)required

The number of times the online offer can be used.

Example: 1
result[].​priceobject(Money)required

The price amount and currency for the online offer.

result[].​price.​amountnumberrequired

Amount of the finance data tuple

Example: 20
result[].​price.​currencystring(ISO 4217)required

Currency of the finance data tuple

Example: "EUR"
result[].​periodOfUseobject(OnlineOfferPeriodOfUse)required

Online offer period of use information.

result[].​periodOfUse.​termobject(TermWithMinutes)required

Represents a term with minutes

result[].​periodOfUse.​term.​valueinteger(int32)required

The value of the term with minutes

Example: 2
result[].​periodOfUse.​term.​unitstringrequired

Represents a temporal unit with minutes

Enum ValueDescription
MONTH

Represents month unit

HOURS

Represents a hours unit

YEAR

Represents year unit

MINUTES

Represents a minutes unit

WEEK

Represents week unit

DAY

Represents day unit

Example: "WEEK"
result[].​periodOfUse.​typestringrequired

Describes the period of use type for a online offer.

Enum ValueDescription
ONE_TIME

The offer can be used only once.

PERIOD

The offer can be used within a specific period.

WHOLE_DAY

The offer can be used for a whole day.

Example: "ONE_TIME"
result[].​typestringrequired

Describes the type of the online offer.

ValueDescription
CHECK_IN_BASED

The offer is based on check-ins.

Example: "CHECK_IN_BASED"
result[].​categoryobject(OnlineOfferCategory)

The category of the online offer.

hasNextbooleanrequired

True if there exists next data slice

Example: true
offsetstringrequired

Offset for next query (last ID of the online offers)

Example: "1234567890"
Response
application/json
{ "result": [ {} ], "hasNext": true, "offset": "1234567890" }

Request

Required Scopes: ONLINE_OFFER_READ

Returns extended information about the online offer by id.

Security
ApiKeyAuth
Path
offerIdinteger(int64)required

The id of the online offer

curl -i -X GET \
  'https://open-api-demo.open-api.perfectgym.com/v1/online-offers/purchasable/{offerId}' \
  -H 'X-API-KEY: YOUR_API_KEY_HERE'

Responses

OK

Bodyapplication/json
onlineOfferIdinteger(int64)required

Unique ID of the online offer.

Example: 12345
namestringrequired

Name of the online offer.

Example: "Day Ticket Adult"
scopeOfUsageinteger(int32)required

The number of times the online offer can be used.

Example: 1
priceobject(Money)required

The price amount and currency for the online offer.

price.​amountnumberrequired

Amount of the finance data tuple

Example: 20
price.​currencystring(ISO 4217)required

Currency of the finance data tuple

Example: "EUR"
periodOfUseobject(OnlineOfferPeriodOfUse)required

Online offer period of use information.

periodOfUse.​termobject(TermWithMinutes)required

Represents a term with minutes

periodOfUse.​term.​valueinteger(int32)required

The value of the term with minutes

Example: 2
periodOfUse.​term.​unitstringrequired

Represents a temporal unit with minutes

Enum ValueDescription
MONTH

Represents month unit

HOURS

Represents a hours unit

YEAR

Represents year unit

MINUTES

Represents a minutes unit

WEEK

Represents week unit

DAY

Represents day unit

Example: "WEEK"
periodOfUse.​typestringrequired

Describes the period of use type for a online offer.

Enum ValueDescription
ONE_TIME

The offer can be used only once.

PERIOD

The offer can be used within a specific period.

WHOLE_DAY

The offer can be used for a whole day.

Example: "ONE_TIME"
typestringrequired

Describes the type of the online offer.

ValueDescription
CHECK_IN_BASED

The offer is based on check-ins.

Example: "CHECK_IN_BASED"
categoryobject(OnlineOfferCategory)

The category of the online offer.

validityobject(Term)

Validity term of the online offer.

restrictionsobject(OnlineOfferRestriction)required

Restrictions (facility, age and time) applicable to the online offer.

restrictions.​minAgeinteger(int32)required

Minimum age for the online offer

Example: 18
restrictions.​studioAccessTypestringrequired

Describes the studio access type for an online offer.

Enum ValueDescription
MAIN_STUDIO

Access is restricted to the main studio.

ALL_STUDIOS

Access is granted to all studios.

RESTRICTED_STUDIOS

Access is restricted to a specific list of studios.

Example: "ALL_STUDIOS"
restrictions.​restrictedStudioIdsArray of integers(int64)uniquerequired

List of studio IDs where the offer is available

restrictions.​timeRestrictionsobject(TimeRestrictions)required

Time restrictions for offer based on opening hours category

restrictions.​timeRestrictions.​openingHoursCategoryobject(OpeningHoursCategory)

Opening hours category that defines these restrictions

restrictions.​timeRestrictions.​availabilitiesArray of objects(Availability)

List of availabilities for this offer

paymentMethodsArray of stringsrequired

Payment methods available for the online offer.

Items Enum ValueDescription
ONLINE_PAYMENT

The offer requires immediate online payment.

PAY_LATER

The offer allows for payment at a later time.

Example: ["ONLINE_PAYMENT"]
Response
application/json
{ "onlineOfferId": 12345, "name": "Day Ticket Adult", "scopeOfUsage": 1, "price": { "amount": 20, "currency": "EUR" }, "periodOfUse": { "term": {}, "type": "ONE_TIME" }, "type": "CHECK_IN_BASED", "category": { "id": 1, "name": "Memberships" }, "validity": { "value": 2, "unit": "WEEK" }, "restrictions": { "minAge": 18, "studioAccessType": "ALL_STUDIOS", "restrictedStudioIds": [], "timeRestrictions": {} }, "paymentMethods": [ "ONLINE_PAYMENT" ] }

Preview online offer purchase preview

Request

Required Scopes: ONLINE_OFFER_WRITE

Returns a preview of an online offer purchase by provided offer id and optional voucher code and customer id.

Security
ApiKeyAuth
Bodyapplication/jsonrequired
onlineOfferIdinteger(int64)required

ID of the online offer to be purchased

Example: 12345
customerIdinteger(int64)

ID of the customer making the purchase

Example: 67890
voucherCodestring

Voucher code to be applied for the purchase

Example: "SUMMER21"
curl -i -X POST \
  https://open-api-demo.open-api.perfectgym.com/v1/online-offers/purchase/preview \
  -H 'Content-Type: application/json' \
  -H 'X-API-KEY: YOUR_API_KEY_HERE' \
  -d '{
    "onlineOfferId": 12345,
    "customerId": 67890,
    "voucherCode": "SUMMER21"
  }'

Responses

OK

Bodyapplication/json
priceobject(Money)

Price of the online offer before discounts

discountedPriceobject(Money)

Discounted price of the online offer after applying the voucher

discountValueobject(Money)

Discount value of the voucher

voucherSuccessMessagestring

Success message if the voucher was applied successfully

Example: "Voucher applied successfully"
voucherErrorCodestring

Represents a voucher error code

Enum ValueDescription
INVALID_CODE

Represents an invalid voucher code

ALREADY_REDEEMED

Represents that the voucher has already been redeemed

Example: "INVALID_CODE"
Response
application/json
{ "price": { "amount": 20, "currency": "EUR" }, "discountedPrice": { "amount": 20, "currency": "EUR" }, "discountValue": { "amount": 20, "currency": "EUR" }, "voucherSuccessMessage": "Voucher applied successfully", "voucherErrorCode": "INVALID_CODE" }

Request

Required Scopes: ONLINE_OFFER_WRITE

Returns response DTO on success.

Security
ApiKeyAuth
Bodyapplication/jsonrequired
onlineOfferIdinteger(int64)required

ID of the online offer to be purchased

Example: 12345
customerIdinteger(int64)required

ID of the customer making the purchase

Example: 67890
validFromstring(date)required

The date from which the purchased online offer becomes valid

Example: "2024-07-01"
voucherCodestring

Voucher code to apply for the purchase

Example: "SUMMER2024"
paymentRequestTokenstring

Payment request token to authenticate the payment request

Example: "abc123token"
curl -i -X POST \
  https://open-api-demo.open-api.perfectgym.com/v1/online-offers/purchase \
  -H 'Content-Type: application/json' \
  -H 'X-API-KEY: YOUR_API_KEY_HERE' \
  -d '{
    "onlineOfferId": 12345,
    "customerId": 67890,
    "validFrom": "2024-07-01",
    "voucherCode": "SUMMER2024",
    "paymentRequestToken": "abc123token"
  }'

Responses

OK

Bodyapplication/json
onlineOfferPurchaseIdinteger(int64)

Unique id of the online offer purchase

Example: 123456
studioAccessCodestring

Code to checkin to a studio

Example: "PTKXPMUO"
priceobject(Money)

Price of the online offer before discounts

discountedPriceobject(Money)

Discounted price of the online offer after applying the voucher

discountValueobject(Money)

Discount value of the voucher

voucherSuccessMessagestring

Success message if the voucher was applied successfully

Example: "Voucher applied successfully"
voucherErrorCodestring

Represents a voucher error code

Enum ValueDescription
INVALID_CODE

Represents an invalid voucher code

ALREADY_REDEEMED

Represents that the voucher has already been redeemed

Example: "INVALID_CODE"
Response
application/json
{ "onlineOfferPurchaseId": 123456, "studioAccessCode": "PTKXPMUO", "price": { "amount": 20, "currency": "EUR" }, "discountedPrice": { "amount": 20, "currency": "EUR" }, "discountValue": { "amount": 20, "currency": "EUR" }, "voucherSuccessMessage": "Voucher applied successfully", "voucherErrorCode": "INVALID_CODE" }

Request

Required Scopes: ONLINE_OFFER_READ

Returns online offer purchases by customer id

Security
ApiKeyAuth
Path
customerIdinteger(int64)required

The id of the customer

curl -i -X GET \
  'https://open-api-demo.open-api.perfectgym.com/v1/online-offers/{customerId}/purchased' \
  -H 'X-API-KEY: YOUR_API_KEY_HERE'

Responses

OK

Bodyapplication/jsonArray [
onlineOfferIdinteger(int64)required

Unique ID of the online offer.

Example: 12345
namestringrequired

Name of the online offer.

Example: "Day Ticket Adult"
scopeOfUsageinteger(int32)required

The number of times the online offer can be used.

Example: 1
priceobject(Money)required

The price amount and currency for the online offer.

price.​amountnumberrequired

Amount of the finance data tuple

Example: 20
price.​currencystring(ISO 4217)required

Currency of the finance data tuple

Example: "EUR"
periodOfUseobject(OnlineOfferPeriodOfUse)required

Online offer period of use information.

periodOfUse.​termobject(TermWithMinutes)required

Represents a term with minutes

periodOfUse.​term.​valueinteger(int32)required

The value of the term with minutes

Example: 2
periodOfUse.​term.​unitstringrequired

Represents a temporal unit with minutes

Enum ValueDescription
MONTH

Represents month unit

HOURS

Represents a hours unit

YEAR

Represents year unit

MINUTES

Represents a minutes unit

WEEK

Represents week unit

DAY

Represents day unit

Example: "WEEK"
periodOfUse.​typestringrequired

Describes the period of use type for a online offer.

Enum ValueDescription
ONE_TIME

The offer can be used only once.

PERIOD

The offer can be used within a specific period.

WHOLE_DAY

The offer can be used for a whole day.

Example: "ONE_TIME"
typestringrequired

Describes the type of the online offer.

ValueDescription
CHECK_IN_BASED

The offer is based on check-ins.

Example: "CHECK_IN_BASED"
categoryobject(OnlineOfferCategory)

The category of the online offer.

onlineOfferPurchaseIdinteger(int64)required

Unique ID of the online offer purchase.

Example: 123456
purchaseDatestring(date-time)required

The date when the online offer was purchased in the timezone of the studio it was purchased in.

Example: "2026-01-15T00:00:00+01:00[Europe/Berlin]"
expiryDatestring(date-time)

The expiry date of the online offer in the timezone of the studio it was purchased in.

Example: "2026-01-15T00:00:00+01:00[Europe/Berlin]"
studioAccessCodestringrequired

Studio access code for the purchased online offer.

Example: "ABC123XYZ"
studioIdinteger(int64)required

The ID of the studio the purchase was made for.

Example: 67890
validFromstring(date-time)required

The date from which the purchased online offer becomes valid

Example: "2026-01-15T00:00:00+01:00[Europe/Berlin]"
voucherCodestring

The voucher code used for the purchase, if any.

Example: "VOUCHER-ABC123"
discountedPriceobject(Money)

Discounted price of the online offer after applying the voucher.

discountValueobject(Money)

Discount value of the voucher.

]
Response
application/json
[ { "onlineOfferId": 12345, "name": "Day Ticket Adult", "scopeOfUsage": 1, "price": {}, "periodOfUse": {}, "type": "CHECK_IN_BASED", "category": {}, "onlineOfferPurchaseId": 123456, "purchaseDate": "2026-01-15T00:00:00+01:00[Europe/Berlin]", "expiryDate": "2026-01-15T00:00:00+01:00[Europe/Berlin]", "studioAccessCode": "ABC123XYZ", "studioId": 67890, "validFrom": "2026-01-15T00:00:00+01:00[Europe/Berlin]", "voucherCode": "VOUCHER-ABC123", "discountedPrice": {}, "discountValue": {} } ]

Get online offer purchases by customer id and offer id

Request

Required Scopes: ONLINE_OFFER_READ

Returns online offer purchases by customer id and offer id

Security
ApiKeyAuth
Path
customerIdinteger(int64)required

The id of the customer

offerIdinteger(int64)required

The id of the online offer

curl -i -X GET \
  'https://open-api-demo.open-api.perfectgym.com/v1/online-offers/{customerId}/purchased/{offerId}' \
  -H 'X-API-KEY: YOUR_API_KEY_HERE'

Responses

OK

Bodyapplication/jsonArray [
onlineOfferIdinteger(int64)required

Unique ID of the online offer.

Example: 12345
namestringrequired

Name of the online offer.

Example: "Day Ticket Adult"
scopeOfUsageinteger(int32)required

The number of times the online offer can be used.

Example: 1
priceobject(Money)required

The price amount and currency for the online offer.

price.​amountnumberrequired

Amount of the finance data tuple

Example: 20
price.​currencystring(ISO 4217)required

Currency of the finance data tuple

Example: "EUR"
periodOfUseobject(OnlineOfferPeriodOfUse)required

Online offer period of use information.

periodOfUse.​termobject(TermWithMinutes)required

Represents a term with minutes

periodOfUse.​term.​valueinteger(int32)required

The value of the term with minutes

Example: 2
periodOfUse.​term.​unitstringrequired

Represents a temporal unit with minutes

Enum ValueDescription
MONTH

Represents month unit

HOURS

Represents a hours unit

YEAR

Represents year unit

MINUTES

Represents a minutes unit

WEEK

Represents week unit

DAY

Represents day unit

Example: "WEEK"
periodOfUse.​typestringrequired

Describes the period of use type for a online offer.

Enum ValueDescription
ONE_TIME

The offer can be used only once.

PERIOD

The offer can be used within a specific period.

WHOLE_DAY

The offer can be used for a whole day.

Example: "ONE_TIME"
typestringrequired

Describes the type of the online offer.

ValueDescription
CHECK_IN_BASED

The offer is based on check-ins.

Example: "CHECK_IN_BASED"
categoryobject(OnlineOfferCategory)

The category of the online offer.

validityobject(Term)

Validity term of the online offer.

restrictionsobject(OnlineOfferRestriction)required

Restrictions (facility, age and time) applicable to the online offer.

restrictions.​minAgeinteger(int32)required

Minimum age for the online offer

Example: 18
restrictions.​studioAccessTypestringrequired

Describes the studio access type for an online offer.

Enum ValueDescription
MAIN_STUDIO

Access is restricted to the main studio.

ALL_STUDIOS

Access is granted to all studios.

RESTRICTED_STUDIOS

Access is restricted to a specific list of studios.

Example: "ALL_STUDIOS"
restrictions.​restrictedStudioIdsArray of integers(int64)uniquerequired

List of studio IDs where the offer is available

restrictions.​timeRestrictionsobject(TimeRestrictions)required

Time restrictions for offer based on opening hours category

restrictions.​timeRestrictions.​openingHoursCategoryobject(OpeningHoursCategory)

Opening hours category that defines these restrictions

restrictions.​timeRestrictions.​availabilitiesArray of objects(Availability)

List of availabilities for this offer

onlineOfferPurchaseIdinteger(int64)required

Unique ID of the online offer purchase.

Example: 123456
purchaseDatestring(date-time)required

The date when the online offer was purchased in the timezone of the studio it was purchased in.

Example: "2026-01-15T00:00:00+01:00[Europe/Berlin]"
expiryDatestring(date-time)

The expiry date of the online offer in the timezone of the studio it was purchased in.

Example: "2026-01-15T00:00:00+01:00[Europe/Berlin]"
studioAccessCodestringrequired

Studio access code for the purchased online offer.

Example: "ABC123XYZ"
studioIdinteger(int64)required

The ID of the studio the purchase was made for.

Example: 67890
validFromstring(date-time)required

The date from which the purchased online offer becomes valid

Example: "2026-01-15T00:00:00+01:00[Europe/Berlin]"
voucherCodestring

The voucher code used for the purchase, if any.

Example: "VOUCHER-ABC123"
discountedPriceobject(Money)

Discounted price of the online offer after applying the voucher.

discountValueobject(Money)

Discount value of the voucher.

]
Response
application/json
[ { "onlineOfferId": 12345, "name": "Day Ticket Adult", "scopeOfUsage": 1, "price": {}, "periodOfUse": {}, "type": "CHECK_IN_BASED", "category": {}, "validity": {}, "restrictions": {}, "onlineOfferPurchaseId": 123456, "purchaseDate": "2026-01-15T00:00:00+01:00[Europe/Berlin]", "expiryDate": "2026-01-15T00:00:00+01:00[Europe/Berlin]", "studioAccessCode": "ABC123XYZ", "studioId": 67890, "validFrom": "2026-01-15T00:00:00+01:00[Europe/Berlin]", "voucherCode": "VOUCHER-ABC123", "discountedPrice": {}, "discountValue": {} } ]
Operations
Operations

Trial Offers

Get trial offers information

Operations