Appointment, bookable appointment and slots operations
- Get purchasable additional modules
PerfectGym Next API (1.31.0)
- 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
- Retrieve customer transaction details
- Get device information
- Employee operations
- Debt collection operations
- Leads operations
- Get member lists
- Manage membership contracts
- Membership operations
- Online offer operations
- Payment operations
- Get studio information
- Get trial offers information
https://open-api-demo.open-api.perfectgym.com/
https://redocly.sportalliance.com/_mock/apis/perfectgym/openapi/openapi/
- Demo tenant
https://open-api-demo.open-api.perfectgym.com/v1/memberships/self-service/additional-modules
- Mock server
https://redocly.sportalliance.com/_mock/apis/perfectgym/openapi/openapi/v1/memberships/self-service/additional-modules
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
https://open-api-demo.open-api.perfectgym.com/v1/memberships/self-service/additional-modules \
-H 'X-API-KEY: YOUR_API_KEY_HERE'OK
Payment frequencies of the additional module
Unique ID of the payment frequency of an additional module
Payment frequency type of an additional module
| Enum Value | Description |
|---|---|
| TERM_BASED | Represents that the additional module payment frequency is based on terms, with a possibly individual price per term. |
| NON_RECURRING | Represents that the additional module payment frequency is non recurring, meaning only one payment is necessary here. |
| FREE | Represents that the additional module payment frequency is free of charge. |
| RECURRING | Represents that the additional module payment frequency is recurring, meaning that the payment will take place every term. |
| MONTH_DAY | Represents that the additional module payment frequency is based on month days, with a possibly individual price per month day. |
Interval between additional module payments, set only for payment frequencies of type RECURRING
Additional module payment amount for payment frequencies of type RECURRING or NON_RECURRING
Month day to prices list, used for additional module payment frequency type MONTH_DAY
Term information of the additional module
Duration of the additional module's initial contract term
Represents an additional module extension
Represents the trial period config of an additional module
[ { "id": 203, "name": "drink flat", "description": "drink flat", "imageUrl": "https://www.image.com", "paymentFrequencies": [ … ], "termInformation": { … }, "trialPeriodConfig": { … }, "rateCodes": [ … ] } ]
- Demo tenant
https://open-api-demo.open-api.perfectgym.com/v1/memberships/{contractId}/self-service/additional-modules/purchasable
- Mock server
https://redocly.sportalliance.com/_mock/apis/perfectgym/openapi/openapi/v1/memberships/{contractId}/self-service/additional-modules/purchasable
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
'https://open-api-demo.open-api.perfectgym.com/v1/memberships/{contractId}/self-service/additional-modules/purchasable' \
-H 'X-API-KEY: YOUR_API_KEY_HERE'OK
Payment frequencies of the additional module
Unique ID of the payment frequency of an additional module
Payment frequency type of an additional module
| Enum Value | Description |
|---|---|
| TERM_BASED | Represents that the additional module payment frequency is based on terms, with a possibly individual price per term. |
| NON_RECURRING | Represents that the additional module payment frequency is non recurring, meaning only one payment is necessary here. |
| FREE | Represents that the additional module payment frequency is free of charge. |
| RECURRING | Represents that the additional module payment frequency is recurring, meaning that the payment will take place every term. |
| MONTH_DAY | Represents that the additional module payment frequency is based on month days, with a possibly individual price per month day. |
Interval between additional module payments, set only for payment frequencies of type RECURRING
Additional module payment amount for payment frequencies of type RECURRING or NON_RECURRING
Month day to prices list, used for additional module payment frequency type MONTH_DAY
Term information of the additional module
Duration of the additional module's initial contract term
Represents an additional module extension
Represents the trial period config of an additional module
[ { "id": 203, "name": "drink flat", "description": "drink flat", "imageUrl": "https://www.image.com", "paymentFrequencies": [ … ], "termInformation": { … }, "trialPeriodConfig": { … }, "rateCodes": [ … ] } ]
Unique ID of the payment frequency of the additional module
- Demo tenant
https://open-api-demo.open-api.perfectgym.com/v1/memberships/{contractId}/self-service/additional-modules/validate
- Mock server
https://redocly.sportalliance.com/_mock/apis/perfectgym/openapi/openapi/v1/memberships/{contractId}/self-service/additional-modules/validate
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
'https://open-api-demo.open-api.perfectgym.com/v1/memberships/{contractId}/self-service/additional-modules/validate' \
-H 'Content-Type: application/json' \
-H 'X-API-KEY: YOUR_API_KEY_HERE' \
-d '{
"additionalModuleId": 203,
"paymentFrequencyId": 203,
"bookTrialPeriod": true
}'Validation completed. Inspect validationStatus: only ADDITIONAL_MODULE_PURCHASABLE permits purchase. Rejections represented by validationStatus are HTTP 200, including ADDITIONAL_MODULE_CONTRACT_ALREADY_PURCHASED, ADDITIONAL_MODULE_CONTRACT_INVALID_STATUS, ADDITIONAL_MODULE_NOT_FOUND, ADDITIONAL_MODULE_NOT_ONLINE_PURCHASABLE, ADDITIONAL_MODULE_TRIAL_PERIOD_NOT_BOOKABLE, and ADDITIONAL_MODULE_CONTRACT_MISSING_BOOKING_ANCHOR (the imported main contract lacks a required booking anchor). A booking anchor is the reference date needed to align the module's recurring payments with the imported main contract. The system uses the earliest non-reversed main-contract charge with a booking date strictly after today in the studio's time zone, or, if none exists, the day after the period recorded on the main contract's non-reversed customer debit balance. That recorded period does not necessarily mean the customer has paid. This status is returned only when alignment requires the reference date and neither source is available. The purchase request cannot supply this date. Do not automatically retry the unchanged purchase. Contact the studio administrator or support with the main contract ID to investigate the imported billing data and payment schedule; this status alone does not identify the appropriate repair. A missing main contract is HTTP 404 with errorCode errormessage.entity.not.found. Scheduling and pre-use exceptions from the imported recurring-contract preflight, and request-format errors, can also return HTTP 400.
Status of the additional module validation
| Enum Value | Description |
|---|---|
| ADDITIONAL_MODULE_NOT_FOUND | The additional module could not be found. |
| ADDITIONAL_MODULE_CONTRACT_MISSING_BOOKING_ANCHOR | The reference date required to align the additional module's recurring payments with the imported main contract is unavailable. The system uses the earliest non-reversed main-contract charge with a booking date strictly after today in the studio's time zone, or, if none exists, the day after the period recorded on the main contract's non-reversed customer debit balance. That recorded period does not necessarily mean the customer has paid. This status is returned only when alignment requires the reference date and neither source is available. The purchase request cannot supply this date. Do not automatically retry the unchanged purchase. Contact the studio administrator or support with the main contract ID to investigate the imported billing data and payment schedule; this status alone does not identify the appropriate repair. |
| ADDITIONAL_MODULE_CONTRACT_INVALID_STATUS | The main contract is reversed or canceled, or the customer's payment method is invalid. |
| ADDITIONAL_MODULE_NOT_ONLINE_PURCHASABLE | The additional module is not purchasable online. |
| ADDITIONAL_MODULE_CONTRACT_ALREADY_PURCHASED | The additional module contract has already been purchased. |
| ADDITIONAL_MODULE_PURCHASABLE | The additional module is purchasable. |
| ADDITIONAL_MODULE_TRIAL_PERIOD_NOT_BOOKABLE | The additional module trial period cannot be booked. |
The request passed business validation.
{ "validationStatus": "ADDITIONAL_MODULE_PURCHASABLE" }