Salesforce Chat Button Availability using REST API

https://hostname/chat/rest/Visitor/Availability can used to find whether a Chat Button is available to receive new incoming Chat Requests in Salesforce.

1. Go to Chat Settings in Salesforce Setup.

2. Copy the "Chat API Endpoint" URL.

Add Visitor/Availability to the end of the URL.

3. Do a GET Call to find the availability.