API Reference

Summary

The API is made up of three endpoints:

  1. Validate Use: This endpoint validates the user's daily token for use with the gym's API;
  2. Token Use: This endpoint validates the user's daily token and check-in and, if valid, allows the user to enter the gym;
  3. Beneficiary Code: This endpoint returns the user's code.

The image below shows the process of a user entering a gym using the Totalpass app. The process involves the Validate Use and Token Use endpoints. Only the Token Use endpoint is mandatory to release the turnstile.

Context

The Validate Use and Token Use endpoints are useful for businesses that want to integrate their access control systems with Totalpass. The process described in the image allows users to enter gyms using the Totalpass app without the need to provide documents or other information.

How it works

To use the Validate Use and Token Use endpoints, you will need to integrate your API with the Totalpass API.

The Token Use endpoint is mandatory to release the turnstile. When a user wants to join your gym, they will need to open the Totalpass app in person, select the gym and check in. To allow the user to enter your gym, the user's daily token must be used. Thus, the gym`s ERP will send the document/code/token to the Token Use endpoint, which will validate the token and the check-in and, if valid, allow the user to enter the gym.

The Validate Use endpoint is optional. It's faster to respond and will only check if the user's daily token is valid. It will not use the user's token, nor will it validate that check-in has occurred.

Benefits

Using the Validate Use and Token Use endpoints offers several benefits, including:

  • Increased security: The use of tokens helps to prevent unauthorized access to your gym.
  • Improved convenience: Users can enter your gym without the need to provide documents or other information.
  • Reduced costs: You can save money by making the user input process more efficient.

Conclusion

The Validate Use and Token Use endpoints are a powerful tool that can help you improve the security, convenience, and cost-effectiveness of your access control system.

Additional Information

The following are some additional things to keep in mind when using the Validate Use and Token Use endpoints:

  • You can only use the Validate Use and Token Use endpoints if you have integrated your API with the Totalpass API.
  • The Validate Use endpoint will only check if users have a valid subscription.
  • The Token Use endpoint will only allow users to enter your gym if the token is valid and has not expired.

Troubleshooting

If you are experiencing problems with the Validate Use or Token Use endpoints, you can refer to the Totalpass documentation for troubleshooting tips.

Contact Information

If you have any questions about the Validate Use or Token Use endpoints, you can contact Totalpass support: