Coder Social home page Coder Social logo

cozy-konnector-trainline's Introduction

Cozy Trainline Konnector

What's Cozy?

Cozy Logo

Cozy is a platform that brings all your web services in the same private space. With it, your webapps and your devices can share data easily, providing you with a new experience. You can install Cozy on your own hardware where no one's tracking you.

What's this new konnector?

This is a cozy konnector which fetch trainline travels bills and bills data

Open a Pull-Request

If you want to work on this konnector and submit code modifications, feel free to open pull-requests! See the [contributing guide][contribute] for more information about how to properly open pull-requests.

Run

If you have a running accessible cozy-stack you can test your the konnector without installing and/or updating the konnector in the cozy-stack :

You first need an installed nodejs (LTS version is fine)

Then just run (but you have to have proper COZY_CREDENTIALS, COZY_URL and COZY_FIELDS environment variables):

npm install
npm start

Test

If you do not want to have to install the konnector on a cozy v3 to test it, you can register the konnector as an OAuth application with the following commands :

npm install
npm run dev

This command will register your konnector as an OAuth application to the cozy-stack. By default, the cozy-stack is supposed to be located in http://cozy.tools:8080. If this is not your case, just update the COZY_URL field in ./data/env.js.

After that, your konnector is run but should not work since you did not specify an credentials to the target service. You can also do this in ./data/env.js by modifying the COZY_FIELDS attribute which is a JSON string.

Now run npm run dev one more time, you dont have to do the Oauth thing now, and it should be ok

Hack

If you do not want to need to have an accessible cozy-stack, just run :

npm install
npm run standalone

The requests to the cozy stack will be stubbed using the ./data/fixture.json file as source of data and when cozy-client-js is asked to create or update data, the data will be output to the console. The bills (or any file) will be saved in the ./data directory

Maintainer

The lead maintainers for this konnector is

Get in touch

You can reach the Cozy Community by:

License

Trainline Konnector is developed by and distributed under the AGPL v3 license.

cozy-konnector-trainline's People

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.