v3: info about API v3

This commit is contained in:
Matteo Pagliazzi 2016-05-18 15:49:58 +02:00
parent 034e464bf2
commit 4b81c97bfc
3 changed files with 8 additions and 2 deletions

View file

@ -1,5 +1,5 @@
{
"name": "habitrpg",
"name": "habitica",
"description": "A habit tracker app which treats your goals like a Role Playing Game.",
"version": "3.0.0",
"main": "./website/server/index.js",

View file

@ -48,7 +48,9 @@ footer.footer(ng-controller='FooterCtrl')
li
a(target='_blank', href='https://trello.com/c/odmhIqyW/440-read-first-table-of-contents')=env.t('communityFeature')
li
a(target='_blank', href='https://habitica.com/static/api')=env.t('API')
a(target='_blank', href='/apidoc')=env.t('API v3')
li
a(target='_blank', href='/static/api-v2')=env.t('API v2 - Deprecated')
li
a(href='http://habitica.wikia.com/wiki/App_and_Extension_Integrations', target='_blank')=env.t('communityExtensions')
li

View file

@ -75,6 +75,10 @@ html
//.input
a#explore(href='#') Explore
br
h2 API v3
p This page contains documentation for version 2 of Habitica's API. A <strong>new API version</strong>, the third, has been released and its documentation can be found <a href="/apidoc">here</a> and an introductory blog post with the most important changes <a href="http://devs.habitica.com">here</a>.
p API v2 is still available to give time to developers to port their apps and integration to the new API but it's considered <strong>deprecated</strong> and should not be used for new projects. It'll be completely retired shortly.
br
h2 Two API Types
p Habitica's API is meant for two different audiences: (1) extensions and scripts, and (2) full-fledged applications. Extensions and scripts can utilize Habitica's up/down scoring for individual tasks. An example of this in action is the <a href="https://chrome.google.com/webstore/detail/habitrpg/pidkmpibnnnhneohdgjclfdjpijggmjj?hl=en-US">Chrome Extension</a>, which up-scores you for visiting productive websites, and down-scores you for visiting procrastination websites. Other examples currently in use are Pomodoro, Anki, and Github scripts - which up-score you for good behavior and downscore you for bad behavior - <a href="http://habitica.wikia.com/wiki/App_and_Extension_Integrations">see the list</a>. The second API consumer is for full-fledge applications, which need read / write access to the entire user document. An example of this would be Mobile Apps or Desktop application.
h2 Extensions / Scripts