xrp

XRP (XRP)

Method: POST channel_authorize

dropdown

POST channel_authorize

The channel_authorize method creates a signature that can be used to redeem a specific amount of XRP from a payment channel.

Parameters

channel_id - String

The unique ID of the payment channel to use.

secret - String

(Optional) The secret key to use to sign the claim.

This must be the same key pair as the public key specified in the channel.

Cannot be used with seed, seed_hex, or passphrase.

seed - String

(Optional) The secret seed to use to sign the claim.

This must be the same key pair as the public key specified in the channel.

Must be in the XRP Ledger's base58 format.

If provided, you must also specify the key_type.

Cannot be used with secret, seed_hex, or passphrase.

seed_hex - String

(Optional) The secret seed to use to sign the claim.

This must be the same key pair as the public key specified in the channel.

Must be in hexadecimal format. If provided, you must also specify the key_type.

Cannot be used with secret, seed, or passphrase.

passphrase - String

(Optional) A string passphrase to use to sign the claim.

This must be the same key pair as the public key specified in the channel.

The key derived from this passphrase must match the public key specified in the channel.

If provided, you must also specify the key_type.

Cannot be used with secret, seed, or seed_hex.

key_type - String

(Optional) The signing algorithm of the cryptographic key pair provided.

Valid types are secp256k1 or ed25519. The default is secp256k1.

amount - String

Cumulative amount of XRP, in drops, to authorize.

If the destination has already received a lesser amount of XRP from this channel, the signature created by this method can be redeemed for the difference.

Request

curl --location --request POST 'https://xrp.getblock.io' 
--header 'x-api-key: YOUR-API-KEY' 
--header 'Content-Type: application/json' 
--data-raw '{"jsonrpc": "2.0",
"method": "channel_authorize",
"params": [{"channel_id": "5DB01B7FFED6B67E6B0414DED11E051D2EE2B7619CE0EAA6286D67A3A4D5BDB3", "amount": 1000000}],
"id": "getblock.io"}'


Response

{
    "result": {
        "signature": "304402204EF0AFB78AC23ED1C472E74F4299C0C21F1B21D07EFC0A3838A420F76D783A400220154FB11B6F54320666E4C36CA7F686C16A3A0456800BBC43746F34AF50290064",
        "status": "success"
    }
}
GetBlock.io

Get access to 40+ blockchain nodes right now! GetBlock provides a fast and reliable connection for the most popular cryptocurrencies` nodes.

Subscribe

Email is invalid

2019 - 2021 GetBlock