Skip to content

Commit

Permalink
feat(pollux): minor changes related to connect implementation (#171)
Browse files Browse the repository at this point in the history
* Added first version of open api spec for connect

* Added first version of open api spec for connect

* Added protocol onnect

* updated the protocol connect

* Added the Agent for connect

* chore(prism-agent): update OAS for Connect

* feat(prism-agent): add mock implementation for Connect OAS

* chore(connect): Fix typo in class names

* chore(prism-agent): return '201' when creating new connection record

* chore(connect): bump mercury version to 0.7.0

* chore(pollux): bump version to 0.4.0-SNAPSHOT

* chore(pollux): bump mercury version to 0.7.0

* chore(prism-agent): add connect dependency

* chore(connect): Fix typo in class names

* chore(prism-agent): configure connect Api and DB layers

* chore(prism-agent): fix compilation warning

* chore(connect): implement all phases of the connection flow

* chore(connect): decode and parse raw invitation in ConnectionService

* chore(prism-agent): align connect OAS with DIDComm v2 OOB invitation format

* chore(prism-agent): execute connect db migrations at startup

* chore(prism-agent): add connect DB app config

* feat(prism-agent): implement create/get connection(s) + accept invitation

* chore(connect): disable Doobie log handler

* chore(connect): implement connection request acceptance by inviter

* chore(prism-agent): return 'myDid' and 'theirDid' in REST api reponse

* feat(prism-agent): implement background job for Connect protocol

* feat(prism-agent): implement DIDComm service endpoint for Connect protocol

* chore(prism-agent): improve code formatting

* chore(prism-agent): move connect API spec to server project

* chore(pollux): downgrade to shared 0.1.0

* chore(connect): downgrade to shared 0.1.0

* chore(prism-agent): add removed connect dependency

* chore(pollux): split PR

Co-authored-by: Shailesh <[email protected]>
  • Loading branch information
bvoiturier and mineme0110 authored Nov 25, 2022
1 parent b707792 commit 4573ef8
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 17 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package io.iohk.atala.mercury

import scala.jdk.CollectionConverters.*
import zio.*

import zio._
import zio.http._
Expand Down Expand Up @@ -47,14 +48,14 @@ object AgentCli extends ZIOAppDefault {
}

val startLogo = Console.printLine("""
| ███╗ ███╗███████╗██████╗ ██████╗██╗ ██╗██████╗ ██╗ ██╗ ██████╗██╗ ██╗
| ████╗ ████║██╔════╝██╔══██╗██╔════╝██║ ██║██╔══██╗╚██╗ ██╔╝ ██╔════╝██║ ██║
| ██╔████╔██║█████╗ ██████╔╝██║ ██║ ██║██████╔╝ ╚████╔╝ █████╗██║ ██║ ██║
| ██║╚██╔╝██║██╔══╝ ██╔══██╗██║ ██║ ██║██╔══██╗ ╚██╔╝ ╚════╝██║ ██║ ██║
| ██║ ╚═╝ ██║███████╗██║ ██║╚██████╗╚██████╔╝██║ ██║ ██║ ╚██████╗███████╗██║
| ╚═╝ ╚═╝╚══════╝╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝ ╚═╝ ╚═════╝╚══════╝╚═╝
|DID Comm V2 Agent - CLI tool for debugging - Build by Atala (IOHK)
|""".stripMargin)
| ███╗ ███╗███████╗██████╗ ██████╗██╗ ██╗██████╗ ██╗ ██╗ ██████╗██╗ ██╗
| ████╗ ████║██╔════╝██╔══██╗██╔════╝██║ ██║██╔══██╗╚██╗ ██╔╝ ██╔════╝██║ ██║
| ██╔████╔██║█████╗ ██████╔╝██║ ██║ ██║██████╔╝ ╚████╔╝ █████╗██║ ██║ ██║
| ██║╚██╔╝██║██╔══╝ ██╔══██╗██║ ██║ ██║██╔══██╗ ╚██╔╝ ╚════╝██║ ██║ ██║
| ██║ ╚═╝ ██║███████╗██║ ██║╚██████╗╚██████╔╝██║ ██║ ██║ ╚██████╗███████╗██║
| ╚═╝ ╚═╝╚══════╝╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝ ╚═╝ ╚═════╝╚══════╝╚═╝
|DID Comm V2 Agent - CLI tool for debugging - Build by Atala (IOHK)
|""".stripMargin)

// val env = zio.http.Client.default ++ zio.Scope.default

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,7 @@ object InvitationPrograms {
"https://didcomm.org/out-of-band/2.0/invitation",
getNewMsgId,
merdiator.myDid,
Body("request-mediate", "RequestMediate", Seq("didcomm/v2", "didcomm/aip2;env=rfc587")),
None
Body("request-mediate", "RequestMediate", Seq("didcomm/v2", "didcomm/aip2;env=rfc587"))
)
_ <- ZIO.log(s"createInvitationV2 from '${merdiator.myDid}'")
result = invitation.asJson.deepDropNullValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ class OutOfBandSpec extends FunSuite {
"did:peer:2.Ez6LSmLmWmTvwjgLSuUaEQHdHSFWPwyibgzomWjFmnC6FhLnU.Vz6MktNgLh4N1u9KNhDiqe8KZ8bsLzLcqsifoNiUtBoSs9jxf.SeyJpZCI6Im5ldy1pZCIsInQiOiJkbSIsInMiOiJodHRwOi8vMTI3LjAuMC4xOjgwMDAiLCJhIjpbImRpZGNvbW0vdjIiXX0"
),
Body("request-mediate", "RequestMediate", Seq("didcomm/v2", "didcomm/aip2;env=rfc587")),
None
)

assertEquals(ret, Right(expected))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ See [https://github.com/hyperledger/aries-rfcs/tree/main/features/0454-present-p

## PIURI

Version 2.0: `https://didcomm.org/present-proof/2.0/propose-presentation`
Version 2.0: `https://didcomm.org/present-proof/3.0/propose-presentation`

Version 2.0: `https://didcomm.org/present-proof/2.0/request-presentation`
Version .0: `https://didcomm.org/present-proof/3.0/request-presentation`

Version 2.0: `https://didcomm.org/present-proof/2.0/presentation`
Version 3.0: `https://didcomm.org/present-proof/3.0/presentation`

### Roles

Expand Down
4 changes: 2 additions & 2 deletions pollux/lib/project/Dependencies.scala
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ object Dependencies {
val zioCatsInterop = "3.3.0"
val prismSdk = "v1.4.1"
val iris = "0.1.0"
val shared = "0.2.0"
val mercury = "0.6.0"
val shared = "0.1.0"
val mercury = "0.7.0"
val flyway = "9.7.0"
}

Expand Down
2 changes: 1 addition & 1 deletion pollux/lib/version.sbt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
ThisBuild / version := "0.3.0-SNAPSHOT"
ThisBuild / version := "0.4.0-SNAPSHOT"

0 comments on commit 4573ef8

Please sign in to comment.