This creates a issuer profile using method. The weightage for this API is 10
Creates a new issuer profile under the given instance.
{
Data: "did:key:z6Mkfm8bqp23Q5629bnmzL26ksvfMgfFUA9hWpZ1dWjpARsQ",
Message: "Issuer Profile Created",
Status: "SUCCESS"
}
{
Data: null,
Message: "mandatory params missing",
Status: "FAILURE"
}
Take a look at how you might call this method using our official libraries, or via curl
:
curl --location --request POST 'https://api.krypcore.com/api/v0/did/createIssuerProfile' \
--header 'Authorization: xxxxxxxxxxxxxxx' \
--header 'DappId: xxxxxxxxxxxxxxx' \
--header 'Content-Type: application/json' \
--data-raw '{
"issuerDescription": "xxx",
"issuerDesignation": "xxx",
"issuerName": "issuer",
"method": "key"
}'
var axios = require('axios');
var data = JSON.stringify({
"issuerDescription": "xxx",
"issuerDesignation": "xxx",
"issuerName": "issuer",
"method": "key"
});
var config = {
method: 'post',
url: 'https://api.krypcore.com/api/v0/did/createIssuerProfile',
headers: {
'Authorization': 'xxxxxxxxxxxxxxx',
'DappId': 'xxxxxxxxxxxxxxx',
'Content-Type': 'application/json'
},
data : data
};
axios(config)
.then(function (response) {
console.log(JSON.stringify(response.data));
})
.catch(function (error) {
console.log(error);
});
import requests
import json
url = "https://api.krypcore.com/api/v0/did/createIssuerProfile"
payload = json.dumps({
"issuerDescription": "xxx",
"issuerDesignation": "xxx",
"issuerName": "issuer",
"method": "key"
})
headers = {
'Authorization': 'xxxxxxxxxxxxxxx',
'DappId': 'xxxxxxxxxxxxxxx',
'Content-Type': 'application/json'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text)
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://api.krypcore.com/api/v0/did/createIssuerProfile"
method := "POST"
payload := strings.NewReader(`{
"issuerDescription": "xxx",
"issuerDesignation": "xxx",
"issuerName": "issuer",
"method": "key"
}`)
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
return
}
req.Header.Add("Authorization", "xxxxxxxxxxxxxxx")
req.Header.Add("DappId", "xxxxxxxxxxxxxxx")
req.Header.Add("Content-Type", "application/json")
res, err := client.Do(req)
if err != nil {
fmt.Println(err)
return
}
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
if err != nil {
fmt.Println(err)
return
}
fmt.Println(string(body))
}