Skip to content
This repository has been archived by the owner on Sep 22, 2023. It is now read-only.

feat/update urls #313

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions docs/admin-credential-definitions/0.1/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
Create a credential definition based on a schema.
```
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-credential-definitions/0.1/send-credential-definition",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-credential-definitions/0.1/send-credential-definition",
"schema_id": "5P4NvotLsVeeGd9UxUtMp6:2:Alice's Test Schema:1.0",
"@id": "4e92857c-2b52-4e15-8e12-be695cb45ca5",
"~transport": {
Expand All @@ -32,7 +32,7 @@ Create a credential definition based on a schema.
Response to a `send-credential-definition` message.
```
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-credential-definitions/0.1/credential-definition-id",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-credential-definitions/0.1/credential-definition-id",
"@id": "795932f4-dd26-4a9c-8b7e-e8c2302c9683",
"~thread": {
"thid": "4e92857c-2b52-4e15-8e12-be695cb45ca5"
Expand All @@ -47,7 +47,7 @@ Retrieve a pre-existing credential definition.

```
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-credential-definitions/0.1/credential-definition-get",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-credential-definitions/0.1/credential-definition-get",
"cred_def_id": "K6fuxNHhNrR44RfkF5jRp7:3:CL:232915:Alice's Test Schema_1.0",
"@id": "9c107592-1786-469a-9a24-eade00d5629f",
"~transport": {
Expand All @@ -61,7 +61,7 @@ Retrieve a pre-existing credential definition.
Respond message to a `credential-definition-get` message.
```
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-credential-definitions/0.1/credential-definition",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-credential-definitions/0.1/credential-definition",
"@id": "0299d15e-9fb1-4e8d-884e-c1ed8e6e7c87",
"~thread": {
"thid": "9c107592-1786-469a-9a24-eade00d5629f"
Expand All @@ -86,7 +86,7 @@ Retrieve the list of credential definitions.

```
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-credential-definitions/0.1/credential-definition-get-list",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-credential-definitions/0.1/credential-definition-get-list",
"@id": "33d0c436-558e-47b2-9a17-f66be8f869ca",
"~transport": {
"return_route": "all"
Expand All @@ -99,7 +99,7 @@ Respond to a `credential-definition-get-list` message.

```
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-credential-definitions/0.1/credential-definition-list",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-credential-definitions/0.1/credential-definition-list",
"@id": "9d070822-821f-4f5c-821f-c92242dc4818",
"~thread": {
"thid": "33d0c436-558e-47b2-9a17-f66be8f869ca"
Expand Down
32 changes: 16 additions & 16 deletions docs/admin-holder/0.1/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## Overview

**Protocol URI:** `did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-holder/0.1`
**Protocol URI:** `https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-holder/0.1`

Define messages for credential holder admin protocols.

Expand Down Expand Up @@ -36,7 +36,7 @@ Example:

```json
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-holder/0.1/credentials-get-list",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-holder/0.1/credentials-get-list",
"@id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"~paginate": {
"limit": 10,
Expand Down Expand Up @@ -66,7 +66,7 @@ Example:

```json
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-holder/0.1/credentials-list",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-holder/0.1/credentials-list",
"@id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"results": [],
"~page": {
Expand Down Expand Up @@ -95,7 +95,7 @@ Example:

```json
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-holder/0.1/credential-offer-accept",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-holder/0.1/credential-offer-accept",
"@id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"credential_exchange_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
}
Expand All @@ -117,7 +117,7 @@ Example:

```json
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-holder/0.1/credential-offer-received",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-holder/0.1/credential-offer-received",
"@id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"state": "credential_acked",
"created_at": "2021-04-13 14:55:53Z",
Expand Down Expand Up @@ -214,7 +214,7 @@ Example:

```json
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-holder/0.1/credential-request-sent",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-holder/0.1/credential-request-sent",
"@id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"state": "credential_acked",
"created_at": "2021-04-13 14:55:53Z",
Expand Down Expand Up @@ -311,7 +311,7 @@ Example:

```json
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-holder/0.1/credential-received",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-holder/0.1/credential-received",
"@id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"state": "credential_acked",
"created_at": "2021-04-13 14:55:53Z",
Expand Down Expand Up @@ -427,7 +427,7 @@ Example:

```json
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-holder/0.1/send-credential-proposal",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-holder/0.1/send-credential-proposal",
"@id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"trace": false,
"connection_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
Expand Down Expand Up @@ -486,7 +486,7 @@ Example:

```json
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-holder/0.1/credential-exchange",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-holder/0.1/credential-exchange",
"@id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"state": "credential_acked",
"created_at": "2021-04-13 14:55:53Z",
Expand Down Expand Up @@ -583,7 +583,7 @@ Example:

```json
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-holder/0.1/presentations-get-list",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-holder/0.1/presentations-get-list",
"@id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"connection_id": null,
"~paginate": {
Expand Down Expand Up @@ -611,7 +611,7 @@ Example:

```json
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-holder/0.1/presentations-list",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-holder/0.1/presentations-list",
"@id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"results": null,
"~page": {
Expand Down Expand Up @@ -640,7 +640,7 @@ Example:

```json
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-holder/0.1/presentation-request-approve",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-holder/0.1/presentation-request-approve",
"@id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"presentation_exchange_id": null,
"self_attested_attributes": null,
Expand Down Expand Up @@ -699,7 +699,7 @@ Example:

```json
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-holder/0.1/presentation-get-matching-credentials",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-holder/0.1/presentation-get-matching-credentials",
"@id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"presentation_exchange_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"~paginate": {
Expand Down Expand Up @@ -727,7 +727,7 @@ Example:

```json
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-holder/0.1/presentation-matching-credentials",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-holder/0.1/presentation-matching-credentials",
"@id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"presentation_exchange_id": null,
"matching_credentials": {
Expand Down Expand Up @@ -772,7 +772,7 @@ Example:

```json
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-holder/0.1/send-presentation-proposal",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-holder/0.1/send-presentation-proposal",
"@id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"trace": false,
"connection_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
Expand Down Expand Up @@ -821,7 +821,7 @@ Example:

```json
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-holder/0.1/presentation-exchange",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-holder/0.1/presentation-exchange",
"@id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"state": "verified",
"created_at": "2021-04-13 14:55:53Z",
Expand Down
14 changes: 7 additions & 7 deletions docs/admin-schemas/0.1/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Schemas Admin Protocol

## Overview
**Protocol URI:** `did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-schemas/0.1`
**Protocol URI:** `https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-schemas/0.1`


#### Protocol Messages
Expand All @@ -19,7 +19,7 @@ Create a schema by inputting a name, version number, and attributes.

```
{
"@type":"did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-schemas/0.1/send-schema",
"@type":"https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-schemas/0.1/send-schema",
"schema_name": "Alice's Test Schema",
"schema_version": "1.0",
"attributes": [
Expand All @@ -38,7 +38,7 @@ Create a schema by inputting a name, version number, and attributes.
Response to a `send-schema` message.
```
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-schemas/0.1/schema-id",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-schemas/0.1/schema-id",
"@id": "c3091caa-ebcd-4d2c-a2fc-636893ee6f43",
"~thread": {
"thid": "ad285eef-a5e4-4cea-9a40-12f3294d1826"
Expand All @@ -52,7 +52,7 @@ Response to a `send-schema` message.
Retrieve a pre-existing schema using the schema ID.
```
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-schemas/0.1/schema-get",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-schemas/0.1/schema-get",
"schema_id": "UjF64u8jDEEuRve7PKQGUo:2:Alice's Test Schema:1.0",
"@id": "32a22f71-eed6-4113-8732-c791302da893",
"~transport": {
Expand All @@ -65,7 +65,7 @@ Retrieve a pre-existing schema using the schema ID.
Response to a `schema-get` message.
```
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-schemas/0.1/schema",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-schemas/0.1/schema",
"@id": "7bc2adbc-e1f2-43be-9d8c-0890fb4e7180",
"~thread": {
"thid": "32a22f71-eed6-4113-8732-c791302da893"
Expand All @@ -91,7 +91,7 @@ Response to a `schema-get` message.
Retrieve the list of schemas.
```
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-schemas/0.1/schema-get-list",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-schemas/0.1/schema-get-list",
"@id": "f8639a9c-b1aa-4df5-ad93-bb91d94ebb1c",
"~transport": {
"return_route": "all"
Expand All @@ -103,7 +103,7 @@ Retrieve the list of schemas.
Response message to `schema-get-list`.
```
{
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-schemas/0.1/schema-list",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-schemas/0.1/schema-list",
"@id": "a94ef367-1892-435b-8522-dc38889dfccb",
"~thread": {
"thid": "f8639a9c-b1aa-4df5-ad93-bb91d94ebb1c"
Expand Down
29 changes: 18 additions & 11 deletions docs/howmoduleswork.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,17 +19,18 @@ An additional `metadata` export informs the toolbox about the Module name and re
```javascript
export const metadata = {
menu: {
label: 'Module Name',
icon: 'el-icon-user',
group: 'Agent to Agent',
priority: 30,
required_protocols: [
'did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-connections/0.1'
]
label: 'Module Name',
icon: 'el-icon-user',
group: 'Agent to Agent',
priority: 30,
required_protocols: [
{'https' : 'https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-connections/0.1'},
{'did:sov' : 'did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-connections/0.1'}
]
}
};
```
};

```
**label** will appear in the menu.

**icon** must be an icon name from the [Element UI Icon Library](https://element.eleme.io/#/en-US/component/icon). This will also be used in the left menu.
Expand Down Expand Up @@ -57,17 +58,23 @@ export const shared = {
},
},
listeners: {
"https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-connections/0.1/connection-list":
(share, msg) => share.connections = msg.results,
"did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-connections/0.1/connection-list":
(share, msg) => share.connections = msg.results,
"https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-connections/0.1/connection":
(share, msg) => share.fetch_connections(),
"did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-connections/0.1/connection":
(share, msg) => share.fetch_connections(),
"did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-connections/0.1/ack":
"https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-connections/0.1/ack":
(share, msg) => share.fetch_connections(),
"did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/docs/admin-connections/0.1/ack":
(share, msg) => share.fetch_connections(),
},
methods: {
fetch_connections: ({send}) => {
send({
"@type": "did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/admin-connections/0.1/connection-get-list",
"@type": "https://github.com/hyperledger/aries-toolbox/tree/master/docs/admin-connections/0.1/connection-get-list",
});
}
}
Expand Down
38 changes: 28 additions & 10 deletions src/renderer/components/AgentBase.vue
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ import message_bus from '@/message_bus.js';
import share, { share_source } from '@/share.js';
import components, { shared } from './components.js';
import Taa from './TAA.vue';
import DidList from './Dids/DidList.vue';


//handle crashes and kill events
Expand Down Expand Up @@ -108,6 +109,21 @@ export default {
console.log("mediator change!", mediator_agent);
},
'did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/notification/1.0/problem-report':
(vm, msg) => {
vm.$notify.error({
title: 'Small problem...',
message: (text => {
if (text.length > 30) {
return text.slice(0, 30).trim() + '...';
}
return text;
})(msg["explain-ltxt"] || msg['description']['en']),
onClick: () => vm.redirect('message-history'),
duration: 4000,
customClass: 'problem-report-notification'
})
}, // if (startsWith('did:sov' || 'https://') && (endsWith('notification/1.0/problem-report')))
'https://github.com/hyperledger/aries-toolbox/tree/master/docs/notification/1.0/problem-report':
(vm, msg) => {
vm.$notify.error({
title: 'Small problem...',
Expand Down Expand Up @@ -165,16 +181,18 @@ export default {
matching_modules_grouped: function () {
// This computed attribute updates when the supported protocol list is updated.
let pid_list = this.protocols.map(p => p.pid);
let filtered_list = module_list.filter(function (m) {
return m.required_protocols.every(req_protocol => pid_list.includes(req_protocol));
});
//group modules
let module_groups = filtered_list.reduce(function (r, m) {
r[m.group] = r[m.group] || [];
r[m.group].push(m);
return r;
}, Object.create(null));
return module_groups;
if (function (m) {m.required_protocols} instanceof Array(JSON)) {
let filtered_list = module_list.filter(function (m) {
return m.required_protocols.every(req_protocol => pid_list.includes(...Object.values(req_protocol)));
});
//group modules
let module_groups = filtered_list.reduce(function (r, m) {
r[m.group] = r[m.group] || [];
r[m.group].push(m);
return r;
}, Object.create(null));
return module_groups;
}
}

},
Expand Down
Loading