While authenticating in my dapp with NFID, I got:
POST https://28oge2ricd.execute-api.us-east-1.amazonaws.com/prod/ecdsa_sign
400 Bad Request
The returned body is {}.
Why does it query AWS, and why the request is bad?
My login code:
const nfid = await NFID.init({
application: {
name: "Zon",
// logo: "https://dev.nfid.one/static/media/id.300eb72f3335b50f5653a7d6ad5467b3.svg" // TODO
},
});
const delegationIdentity: Identity = await nfid.getDelegation({
// optional targets ICRC-28 implementation, but required to support universal NFID Wallet auth
targets: [], // FIXME: needed?
// optional derivationOrigin in case you're running on a custom domain
derivationOrigin: `https://${process.env.CANISTER_ID_frontend!}.icp0.app`,
// optional maxTimeToLive defaults to 8 hours in nanoseconds;
maxTimeToLive: BigInt(8) * BigInt(3_600_000_000_000) // TODO
});
updateClientNfid(delegationIdentity);
if (getIsLocal()) {
auth.authClient.fetchRootKey();
}
Also, do I need any targets?