/users

GET /users

Verifies that the given userId exists in Club OS and you have access to it.  

GET https://api.club-os.com/users?clubLocationId=[clubLocationId]&userId=[userId]

Parameters

The following fields must be included as parameters in the URL of the request.

VariableTypeDescription
clubLocationIdIntegerThe Club OS unique id for the club location you wish to access. Club OS will provide these to you.
userIdIntegerThe Club OS unique id for the user you are requesting.
Response Message

The following message will be returned when the request succeeds.

MessageDescription
User was foundThe user was found and you have access to them.

POST /users

Add a user to the system.

POST https://api.club-os.com/users?clubLocationId=[clubLocationId]

Parameters

The following fields must be included as parameters in the URL of the request.

VariableTypeDescription
clubLocationIdIntegerThe Club OS unique id for the club location you wish to access. Club OS will provide these to you.
Request Body

The following fields must be included in the body of the HTTP request as a valid JSON string.

PropertyTypeRequiredDefaultDescription
roleStringY One of 'member', 'trainer', 'salesperson', 'manager', or 'frontdesk'.
fullAccountBooleanYfalse

Club OS has 2 types of member accounts, Full and Basic. Full means they get access to both nutrition and/or workout features based on the club's service plan.

false - Make the member a Basic account.

true - Make the member a Full account.

sendEmailBooleanYfalseIf true, sends a welcome email to the member if they are created successfully and an email address was sent.
trainerIdIntegerN The Club OS unique id for the trainer of the user being added or updated.
salespersonIdIntegerN The Club OS unique id for the salesperson of the user being added or updated (applies to members only).
templateUsernameStringN The username of the template account that should be applied to the user (applies to members only).
localUserIdStringY Your systems unique id for the user.
firstNameStringY User first name.
lastNameStringN User last name.
emailStringN Email address of the user. This will also be the username for the Club OS account if no username if provided.
usernameStringN Username of the user. This will be used to login to the system.
passwordStringN Password for the account. If left blank, one will be auto-generated.
genderStringY 'M' for male, 'F' for female.
birthDateDate (M-d-YYYY)N User date of birth.
joinDateDate (M-d-YYYY)N The date the User joined the club.
guestPassStartDate (M-d-YYYY)N The start date of the user's guest pass.
guestPassEndDate (M-d-YYYY)N The end date of the users's guest pass.
homePhoneStringN User home phone number.
workPhoneStringN User work phone number.
mobilePhoneStringN User mobile phone number.
address1StringN User address line 1.
address2StringN User address line 2.
cityStringN User full city.
stateStringN User 2 letter state code, i.e. PA for Pennsylvania.
zipStringN User zip code.
Response Messages

One of the following messages will be returned when the request succeeds.

MessageDescription
Member CreatedMember account successfully created.
Member FoundMember account exists in the system already.
Trainer CreatedTrainer account was successfully created.
Trainer FoundTrainer account exists in the system already.
Salesperson CreatedSalesperson account successfully created.
Salesperson FoundSalesperson account exists in the system already.

PUT /users

Update a users account type and deleted status. If the user has been previously deleted, they will be undeleted after a successful PUT request.

PUT https://api.club-os.com/users?clubLocationId=[clubLocationId]

Parameters

The following fields must be included as parameters in the URL of the request.

VariableTypeDescription
clubLocationIdIntegerThe Club OS unique id for the club location you wish to access. Club OS will provide these to you.
Request Body

Any of the fields below may be included in the body of the HTTP request as a valid JSON string.  Only fields included in the request will be updated.  For example, if you only want to update the first and last name, the JSON should be { userId: "clubOsUserId", firstName: "newFirstName", lastName: "newLastName"}

PropertyTypeRequiredDefaultDescription
userIdIntegerY The Club OS unique id for the member to update.
firstNameStringN User first name.
lastNameStringN User last name.
emailStringN Email address of the user. This will also be the username for the Club OS account. If left blank, the user will not be able to login to Club OS.
homePhoneStringN User home phone number.
workPhoneStringN User work phone number.
mobilePhoneStringN User mobile phone number.
address1StringN User address line 1.
address2StringN User address line 2.
cityStringN User full city.
stateStringN User 2 letter state code, i.e. PA for Pennsylvania.
zipStringN User zip code.
fullAccountBooleanYfalse

Club OS has 2 types of member accounts, Full and Basic. Full means they get access to both nutrition and/or workout features based on the club's service plan. This field only applies to member accounts.

false - Make the member a Basic account.

true - Make the member full account.

guestPassStartDate (M-d-YYYY)N The start date of the user's guest pass. Only saved if present, i.e. NULL or "" value will not update the record in Club OS.
guestPassEndDate (M-d-YYYY)N The end date of the users's guest pass. Only saved if present, i.e. NULL or "" value will not update the record in Club OS.
joinDateDate (M-d-YYYY)N The date the User joined the club.
Response Messages

One of the following messages will be returned when the request succeeds.

MessageDescription
<name> was made FULLThe account was made FULL.
<name> was made BASICThe account was made BASIC.

DELETE /users

Delete a users account from Club OS.

DELETE https://api.club-os.com/users?clubLocationId=[clubLocationId]&userId=[userId]

Parameters

The following fields must be included as parameters in the URL of the request.

VariableTypeDescription
clubLocationIdIntegerThe Club OS unique id for the club location you wish to access. Club OS will provide these to you.
userIdIntegerThe Club OS unique id for the user you are deleting.
Response Messages

The following message will be returned when the request succeeds.

MessageDescription
<name> was deletedThe account was made deleted.