Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Chat] Identity package #732

Closed
wants to merge 7 commits into from
Closed

Conversation

flypaper0
Copy link
Contributor

Description

  • WalletConnectIdentity package
  • JWTFactory restructured
  • Web3Inbox debug session

Resolves # (issue)

How Has This Been Tested?

Due Dilligence

  • Breaking change
  • Requires a documentation update

private let networkingInteractor: NetworkInteracting
private let identityStorage: IdentityStorage
private let identityService: IdentityService
private let networkClient: NetworkInteracting
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should we rename networkingInteractor to networkClient? we already got use to networkingInteractor and it's consistent in all the SDKs

I personally wouldn't do it

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

reverted, planning to discuss it later

Comment on lines -49 to 88
private extension RegistryService {
private extension IdentityClient {

func subscribeForInvites(inviteKey: AgreementPublicKey) async throws {
let topic = inviteKey.rawRepresentation.sha256().toHexString()
try kms.setPublicKey(publicKey: inviteKey, for: topic)
try await networkingInteractor.subscribe(topic: topic)
try await networkClient.subscribe(topic: topic)
}

func unsubscribeFromInvites(inviteKey: AgreementPublicKey) {
let topic = inviteKey.rawRepresentation.sha256().toHexString()
kms.deletePublicKey(for: topic)
networkingInteractor.unsubscribe(topic: topic)
networkClient.unsubscribe(topic: topic)
}
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could this be a part of the Chat sdk?
Identity Package for client->server interaction

but this part is just chat peer to peer

@flypaper0
Copy link
Contributor Author

@llbartekll suggestions fixed in #735

@flypaper0
Copy link
Contributor Author

Merged with #735

@flypaper0 flypaper0 closed this Mar 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

3 participants