CredentialAccept Transaction

A CredentialAccept transaction accepts a credential, which makes the credential valid. Only the subject of the credential can do this.

Example CredentialAccept JSON

{
    "TransactionType" : "CredentialAccept",
    "Account": "rsUiUMpnrgxQp24dJYZDhmV4bE3aBtQyt8",
    "Issuer": "ra5nK24KXen9AHvsdFTKHSANinZseWnPcX",
    "CredentialType": "6D795F63726564656E7469616C",
    "Fee": "10",
    "Flags": 0,
    "Sequence": 234203
}

CredentialAccept Fields

In addition to the common fields, CredentialAccept transactions use the following fields:

FieldJSON TypeInternal TypeRequired?Description
IssuerString - AddressAccountIDYesThe address of the issuer that created the credential.
CredentialTypeStringBlobYesArbitrary data defining the type of credential. The minimum size is 1 byte and the maximum is 64 bytes.

The Account field (the sender of this transaction) must be the subject of the credential.

The combination of Account, Issuer, and CredentialType must match a Credential ledger entry that exists in the ledger and has not already been accepted; otherwise, the transaction fails.

Error Cases

Error CodeDescription
tecDUPLICATEThe specified credential has already been accepted.
tecEXPIREDThe specified credential has an expiration time in the past. (In this case, the transaction also deletes the expired credentials from the ledger.)
tecNO_ENTRYThe credential uniquely identified by the Account, Issuer, and CredentialType fields of the transaction does not exist in the ledger.
temDISABLEDThe related amendment is not enabled.
temINVALID_ACCOUNT_IDThe provided Issuer field is invalid. For example, it contains ACCOUNT_ZERO.