Hey @altaf,
We have API documentation available here: https://api.mattermost.com/
Note that not all the endpoints are documented yet.
We're also in the process of moving to API v4, which will be fully documented when released on March 16, 2017. https://forum.mattermost.org/t/mattermost-moving-to-api-version-4/2830