ADORSYS-GIS / ADORSYS-GIS/cloud-identity-wallet
feat: implement credential offer URI dereferencing
- Lingua principale
- Rust
- Stelle
- 4
- Fork
- 0
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
## Summary
Implement HTTP fetch to dereference `credential_offer_uri` URLs for credential offers passed by reference.
## Background
The `CredentialOfferSource` enum supports two variants:
- `ByValue(CredentialOffer)` - Already parsed credential offer
- `ByReference(String)` - URI that needs to be fetched
Currently, only the `ByValue` path is fully implemented. We need to implement the HTTP fetch to dereference `ByReference` URIs.
## Requirements
- Add HTTP client dependency (e.g., `reqwest` or use existing)
- Implement `resolve()` method on `CredentialOfferUri` that:
- Returns the `CredentialOffer` directly for `ByValue`
- Fetches and parses the JSON for `ByReference`
- Handle errors appropriately (network errors, invalid JSON, etc.)
- Add tests for URI dereferencing
## Related
- PR #77 - Credential offer data models
- OpenID4VCI Section 4.1
## Milestone
M1
Guida per i contributori
Apri la guida per i contributori
Valutazione
Questa issue non è ancora stata valutata.