feknall / Hyperledger-FL

4 stars 0 forks source link

Issue a credential of agent A by agent B #5

Closed feknall closed 2 years ago

feknall commented 2 years ago

This process must be followed in order to issue a credential.

  1. Issuer:

    POST issue-credential/send-offer
    {
    "auto_issue": true,
    "auto_remove": false,
    "comment": "string",
    "connection_id": "6d757b7b-7559-4886-8567-466f74660287",
    "cred_def_id": "GxM23MVQTZjP7ewJBouE6K:3:CL:19:default",
    "credential_preview": {
    "@type": "issue-credential/1.0/credential-preview",
    "attributes": [
      {
        "name": "sin",
        "value": "111"
    
      }
    ]
    },
    "trace": true
    }
  2. Holder:

    POST issue-credential/records/{cred_ex_id}/send-request
    {}
  3. Issuer:

    POST /issue-credential/records/{cred_ex_id}/issue'
    {}
  4. Holder:

    POST issue-credential/records/{cred_ex_id}/store
    {
    "credential_id": "a-random-string"
    }

Execute GET /credentials in order to make sure everything is completed successfully.