-
Notifications
You must be signed in to change notification settings - Fork 204
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Accept credential Offer is not working. #822
Comments
Yes I've also noticed this recently. This issue is already tracked in this issue: #747, but good to have a dedicated issue for it. @NB-MikeRichardson did you already have a chance to look into this? |
No i haven't looked at this issue. Will start investigating...what exactly is the issue here? Can someone supply steps to reproduce the problem? (Just stating "but now it is not working" doesn't really help us) |
@NB-MikeRichardson descrihed in #747:
|
I thought the problem was with accept offer rather than accept proposal at least that's what the title of this issue says |
I would think you would want to take care with taking the cred_def_id from the proposal. That data element is from the holder and may not align with what the issuer is able/willing to offer. Obvs if the cred-def-id is not one the issuer owns, they can't issue such a credential, so that check is a minimum. |
The method we're talking about is |
You're right, I misread. This is probably another issue then. @ChSonendra can you add some more context on the issue? Looking at the API you should be able to call it like this: await this.agent.credentials.acceptOffer({
credentialRecordId: credentialRecord.id,
}) |
okay so when we have a credential offer and if we try to accept it by calling but i really and everyone would like to accept the credential offer just by calling acceptOffer with cred_ex_id. |
Looking at the code, the acceptOffer method takes one argument in the credentials module:
And AcceptOfferOptions only requires a single attribute - credentialRecordId. Holder did is not a requirement for that interface. This is the same as before so it's not clear to me where there could be a problem |
Now I notice in that method we have some new code that was added last week to fix a bug with the Indy DID:
Could there be an issue somewhere in this code? |
I am debugging this piece of code and will tell the outcomes here shortly. |
@NB-MikeRichardson const options = { for confirmation of the issue i tried it many times even with a fresh app, but its not working. |
closed by mistake. |
@ChSonendra I think the autoAcceptCredential is not a boolean but takes an enum:
Can you try that? |
Thankyou @NB-MikeRichardson issue is now resolved and we have to pass
this kind of argument to acceptOffer instead of just a cred_ex_id and it works fine. |
@ChSonendra what have you set for |
@TimoGlastra Maybe we should add a warning log when
A warning might be a bit too high, so maybe an |
@TimoGlastra Right, So Issuer can change the content at the time of issuing of credential, thanks for mentioning this. I will try to make space to add an option for asking user to autoAcceptCredential in the App itself. |
This should be fixed in the latest main. @ChSonendra could you check if this is fixed now. Please reopen if the issue still persists |
previously it was fine we just needed to pass cred_ex_id of the credential offer but now it is not working.
it expects some kind of options attribute i figured it out it needed some extra things that credential doesn't contain.
It would be great if it can be used as we used in the previous version.
The text was updated successfully, but these errors were encountered: