SmapiAuthTokens that expire, with sonos refreshAuthToken functionality (#81)

Bearer token to Authorization header for stream requests
Versioned SMAPI Tokens
This commit is contained in:
Simon J
2021-12-02 11:03:52 +11:00
committed by GitHub
parent 89340dd454
commit d1300b8119
24 changed files with 1792 additions and 1330 deletions

View File

@@ -33,9 +33,10 @@ class LoggedInSonosDriver {
this.client = client;
this.token = token;
this.client.addSoapHeader({
credentials: someCredentials(
this.token.getDeviceAuthTokenResult.authToken
),
credentials: someCredentials({
token: this.token.getDeviceAuthTokenResult.authToken,
key: this.token.getDeviceAuthTokenResult.privateKey
}),
});
}
@@ -272,7 +273,7 @@ describe("scenarios", () => {
bonobUrl,
musicService,
{
linkCodes: () => linkCodes
linkCodes: () => linkCodes,
}
);