1.4.5 • Published 2 years ago

domoja-freebox v1.4.5

Weekly downloads
1
License
GPL-3.0
Repository
github
Last release
2 years ago

NPM

NPM version Node.js CI CodeQL Coverage Status

domoja-freebox

Connect a Freebox to Domoja.

Usage

imports:
  - module: freebox
    source: Freebox

sources:
  - freebox: {
    type: Freebox,
    URL: "http://mafreebox.freebox.fr",
    app_token: "app_token"
  }

devices:
    - last-call: { type: sensor, widget: text, tags: 'calls', source: freebox, id: '/call/log/', transform: !!js/function 'function (value) { 
      if (!value) return value; 
      let tab = JSON.parse(value);
      if (tab.length>0)
        return tab[0].number==""?"Inconnu":tab[0].number;
      else
        return "";
    }', name: "Last call" }

Application registration

It is mandatory to register Domoja as a Freebox application. For this, run the following command on the same network as the Freebox, and accept the request on the LCD of the Freebox:

$ curl http://mafreebox.freebox.fr/api/v1/login/authorize -d '{"app_id":"domoja","app_name":"Freebox Module","app_version":"0.0.1","device_name":"Domoja"}'

Keep track of the app_token and of the track_id.

To finalize the approval, you must acknowledge through by visiting the following URL (use the provided track_id):

http://mafreebox.freebox.fr/api/v8/login/authorize/{track_id}

You can then insert app_token in your configuration file.

If you have no access to curl, you can make use of the iCurlHTTP app when connected to the Freebox with the WiFi.

The list of available apis can be found here: http://mafreebox.freebox.fr/doc/index.html

1.4.5

2 years ago

1.4.3

2 years ago

1.4.2

2 years ago

1.4.1

3 years ago

0.0.3

3 years ago

0.0.2

4 years ago

0.0.1

4 years ago