aries_cloudagent.protocols.present_proof.v1_0.messages.inner package¶
Submodules¶
aries_cloudagent.protocols.present_proof.v1_0.messages.inner.presentation_preview module¶
A presentation preview inner object.
-
class
aries_cloudagent.protocols.present_proof.v1_0.messages.inner.presentation_preview.
PresAttrSpec
(name: str, *, cred_def_id: str = None, mime_type: str = None, value: str = None, referent: str = None, **kwargs)[source]¶ Bases:
aries_cloudagent.messaging.models.base.BaseModel
Class representing an attibute specification within a presentation preview.
-
class
Posture
[source]¶ Bases:
enum.Enum
Attribute posture: self-attested, revealed claim or unrevealed claim.
-
REVEALED_CLAIM
= 1¶
-
SELF_ATTESTED
= 0¶
-
UNREVEALED_CLAIM
= 2¶
-
-
static
list_plain
(plain: dict, cred_def_id: str, referent: str = None)[source]¶ Return a list of PresAttrSpec on input cred def id.
Parameters: - plain – dict mapping names to values
- cred_def_id – credential definition identifier to specify
- referent – single referent to use, omit for none
Returns: List of PresAttrSpec on input cred def id with no MIME types
-
posture
¶ self-attested, revealed claim, or unrevealed claim.
Type: Attribute posture
-
class
-
class
aries_cloudagent.protocols.present_proof.v1_0.messages.inner.presentation_preview.
PresAttrSpecSchema
(*args, **kwargs)[source]¶ Bases:
aries_cloudagent.messaging.models.base.BaseModelSchema
Attribute specifiation schema.
-
class
Meta
[source]¶ Bases:
object
Attribute specifiation schema metadata.
-
model_class
¶ alias of
PresAttrSpec
-
-
cred_def_id
= <fields.String(default=<marshmallow.missing>, attribute=None, validate=<aries_cloudagent.messaging.valid.IndyCredDefId object>, required=False, load_only=False, dump_only=False, missing=<marshmallow.missing>, allow_none=False, error_messages={'required': 'Missing data for required field.', 'null': 'Field may not be null.', 'validator_failed': 'Invalid value.', 'invalid': 'Not a valid string.', 'invalid_utf8': 'Not a valid utf-8 string.'})>¶
-
mime_type
= <fields.String(default=<marshmallow.missing>, attribute=None, validate=None, required=False, load_only=False, dump_only=False, missing=<marshmallow.missing>, allow_none=False, error_messages={'required': 'Missing data for required field.', 'null': 'Field may not be null.', 'validator_failed': 'Invalid value.', 'invalid': 'Not a valid string.', 'invalid_utf8': 'Not a valid utf-8 string.'})>¶
-
name
= <fields.String(default=<marshmallow.missing>, attribute=None, validate=None, required=True, load_only=False, dump_only=False, missing=<marshmallow.missing>, allow_none=False, error_messages={'required': 'Missing data for required field.', 'null': 'Field may not be null.', 'validator_failed': 'Invalid value.', 'invalid': 'Not a valid string.', 'invalid_utf8': 'Not a valid utf-8 string.'})>¶
-
referent
= <fields.String(default=<marshmallow.missing>, attribute=None, validate=None, required=False, load_only=False, dump_only=False, missing=<marshmallow.missing>, allow_none=False, error_messages={'required': 'Missing data for required field.', 'null': 'Field may not be null.', 'validator_failed': 'Invalid value.', 'invalid': 'Not a valid string.', 'invalid_utf8': 'Not a valid utf-8 string.'})>¶
-
value
= <fields.String(default=<marshmallow.missing>, attribute=None, validate=None, required=False, load_only=False, dump_only=False, missing=<marshmallow.missing>, allow_none=False, error_messages={'required': 'Missing data for required field.', 'null': 'Field may not be null.', 'validator_failed': 'Invalid value.', 'invalid': 'Not a valid string.', 'invalid_utf8': 'Not a valid utf-8 string.'})>¶
-
class
-
class
aries_cloudagent.protocols.present_proof.v1_0.messages.inner.presentation_preview.
PresPredSpec
(name: str, *, cred_def_id: str, predicate: str, threshold: int, **kwargs)[source]¶ Bases:
aries_cloudagent.messaging.models.base.BaseModel
Class representing a predicate specification within a presentation preview.
-
class
aries_cloudagent.protocols.present_proof.v1_0.messages.inner.presentation_preview.
PresPredSpecSchema
(*args, **kwargs)[source]¶ Bases:
aries_cloudagent.messaging.models.base.BaseModelSchema
Predicate specifiation schema.
-
class
Meta
[source]¶ Bases:
object
Predicate specifiation schema metadata.
-
model_class
¶ alias of
PresPredSpec
-
-
cred_def_id
= <fields.String(default=<marshmallow.missing>, attribute=None, validate=<aries_cloudagent.messaging.valid.IndyCredDefId object>, required=True, load_only=False, dump_only=False, missing=<marshmallow.missing>, allow_none=False, error_messages={'required': 'Missing data for required field.', 'null': 'Field may not be null.', 'validator_failed': 'Invalid value.', 'invalid': 'Not a valid string.', 'invalid_utf8': 'Not a valid utf-8 string.'})>¶
-
name
= <fields.String(default=<marshmallow.missing>, attribute=None, validate=None, required=True, load_only=False, dump_only=False, missing=<marshmallow.missing>, allow_none=False, error_messages={'required': 'Missing data for required field.', 'null': 'Field may not be null.', 'validator_failed': 'Invalid value.', 'invalid': 'Not a valid string.', 'invalid_utf8': 'Not a valid utf-8 string.'})>¶
-
predicate
= <fields.String(default=<marshmallow.missing>, attribute=None, validate=<aries_cloudagent.messaging.valid.IndyPredicate object>, required=True, load_only=False, dump_only=False, missing=<marshmallow.missing>, allow_none=False, error_messages={'required': 'Missing data for required field.', 'null': 'Field may not be null.', 'validator_failed': 'Invalid value.', 'invalid': 'Not a valid string.', 'invalid_utf8': 'Not a valid utf-8 string.'})>¶
-
threshold
= <fields.Integer(default=<marshmallow.missing>, attribute=None, validate=None, required=True, load_only=False, dump_only=False, missing=<marshmallow.missing>, allow_none=False, error_messages={'required': 'Missing data for required field.', 'null': 'Field may not be null.', 'validator_failed': 'Invalid value.', 'invalid': 'Not a valid integer.', 'too_large': 'Number too large.'})>¶
-
class
-
class
aries_cloudagent.protocols.present_proof.v1_0.messages.inner.presentation_preview.
PresentationPreview
(*, _type: str = None, attributes: Sequence[aries_cloudagent.protocols.present_proof.v1_0.messages.inner.presentation_preview.PresAttrSpec] = None, predicates: Sequence[aries_cloudagent.protocols.present_proof.v1_0.messages.inner.presentation_preview.PresPredSpec] = None, **kwargs)[source]¶ Bases:
aries_cloudagent.messaging.models.base.BaseModel
Class representing presentation preview.
-
class
Meta
[source]¶ Bases:
object
Presentation preview metadata.
-
message_type
= 'did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/present-proof/1.0/presentation-preview'¶
-
schema_class
= 'PresentationPreviewSchema'¶
-
-
has_attr_spec
(cred_def_id: str, name: str, value: str) → bool[source]¶ Return whether preview contains given attribute specification.
Parameters: - cred_def_id – credential definition identifier
- name – attribute name
- value – attribute value
Returns: Whether preview contains matching attribute specification.
-
indy_proof_request
(name: str = None, version: str = None, nonce: str = None, ledger: aries_cloudagent.ledger.indy.IndyLedger = None, non_revoc_intervals: Mapping[str, aries_cloudagent.revocation.models.indy.NonRevocationInterval] = None) → dict[source]¶ Return indy proof request corresponding to presentation preview.
Typically the verifier turns the proof preview into a proof request.
Parameters: - name – for proof request
- version – version for proof request
- nonce – nonce for proof request
- ledger – ledger with credential definitions, to check for revocation support
- non_revoc_intervals – non-revocation interval to use per cred def id where applicable (default from and to the current time if applicable)
Returns: Indy proof request dict.
-
class
-
class
aries_cloudagent.protocols.present_proof.v1_0.messages.inner.presentation_preview.
PresentationPreviewSchema
(*args, **kwargs)[source]¶ Bases:
aries_cloudagent.messaging.models.base.BaseModelSchema
Presentation preview schema.
-
class
Meta
[source]¶ Bases:
object
Presentation preview schema metadata.
-
model_class
¶ alias of
PresentationPreview
-
-
attributes
= <fields.Nested(default=<marshmallow.missing>, attribute=None, validate=None, required=True, load_only=False, dump_only=False, missing=<marshmallow.missing>, allow_none=False, error_messages={'required': 'Missing data for required field.', 'null': 'Field may not be null.', 'validator_failed': 'Invalid value.', 'type': 'Invalid type.'})>¶
-
predicates
= <fields.Nested(default=<marshmallow.missing>, attribute=None, validate=None, required=True, load_only=False, dump_only=False, missing=<marshmallow.missing>, allow_none=False, error_messages={'required': 'Missing data for required field.', 'null': 'Field may not be null.', 'validator_failed': 'Invalid value.', 'type': 'Invalid type.'})>¶
-
class