Python client for Toyota North America service API

Overview

toyota-na

Python client for Toyota North America service API

Install

pip install toyota-na[qt]

[qt] is required for generating authorization code.

Usage

python -m toyota_na.app -h  # Get help
python -m toyota_na.app get_user_vehicle_list  # List vehicle
python -m toyota_na.app get_vehicle_status 
   
      # Get vehcicle status
...

   

Developer Guide

Quick Start

from toyota_na.client import ToyotaOneClient
cli = ToyotaOneClient()
cli.auth.login()
vehicle_list = cli.get_user_vehicle_list()
vehicle_status = cli.get_vehicle_status(vehicle_list[0]["vin])
...

About authorization

Toyota OAuth2 service require the redirect_uri to be "com.toyota.oneapp:/oauth2Callback". we need to mock this app. We use PyQt5 to intercept the redirection in this module. Qt5 application can not be launched in a server side setup, such as Home Assistant. Alternatively, the login can be separated to two steps here:

  1. Get the authorization code (requires Qt5)
  2. Use the code to retrieve the tokens

To get the authorization code:

python -m toyota_na.app authorize

To use the authorization code:

  • In python code:
from toyota_na.client import ToyotaOneClient
cli = ToyotaOneClient()
cli.auth.login(authorization_code)
  • In CLI:
python -m toyota_na.app authorize 
   

   

Samples

Sample responses from API calls are stored in samples folder. The data is from Toyota app's "Demo Mode"

You might also like...
An API wrapper for the file.io web service.

🗃️ File.io An API wrapper for the file.io web service. Install $ pip3 install fileio or

Mazda Connected Service API wrapper based on pymazda and Flask.

Mazda Connected Service Relay Mazda Connected Service API wrapper based on pymazda and Flask. Usage Make POST calls to https://mymazda.herokuapp.com/{

Official Python client for the MonkeyLearn API. Build and consume machine learning models for language processing from your Python apps.

MonkeyLearn API for Python Official Python client for the MonkeyLearn API. Build and run machine learning models for language processing from your Pyt

🖥️ Python - P1 Monitor API Asynchronous Python Client

🖥️ Asynchronous Python client for the P1 Monitor

Python API Client for Close

Close API A convenient Python wrapper for the Close API. API docs: http://developer.close.com Support: [email protected] Installation pip install clos

Python client for CoinPayments API

pyCoinPayments - Python API client for CoinPayments Updates This library has now been converted to work with python3 This is an unofficial client for

DEPRECATED - Official Python Client for the Discogs API

⚠️ DEPRECATED This repository is no longer maintained. You can still use a REST client like Requests or other third-party Python library to access the

The Foursquare API client for Python

foursquare Python client for the foursquare API. Philosophy: Map foursquare's endpoints one-to-one Clean, simple, Pythonic calls Only handle raw data,

Python Client for Instagram API

This project is not actively maintained. Proceed at your own risk! python-instagram A Python 2/3 client for the Instagram REST and Search APIs Install

Releases(v2.1.1)
  • v2.1.1(May 1, 2022)

  • v2.1.0(May 1, 2022)

    What's Changed

    • refactor: use poetry by @vanstinator in https://github.com/toyotha/toyota-na/pull/26
    • fix: hack around support for mm21 vehicles by @vanstinator in https://github.com/toyotha/toyota-na/pull/25

    Full Changelog: https://github.com/toyotha/toyota-na/compare/v2.0.3...v2.1.0

    Source code(tar.gz)
    Source code(zip)
  • v2.0.3(Apr 9, 2022)

    What's Changed

    • Better check around generations by @jlmaners in https://github.com/toyotha/toyota-na/pull/24

    Full Changelog: https://github.com/toyotha/toyota-na/compare/v2.0.2...v2.0.3

    Source code(tar.gz)
    Source code(zip)
  • v2.0.2(Apr 8, 2022)

    What's Changed

    • feat: publish a release build when pushing a release on github by @vanstinator in https://github.com/toyotha/toyota-na/pull/23
    • Skip attempt to add vehicle if not one of matching generations by @jlmaners in https://github.com/toyotha/toyota-na/pull/22

    Full Changelog: https://github.com/toyotha/toyota-na/compare/v2.0.1...v2.0.2

    Source code(tar.gz)
    Source code(zip)
  • v2.0.1(Apr 6, 2022)

    What's Changed

    • fix: missing quote in quick start by @MrReBot in https://github.com/toyotha/toyota-na/pull/17
    • fix: stop pinning pyjwt and crypto deps

    New Contributors

    • @MrReBot made their first contribution in https://github.com/toyotha/toyota-na/pull/17

    Full Changelog: https://github.com/toyotha/toyota-na/compare/v2.0.0...v2.0.1

    Source code(tar.gz)
    Source code(zip)
  • v2.0.0(Mar 11, 2022)

  • v1.1.0(Jan 19, 2022)

    Add support for send_refresh_status Add support for remote_request (tested with door-lock, door-unlock)

    Thanks for @JiDoan at https://github.com/widewing/toyota-na/pull/3 !

    Source code(tar.gz)
    Source code(zip)
Owner
Gavin Ni
Gavin Ni
pyhakuna is a client to access the API of the time keeping service hakuna.ch.

pyhakuna pyhakuna is a client to access the API of the time keeping service hakuna.ch. The Hakuna API is – unfortunately – personal and currently does

Christian Mäder 1 Feb 15, 2022
wyscoutapi is an extremely basic API client for the Wyscout API (v2 & v3) for Python

wyscoutapi wyscoutapi is an extremely basic API client for the Wyscout API (v2 & v3). Usage Install with pip install wyscoutapi. To connect to the Wys

Ben Torvaney 11 Nov 22, 2022
Beyonic API Python official client library simplified examples using Flask, Django and Fast API.

Beyonic API Python official client library simplified examples using Flask, Django and Fast API.

Harun Mbaabu Mwenda 46 Sep 1, 2022
Python API Client for Twitter API v2

?? Python Client For Twitter API v2 ?? Why Twitter Stream ? Twitter-Stream.py a python API client for Twitter API v2 now supports FilteredStream, Samp

Twitivity 31 Nov 19, 2022
Dns-Client-Server - Dns Client Server For Python

Dns-client-server DNS Server: supporting all types of queries and replies. Shoul

Nishant Badgujar 1 Feb 15, 2022
Raphtory-client - The python client for the Raphtory project

Raphtory Client This is the python client for the Raphtory project Install via p

Raphtory 5 Apr 28, 2022
Drcom-pt-client - Drcom Pt version client with refresh timer

drcom-pt-client Drcom Pt version client with refresh timer Dr.com Pt版本客户端 可用于网页认

null 4 Nov 16, 2022
Python bindings for Alexa Web Information Service (AWIS) API

Attention! This package is no longer maintained. See this ticket for more info. Wraps Alexa Web Information Service. Usage Making UrlInfo requests: ap

Atamert Ölçgen 51 Feb 12, 2022
:globe_with_meridians: A Python wrapper for the Geocodio geolocation service API

Py-Geocodio Python wrapper for Geocodio geocoding API. Full documentation on Read the Docs. If you are upgrading from a version prior to 0.2.0 please

Ben Lopatin 84 Aug 2, 2022
Design and build a wrapper for the Open Weather API current weather data service

Design and build a wrapper for the Open Weather API current weather data service that returns a city's temperature, with caching, also allowing for the temperature of the latest queried cities that are still validly cached to be retrieved.

Duan Rafael Ribeiro 1 Jun 27, 2022