Skip to main content

AddAccountPermission

Adds permissions to a specific account on the Shamwari Network.

Request

POST /nxt?requestType=add-account-permission

All endpoints use port 22024 by default.

Parameters

NameTypeDescriptionRequired
recipientstringAccount ID or SHAMWARI address to modifyYes
permissionstringPermission to add (see permission bit values)Yes
secretPhrasestringSender's secret passphraseYes
accountTypeintAccount typeOptional
genderstringGender (M/F/Other)Optional
nationalitystringNationality codeOptional
dateOfBirthintDate of birth (YYYYMMDD)Optional

Permission Values

PermissionDescription
OUTGOING_TRANSACTIONS_ALLOWEDAllow outgoing transactions
INCOMING_TRANSACTIONS_ALLOWEDAllow incoming transactions
ASSET_ISSUANCE_ALLOWEDAllow asset issuance
CURRENCY_ISSUANCE_ALLOWEDAllow currency issuance
ACCOUNT_PROPERTY_SET_ALLOWEDAllow account property setting
ACCOUNT_CONTROLLER_ALLOWEDAllow account controlling
GRAYLISTING_ALLOWEDAllow graylisting

Response

{
"transaction": "1234567890123456789",
"fullHash": "abc123def456...",
"transactionJSON": {
"type": 2,
"subtype": 10,
"timestamp": 123456789,
"deadline": 14400,
"senderPublicKey": "abc123...",
"amountNQT": "0",
"feeNQT": "100000000",
"signature": "def456...",
"attachment": {
"version.AddAccountPermission": 1,
"recipient": "0987654321",
"permission": "CURRENCY_ISSUANCE_ALLOWED"
}
},
"errorCode": 0,
"errorDescription": ""
}

Example

curl -X POST "http://localhost:22024/nxt?requestType=add-account-permission" \
-d "recipient=SHAMWARI-ABCD-EFGH-IJKL-MNOPQ" \
-d "permission=CURRENCY_ISSUANCE_ALLOWED" \
-d "secretPhrase=your_secret_passphrase"