TMC is an independent, primarily volunteer organization that relies on ad revenue to cover its operating costs. Please consider whitelisting TMC on your ad blocker and becoming a Supporting Member. For more info: Support TMC

Tesla API Call in cURL -- Help Please

Discussion in 'Model S: User Interface' started by 1NJ85D, Oct 22, 2015.

  1. 1NJ85D

    1NJ85D Member

    Joined:
    Feb 26, 2015
    Messages:
    93
    Location:
    Scotch Plains, NJ
    I'm trying to use cURL to do the authentication and get an access token but have been unable to get the proper format together. I am trying:

    curl -H "Content-Type: application/json" -d {"grant_type" : "password", "client_id" : "***", "client_secret" : "***", "email" : "***", "password" : "***" } https://owner-api.teslamotors.com/oauth/token

    Any help would be much appreciated.

    Thanks!
     
  2. cryptyk

    cryptyk Member

    Joined:
    Jul 8, 2015
    Messages:
    346
    Location:
    United States
    Courtesy of the evMote "team" ;)

    curl --include --data "grant_type=password&client_id=xxxxxxxxxxx&client_secret=xxxxxxxx&[email protected]&password=xxxxxxxxx" --request POST 'https://owner-api.teslamotors.com/oauth/token'
     

Share This Page

  • About Us

    Formed in 2006, Tesla Motors Club (TMC) was the first independent online Tesla community. Today it remains the largest and most dynamic community of Tesla enthusiasts. Learn more.
  • Do you value your experience at TMC? Consider becoming a Supporting Member of Tesla Motors Club. As a thank you for your contribution, you'll get nearly no ads in the Community and Groups sections. Additional perks are available depending on the level of contribution. Please visit the Account Upgrades page for more details.


    SUPPORT TMC