Skip to content

Instantly share code, notes, and snippets.

View jorenvandeweyer's full-sized avatar

Joren Vandeweyer jorenvandeweyer

View GitHub Profile
@jorenvandeweyer
jorenvandeweyer / tesla-oauth-v3.ts
Created January 31, 2021 12:29
NodeJS (TS) Implementation for /oauth2/v3 (with optional MFA)
/* eslint-disable camelcase */
import axios, { AxiosInstance, AxiosResponse } from 'axios'
import crypto from 'crypto'
import qs from 'querystring'
import URLSafeBase64 from 'urlsafe-base64'
import cryptoRandomString from 'crypto-random-string'
import { Cookie, CookieJar } from 'tough-cookie'
import { EventEmitter } from 'events'
interface OAuthParameters {
@jorenvandeweyer
jorenvandeweyer / ski_track.csv
Created April 7, 2018 20:51
longitude, latitude, altitude(m), time, speed(km/h)
We can't make this file beautiful and searchable because it's too large.
45.3179580,6.5477440,2028.66,2018-04-01T12:33:39Z
45.3178380,6.5478220,1994.43,2018-04-01T12:36:18Z,0.8433518145515436
45.3177120,6.5478590,1992.37,2018-04-01T12:36:20Z,26.045179526896153
45.3175680,6.5478750,1989.78,2018-04-01T12:36:22Z,29.315021650956638
45.3174300,6.5478570,1987.40,2018-04-01T12:36:24Z,28.096348771628513
45.3172550,6.5478220,1982.70,2018-04-01T12:36:26Z,36.40728297874478
45.3171640,6.5478260,1980.20,2018-04-01T12:36:27Z,37.57931538802937
45.3168810,6.5476010,1978.03,2018-04-01T12:36:31Z,32.54189250379977
45.3167610,6.5471690,1977.60,2018-04-01T12:36:35Z,32.72545828871679
45.3165260,6.5470550,1973.87,2018-04-01T12:36:39Z,25.101710007545876