Invalidates delegated stake transaction either by `hash`, `cert name` or `cert public key hash` and returns locked [[Token Delegated (m-token)|m-tokens]] to the wallet. `Command syntax:` ```actionscript srv_stake invalidate -net <net_name> {-tx <transaction_hash> -w <wallet_name> -fee <value> | -siging_pkey_hash <pkey_hash> -signing_pkey_type <pkey_type> -poa_cert <cert_name>} ``` `Options:` ```actionscript -net - name of the Cellframe Network. The list of networks can be found in the <Config_dir> \ etc \ network folder or received by The Cellframe-Node-CLI using command - net list -tx - hash of the delegation transaction -w - the name of the wallet where funds will be returned -fee - commission sum *** or -siging_pkey_hash - public key hash of the signer -signing_pkey_type - type of the public key of a signer -poa_cert - root node certificate ``` ### CLI Example If `-w,-fee` were specified, a transaction will be created. `Command:` ```actionscript cellframe-node-cli srv_stake invalidate -net foobar -tx 0x908DAC21FD62DD1CE8DA2A4F41DE2550A05A6EE6C85ED582C231E2CB976AD776 -w foobar_master_1 -fee 5.0e+18 ``` `Response 1:` ``` Transaction 0x908DAC21FD62DD1CE8DA2A4F41DE2550A05A6EE6C85ED582C231E2CB976AD776 has active delegated key 0x332EE135EB8D38045AFECD0E261AC1EE6CFCA6A3B171A3E67259709253AA4303, need to revoke it first ``` `Response 2:` ``` All m-tokens successfully returned to owner. Returning tx hash 0xD5E031714476D78C0CD59E5250BC9C7D4C7FDBFC2CAADF49154D021A822AB3B6. ``` If `-poa_cert` was specified then decree of key recall will be created. `Command:` ```actionscript cellframe-node-cli srv_stake invalidate -net foobar -signing_pkey_hash 0x332EE135EB8D38045AFECD0E261AC1EE6CFCA6A3B171A3E67259709253AA4303 -signing_pkey_type sig_dil  -poa_cert foobar.root.pvt.0 ``` `Response:` ``` Specified delegated key invalidated. Created key invalidation decree 0x6A692BCC1186E138B971870A1DE738AE680341538B2163980D2D4378CC538BCB.Try to execute this command with -w to return m-tokens to owner ``` ### JSON-RPC Example ![[JSON-RPC Request - SRV_STAKE INVALIDATE]]