Abstract Readonly Abstract idReadonly preferSet to true if getClaimsPage method should be preferred instead claim iteration operations. This could be useful if the Provider subclass has a getClaimsPage implentation that is able to obtain both Claims and ClaimsIds with a single HTTP request. For example, if the Provider were to supply a GraphQL API, or if the webscraped page were to contain the contents of both.
Abstract authenticateAuthenticates to an identity id, acquiring the token This token must be stored on the token database. This is a generator that only has 1 step. This is because we require the caller to perform an authorisation action. The final return value is the identity ID.
Optional timeout: numberChecks that the token is still valid
If the access token has expired, and there is no refresh token then this
will throw the ErrorProviderUnauthenticated exception
If the refresh token exists but has expired then this will throw the
ErrorProviderUnauthenticated exception
If the refresh token exists, and is still valid, then it will attempt to
refresh the token.
If you pass in identityId, expect that the new token will be persisted.
If either providerToken.accessTokenExpiresIn or providerToken.refreshTokenExpiresIn is set to 0,
their related tokens will be treated as never-expiring.
Optional identityId: IdentityIdAbstract getGets an array of authenticated identity ids
Abstract getGets the identity claim given the claim's ID on the provider
Stream identity claimIds from an identity
Abstract getStream a page of identity claimIds from an identity
Optional paginationToken: ProviderPaginationTokenStream identity claims from an identity
Stream a page of identity claims from an identity
Optional paginationToken: ProviderPaginationTokenAbstract getStream connected identity infos to a particular identity This is intended to find "friends", "followers", "contacts"... etc Some social providers do not have this concept In such a case, one stream other random identities that exist on the network Search terms are provider-implementation specific
Optional searchTerms: string[]Abstract getGets the identity data for a given identity
Optional options: { Optional signal?: AbortSignalAbstract getGets the corresponding identity ID to a token key
This verifies that the claim's JSON data fits our schema This does not verify whether the signature is correct
Abstract publishPublishes an identity claim on the authenticated identity.
Returns an IdentitySignedClaim, wrapping the SignedClaim itself with extra
metadata from the published claim (e.g. URL, claim ID on provider)
Abstract refreshRefreshes the token If identity is passed in, this function should update the token db
Optional identityId: IdentityIdGenerated using TypeDoc
Set to the unique hostname of the provider