Coder Social home page Coder Social logo

irkit-gas's Introduction

IRKit-GAS

Google Assistant -> IFTTT -> GAS -> IRKitで家電をリモコン操作するためのスクリプト。 @howdy39様のgas-clasp-starterをお借りしています。

Getting Started

Clone the repository

git clone https://github.com/s-higuma/irkit-gas.git
cd irkit-gas

Install dependencies

npm install

Configuration

Rename .clasp.json.sample to .clasp.json

Open .clasp.json, change scriptId

What is scriptId ? https://github.com/google/clasp#scriptid-required

{
  "scriptId": <your_script_id>,
  "rootDir": "dist"
}

Open src/appsscript.json, change timeZone (optional)

Apps Script Manifests

{
  "timeZone": "Asia/Tokyo", ## Change timeZone
  "dependencies": {
  },
  "webapp": {
    "access": "ANYONE_ANONYMOUS",
    "executeAs": "USER_DEPLOYING"
  },
  "exceptionLogging": "STACKDRIVER",
  "executionApi": {
    "access": "ANYONE"
  }
}

Rename src/config.json.sample to src/config.json

Open src/config.json, change google spread sheet id, clientkey, deviceid

{
    "sheet_id": "<your google spread sheet id>",
    "post_url": "https://api.getirkit.com/1/messages",
    "clientkey": "<your irkit clientkey>",
    "deviceid": "<your irkit deviceid>"
}
How to get clientkey and deviceid

Go https://getirkit.com/ and check POST /1/keys API

Development and build project

npm run build

Push

clasp push

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.