PermissionedDomainSet

[Source]

Create a permissioned domain, or modify one that you own.

(Requires the PermissionedDomains amendment )

Example PermissionedDomainSet JSON

{
  "TransactionType": "PermissionedDomainSet",
  "Account": "rf1BiGeXwwQoi8Z2ueFYTEXSwuJYfV2Jpn",
  "Fee": "10",
  "Sequence": 390,
  "AcceptedCredentials": [
    {
        "Credential": {
            "Issuer": "ra5nK24KXen9AHvsdFTKHSANinZseWnPcX",
            "CredentialType": "6D795F63726564656E7469616C"
        }
    }
  ]
}

PermissionedDomainSet Fields

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

FieldJSON TypeInternal TypeRequired?Description
DomainIDString - HashHash256NoThe ledger entry ID of an existing permissioned domain to modify. If omitted, creates a new permissioned domain.
AcceptedCredentialsArrayArrayYesA list of 1 to 10 Accepted Credentials objects that grant access to this domain. The list does not need to be sorted, but it cannot contain duplicates. When modifying an existing domain, this list replaces the existing list.

AcceptedCredentials Objects

Each member of the AcceptedCredentials array is an inner object named Credential with the following nested fields:

FieldJSON TypeInternal TypeRequired?Description
IssuerString - AddressAccountIDYesThe issuer of the credential.
CredentialTypeStringBlobYesThe type of credential, as hexadecimal. This is an arbitrary value from 1 to 64 bytes that the issuer sets when they issue a credential.
Note

In the usual JSON format, inner objects are wrapped in an object with one field, whose name defines the inner object type. In this case, the wrapping field is named Credential. For example:

"AcceptedCredentials": [
    {
        "Credential": {
            "Issuer": "ra5nK24KXen9AHvsdFTKHSANinZseWnPcX",
            "CredentialType": "6D795F63726564656E7469616C"
        }
    },
    // ... additional Credential inner objects ...
]

PermissionedDomainSet Flags

There are no flags defined for PermissionedDomainSet transactions.

Error Cases

Besides errors that can occur for all transactions, PermissionedDomainSet transactions can result in the following transaction result codes:

Error CodeDescription
tecDIR_FULLThe transaction would create a new PermissionedDomain, but the sender's owner directory is full.
tecINSUFFICIENT_RESERVEThe transaction would create a new PermissionedDomain, but the sender does not have enough XRP to meet the increased owner reserve.
tecNO_ENTRYThe transaction attempted to modify a Domain that does not exist. Check the DomainID field of the transaction.
tecNO_ISSUERAt least one of the issuers specified in the AcceptedCredentials field is does not exist in the XRP Ledger. Check the Issuer field of each member of the array.
tecNO_PERMISSIONThe transaction attempted to modify an existing Domain, but the sender of the transaction is not the owner of the specified Domain.
temDISABLEDEither the PermissionedDomains amendment is not enabled, or the Credentials amendment is not enabled.