Customer Updated V1

View JSON Schema

A message that is sent when a customer is updated. The message contains information about the customer, the customer categories, the customer memberships and the facility that the customer was updated for. This event is triggered when a customer is updated. It is only sent for customers that have an email address, a first name and a last name. This is data part of the message please read the event section for more information of the metadata envelop.

Properties

NameTypeTitleDescriptionRequired
customerobjectCustomerCustomer informationyes
customerCategoriesobject[]CustomerCategoriesList of customer categoriesno
customerMembershipsobject[]CustomerMembershipsThe customer’s active membership, if any. The list holds at most one membership.no
facilityobjectFacilityFacility informationyes

Example

{
    "customer": {
        "customerId": "12345",
        "userId": "123e4567-e89b-12d3-a456-426614174000",
        "firstName": "John",
        "lastName": "Doe",
        "email": "john.doe@example.com",
        "address": "123 Main St",
        "city": "Anytown",
        "zipcode": "12345",
        "country": "USA",
        "nationality": "American",
        "cellphone": "+1234567890",
        "telephone": "+0987654321",
        "dateOfBirth": "1980-01-01",
        "gender": "MALE",
        "isOrganization": false,
        "doNotEmail": true,
        "registrationDate": "2023-01-01T12:00:00+01:00"
    },
    "customerCategories": [
        {
            "categoryId": "cat123",
            "categoryName": "Premium"
        }
    ],
    "customerMemberships": [
        {
            "membershipId": "mem123",
            "membershipName": "Gold"
        }
    ],
    "facility": {
        "facilityId": "2344123",
        "facilityName": "Matchi Tennis Club"
    }
}

 

customer: Customer

Customer information

Properties

NameTypeTitleDescriptionRequired
customerIdstringCustomer IDA unique identifier for the customer.yes
userIdstringUser IDThe MATCHi user id of the account linked to this customer, present only while the customer is linked to an account. The link can be removed (for example when the customer is archived) or replaced, so read it from each event. Booking events can carry a different userId for the same person (see Player and Owner), so do not join events on userId alone.Format: "uuid"no
firstNamestringFirst NameThe first name of the customer.no
lastNamestringLast NameThe last name of the customer.no
emailstringEmailThe email address of the customer, in a valid email format.Format: "email"no
addressstringAddressThe street address of the customer.no
citystringCityThe city where the customer resides.no
zipcodestringZipcodeThe postal code of the customer’s address.no
countrystringCountryThe country where the customer resides.no
nationalitystringNationalityThe nationality of the customer.no
cellphonestringCellphoneThe cellphone number of the customer.no
telephonestringTelephoneThe telephone number of the customer.no
dateOfBirthstringDate of BirthThe date of birth of the customer, in YYYY-MM-DD format.Format: "date"no
genderstringGenderThe gender of the customer: MALE, FEMALE, OTHER or NOT_SPECIFIED. Absent for organizations.no
isOrganizationbooleanIs OrganizationIndicates whether the customer is an organization.no
doNotEmailbooleanDo Not EmailIndicates whether the customer should not receive emails from facility.no
registrationDatestringRegistration DateThe date and time when the customer registered, in ISO 8601 format. The time is the facility’s local time, with its UTC offset included.Format: "date-time"no

Example

{
    "customerId": "12345",
    "userId": "123e4567-e89b-12d3-a456-426614174000",
    "firstName": "John",
    "lastName": "Doe",
    "email": "john.doe@example.com",
    "address": "123 Main St",
    "city": "Anytown",
    "zipcode": "12345",
    "country": "USA",
    "nationality": "American",
    "cellphone": "+1234567890",
    "telephone": "+0987654321",
    "dateOfBirth": "1980-01-01",
    "gender": "MALE",
    "isOrganization": false,
    "doNotEmail": true,
    "registrationDate": "2023-01-01T12:00:00+01:00"
}

 

customerCategories[]: CustomerCategories

List of customer categories

Items: CustomerCategory

Customer category information

Item Properties

NameTypeTitleDescriptionRequired
categoryIdstringCategory IDA unique identifier for the customer category.yes
categoryNamestringCategory NameThe name of the customer category.yes

Example

[
    {
        "categoryId": "cat123",
        "categoryName": "Premium"
    }
]

 

customerMemberships[]: CustomerMemberships

The customer’s active membership, if any. The list holds at most one membership.

Items: CustomerMembership

Customer membership information

Item Properties

NameTypeTitleDescriptionRequired
membershipIdstringMembership IDA unique identifier for the membership.yes
membershipNamestringMembership NameThe name of the membership.yes

Example

[
    {
        "membershipId": "mem123",
        "membershipName": "Gold"
    }
]

 

facility: Facility

Facility information

Properties

NameTypeTitleDescriptionRequired
facilityIdstringFacility IDA unique identifier for the facility.yes
facilityNamestringFacility NameThe name of the facility.yes

Example

{
    "facilityId": "2344123",
    "facilityName": "Matchi Tennis Club"
}