CreateAuthnWalletChallenge

Start login process on the device wallet.

rpc CreateAuthnWalletChallenge

user_api.v1.CreateAuthnWalletChallenge

Start login process on the device wallet.

requests CreateAuthnWalletChallengeRequest

user_api.v1.CreateAuthnWalletChallengeRequest

FieldTypeDescription
didstringW3C Decentralized Identifier (DID) of the wallet.
resp, _ := userApiService.CreateAuthnWalletChallenge(ctx, &v1.CreateAuthnWalletChallengeRequest{
  Did: "did:method-name:zDIDMultibase58Encoded",
})
fmt.Println(resp)
const createauthnwalletchallengerequest = new CreateAuthnWalletChallengeRequest();
createauthnwalletchallengerequest.setDid("did:method-name:zDIDMultibase58Encoded");

service.createAuthnWalletChallenge(createauthnwalletchallengerequest, (err, value:CreateAuthnWalletChallengeResponse|null) => {
    const resp = JSON.stringify(err ? err : value);
    console.log("received ", resp);
})
using System;
using Grpc.Core;
using UserApi.V1;

namespace main
{
  class Program
  {
    static void Main(string[] args)
    {
      Channel channel = new Channel("user-mgmt.YOUR_SANDBOX_ID.knoxnetworks.io:443", ChannelCredentials.Insecure); 
      var client = new UserApiService.UserApiServiceClient(channel); 
      var headers = new Metadata();
      var createAuthnWalletChallengeRequest = new CreateAuthnWalletChallengeRequest{
        Did = "did:method-name:zDIDMultibase58Encoded",
      };
      var reply = client.CreateAuthnWalletChallenge(createAuthnWalletChallengeRequest, headers);
      Console.WriteLine("Response: " + reply);
      channel.ShutdownAsync().Wait();
    }
  }
}
package demo;

import io.grpc.Channel;
import io.grpc.ManagedChannel;
import io.grpc.ManagedChannelBuilder;
import user_api.v1.User.CreateAuthnWalletChallengeRequest;
import user_api.v1.User.CreateAuthnWalletChallengeResponse;
import user_api.v1.UserApiServiceGrpc;

public class App {
  public static void main(String[] args) {
    ManagedChannel channel = ManagedChannelBuilder
      .forAddress("user-mgmt.YOUR_SANDBOX_ID.knoxnetworks.io", 443)
      .usePlaintext()
      .build();
    UserApiServiceGrpc.UserApiServiceBlockingStub blockStub =
        UserApiServiceGrpc.newBlockingStub(channel);
    
    CreateAuthnWalletChallengeRequest req_CreateAuthnWalletChallengeRequest =
        CreateAuthnWalletChallengeRequest.newBuilder()
          .setDid("did:method-name:zDIDMultibase58Encoded")
          .build();
    CreateAuthnWalletChallengeResponse resp = blockStub.createAuthnWalletChallenge(req_CreateAuthnWalletChallengeRequest);
    System.out.println(resp);
    channel.shutdown();
  }
}
const createauthnwalletchallengerequest = new CreateAuthnWalletChallengeRequest();
createauthnwalletchallengerequest.setDid("did:method-name:zDIDMultibase58Encoded");

service.createAuthnWalletChallenge(createauthnwalletchallengerequest, (err, value) => {
    const resp = JSON.stringify(err ? err : value);
    console.log("received ", resp);
})
extern crate grpc-sdks;
use tonic::transport::Channel;

use grpc-sdks::user_api::v1::user_api_service_client::UserApiServiceClient;
use grpc-sdks::user_api::v1::CreateAuthnWalletChallengeRequest;

#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
  let channel = Channel::from_static("user-mgmt.YOUR_SANDBOX_ID.knoxnetworks.io")
    .connect()
    .await?;
  let mut client = UserApiServiceClient::new(channel); 

  let request = tonic::Request::new(
    CreateAuthnWalletChallengeRequest{
      did: String::from("did:method-name:zDIDMultibase58Encoded")
    });
// sending request and waiting for response
  let response = client.create_authn_wallet_challenge(request).await?.into_inner();
  println!("RESPONSE={:?}", response);
  Ok(())
}
package app

import io.grpc.ManagedChannelBuilder
import user_api.v1.User.CreateAuthnWalletChallengeRequest
import user_api.v1.User.CreateAuthnWalletChallengeResponse
import user_api.v1.UserApiServiceGrpc

fun main() {
    val channel = ManagedChannelBuilder
            .forAddress("user-mgmt.YOUR_SANDBOX_ID.knoxnetworks.io", 443)
            .usePlaintext()
            .build()
    var blockStub = UserApiServiceGrpc.newBlockingStub(channel)
    
    val req_CreateAuthnWalletChallengeRequest = CreateAuthnWalletChallengeRequest.newBuilder()
          .setDid("did:method-name:zDIDMultibase58Encoded")
          .build()
    val resp = blockStub.createAuthnWalletChallenge(req_CreateAuthnWalletChallengeRequest)
    println(resp)
    channel.shutdown()
}


returns CreateAuthnWalletChallengeResponse

user_api.v1.CreateAuthnWalletChallengeResponse

FieldTypeDescription
noncestringValue used for the challenge.
{
  "nonce": "NONCE"
}