Public Assets API

Public Assets API Reference

Public Assets API Examples

Public Assets are created using the Assets API and setting the value of public to true.

To see more information about creating a Public Asset see Creating a Public Asset.

Each Public Asset has a Private and a Public Interface, the Private Interface is used to update the asset by the creating tenancy, the Public is a read-only view of the Asset that you do not need to be authenticated for.

The methods described below cover interacting with the Public Interface Only, to interact with the Private Interface, use the standard Assets API.

Fetch a Public Asset Record

curl -H "Content-Type: application/json" https://app.rkvst.io/archivist/publicassets/86b61c4b-030e-4c07-9400-463612e6cee4
{
  "identity": "assets/86b61c4b-030e-4c07-9400-463612e6cee4",
  "behaviours": ["RecordEvidence", "Builtin", "AssetCreator"] ,
  "attributes": {
    "arc_display_type": "Asset",
    "foo": "bar",
    "A": "B",
    "arc_description": "This asset is public",
    "arc_display_name": "Public Asset"
  },
  "confirmation_status": "CONFIRMED",
  "tracked": "TRACKED",
  "owner": "0x5eC362570D1b52a01648997db5ed7693fc6b3978",
  "at_time": "2022-07-15T14:26:40Z",
  "storage_integrity": "TENANT_STORAGE",
  "proof_mechanism": "SIMPLE_HASH",
  "chain_id": "8275868384",
  "public": true,
  "tenant_identity": "tenant/8e0b600c-8234-43e4-860c-e95bdcd695a9"
}

Fetch all of a Public Asset’s Events Records

curl -H "Content-Type: application/json" https://app.rkvst.io/archivist/publicassets/86b61c4b-030e-4c07-9400-463612e6cee4/events
{
    "events": [
        {
            "identity": "assets/86b61c4b-030e-4c07-9400-463612e6cee4/events/083f90fb-c379-40db-b56a-190564d53cd5",
            "asset_identity": "assets/86b61c4b-030e-4c07-9400-463612e6cee4",
            "event_attributes": {
                "arc_attachments": [],
                "arc_display_type": "Change"
            },
            "asset_attributes": {
                "A": "B"
            },
            "operation": "Record",
            "behaviour": "RecordEvidence",
            "timestamp_declared": "2022-07-06T14:56:24Z",
            "timestamp_accepted": "2022-07-06T14:56:24Z",
            "timestamp_committed": "2022-07-06T14:56:24.681514884Z",
            "principal_declared": {
                "issuer": "",
                "subject": "",
                "display_name": "",
                "email": ""
            },
            "principal_accepted": {
                "issuer": "",
                "subject": "",
                "display_name": "",
                "email": ""
            },
            "confirmation_status": "CONFIRMED",
            "transaction_id": "",
            "block_number": 0,
            "transaction_index": 0,
            "from": "0x5eC362570D1b52a01648997db5ed7693fc6b3978",
            "tenant_identity": "tenant/8e0b600c-8234-43e4-860c-e95bdcd695a9"
        },
        {
            "identity": "assets/86b61c4b-030e-4c07-9400-463612e6cee4/events/10d252f2-3116-4c22-b34a-7e3f768895c9",
            "asset_identity": "assets/86b61c4b-030e-4c07-9400-463612e6cee4",
            "event_attributes": {
                "arc_access_policy_always_read": [
                    {
                        "tessera": "SmL4PHAHXLdpkj/c6Xs+2br+hxqLmhcRk75Hkj5DyEQ=",
                        "wallet": "0x5eC362570D1b52a01648997db5ed7693fc6b3978"
                    }
                ],
                "arc_access_policy_asset_attributes_read": [
                    {
                        "0x4609ea6bbe85F61bc64760273ce6D89A632B569f": "wallet",
                        "SmL4PHAHXLdpkj/c6Xs+2br+hxqLmhcRk75Hkj5DyEQ=": "tessera",
                        "attribute": "*"
                    }
                ],
                "arc_access_policy_event_arc_display_type_read": [
                    {
                        "SmL4PHAHXLdpkj/c6Xs+2br+hxqLmhcRk75Hkj5DyEQ=": "tessera",
                        "value": "*",
                        "0x4609ea6bbe85F61bc64760273ce6D89A632B569f": "wallet"
                    }
                ]
            },
            "asset_attributes": {
                "foo": "bar",
                "arc_attachments": [],
                "arc_description": "This asset is public",
                "arc_display_name": "Public Asset",
                "arc_display_type": "Asset"
            },
            "operation": "NewAsset",
            "behaviour": "AssetCreator",
            "timestamp_declared": "2022-07-06T13:38:34Z",
            "timestamp_accepted": "2022-07-06T13:38:34Z",
            "timestamp_committed": "2022-07-06T13:38:35.143791572Z",
            "principal_declared": {
                "issuer": "",
                "subject": "",
                "display_name": "",
                "email": ""
            },
            "principal_accepted": {
                "issuer": "",
                "subject": "",
                "display_name": "",
                "email": ""
            },
            "confirmation_status": "CONFIRMED",
            "transaction_id": "",
            "block_number": 0,
            "transaction_index": 0,
            "from": "0x5eC362570D1b52a01648997db5ed7693fc6b3978",
            "tenant_identity": "tenant/8e0b600c-8234-43e4-860c-e95bdcd695a9"
        }
    ],
    "next_page_token": ""
}

Fetch a Public Asset’s specific Event Record

curl -H "Content-Type: application/json" https://app.rkvst.io/archivist/publicassets/86b61c4b-030e-4c07-9400-463612e6cee4/events/7da272ad-19d5-4106-b4af-2980a84c2721
{
    "identity": "assets/86b61c4b-030e-4c07-9400-463612e6cee4/events/083f90fb-c379-40db-b56a-190564d53cd5",
    "asset_identity": "assets/86b61c4b-030e-4c07-9400-463612e6cee4",
    "event_attributes": {
        "arc_display_type": "Change",
        "arc_attachments": []
    },
    "asset_attributes": {
        "A": "B"
    },
    "operation": "Record",
    "behaviour": "RecordEvidence",
    "timestamp_declared": "2022-07-06T14:56:24Z",
    "timestamp_accepted": "2022-07-06T14:56:24Z",
    "timestamp_committed": "2022-07-06T14:56:24.681514884Z",
    "principal_declared": {
        "issuer": "",
        "subject": "",
        "display_name": "",
        "email": ""
    },
    "principal_accepted": {
        "issuer": "",
        "subject": "",
        "display_name": "",
        "email": ""
    },
    "confirmation_status": "CONFIRMED",
    "transaction_id": "",
    "block_number": 0,
    "transaction_index": 0,
    "from": "0x5eC362570D1b52a01648997db5ed7693fc6b3978",
    "tenant_identity": "tenant/8e0b600c-8234-43e4-860c-e95bdcd695a9"
}

Public Assets OpenAPI Docs

API for public asset and event management.

get  /archivist/v2/publicassets/{asset_uuid}/events/{uuid}

Retrieves Archivist event for public asset

Description: Retrieves a specific Archivist event for a public asset

{
  "asset_attributes": {
    "arc_firmware_version": "3.2.1",
    "arc_home_location_identity": "locations/42054f10-9952-4c10-a082-9fd0d10295ae"
  },
  "asset_identity": "assets/add30235-1424-4fda-840a-d5ef82c4c96f",
  "behaviour": "RecordEvidence",
  "block_number": 12,
  "confirmation_status": "CONFIRMED",
  "event_attributes": {
    "arc_attachments": [
      {
        "arc_attachment_identity": "blobs/1754b920-cf20-4d7e-9d36-9ed7d479744d",
        "arc_display_name": "Picture from yesterday",
        "arc_hash_alg": "sha256",
        "arc_hash_value": "01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b"
      }
    ]
  },
  "identity": "assets/add30235-1424-4fda-840a-d5ef82c4c96f/events/11bf5b37-e0b8-42e0-8dcf-dc8c4aefc000",
  "operation": "Record",
  "principal_accepted": {
    "issuer": "job.idp.server/1234",
    "subject": "bob@job"
  },
  "principal_declared": {
    "issuer": "job.idp.server/1234",
    "subject": "bob@job"
  },
  "tenant_identity": "tenant/8e0b600c-8234-43e4-860c-e95bdcd695a9",
  "timestamp_accepted": "2019-11-27T14:44:19Z",
  "timestamp_committed": "2019-11-27T14:44:19Z",
  "timestamp_declared": "2019-11-27T14:44:19Z",
  "transaction_id": "0x07569",
  "transaction_index": 5
}
Response ParameterTypeDescription
asset_attributesobjectkey value mapping of asset attributes
asset_identitystringidentity of a related asset resource assets/11bf5b37-e0b8-42e0-8dcf-dc8c4aefc000
behaviourstringThe behaviour used to create event. RecordEvidence
block_numberstringnumber of block event was commited on
confirmation_statusstringindicates if the event has been succesfully committed to the blockchain
event_attributesobjectkey value mapping of event attributes
fromstringwallet address for the creator of this event
identitystringidentity of a event resource
operationstringThe operation represented by the event. Record
principal_acceptedobjectprincipal recorded by the server
principal_declaredobjectprincipal provided by the user
tenant_identitystringIdentity of the tenant the that created this event
timestamp_acceptedstringtime of event as recorded by the server
timestamp_committedstringtime of event as recorded on blockchain
timestamp_declaredstringtime of event as declared by the user
transaction_idstringhash of the transaction as a hex string 0x11bf5b37e0b842e08dcfdc8c4aefc000
transaction_indexstringindex of event within commited block
ResponsesDescription
200A successful response.
404Returned when the event does not exist.
defaultAn unexpected error response.

get  /archivist/v2/publicassets/{uuid}

Retrieves a specific public Archivist asset

Description: Retrieves a specific public Archivist asset

{
  "at_time": "2019-11-27T14:44:19Z",
  "attributes": {
    "arc_attachments": [
      {
        "arc_attachment_identity": "blobs/1754b920-cf20-4d7e-9d36-9ed7d479744d",
        "arc_display_name": "Picture from yesterday",
        "arc_hash_alg": "sha256",
        "arc_hash_value": "01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b"
      }
    ],
    "arc_firmware_version": "3.2.1",
    "arc_home_location_identity": "locations/42054f10-9952-4c10-a082-9fd0d10295ae"
  },
  "behaviours": [
    "RecordEvidence"
  ],
  "confirmation_status": "PENDING",
  "identity": "assets/add30235-1424-4fda-840a-d5ef82c4c96f",
  "owner": "0x601f5A7D3e6dcB55e87bf2F17bC8A27AaCD3511",
  "proof_mechanism": "SIMPLE_HASH",
  "public": false,
  "tenant_identity": "tenant/8e0b600c-8234-43e4-860c-e95bdcd695a9",
  "tracked": "TRACKED"
}
Response ParameterTypeDescription
access_policyobjectkey value mapping of behaviour to private for keys
at_timestringindicates time the asset data is from
attributesobjectkey value mapping of asset properties
behavioursarraylist of behaviours enabled for this asset
chain_idstringchain id of the blockchain associated with this asset
confirmation_statusstringindicates if the asset has been succesfully committed to the blockchain
identitystringrelative resource address assets/{UUID}
ownerstringwallet address of the asset owner
proof_mechanismstringthe mechanism used to provide evidential proof
publicbooleanPublic asset
storage_integritystringDEPRECATED use proof_mechanism
tenant_identitystringIdentity of the tenant the that created this asset
trackedstringindicates whether asset is still being tracked in the system
ResponsesDescription
200A successful response.
404Returned when the asset with the id does not exist.
defaultAn unexpected error response.

get  /archivist/v2/publicassets/{uuid}/events

List Archivist events for a public asset

Description: Lists Archivist events for a public asset

{
  "events": [
    {
      "asset_attributes": {
        "arc_firmware_version": "3.2.1",
        "arc_home_location_identity": "locations/42054f10-9952-4c10-a082-9fd0d10295ae"
      },
      "asset_identity": "assets/add30235-1424-4fda-840a-d5ef82c4c96f",
      "behaviour": "RecordEvidence",
      "block_number": 12,
      "confirmation_status": "CONFIRMED",
      "event_attributes": {
        "arc_attachments": [
          {
            "arc_attachment_identity": "blobs/1754b920-cf20-4d7e-9d36-9ed7d479744d",
            "arc_display_name": "Picture from yesterday",
            "arc_hash_alg": "sha256",
            "arc_hash_value": "01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b"
          }
        ]
      },
      "identity": "assets/add30235-1424-4fda-840a-d5ef82c4c96f/events/11bf5b37-e0b8-42e0-8dcf-dc8c4aefc000",
      "operation": "Record",
      "principal_accepted": {
        "issuer": "job.idp.server/1234",
        "subject": "bob@job"
      },
      "principal_declared": {
        "issuer": "job.idp.server/1234",
        "subject": "bob@job"
      },
      "tenant_identity": "tenant/8e0b600c-8234-43e4-860c-e95bdcd695a9",
      "timestamp_accepted": "2019-11-27T14:44:19Z",
      "timestamp_committed": "2019-11-27T14:44:19Z",
      "timestamp_declared": "2019-11-27T14:44:19Z",
      "transaction_id": "0x07569",
      "transaction_index": 5
    },
    {
      "asset_attributes": {
        "arc_firmware_version": "3.2.1",
        "arc_home_location_identity": "locations/42054f10-9952-4c10-a082-9fd0d10295ae"
      },
      "asset_identity": "assets/bf330235-1424-4fda-840a-d5ef82c4c96f",
      "behaviour": "RecordEvidence",
      "block_number": 13,
      "confirmation_status": "CONFIRMED",
      "event_attributes": {
        "arc_attachments": [
          {
            "arc_attachment_identity": "blobs/1754b920-cf20-4d7e-9d36-9ed7d479744d",
            "arc_display_name": "Picture",
            "arc_hash_alg": "sha256",
            "arc_hash_value": "01ba4719c80b6fe911b091a7c05124b64eeece964e09c058ef8f9805daca546b"
          }
        ]
      },
      "identity": "assets/bf330235-1424-4fda-840a-d5ef82c4c96f/events/23c06c48-e0b8-42e0-8dcf-dc8c4fdad123",
      "operation": "Record",
      "principal_accepted": {
        "issuer": "job.idp.server/1234",
        "subject": "bob@job"
      },
      "principal_declared": {
        "issuer": "job.idp.server/1234",
        "subject": "bob@job"
      },
      "tenant_identity": "tenant/8e0b600c-8234-43e4-860c-e95bdcd695a9",
      "timestamp_accepted": "2019-07-27T14:44:19Z",
      "timestamp_committed": "2019-07-27T14:44:19Z",
      "timestamp_declared": "2019-07-27T14:44:19Z",
      "transaction_id": "0x12569",
      "transaction_index": 6
    }
  ],
  "next_page_token": "abcd"
}
Response ParameterTypeDescription
eventsarrayThis describes RKVST Event.
next_page_tokenstringToken to retrieve the next page of results or empty if there are none.
ResponsesDescription
200A successful response.
206The number of events exceeds the servers limit. The approximate number of matching results is provided by the x-total-count header, the exact limit is available in the content-range header. The value format is ‘items 0-LIMIT/TOTAL’. Note that x-total-count is always present for 200 and 206 responses. It is the servers best available approximation. Similarly, in any result set, you may get a few more than LIMIT items.
defaultAn unexpected error response.

Edit this page on GitHub