Skip to content
This repository has been archived by the owner on Feb 13, 2024. It is now read-only.

Feature/receive invite #585

Merged

Conversation

usingtechnology
Copy link
Contributor

@usingtechnology usingtechnology commented Aug 24, 2021

Update the Add Partner page to allow connect by DID and connect by Invitation Url.

This is to support connecting with non-phone Agents (ex. Trinsic Studio) that are only generating QR Codes and invitations. This allows us to take their generated invitation and create a Partner.

Currently tested and connected using our own invitations (connection and out of band) and an Invitation from Trinisic Studio.

I have added a simple single redirect handler when reading the invitation url. This is for implementations like Trinsic Studio, where they generate a short url (and thus a simpler easier to read qr code) that will take you to the real underlying invitation url (trinisic uses d_m query param, but results in a connection 1.0 invitation).

Query Params for invitations

  • c_i (Aries RFC 0160: Connection Protocol)
  • d_m (RFC 0268: Unified DIDCOMM Deeplinking)
  • oob (Aries RFC 0434: Out-of-Band Protocol 1.1)

Jason Sherman added 3 commits August 23, 2021 18:38
Signed-off-by: Jason Sherman <jsherman@parcsystems.ca>
* main:
  Set button loading during request
  Implement create and send button functionality
  Enable sending proof templates to the backend
  Add create proof template page + link router and buttons
  technical documentation via Sphinx and hosted by GitHub pages
  Prepare request presentation page for proof templates and pass through v-model from table
  Add optional checkboxes and search bar to proof templates list component

Signed-off-by: Jason Sherman <jsherman@parcsystems.ca>

# Conflicts:
#	frontend/src/plugins/vuetify.js
Signed-off-by: Jason Sherman <jsherman@parcsystems.ca>
@usingtechnology usingtechnology marked this pull request as ready for review August 24, 2021 21:12
@usingtechnology usingtechnology requested review from etschelp and domwoe and removed request for etschelp August 25, 2021 15:45
invitation.setOob(true);
// not supporting this until we can parse and send to aries client successfully
// coming very soon with next update of Aries Client Jar!!!
String msg = "Out of band Invitations are currently not supported";
Copy link
Contributor

Choose a reason for hiding this comment

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

I have just released a new client 0.7.4 with the fix

Copy link
Contributor Author

Choose a reason for hiding this comment

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

ok, I'll pull that in and add this functionality. Thanks for getting that done so quickly.

partnerRepo.save(Partner
.builder()
.ariesSupport(Boolean.TRUE)
.alias(StringUtils.trimToNull(record.getTheirLabel()))
Copy link
Contributor

Choose a reason for hiding this comment

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

Alias should always be set by the user. In this case theirLabel should be label. See discussion about aliases, labels and fallbacks :)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

ok, so, should the UX have an alias field, defaulted to the label from the invitation? that make sense?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

basically, re-use the set tags/ping/alias code?

Copy link
Contributor

Choose a reason for hiding this comment

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

when we generate the barcode for the invitation we have the UI below. In your case what about setting the placeholder to the label and if the user does not provide any input the backend can set the alias to the value of the label like you have it now?

Screen Shot 2021-08-25 at 18 04 25

Copy link
Contributor

Choose a reason for hiding this comment

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

basically, re-use the set tags/ping/alias code?

yes same behavior

Copy link
Contributor Author

Choose a reason for hiding this comment

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

perfect, will add that in, makes sense.

.did(didPrefix + UNKNOWN_DID)
.state(ConnectionState.INVITATION)
.incoming(Boolean.TRUE)
.tags(null)
Copy link
Contributor

Choose a reason for hiding this comment

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

It would be cool if we could keep everything consistent. If we generate a partner invitation we also have the possibility to set an alias and tags.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

👍 see the above comments, will add that ux in.

.state(ConnectionState.INVITATION)
.incoming(Boolean.TRUE)
.tags(null)
.trustPing(Boolean.FALSE)
Copy link
Contributor

Choose a reason for hiding this comment

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

Also selectable by the user everywhere else

Jason Sherman added 2 commits August 25, 2021 12:37
add support for receiving out of band invitation
update add partner from invitation screen to match add partner from did

Signed-off-by: Jason Sherman <jsherman@parcsystems.ca>
Signed-off-by: Jason Sherman <jsherman@parcsystems.ca>
@usingtechnology usingtechnology merged commit 7a501b7 into hyperledger-labs:main Aug 26, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants