Skip to content

PerfectGym Next API (1.11.1)

  • 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
  • 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

Request

Required Scopes: MEMBERSHIP_READ

Returns all available membership offers.

Security
ApiKeyAuth
curl -i -X GET \
  https://open-api-demo.open-api.perfectgym.com/v1/memberships/membership-offers \
  -H 'X-API-KEY: YOUR_API_KEY_HERE'

Responses

OK

Bodyapplication/jsonArray [
idinteger(int64)required

Unique identifier for the membership offer.

descriptionstringrequired

Description of the membership offer.

Example: "This offer includes access to all gym facilities and group classes."
namestringrequired

Name of the membership offer.

Example: "Standard Membership"
subDescriptionstring

Sub description for the membership offer.

Example: "Best value for regular gym-goers."
imageUrlstring

Temporary valid download link for rate bundle image. Expires after 2 hours.

Example: "https://example.com"
footnotestring

Contractual or legal comments to be displayed below the offer.

Example: "This offer is valid for new members only. Terms and conditions apply."
preUseTypestring(ContractPreUseType)required

Contract pre-use type information.

Enum ValueDescription
CHARGEABLE

Contract pre-use is chargeable

FREE

Contract pre-use is free

NOT_AVAILABLE

Contract is not available for pre-use

limitedOfferingPeriodobject(DatePeriod)required

Period in which the membership offer is valid.

limitedOfferingPeriod.​startDatestring(date)required

Start of the interval

Example: "2025-01-01"
limitedOfferingPeriod.​endDatestring(date)required

End of the interval

Example: "2026-01-01"
rateCodesArray of objects(RateCode)required

Rate codes of the membership offer.

rateCodes[].​namestring

The name of the rate code

Example: "Standard Rate"
rateCodes[].​identifierstring

Unique identifier for the rate code.

Example: "RC12345"
termsArray of objects(MembershipOfferTerm)required

List of terms that are part of this membership offer.

terms[].​idinteger(int64)required

Unique identifier of the membership offer term

Example: 1234567890
terms[].​termobject(Term)

Represents a term

terms[].​contractVolumeInformationobject(ContractVolume)

Contains the total amount to be paid during the initial runtime of the contract and the average amounts per month and per the rate's payment frequency (e.g. 1 week)

terms[].​paymentFrequencyobject(MembershipOfferPaymentFrequency)required

Represents the payment frequency

terms[].​paymentFrequency.​idinteger(int64)

The unique identifier of the payment frequency. (null possible for starter package)

Example: 1234567890
terms[].​paymentFrequency.​typestringrequired

Payment frequency type of a contract

Enum ValueDescription
TERM_BASED

Represents that the contract payment frequency is based on terms, with a possibly individual price per term.

NON_RECURRING

Represents that the contract payment frequency is non recurring, meaning only one payment is necessary here.

FREE

Represents that the contract payment frequency is free of charge.

RECURRING

Represents that the contract payment frequency is recurring, meaning that the payment will take place every term.

MONTH_DAY

Represents that the contract payment frequency is based on month days, with a possibly individual price per month day.

Example: "FREE"
terms[].​paymentFrequency.​termobject(Term)

Represents a term

terms[].​paymentFrequency.​priceobject(Money)

Base price, used only for payment frequencies of type RECURRING

terms[].​paymentFrequency.​monthDaysToPricesArray of objects(MembershipOfferMonthDayToPrice)

Month day to prices list, used for contract payment frequency type MONTH_DAY

terms[].​paymentFrequency.​termsToPricesArray of objects(MembershipOfferTermToPrice)

Terms to prices list, used for contract payment frequency type TERM_BASED. Note that the price will become active AFTER the respective term has passed

terms[].​paymentFrequency.​recurringboolean

Whether the cycle of payments repeats indefinitely. Only relevant if type is TERM_BASED or MONTH_DAY.

terms[].​paymentFrequency.​ageBasedAdjustmentsArray of objects(MembershipOfferModuleAgeBasedAdjustment)

List of age-based adjustments for the membership offer module.

terms[].​paymentFrequency.​formattedPaymentFrequencystringrequired

The formatted payment frequency

Example: "Every 6 months"
terms[].​extensionTermobject(Term)

Represents a term

]
Response
application/json
[ { "id": 0, "description": "This offer includes access to all gym facilities and group classes.", "name": "Standard Membership", "subDescription": "Best value for regular gym-goers.", "imageUrl": "https://example.com", "footnote": "This offer is valid for new members only. Terms and conditions apply.", "preUseType": "NOT_AVAILABLE", "limitedOfferingPeriod": {}, "rateCodes": [], "terms": [] } ]

Request

Required Scopes: MEMBERSHIP_READ

Returns extended information about the membership offer.

Security
ApiKeyAuth
Path
membershipOfferIdinteger(int64)required
curl -i -X GET \
  'https://open-api-demo.open-api.perfectgym.com/v1/memberships/membership-offers/{membershipOfferId}' \
  -H 'X-API-KEY: YOUR_API_KEY_HERE'

Responses

OK

Bodyapplication/json
idinteger(int64)required

Unique identifier for the membership offer.

descriptionstringrequired

Description of the membership offer.

Example: "This offer includes access to all gym facilities and group classes."
namestringrequired

Name of the membership offer.

Example: "Standard Membership"
subDescriptionstring

Sub description for the membership offer.

Example: "Best value for regular gym-goers."
imageUrlstring

Temporary valid download link for rate bundle image. Expires after 2 hours.

Example: "https://example.com"
footnotestring

Contractual or legal comments to be displayed below the offer.

Example: "This offer is valid for new members only. Terms and conditions apply."
preUseTypestring(ContractPreUseType)required

Contract pre-use type information.

Enum ValueDescription
CHARGEABLE

Contract pre-use is chargeable

FREE

Contract pre-use is free

NOT_AVAILABLE

Contract is not available for pre-use

limitedOfferingPeriodobject(DatePeriod)required

Period in which the membership offer is valid.

limitedOfferingPeriod.​startDatestring(date)required

Start of the interval

Example: "2025-01-01"
limitedOfferingPeriod.​endDatestring(date)required

End of the interval

Example: "2026-01-01"
rateCodesArray of objects(RateCode)required

Rate codes of the membership offer.

rateCodes[].​namestring

The name of the rate code

Example: "Standard Rate"
rateCodes[].​identifierstring

Unique identifier for the rate code.

Example: "RC12345"
includedModulesArray of objects(MembershipOfferIncludedModule)required

List of included modules of this membership offer.

includedModules[].​idinteger(int64)required

Unique identifier for the membership offer module.

Example: 1234567890
includedModules[].​namestringrequired

Name of the membership offer module.

Example: "Premium Fitness Package"
includedModules[].​descriptionstringrequired

Description of the membership offer module.

Example: "Includes access to all gym facilities and group classes."
includedModules[].​imageUrlstring

Image url of membership offer module. Expires after 5hours.

Example: "https://some-module.com"
includedModules[].​termobject(MembershipOfferModuleTerm)required

Represents the terms of a membership offer.

includedModules[].​term.​extensionTypestringrequired

Module term extension type

Enum ValueDescription
SUBSEQUENT_RATE_DETAIL

Subsequent rate detail

TERM_EXTENSION

Term extension

NONE

No extension

Example: "TERM_EXTENSION"
includedModules[].​term.​termobject(Term)

Represents a term

includedModules[].​term.​termExtensionobject(Term)

Represents a term

includedModules[].​term.​cancelationPeriodobject(Term)

Represents a term

includedModules[].​term.​extensionCancelationPeriodobject(Term)

Represents a term

includedModules[].​trialPeriodobject(MembershipOfferTrialPeriod)

Represents the trial period of a membership offer.

includedModules[].​consentTextBlockobject(MembershipOfferTextBlock)

Contract text block information.

includedModules[].​rateCodesArray of objects(RateCode)

Rate codes of the membership offer module.

contractSignaturesRequiredboolean

Indicates if contract signatures are required for this membership offer.

allowedPaymentChoicesArray of stringsuniquerequired

Allowed payment choices for this membership offer.

Items Enum ValueDescription
BACS

Payment by BACS direct debit

IDEAL

Payment by ideal

PAYPAL

Payment by paypal

TWINT

Payment by Twint

SEPA

Payment by SEPA direct debit

BANK_TRANSFER

Payment by bank transfer

CH_DD

Payment by CH_DD direct debit

CASH

Payment by cash

BANCONTACT

Payment by bancontact

CREDIT_CARD

Payment by credit card

Example: ["CASH"]
maximumNumberOfSelectableModulesinteger(int32)

Maximum number of selectableModules for this membership offer. If 0, no modules can be selected.

contractTextBlocksArray of objects(MembershipOfferTextBlock)required

List of contract text blocks that are part of this membership offer.

contractTextBlocks[].​idinteger(int64)

The unique identifier of the text block

Example: 1234567890
contractTextBlocks[].​titlestring

The title of the text block

Example: "Title of 1. text block"
contractTextBlocks[].​textstring

The text of the text block

Example: "Text of 1. text block"
contractTextBlocks[].​orderinteger(int32)

The order of the text block in the contract

Example: 1
contractTextBlocks[].​hasSignatureboolean

Text block configuration has a signature field. You have the option to show a signature input field and it will be added in the contract document. It is not a required field in magicline. It is up to your implementation if you add this field.

contractTextBlocks[].​showCommunicationPrivacyOptionsboolean

Text block contains information about the communication privacy options. You are advised to show a matrix with communication settings in combination with this text block.

contractTextBlocks[].​attachmentTypestring

Indicates the type of attachment for this block

Enum ValueDescription
CONTRACT_PDF_PREVIEW

Contract PDF preview

NONE

No text block

FILE

File information available in attachedDocument

URL

Url information available in attachedExternalUrlDto

Example: "CONTRACT_PDF_PREVIEW"
contractTextBlocks[].​attachedExternalUrlDtoobject(ExternalUrl)

Represents url information.

contractTextBlocks[].​attachedDocumentobject(AttachedDocument)

Represents document information.

contractTextBlocks[].​rateBundleModuleIdinteger(int64)

The ID of the associated rate bundle module. Only set if this is a module consent text block.

Example: 1234567890
contractTextBlocks[].​confirmationRequiredboolean
selectableModulesArray of objects(MembershipOfferModule)

List of selectable modules for this membership offer. Limited by maximumNumberOfSelectableModules.

termsArray of objects(MembershipOfferTermExtended)

List of terms that are part of this membership offer.

timeRestrictionsobject(TimeRestrictions)

Time restrictions for this membership offer based on opening hours categories. Null if no restrictions apply.

Response
application/json
{ "id": 0, "description": "This offer includes access to all gym facilities and group classes.", "name": "Standard Membership", "subDescription": "Best value for regular gym-goers.", "imageUrl": "https://example.com", "footnote": "This offer is valid for new members only. Terms and conditions apply.", "preUseType": "NOT_AVAILABLE", "limitedOfferingPeriod": { "startDate": "2025-01-01", "endDate": "2026-01-01" }, "rateCodes": [ {} ], "includedModules": [ {} ], "contractSignaturesRequired": true, "allowedPaymentChoices": [ "CASH" ], "maximumNumberOfSelectableModules": 0, "contractTextBlocks": [ {} ], "selectableModules": [ {} ], "terms": [ {} ], "timeRestrictions": { "openingHoursCategory": {}, "availabilities": [] } }

Preview information before signing up for a new membership

Request

Required Scopes: MEMBERSHIP_WRITE

Security
ApiKeyAuth
Bodyapplication/jsonrequired
contractobject(MembershipSignupContract)required

The contract information used for the membership signup

contract.​contractOfferTermIdinteger(int64)required

Unique ID of the contract offer term

Example: 1000
contract.​startDatestring(date)required

The start date of the contract

Example: "2026-02-01"
contract.​preuseDatestring(date)

The pre use date of the contract. If not provided, it will be evaluated based on contract offer configuration.

Example: "2026-01-01"
contract.​notesstring

The notes related to the contract

Example: "Some notes"
contract.​thirdPartyIdstring

Unique ID of the third party contract in the third party system

Example: "1000a"
contract.​employeeIdinteger(int64)

Unique ID of the employee who created the membership

Example: 1239812733
contract.​referralCodestring

Referral code to link with recruiter

Example: "A500D"
contract.​selectedSelectableModuleIdsArray of integers(int64)

The selected modules from the available selectable modules

contract.​selectedOptionalModuleIdsArray of integers(int64)

The selected modules from the available optional modules

contract.​initialPaymentRequestTokenstring

This token identifies a pre-authorized payment request. It acts as a reference to the payment session initiated by the user. It's not needed for preview endpoints.

Example: "3JtyH5sakfn2V22vB0napNC2zWMlpFwS9gPQawuk7Jw1F00atOD0BA"
contract.​contractSignatureobject(Signature)

The signature SVG for the contract document

contract.​textBlockSignaturesArray of objects(TextBlockSignature)

Signatures for text blocks

contract.​voucherCodestring

An optional code for a voucher. Only credit and discount vouchers are supported.

Example: 123
customerobject(MembershipSignupCustomer)required

The customer information used for the membership signup

customer.​thirdPartyIdstring

Unique ID of the third party customer in the third party system

Example: "A1000"
customer.​firstNamestringrequired

First name of the customer

Example: "Peter"
customer.​secondFirstNamestring

Second first name of the customer

Example: "Thomas"
customer.​lastNamestringrequired

Last name of the customer

Example: "Muller"
customer.​secondLastNamestring

Second last name of the customer

Example: "Meyer"
customer.​dateOfBirthstring(date)required

Date of birth of the customer

Example: "2019-08-24"
customer.​placeOfBirthstring

Place of birth of the customer. Required for Italian studios and nationals.

customer.​countryOfBirthstring

Country of birth of the customer. Required for Italian studios and non-Italian nationals

customer.​emailstringrequired

Email address of the customer

Example: "example@example.com"
customer.​genderstring

Gender of the customer

Enum ValueDescription
MALE

Male gender of the customer

FEMALE

Female gender of the customer

UNISEX

Unisex gender of the customer

Example: "MALE"
customer.​phoneNumberPrivatestring

Private phone number of the customer

Example: "+44123456789"
customer.​phoneNumberMobilestring

Mobile phone number of the customer

Example: "+44987654321"
customer.​streetstringrequired

Street of the customer's address

Example: "Raboisen Street"
customer.​secondStreetstring

Second street line of the customer's address

Example: "Second Street"
customer.​cityPartstring

City part of the customer's address

Example: "Tegel"
customer.​districtstring

District of the customer's address

Example: "District 12"
customer.​streetTypestring

Street type of the customer's address

Example: "Avenue"
customer.​streetBlockstring

Street block of the customer's address

Example: "5th block"
customer.​portalstring

Portal of the customer's address

Example: "Portal 1"
customer.​stairwaystring

Stairway of the customer's address

Example: "Right stairway"
customer.​doorstring

Door of the customer's address

Example: "Door 1"
customer.​provincestring

Province of the customer's address

Example: "Champagne"
customer.​additionalAddressInformationstring

Additional address information of the customer's address

Example: "Additional information"
customer.​floorstring

Floor of the customer's address

Example: "2nd floor"
customer.​languageobject(Language)required

Language of the customer

customer.​language.​languageCodestring(ISO 639-1)required

The language code

Example: "de"
customer.​language.​countryCodestring(ISO 3166-1)

The country code

Example: "DE"
customer.​houseNumberstring

House number of the customer's address

Example: "3-4"
customer.​buildingNamestring

Building name

Example: "Empire State Building"
customer.​citystringrequired

City of the customer's address

Example: "Hamburg"
customer.​zipCodestringrequired

Zip code of the customer's address

Example: "220-99"
customer.​countryCodestring(ISO 3166-1)required

Country code of the customer's address

Example: "DE"
customer.​taxIdstring

Required if the studio is located in Spain or Italy. Alternatively, a valid document identification can be provided.

Example: "12345678A"
customer.​communicationPreferencesArray of objects(CommunicationPreference)

List of communication preferences for the customer

customer.​documentIdentificationobject(DocumentIdentification)

Information from an official document that identifies the customer

customer.​paymentRequestTokenstring

By assigning the paymentRequestToken to the customer, the payment method associated with the token will be used as payment method setting of the customer. Additionally, if the paymentRequestToken is associated with a payment instrument, i.e. a SEPA Mandate, BACS Mandate, Credit Card, or other, the payment instrument will be made available in the member account for future collection via payment runs. By leaving this field empty the payment method of the customer will be set to CASH. For reference check 'Create a user payment session'.

customer.​additionalInformationFieldAssignmentsArray of objects(AdditionalInformationFieldAssignment)

List of additional information field assignments of the customer

curl -i -X POST \
  https://open-api-demo.open-api.perfectgym.com/v1/memberships/signup/preview \
  -H 'Content-Type: application/json' \
  -H 'X-API-KEY: YOUR_API_KEY_HERE' \
  -d '{
    "contract": {
      "contractOfferTermId": 1000,
      "startDate": "2026-02-01",
      "preuseDate": "2026-01-01",
      "notes": "Some notes",
      "thirdPartyId": "1000a",
      "employeeId": 1239812733,
      "referralCode": "A500D",
      "selectedSelectableModuleIds": [
        0
      ],
      "selectedOptionalModuleIds": [
        0
      ],
      "initialPaymentRequestToken": "3JtyH5sakfn2V22vB0napNC2zWMlpFwS9gPQawuk7Jw1F00atOD0BA",
      "contractSignature": {
        "base64SvgSignature": "string"
      },
      "textBlockSignatures": [
        {
          "base64SvgSignature": "string",
          "textBlockId": 0
        }
      ],
      "voucherCode": 123
    },
    "customer": {
      "thirdPartyId": "A1000",
      "firstName": "Peter",
      "secondFirstName": "Thomas",
      "lastName": "Muller",
      "secondLastName": "Meyer",
      "dateOfBirth": "2019-08-24",
      "placeOfBirth": "string",
      "countryOfBirth": "string",
      "email": "example@example.com",
      "gender": "MALE",
      "phoneNumberPrivate": "+44123456789",
      "phoneNumberMobile": "+44987654321",
      "street": "Raboisen Street",
      "secondStreet": "Second Street",
      "cityPart": "Tegel",
      "district": "District 12",
      "streetType": "Avenue",
      "streetBlock": "5th block",
      "portal": "Portal 1",
      "stairway": "Right stairway",
      "door": "Door 1",
      "province": "Champagne",
      "additionalAddressInformation": "Additional information",
      "floor": "2nd floor",
      "language": {
        "languageCode": "de",
        "countryCode": "DE"
      },
      "houseNumber": "3-4",
      "buildingName": "Empire State Building",
      "city": "Hamburg",
      "zipCode": "220-99",
      "countryCode": "DE",
      "taxId": "12345678A",
      "communicationPreferences": [
        {
          "messageCategory": "CONTRACT",
          "channels": [
            {
              "communicationChannel": "EMAIL",
              "customerOverridable": true,
              "active": true
            }
          ]
        }
      ],
      "documentIdentification": {
        "documentNumber": "CX5432112345DS",
        "documentType": "ID_CARD"
      },
      "paymentRequestToken": "string",
      "additionalInformationFieldAssignments": [
        {
          "additionalInformationFieldId": 1234567890,
          "value": "string"
        }
      ]
    }
  }'

Responses

OK

Bodyapplication/json
basePriceobject(Money)required

Base price of contract

basePrice.​amountnumberrequired

Amount of the finance data tuple

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

Currency of the finance data tuple

Example: "EUR"
preUseChargeobject(Money)

Charge for the time between the start date of use and start date

voucherTypestring

Type of a voucher, if a valid voucher code has been provided

Enum ValueDescription
CREDIT

Represents a credit voucher

CHECKIN

Represents a check-in voucher

COMPANY_FEE_SPLIT

Represents a company fee split voucher

CONTRACT

Represents a contract voucher

DISCOUNT

Represents a discount voucher

Example: "DISCOUNT"
voucherRemarksstring

Voucher remarks, if a valid voucher code has been provided

Example: "Yoga class not included"
voucherDiscountPeriodsArray of objects(VoucherDiscountPeriod)

List of discount periods for the voucher, if a valid discount voucher code has been provided. Each period has its own discount and effective period.

discountedPreUseChargeobject(Money)

Discounted pre-use charge, if a valid discount voucher code has been provided

creditValueobject(Money)

Voucher credit value, if a valid credit voucher code has been provided

companyFeeSplitTypestring

Type of company fee split (percentage or absolute), if a valid company discount voucher code has been provided

Enum ValueDescription
ABSOLUTE

Represents an absolute discount

PERCENTAGE

Represents a percentage based discount

Example: "ABSOLUTE"
companyFeeSplitValueobject(Money)

Company fee split value, if a valid company discount voucher code has been provided

companyNamestring

Name of the company that will pay the company amount, if a valid company discount voucher code has been provided

Example: "Some company"
companyAmountobject(Money)

Amount the company has to pay, if a valid company discount voucher code has been provided. This field is populated when there are 0 or 1 discount periods. For multiple discount periods, use voucherDiscountPeriods[].companyAmount instead to see amounts per discount period.

memberAmountobject(Money)

Amount the member has to pay, if a valid company discount voucher code has been provided. This field is populated when there are 0 or 1 discount periods. For multiple discount periods, use voucherDiscountPeriods[].memberAmount instead to see amounts per discount period.

companyAmountWithoutDiscountobject(Money)

Amount the company has to pay without discount, if a valid company discount voucher code has been provided

memberAmountWithoutDiscountobject(Money)

Amount the member has to pay without discount, if a valid company discount voucher code has been provided

voucherBonusPeriodobject(MembershipOfferRateBonusPeriod)

Bonus period applied with the discount voucher, if valid a discount voucher has been provided

voucherTextBlocksArray of objects(MembershipOfferTextBlock)

Voucher related text blocks, if a valid voucher code has been provided

flatFeePreviewsArray of objects(FlatFeePreview)

Flat fee previews, including discount if a valid discount voucher code has been provided

voucherSuccessMessagestring

Textual representation of the voucher conditions, if a valid voucher code has been provided

Example: "Voucher code \"123\" successfully applied: 5% discount on the membership fee"
voucherErrorCodestring

An error code, if the voucher code is invalid

ValueDescription
INVALID_CODE

Represents an invalid voucher code

Example: "INVALID_CODE"
ageAdjustedPriceobject(Money)

The adjusted price, if age-based discounts are configured and the customer is eligible, null otherwise

contractVolumeInformationobject(ContractVolume)

Contains the total amount to be paid during the initial runtime of the contract and the average amounts per month and per the rate's payment frequency (e.g. 1 week)

moduleConsentTextBlocksArray of objects(MembershipOfferTextBlock)

Consent texts for modules that are part of the contract

selectedOptionalModulesPreviewsArray of objects(ModuleContractPreview)

Optional module contract preview including discount, company split or credit, if a valid voucher code has been provided

paymentPreviewobject(SignupPaymentPreview)

Detailed payment preview including schedule and due-on-signing amount

voucherEffectivePeriodstringDeprecated

The type of period for which the voucher is applied, if a valid voucher code has been provided. Deprecated: Use voucherDiscountPeriods[].effectivePeriod instead to see periods per discount period.

Enum ValueDescription
TIME_BASED

Represents a voucher with a time based effective period

UNLIMITED

Represents a voucher with unlimited effective period

INITIAL_TERM

Represents a voucher effective during the initial term of the membership

Example: "UNLIMITED"
effectivePeriodTimeBasedTermobject(Term)Deprecated

Effective period: term for which a discount is applied, if type is time based and a valid voucher code has been provided. Deprecated: Use voucherDiscountPeriods[].effectivePeriodTimeBasedTerm instead to see terms per discount period.

discountedBasePriceobject(Money)Deprecated

Discounted base price, if a valid discount voucher code has been provided. Deprecated: Use voucherDiscountPeriods[].discountedBasePrice instead to see prices per discount period.

discountTypestringDeprecated

Type of discount (percentage or absolute), if a valid discount voucher code has been provided. Deprecated: Use voucherDiscountPeriods[].discountType instead to see discount types per discount period.

Enum ValueDescription
ABSOLUTE

Represents an absolute discount

PERCENTAGE

Represents a percentage based discount

Example: "PERCENTAGE"
discountValueobject(Money)Deprecated

Discount value, if a valid discount voucher code has been provided. Deprecated: Use voucherDiscountPeriods[].discountValue instead to see discount values per discount period.

Response
application/json
{ "basePrice": { "amount": 20, "currency": "EUR" }, "preUseCharge": { "amount": 20, "currency": "EUR" }, "voucherType": "DISCOUNT", "voucherRemarks": "Yoga class not included", "voucherEffectivePeriod": "UNLIMITED", "effectivePeriodTimeBasedTerm": { "value": 2, "unit": "WEEK" }, "discountedBasePrice": { "amount": 20, "currency": "EUR" }, "discountType": "PERCENTAGE", "discountValue": { "amount": 20, "currency": "EUR" }, "voucherDiscountPeriods": [ {} ], "discountedPreUseCharge": { "amount": 20, "currency": "EUR" }, "creditValue": { "amount": 20, "currency": "EUR" }, "companyFeeSplitType": "ABSOLUTE", "companyFeeSplitValue": { "amount": 20, "currency": "EUR" }, "companyName": "Some company", "companyAmount": { "amount": 20, "currency": "EUR" }, "memberAmount": { "amount": 20, "currency": "EUR" }, "companyAmountWithoutDiscount": { "amount": 20, "currency": "EUR" }, "memberAmountWithoutDiscount": { "amount": 20, "currency": "EUR" }, "voucherBonusPeriod": { "term": {}, "termStrategy": "CONTRACT_START", "displaySeparately": true, "runtimeExtensionType": "WITH_EXTENSION", "extendsCancellationPeriod": false }, "voucherTextBlocks": [ {} ], "flatFeePreviews": [ {} ], "voucherSuccessMessage": "Voucher code \"123\" successfully applied: 5% discount on the membership fee", "voucherErrorCode": "INVALID_CODE", "ageAdjustedPrice": { "amount": 20, "currency": "EUR" }, "contractVolumeInformation": { "totalContractVolume": {}, "averagePaymentVolumePerMonth": {}, "averagePaymentVolumePerPaymentFrequencyTerm": {} }, "moduleConsentTextBlocks": [ {} ], "selectedOptionalModulesPreviews": [ {} ], "paymentPreview": { "paymentSchedule": [], "dueOnSigningAmount": {} } }

Request

Required Scopes: MEMBERSHIP_WRITE

Returns customer id within the result dto.

Security
ApiKeyAuth
Bodyapplication/jsonrequired
contractobject(MembershipSignupContract)required

The contract information used for the membership signup

contract.​contractOfferTermIdinteger(int64)required

Unique ID of the contract offer term

Example: 1000
contract.​startDatestring(date)required

The start date of the contract

Example: "2026-02-01"
contract.​preuseDatestring(date)

The pre use date of the contract. If not provided, it will be evaluated based on contract offer configuration.

Example: "2026-01-01"
contract.​notesstring

The notes related to the contract

Example: "Some notes"
contract.​thirdPartyIdstring

Unique ID of the third party contract in the third party system

Example: "1000a"
contract.​employeeIdinteger(int64)

Unique ID of the employee who created the membership

Example: 1239812733
contract.​referralCodestring

Referral code to link with recruiter

Example: "A500D"
contract.​selectedSelectableModuleIdsArray of integers(int64)

The selected modules from the available selectable modules

contract.​selectedOptionalModuleIdsArray of integers(int64)

The selected modules from the available optional modules

contract.​initialPaymentRequestTokenstring

This token identifies a pre-authorized payment request. It acts as a reference to the payment session initiated by the user. It's not needed for preview endpoints.

Example: "3JtyH5sakfn2V22vB0napNC2zWMlpFwS9gPQawuk7Jw1F00atOD0BA"
contract.​contractSignatureobject(Signature)

The signature SVG for the contract document

contract.​textBlockSignaturesArray of objects(TextBlockSignature)

Signatures for text blocks

contract.​voucherCodestring

An optional code for a voucher. Only credit and discount vouchers are supported.

Example: 123
customerobject(MembershipSignupCustomer)required

The customer information used for the membership signup

customer.​thirdPartyIdstring

Unique ID of the third party customer in the third party system

Example: "A1000"
customer.​firstNamestringrequired

First name of the customer

Example: "Peter"
customer.​secondFirstNamestring

Second first name of the customer

Example: "Thomas"
customer.​lastNamestringrequired

Last name of the customer

Example: "Muller"
customer.​secondLastNamestring

Second last name of the customer

Example: "Meyer"
customer.​dateOfBirthstring(date)required

Date of birth of the customer

Example: "2019-08-24"
customer.​placeOfBirthstring

Place of birth of the customer. Required for Italian studios and nationals.

customer.​countryOfBirthstring

Country of birth of the customer. Required for Italian studios and non-Italian nationals

customer.​emailstringrequired

Email address of the customer

Example: "example@example.com"
customer.​genderstring

Gender of the customer

Enum ValueDescription
MALE

Male gender of the customer

FEMALE

Female gender of the customer

UNISEX

Unisex gender of the customer

Example: "MALE"
customer.​phoneNumberPrivatestring

Private phone number of the customer

Example: "+44123456789"
customer.​phoneNumberMobilestring

Mobile phone number of the customer

Example: "+44987654321"
customer.​streetstringrequired

Street of the customer's address

Example: "Raboisen Street"
customer.​secondStreetstring

Second street line of the customer's address

Example: "Second Street"
customer.​cityPartstring

City part of the customer's address

Example: "Tegel"
customer.​districtstring

District of the customer's address

Example: "District 12"
customer.​streetTypestring

Street type of the customer's address

Example: "Avenue"
customer.​streetBlockstring

Street block of the customer's address

Example: "5th block"
customer.​portalstring

Portal of the customer's address

Example: "Portal 1"
customer.​stairwaystring

Stairway of the customer's address

Example: "Right stairway"
customer.​doorstring

Door of the customer's address

Example: "Door 1"
customer.​provincestring

Province of the customer's address

Example: "Champagne"
customer.​additionalAddressInformationstring

Additional address information of the customer's address

Example: "Additional information"
customer.​floorstring

Floor of the customer's address

Example: "2nd floor"
customer.​languageobject(Language)required

Language of the customer

customer.​language.​languageCodestring(ISO 639-1)required

The language code

Example: "de"
customer.​language.​countryCodestring(ISO 3166-1)

The country code

Example: "DE"
customer.​houseNumberstring

House number of the customer's address

Example: "3-4"
customer.​buildingNamestring

Building name

Example: "Empire State Building"
customer.​citystringrequired

City of the customer's address

Example: "Hamburg"
customer.​zipCodestringrequired

Zip code of the customer's address

Example: "220-99"
customer.​countryCodestring(ISO 3166-1)required

Country code of the customer's address

Example: "DE"
customer.​taxIdstring

Required if the studio is located in Spain or Italy. Alternatively, a valid document identification can be provided.

Example: "12345678A"
customer.​communicationPreferencesArray of objects(CommunicationPreference)

List of communication preferences for the customer

customer.​documentIdentificationobject(DocumentIdentification)

Information from an official document that identifies the customer

customer.​paymentRequestTokenstring

By assigning the paymentRequestToken to the customer, the payment method associated with the token will be used as payment method setting of the customer. Additionally, if the paymentRequestToken is associated with a payment instrument, i.e. a SEPA Mandate, BACS Mandate, Credit Card, or other, the payment instrument will be made available in the member account for future collection via payment runs. By leaving this field empty the payment method of the customer will be set to CASH. For reference check 'Create a user payment session'.

customer.​additionalInformationFieldAssignmentsArray of objects(AdditionalInformationFieldAssignment)

List of additional information field assignments of the customer

curl -i -X POST \
  https://open-api-demo.open-api.perfectgym.com/v1/memberships/signup \
  -H 'Content-Type: application/json' \
  -H 'X-API-KEY: YOUR_API_KEY_HERE' \
  -d '{
    "contract": {
      "contractOfferTermId": 1000,
      "startDate": "2026-02-01",
      "preuseDate": "2026-01-01",
      "notes": "Some notes",
      "thirdPartyId": "1000a",
      "employeeId": 1239812733,
      "referralCode": "A500D",
      "selectedSelectableModuleIds": [
        0
      ],
      "selectedOptionalModuleIds": [
        0
      ],
      "initialPaymentRequestToken": "3JtyH5sakfn2V22vB0napNC2zWMlpFwS9gPQawuk7Jw1F00atOD0BA",
      "contractSignature": {
        "base64SvgSignature": "string"
      },
      "textBlockSignatures": [
        {
          "base64SvgSignature": "string",
          "textBlockId": 0
        }
      ],
      "voucherCode": 123
    },
    "customer": {
      "thirdPartyId": "A1000",
      "firstName": "Peter",
      "secondFirstName": "Thomas",
      "lastName": "Muller",
      "secondLastName": "Meyer",
      "dateOfBirth": "2019-08-24",
      "placeOfBirth": "string",
      "countryOfBirth": "string",
      "email": "example@example.com",
      "gender": "MALE",
      "phoneNumberPrivate": "+44123456789",
      "phoneNumberMobile": "+44987654321",
      "street": "Raboisen Street",
      "secondStreet": "Second Street",
      "cityPart": "Tegel",
      "district": "District 12",
      "streetType": "Avenue",
      "streetBlock": "5th block",
      "portal": "Portal 1",
      "stairway": "Right stairway",
      "door": "Door 1",
      "province": "Champagne",
      "additionalAddressInformation": "Additional information",
      "floor": "2nd floor",
      "language": {
        "languageCode": "de",
        "countryCode": "DE"
      },
      "houseNumber": "3-4",
      "buildingName": "Empire State Building",
      "city": "Hamburg",
      "zipCode": "220-99",
      "countryCode": "DE",
      "taxId": "12345678A",
      "communicationPreferences": [
        {
          "messageCategory": "CONTRACT",
          "channels": [
            {
              "communicationChannel": "EMAIL",
              "customerOverridable": true,
              "active": true
            }
          ]
        }
      ],
      "documentIdentification": {
        "documentNumber": "CX5432112345DS",
        "documentType": "ID_CARD"
      },
      "paymentRequestToken": "string",
      "additionalInformationFieldAssignments": [
        {
          "additionalInformationFieldId": 1234567890,
          "value": "string"
        }
      ]
    }
  }'

Responses

OK

Bodyapplication/json
customerIdinteger(int64)required

Unique ID of the customer

Example: 1000
Response
application/json
{ "customerId": 1000 }

Preview information before adding a contract to an existing customer

Request

Required Scopes: MEMBERSHIP_WRITE

Security
ApiKeyAuth
Path
customerIdinteger(int64)required
Bodyapplication/jsonrequired
contractOfferTermIdinteger(int64)required

Unique ID of the contract offer term

Example: 1000
startDatestring(date)required

The start date of the contract

Example: "2026-02-01"
preuseDatestring(date)

The pre use date of the contract. If not provided, it will be evaluated based on contract offer configuration.

Example: "2026-01-01"
notesstring

The notes related to the contract

Example: "Some notes"
thirdPartyIdstring

Unique ID of the third party contract in the third party system

Example: "1000a"
employeeIdinteger(int64)

Unique ID of the employee who created the membership

Example: 1239812733
referralCodestring

Referral code to link with recruiter

Example: "A500D"
selectedSelectableModuleIdsArray of integers(int64)

The selected modules from the available selectable modules

selectedOptionalModuleIdsArray of integers(int64)

The selected modules from the available optional modules

initialPaymentRequestTokenstring

This token identifies a pre-authorized payment request. It acts as a reference to the payment session initiated by the user. It's not needed for preview endpoints.

Example: "3JtyH5sakfn2V22vB0napNC2zWMlpFwS9gPQawuk7Jw1F00atOD0BA"
contractSignatureobject(Signature)

The signature SVG for the contract document

textBlockSignaturesArray of objects(TextBlockSignature)

Signatures for text blocks

voucherCodestring

An optional code for a voucher. Only credit and discount vouchers are supported.

Example: 123
curl -i -X POST \
  'https://open-api-demo.open-api.perfectgym.com/v1/memberships/customers/{customerId}/add-membership/preview' \
  -H 'Content-Type: application/json' \
  -H 'X-API-KEY: YOUR_API_KEY_HERE' \
  -d '{
    "contractOfferTermId": 1000,
    "startDate": "2026-02-01",
    "preuseDate": "2026-01-01",
    "notes": "Some notes",
    "thirdPartyId": "1000a",
    "employeeId": 1239812733,
    "referralCode": "A500D",
    "selectedSelectableModuleIds": [
      0
    ],
    "selectedOptionalModuleIds": [
      0
    ],
    "initialPaymentRequestToken": "3JtyH5sakfn2V22vB0napNC2zWMlpFwS9gPQawuk7Jw1F00atOD0BA",
    "contractSignature": {
      "base64SvgSignature": "string"
    },
    "textBlockSignatures": [
      {
        "base64SvgSignature": "string",
        "textBlockId": 0
      }
    ],
    "voucherCode": 123
  }'

Responses

OK

Bodyapplication/json
basePriceobject(Money)required

Base price of contract

basePrice.​amountnumberrequired

Amount of the finance data tuple

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

Currency of the finance data tuple

Example: "EUR"
preUseChargeobject(Money)

Charge for the time between the start date of use and start date

voucherTypestring

Type of a voucher, if a valid voucher code has been provided

Enum ValueDescription
CREDIT

Represents a credit voucher

CHECKIN

Represents a check-in voucher

COMPANY_FEE_SPLIT

Represents a company fee split voucher

CONTRACT

Represents a contract voucher

DISCOUNT

Represents a discount voucher

Example: "DISCOUNT"
voucherRemarksstring

Voucher remarks, if a valid voucher code has been provided

Example: "Yoga class not included"
voucherDiscountPeriodsArray of objects(VoucherDiscountPeriod)

List of discount periods for the voucher, if a valid discount voucher code has been provided. Each period has its own discount and effective period.

discountedPreUseChargeobject(Money)

Discounted pre-use charge, if a valid discount voucher code has been provided

creditValueobject(Money)

Voucher credit value, if a valid credit voucher code has been provided

companyFeeSplitTypestring

Type of company fee split (percentage or absolute), if a valid company discount voucher code has been provided

Enum ValueDescription
ABSOLUTE

Represents an absolute discount

PERCENTAGE

Represents a percentage based discount

Example: "ABSOLUTE"
companyFeeSplitValueobject(Money)

Company fee split value, if a valid company discount voucher code has been provided

companyNamestring

Name of the company that will pay the company amount, if a valid company discount voucher code has been provided

Example: "Some company"
companyAmountobject(Money)

Amount the company has to pay, if a valid company discount voucher code has been provided. This field is populated when there are 0 or 1 discount periods. For multiple discount periods, use voucherDiscountPeriods[].companyAmount instead to see amounts per discount period.

memberAmountobject(Money)

Amount the member has to pay, if a valid company discount voucher code has been provided. This field is populated when there are 0 or 1 discount periods. For multiple discount periods, use voucherDiscountPeriods[].memberAmount instead to see amounts per discount period.

companyAmountWithoutDiscountobject(Money)

Amount the company has to pay without discount, if a valid company discount voucher code has been provided

memberAmountWithoutDiscountobject(Money)

Amount the member has to pay without discount, if a valid company discount voucher code has been provided

voucherBonusPeriodobject(MembershipOfferRateBonusPeriod)

Bonus period applied with the discount voucher, if valid a discount voucher has been provided

voucherTextBlocksArray of objects(MembershipOfferTextBlock)

Voucher related text blocks, if a valid voucher code has been provided

flatFeePreviewsArray of objects(FlatFeePreview)

Flat fee previews, including discount if a valid discount voucher code has been provided

voucherSuccessMessagestring

Textual representation of the voucher conditions, if a valid voucher code has been provided

Example: "Voucher code \"123\" successfully applied: 5% discount on the membership fee"
voucherErrorCodestring

An error code, if the voucher code is invalid

ValueDescription
INVALID_CODE

Represents an invalid voucher code

Example: "INVALID_CODE"
ageAdjustedPriceobject(Money)

The adjusted price, if age-based discounts are configured and the customer is eligible, null otherwise

contractVolumeInformationobject(ContractVolume)

Contains the total amount to be paid during the initial runtime of the contract and the average amounts per month and per the rate's payment frequency (e.g. 1 week)

moduleConsentTextBlocksArray of objects(MembershipOfferTextBlock)

Consent texts for modules that are part of the contract

selectedOptionalModulesPreviewsArray of objects(ModuleContractPreview)

Optional module contract preview including discount, company split or credit, if a valid voucher code has been provided

paymentPreviewobject(SignupPaymentPreview)

Detailed payment preview including schedule and due-on-signing amount

voucherEffectivePeriodstringDeprecated

The type of period for which the voucher is applied, if a valid voucher code has been provided. Deprecated: Use voucherDiscountPeriods[].effectivePeriod instead to see periods per discount period.

Enum ValueDescription
TIME_BASED

Represents a voucher with a time based effective period

UNLIMITED

Represents a voucher with unlimited effective period

INITIAL_TERM

Represents a voucher effective during the initial term of the membership

Example: "UNLIMITED"
effectivePeriodTimeBasedTermobject(Term)Deprecated

Effective period: term for which a discount is applied, if type is time based and a valid voucher code has been provided. Deprecated: Use voucherDiscountPeriods[].effectivePeriodTimeBasedTerm instead to see terms per discount period.

discountedBasePriceobject(Money)Deprecated

Discounted base price, if a valid discount voucher code has been provided. Deprecated: Use voucherDiscountPeriods[].discountedBasePrice instead to see prices per discount period.

discountTypestringDeprecated

Type of discount (percentage or absolute), if a valid discount voucher code has been provided. Deprecated: Use voucherDiscountPeriods[].discountType instead to see discount types per discount period.

Enum ValueDescription
ABSOLUTE

Represents an absolute discount

PERCENTAGE

Represents a percentage based discount

Example: "PERCENTAGE"
discountValueobject(Money)Deprecated

Discount value, if a valid discount voucher code has been provided. Deprecated: Use voucherDiscountPeriods[].discountValue instead to see discount values per discount period.

Response
application/json
{ "basePrice": { "amount": 20, "currency": "EUR" }, "preUseCharge": { "amount": 20, "currency": "EUR" }, "voucherType": "DISCOUNT", "voucherRemarks": "Yoga class not included", "voucherEffectivePeriod": "UNLIMITED", "effectivePeriodTimeBasedTerm": { "value": 2, "unit": "WEEK" }, "discountedBasePrice": { "amount": 20, "currency": "EUR" }, "discountType": "PERCENTAGE", "discountValue": { "amount": 20, "currency": "EUR" }, "voucherDiscountPeriods": [ {} ], "discountedPreUseCharge": { "amount": 20, "currency": "EUR" }, "creditValue": { "amount": 20, "currency": "EUR" }, "companyFeeSplitType": "ABSOLUTE", "companyFeeSplitValue": { "amount": 20, "currency": "EUR" }, "companyName": "Some company", "companyAmount": { "amount": 20, "currency": "EUR" }, "memberAmount": { "amount": 20, "currency": "EUR" }, "companyAmountWithoutDiscount": { "amount": 20, "currency": "EUR" }, "memberAmountWithoutDiscount": { "amount": 20, "currency": "EUR" }, "voucherBonusPeriod": { "term": {}, "termStrategy": "CONTRACT_START", "displaySeparately": true, "runtimeExtensionType": "WITH_EXTENSION", "extendsCancellationPeriod": false }, "voucherTextBlocks": [ {} ], "flatFeePreviews": [ {} ], "voucherSuccessMessage": "Voucher code \"123\" successfully applied: 5% discount on the membership fee", "voucherErrorCode": "INVALID_CODE", "ageAdjustedPrice": { "amount": 20, "currency": "EUR" }, "contractVolumeInformation": { "totalContractVolume": {}, "averagePaymentVolumePerMonth": {}, "averagePaymentVolumePerPaymentFrequencyTerm": {} }, "moduleConsentTextBlocks": [ {} ], "selectedOptionalModulesPreviews": [ {} ], "paymentPreview": { "paymentSchedule": [], "dueOnSigningAmount": {} } }

Add a contract to an existing customer

Request

Required Scopes: MEMBERSHIP_WRITE

Security
ApiKeyAuth
Path
customerIdinteger(int64)required
Bodyapplication/jsonrequired
contractOfferTermIdinteger(int64)required

Unique ID of the contract offer term

Example: 1000
startDatestring(date)required

The start date of the contract

Example: "2026-02-01"
preuseDatestring(date)

The pre use date of the contract. If not provided, it will be evaluated based on contract offer configuration.

Example: "2026-01-01"
notesstring

The notes related to the contract

Example: "Some notes"
thirdPartyIdstring

Unique ID of the third party contract in the third party system

Example: "1000a"
employeeIdinteger(int64)

Unique ID of the employee who created the membership

Example: 1239812733
referralCodestring

Referral code to link with recruiter

Example: "A500D"
selectedSelectableModuleIdsArray of integers(int64)

The selected modules from the available selectable modules

selectedOptionalModuleIdsArray of integers(int64)

The selected modules from the available optional modules

initialPaymentRequestTokenstring

This token identifies a pre-authorized payment request. It acts as a reference to the payment session initiated by the user. It's not needed for preview endpoints.

Example: "3JtyH5sakfn2V22vB0napNC2zWMlpFwS9gPQawuk7Jw1F00atOD0BA"
contractSignatureobject(Signature)

The signature SVG for the contract document

textBlockSignaturesArray of objects(TextBlockSignature)

Signatures for text blocks

voucherCodestring

An optional code for a voucher. Only credit and discount vouchers are supported.

Example: 123
curl -i -X POST \
  'https://open-api-demo.open-api.perfectgym.com/v1/memberships/customers/{customerId}/add-membership' \
  -H 'Content-Type: application/json' \
  -H 'X-API-KEY: YOUR_API_KEY_HERE' \
  -d '{
    "contractOfferTermId": 1000,
    "startDate": "2026-02-01",
    "preuseDate": "2026-01-01",
    "notes": "Some notes",
    "thirdPartyId": "1000a",
    "employeeId": 1239812733,
    "referralCode": "A500D",
    "selectedSelectableModuleIds": [
      0
    ],
    "selectedOptionalModuleIds": [
      0
    ],
    "initialPaymentRequestToken": "3JtyH5sakfn2V22vB0napNC2zWMlpFwS9gPQawuk7Jw1F00atOD0BA",
    "contractSignature": {
      "base64SvgSignature": "string"
    },
    "textBlockSignatures": [
      {
        "base64SvgSignature": "string",
        "textBlockId": 0
      }
    ],
    "voucherCode": 123
  }'

Responses

OK

Response
No content

Get all membership switch configurations for a customer

Request

Required Scopes: MEMBERSHIP_READ

Returns all available membership switch configurations for a customer.

Security
ApiKeyAuth
Path
customerIdinteger(int64)required

The ID of the customer to load membership switch configurations for

Query
studioIdinteger(int64)

An optional studio ID to load membership switch configurations for instead of the customer's

curl -i -X GET \
  'https://open-api-demo.open-api.perfectgym.com/v1/memberships/{customerId}/membership-switch/configs?studioId=0' \
  -H 'X-API-KEY: YOUR_API_KEY_HERE'

Responses

OK

Bodyapplication/jsonArray [
idinteger(int64)required

Unique ID of the configuration

Example: 1000
namestringrequired

Name of the configuration

Example: "Premium Membership Upgrade"
presentationobject(MembershipSwitchConfigPresentationDto)required

Presentation details for the membership switch configuration

presentation.​bannerTextstring

Text associated to the configured presentation banner

presentation.​imageUrlstring

Image URL of the presentation banner. It will expire after 15 minutes.

sourceContractsArray of objects(MembershipSwitchConfigSourceContractDto)required

List of source contracts for the membership switch

sourceContracts[].​idinteger(int64)required

Unique ID of the source contract rate

Example: 1000
sourceContracts[].​rateNamestringrequired

Name of the source contract rate

Example: "Basic Membership"
]
Response
application/json
[ { "id": 1000, "name": "Premium Membership Upgrade", "presentation": {}, "sourceContracts": [] } ]

Get membership switch configuration by id for a customer

Request

Required Scopes: MEMBERSHIP_READ

Returns extended information about the membership offer.

Security
ApiKeyAuth
Path
customerIdinteger(int64)required

The ID of the customer to load a membership switch configuration for

configIdinteger(int64)required

The ID of the membership switch configuration

Query
studioIdinteger(int64)

An optional studio ID to validate whether the specified membership switch configuration is available for that studio

curl -i -X GET \
  'https://open-api-demo.open-api.perfectgym.com/v1/memberships/{customerId}/membership-switch/configs/{configId}?studioId=0' \
  -H 'X-API-KEY: YOUR_API_KEY_HERE'

Responses

OK

Bodyapplication/json
idinteger(int64)required

Unique ID of the configuration

Example: 1000
namestringrequired

Name of the configuration

Example: "Premium Membership Upgrade"
presentationobject(MembershipSwitchConfigPresentationDto)required

Presentation details for the membership switch configuration

presentation.​bannerTextstring

Text associated to the configured presentation banner

presentation.​imageUrlstring

Image URL of the presentation banner. It will expire after 15 minutes.

sourceContractsArray of objects(MembershipSwitchConfigSourceContractDto)required

List of source contracts for the membership switch

sourceContracts[].​idinteger(int64)required

Unique ID of the source contract rate

Example: 1000
sourceContracts[].​rateNamestringrequired

Name of the source contract rate

Example: "Basic Membership"
destinationMembershipOffersArray of objects(MembershipOfferExtended)required

List of destination membership offers

destinationMembershipOffers[].​idinteger(int64)required

Unique identifier for the membership offer.

destinationMembershipOffers[].​descriptionstringrequired

Description of the membership offer.

Example: "This offer includes access to all gym facilities and group classes."
destinationMembershipOffers[].​namestringrequired

Name of the membership offer.

Example: "Standard Membership"
destinationMembershipOffers[].​subDescriptionstring

Sub description for the membership offer.

Example: "Best value for regular gym-goers."
destinationMembershipOffers[].​imageUrlstring

Temporary valid download link for rate bundle image. Expires after 2 hours.

Example: "https://example.com"
destinationMembershipOffers[].​footnotestring

Contractual or legal comments to be displayed below the offer.

Example: "This offer is valid for new members only. Terms and conditions apply."
destinationMembershipOffers[].​preUseTypestring(ContractPreUseType)required

Contract pre-use type information.

Enum ValueDescription
CHARGEABLE

Contract pre-use is chargeable

FREE

Contract pre-use is free

NOT_AVAILABLE

Contract is not available for pre-use

destinationMembershipOffers[].​limitedOfferingPeriodobject(DatePeriod)required

Period in which the membership offer is valid.

destinationMembershipOffers[].​limitedOfferingPeriod.​startDatestring(date)required

Start of the interval

Example: "2025-01-01"
destinationMembershipOffers[].​limitedOfferingPeriod.​endDatestring(date)required

End of the interval

Example: "2026-01-01"
destinationMembershipOffers[].​rateCodesArray of objects(RateCode)required

Rate codes of the membership offer.

destinationMembershipOffers[].​rateCodes[].​namestring

The name of the rate code

Example: "Standard Rate"
destinationMembershipOffers[].​rateCodes[].​identifierstring

Unique identifier for the rate code.

Example: "RC12345"
destinationMembershipOffers[].​includedModulesArray of objects(MembershipOfferIncludedModule)required

List of included modules of this membership offer.

destinationMembershipOffers[].​includedModules[].​idinteger(int64)required

Unique identifier for the membership offer module.

Example: 1234567890
destinationMembershipOffers[].​includedModules[].​namestringrequired

Name of the membership offer module.

Example: "Premium Fitness Package"
destinationMembershipOffers[].​includedModules[].​descriptionstringrequired

Description of the membership offer module.

Example: "Includes access to all gym facilities and group classes."
destinationMembershipOffers[].​includedModules[].​imageUrlstring

Image url of membership offer module. Expires after 5hours.

Example: "https://some-module.com"
destinationMembershipOffers[].​includedModules[].​termobject(MembershipOfferModuleTerm)required

Represents the terms of a membership offer.

destinationMembershipOffers[].​includedModules[].​term.​extensionTypestringrequired

Module term extension type

Enum ValueDescription
SUBSEQUENT_RATE_DETAIL

Subsequent rate detail

TERM_EXTENSION

Term extension

NONE

No extension

Example: "TERM_EXTENSION"
destinationMembershipOffers[].​includedModules[].​term.​termobject(Term)

Represents a term

destinationMembershipOffers[].​includedModules[].​term.​termExtensionobject(Term)

Represents a term

destinationMembershipOffers[].​includedModules[].​term.​cancelationPeriodobject(Term)

Represents a term

destinationMembershipOffers[].​includedModules[].​term.​extensionCancelationPeriodobject(Term)

Represents a term

destinationMembershipOffers[].​includedModules[].​trialPeriodobject(MembershipOfferTrialPeriod)

Represents the trial period of a membership offer.

destinationMembershipOffers[].​includedModules[].​consentTextBlockobject(MembershipOfferTextBlock)

Contract text block information.

destinationMembershipOffers[].​includedModules[].​rateCodesArray of objects(RateCode)

Rate codes of the membership offer module.

destinationMembershipOffers[].​contractSignaturesRequiredboolean

Indicates if contract signatures are required for this membership offer.

destinationMembershipOffers[].​allowedPaymentChoicesArray of stringsuniquerequired

Allowed payment choices for this membership offer.

Items Enum ValueDescription
BACS

Payment by BACS direct debit

IDEAL

Payment by ideal

PAYPAL

Payment by paypal

TWINT

Payment by Twint

SEPA

Payment by SEPA direct debit

BANK_TRANSFER

Payment by bank transfer

CH_DD

Payment by CH_DD direct debit

CASH

Payment by cash

BANCONTACT

Payment by bancontact

CREDIT_CARD

Payment by credit card

Example: ["CASH"]
destinationMembershipOffers[].​maximumNumberOfSelectableModulesinteger(int32)

Maximum number of selectableModules for this membership offer. If 0, no modules can be selected.

destinationMembershipOffers[].​contractTextBlocksArray of objects(MembershipOfferTextBlock)required

List of contract text blocks that are part of this membership offer.

destinationMembershipOffers[].​contractTextBlocks[].​idinteger(int64)

The unique identifier of the text block

Example: 1234567890
destinationMembershipOffers[].​contractTextBlocks[].​titlestring

The title of the text block

Example: "Title of 1. text block"
destinationMembershipOffers[].​contractTextBlocks[].​textstring

The text of the text block

Example: "Text of 1. text block"
destinationMembershipOffers[].​contractTextBlocks[].​orderinteger(int32)

The order of the text block in the contract

Example: 1
destinationMembershipOffers[].​contractTextBlocks[].​hasSignatureboolean

Text block configuration has a signature field. You have the option to show a signature input field and it will be added in the contract document. It is not a required field in magicline. It is up to your implementation if you add this field.

destinationMembershipOffers[].​contractTextBlocks[].​showCommunicationPrivacyOptionsboolean

Text block contains information about the communication privacy options. You are advised to show a matrix with communication settings in combination with this text block.

destinationMembershipOffers[].​contractTextBlocks[].​attachmentTypestring

Indicates the type of attachment for this block

Enum ValueDescription
CONTRACT_PDF_PREVIEW

Contract PDF preview

NONE

No text block

FILE

File information available in attachedDocument

URL

Url information available in attachedExternalUrlDto

Example: "CONTRACT_PDF_PREVIEW"
destinationMembershipOffers[].​contractTextBlocks[].​attachedExternalUrlDtoobject(ExternalUrl)

Represents url information.

destinationMembershipOffers[].​contractTextBlocks[].​attachedDocumentobject(AttachedDocument)

Represents document information.

destinationMembershipOffers[].​contractTextBlocks[].​rateBundleModuleIdinteger(int64)

The ID of the associated rate bundle module. Only set if this is a module consent text block.

Example: 1234567890
destinationMembershipOffers[].​contractTextBlocks[].​confirmationRequiredboolean
destinationMembershipOffers[].​selectableModulesArray of objects(MembershipOfferModule)

List of selectable modules for this membership offer. Limited by maximumNumberOfSelectableModules.

destinationMembershipOffers[].​termsArray of objects(MembershipOfferTermExtended)

List of terms that are part of this membership offer.

destinationMembershipOffers[].​timeRestrictionsobject(TimeRestrictions)

Time restrictions for this membership offer based on opening hours categories. Null if no restrictions apply.

Response
application/json
{ "id": 1000, "name": "Premium Membership Upgrade", "presentation": { "bannerText": "string", "imageUrl": "string" }, "sourceContracts": [ {} ], "destinationMembershipOffers": [ {} ] }

Request

Required Scopes: MEMBERSHIP_WRITE

Returns information about an impact of a membership switch of a given contract.

Security
ApiKeyAuth
Path
customerIdinteger(int64)required

The ID of the customer to preview the membership switch for

Query
studioIdinteger(int64)

An optional studio ID to retrieve studio-specific offer information for, such as pricing

Bodyapplication/jsonrequired
configIdinteger(int64)required

Unique ID of the membership switch configuration

Example: 1234567890
membershipOfferTermIdinteger(int64)required

Unique ID of the membership switch offer term

Example: 1234567890
sourceContractIdinteger(int64)required

Unique ID of the contract which is being switched from

Example: 1234567890
startDatestring(date)required

The start date of the contract

Example: "2025-08-24"
notesstring

The notes related to the membership switch

Example: "Some notes"
thirdPartyIdstring

Unique ID of the third party contract in the third party system

Example: "1000a"
selectedSelectableModuleIdsArray of integers(int64)

The selected modules from the available selectable modules

selectedOptionalModuleIdsArray of integers(int64)

The selected modules from the available optional modules

initialPaymentRequestTokenstring

This token identifies a pre-authorized payment request. It acts as a reference to the payment session initiated by the user. It's not needed for preview endpoints.

Example: "3JtyH5sakfn2V22vB0napNC2zWMlpFwS9gPQawuk7Jw1F00atOD0BA"
curl -i -X POST \
  'https://open-api-demo.open-api.perfectgym.com/v1/memberships/{customerId}/membership-switch/preview?studioId=0' \
  -H 'Content-Type: application/json' \
  -H 'X-API-KEY: YOUR_API_KEY_HERE' \
  -d '{
    "configId": 1234567890,
    "membershipOfferTermId": 1234567890,
    "sourceContractId": 1234567890,
    "startDate": "2025-08-24",
    "notes": "Some notes",
    "thirdPartyId": "1000a",
    "selectedSelectableModuleIds": [
      0
    ],
    "selectedOptionalModuleIds": [
      0
    ],
    "initialPaymentRequestToken": "3JtyH5sakfn2V22vB0napNC2zWMlpFwS9gPQawuk7Jw1F00atOD0BA"
  }'

Responses

OK

Bodyapplication/json
contractVolumeInformationobject(ContractVolume)

Contains the total amount to be paid during the initial runtime of the contract and the average amounts per month and per the rate's payment frequency (e.g. 1 week)

ageAdjustedPriceobject(Money)

The price adjusted for the age of the member, if applicable

moduleConsentTextBlocksArray of objects(MembershipOfferTextBlock)

List of contract text blocks that are part of this membership switch.

paymentPreviewobject(SignupPaymentPreview)

Detailed payment preview including schedule and due-on-signing amount

Response
application/json
{ "contractVolumeInformation": { "totalContractVolume": {}, "averagePaymentVolumePerMonth": {}, "averagePaymentVolumePerPaymentFrequencyTerm": {} }, "ageAdjustedPrice": { "amount": 20, "currency": "EUR" }, "moduleConsentTextBlocks": [ {} ], "paymentPreview": { "paymentSchedule": [], "dueOnSigningAmount": {} } }

Request

Required Scopes: MEMBERSHIP_WRITE

Performs the membership switch for a given contract.

Security
ApiKeyAuth
Path
customerIdinteger(int64)required
Bodyapplication/jsonrequired
configIdinteger(int64)required

Unique ID of the membership switch configuration

Example: 1234567890
membershipOfferTermIdinteger(int64)required

Unique ID of the membership switch offer term

Example: 1234567890
sourceContractIdinteger(int64)required

Unique ID of the contract which is being switched from

Example: 1234567890
startDatestring(date)required

The start date of the contract

Example: "2025-08-24"
notesstring

The notes related to the membership switch

Example: "Some notes"
thirdPartyIdstring

Unique ID of the third party contract in the third party system

Example: "1000a"
selectedSelectableModuleIdsArray of integers(int64)

The selected modules from the available selectable modules

selectedOptionalModuleIdsArray of integers(int64)

The selected modules from the available optional modules

initialPaymentRequestTokenstring

This token identifies a pre-authorized payment request. It acts as a reference to the payment session initiated by the user. It's not needed for preview endpoints.

Example: "3JtyH5sakfn2V22vB0napNC2zWMlpFwS9gPQawuk7Jw1F00atOD0BA"
curl -i -X POST \
  'https://open-api-demo.open-api.perfectgym.com/v1/memberships/{customerId}/membership-switch' \
  -H 'Content-Type: application/json' \
  -H 'X-API-KEY: YOUR_API_KEY_HERE' \
  -d '{
    "configId": 1234567890,
    "membershipOfferTermId": 1234567890,
    "sourceContractId": 1234567890,
    "startDate": "2025-08-24",
    "notes": "Some notes",
    "thirdPartyId": "1000a",
    "selectedSelectableModuleIds": [
      0
    ],
    "selectedOptionalModuleIds": [
      0
    ],
    "initialPaymentRequestToken": "3JtyH5sakfn2V22vB0napNC2zWMlpFwS9gPQawuk7Jw1F00atOD0BA"
  }'

Responses

OK

Response
No content
Operations
Operations

Trial Offers

Get trial offers information

Operations