rest-client-sdk
Advanced tools
Changelog
6.0.0
unitOfWorkEnabled
with value true to the config object passed to the RestClientSdk's constructor in order to enable itgenerateToken
and refreshToken
methods are now memoized in order to avoid bugs when making concurrent callsChangelog
5.0.0
This release is a migration to TypeScript, but the API stay the same. The only breaking changes are more fixed bugs that might be breaking in really improbable case.
[BREAKING] TokenGenerator's refreshToken
method signature changed from refreshToken(accessToken, parameters)
to refreshToken(accessToken)
.
If you did extend the AbstractToken
generator, you shouldn't relly on the second parameter.
As a matter of fact, the auto-refreshed token in AbstractClient
did not send any parameters either, so it should not have been working before !
Accordingly The refreshToken
method of TokenStorage
signature changed from refreshToken(parameters)
to refreshToken()
[Might Break] all pseudo-private methods and attributes (starting with _
) are unavailable and are now really private (or protected).
_storeAccessToken
should be replace by a ProvidedTokenGenerator
[Might Break] ClassMetadata
, Attribute
and Relation
attributes are now readonly
. You can not change them after initialization.
[Might Break] AbstractTokenGenerator
is now abstract. It should not have been used directly anyway. It implies that the method that previously did thrown errors are not callable (generateToken
, refreshToken
and checkTokenGeneratorConfig
). They should not have been called. They don't exist in JS land anymore.
[Might Break] canAutogenerateToken
has been removed from the token storages and replaced by a autogenerateToken()
method (it's not real POO, but I did not manage to deal with instance of for now)
[Might Break] AbstractClient._refreshTokenAndRefetch does not take the response as a first argument (it wan unused). The method was supposed to be private be the way.
Make SerializerInterace
and Serializer
input and output understandable
RestClientSdkInterface
and TokenStorageInterface
TokenGeneratorInterface
and AsyncStorageInterface
Changelog
4.1.4
ProvidedTokenGenerator
is now deprecated. You should pass the token object instead. It should have had a weird comportment before by the way.Changelog
4.1.3
{ expires_at: null }