Skip to content

Commit

Permalink
Merge pull request #185 from itchannel/1.32-beta
Browse files Browse the repository at this point in the history
1.32 beta
  • Loading branch information
itchannel authored Jun 22, 2022
2 parents 849071b + 776a788 commit 346425b
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 16 deletions.
6 changes: 1 addition & 5 deletions .github/workflows/combined.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,4 @@ jobs:
- uses: hacs/action@main
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CATEGORY: integration
- uses: KTibow/ha-blueprint@stable
name: CI
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CATEGORY: integration
10 changes: 5 additions & 5 deletions custom_components/fordpass/fordpass_new.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,11 +82,11 @@ def auth(self):
if r.status_code == 200:
_LOGGER.debug("Succesfully fetched token Stage1")
result = r.json()
data = {"code": result["access_token"]}
data = {"ciToken": result["access_token"]}
headers = {**apiHeaders, "Application-Id": self.region}
# Fetch OAUTH token stage 2 and refresh token
r = session.put(
"https://api.mps.ford.com/api/oauth2/v1/token",
r = session.post(
"https://api.mps.ford.com/api/token/v2/cat-with-ci-access-token",
data=json.dumps(data),
headers=headers,
)
Expand All @@ -107,8 +107,8 @@ def refreshToken(self, token):
data = {"refresh_token": token["refresh_token"]}
headers = {**apiHeaders, "Application-Id": self.region}

r = session.put(
"https://api.mps.ford.com/api/oauth2/v1/refresh",
r = session.post(
"https://api.mps.ford.com/api/token/v2/cat-with-refresh-token",
data=json.dumps(data),
headers=headers,
)
Expand Down
4 changes: 2 additions & 2 deletions custom_components/fordpass/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@
"config_flow": true,
"documentation": "https://github.com/itchannel/fordpass-ha",
"issue_tracker": "https://github.com/itchannel/fordpass-ha/issues",
"version": "0.1.31",
"version": "0.1.32",
"requirements": ["dotted==0.1.8"],
"ssdp": [],
"zeroconf": [],
"homekit": {},
"dependencies": [],
"iot_class": "cloud_polling",
"codeowners": ["@itchannel"]
}
}
1 change: 1 addition & 0 deletions custom_components/fordpass/strings.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{
"title": "Fordpass",
"config": {
"step": {
"user": {
Expand Down
3 changes: 2 additions & 1 deletion custom_components/fordpass/translations/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,6 @@
"description": "Configure fordpass options"
}
}
}
},
"title": "Fordpass"
}
3 changes: 1 addition & 2 deletions hacs.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
{
"name": "fordpass",
"content_in_root": false,
"iot_class": "cloud_polling"
"content_in_root": false
}
4 changes: 3 additions & 1 deletion info.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@

# **Changelog**
- Fix for elvDTE error
## Version 1.32
- Fix auth flow to comply with new endpoints
**Warning - If you encounter auth errors please delete the token file located in the install directory or use the "delete_token" service**
## Version 1.31
- Fix for multiple accounts
## Version 1.30
Expand Down

0 comments on commit 346425b

Please sign in to comment.