listPublicKeys method
Lists the verified public keys for a userLogin
. If no userLogin
is specified,
the public keys for the authenticated user are fetched.
API docs: https://developer.github.com/v3/users/keys/#list-public-keys-for-a-user and https://developer.github.com/v3/users/keys/#list-your-public-keys
Implementation
Stream<PublicKey> listPublicKeys([String? userLogin]) {
final path = userLogin == null ? '/user/keys' : '/users/$userLogin/keys';
return PaginationHelper(github).objects('GET', path, PublicKey.fromJson);
}