npm install bts> NOTE: This package is not ready yet. Some things do NOT work atm!
``shell`
npm install bts -g
We recommend installing bts server globally since this seperates your config away from bts itself + is easy to update
package available on npm that handles requests and json parsing for you.
In general an API request looks like this:
GET /someappdomain.com/userId/
Note: You have to specify your long lived bts access token in the header for authentication.The response will be a json string as body:
`json
{
"btId":"someInternalBtsId",
"btUserLink":"https://bill.today/someappdomain.com/someInternalBtsId",
"userId":"userId",
"userEmail":"mail@example.com",
"status":"ok",
"statusMessage":"Everything ok!",
"subscribed":true,
"subscribedUntil":"2030-12-01",
"plan":"pro"
}
``