Broadcast Delegation
curl --request POST \
--url https://api.minaexplorer.com/broadcast/delegation \
--header 'Content-Type: application/json' \
--data '
{
"publicKey": "<string>",
"signature": {
"field": "<string>",
"scalar": "<string>"
},
"payload": {
"to": "<string>",
"from": "<string>",
"fee": "<string>",
"nonce": "<string>",
"memo": "<string>",
"validUntil": "<string>"
}
}
'import requests
url = "https://api.minaexplorer.com/broadcast/delegation"
payload = {
"publicKey": "<string>",
"signature": {
"field": "<string>",
"scalar": "<string>"
},
"payload": {
"to": "<string>",
"from": "<string>",
"fee": "<string>",
"nonce": "<string>",
"memo": "<string>",
"validUntil": "<string>"
}
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
publicKey: '<string>',
signature: {field: '<string>', scalar: '<string>'},
payload: {
to: '<string>',
from: '<string>',
fee: '<string>',
nonce: '<string>',
memo: '<string>',
validUntil: '<string>'
}
})
};
fetch('https://api.minaexplorer.com/broadcast/delegation', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.minaexplorer.com/broadcast/delegation",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'publicKey' => '<string>',
'signature' => [
'field' => '<string>',
'scalar' => '<string>'
],
'payload' => [
'to' => '<string>',
'from' => '<string>',
'fee' => '<string>',
'nonce' => '<string>',
'memo' => '<string>',
'validUntil' => '<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.minaexplorer.com/broadcast/delegation"
payload := strings.NewReader("{\n \"publicKey\": \"<string>\",\n \"signature\": {\n \"field\": \"<string>\",\n \"scalar\": \"<string>\"\n },\n \"payload\": {\n \"to\": \"<string>\",\n \"from\": \"<string>\",\n \"fee\": \"<string>\",\n \"nonce\": \"<string>\",\n \"memo\": \"<string>\",\n \"validUntil\": \"<string>\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.minaexplorer.com/broadcast/delegation")
.header("Content-Type", "application/json")
.body("{\n \"publicKey\": \"<string>\",\n \"signature\": {\n \"field\": \"<string>\",\n \"scalar\": \"<string>\"\n },\n \"payload\": {\n \"to\": \"<string>\",\n \"from\": \"<string>\",\n \"fee\": \"<string>\",\n \"nonce\": \"<string>\",\n \"memo\": \"<string>\",\n \"validUntil\": \"<string>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.minaexplorer.com/broadcast/delegation")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"publicKey\": \"<string>\",\n \"signature\": {\n \"field\": \"<string>\",\n \"scalar\": \"<string>\"\n },\n \"payload\": {\n \"to\": \"<string>\",\n \"from\": \"<string>\",\n \"fee\": \"<string>\",\n \"nonce\": \"<string>\",\n \"memo\": \"<string>\",\n \"validUntil\": \"<string>\"\n }\n}"
response = http.request(request)
puts response.read_body{
"message": "Delegation broadcast sucessfully",
"result": {
"delegation": {
"amount": "0",
"fee": "1000000000",
"feePayer": {
"publicKey": "B62qogU1qY33L8jwRmkwjN42xpSNrv8UkxaKrRFZxJSgbaNRMtpMTg7",
"token": "1"
},
"feeToken": "1",
"from": "B62qogU1qY33L8jwRmkwjN42xpSNrv8UkxaKrRFZxJSgbaNRMtpMTg7",
"fromAccount": {
"publicKey": "B62qogU1qY33L8jwRmkwjN42xpSNrv8UkxaKrRFZxJSgbaNRMtpMTg7",
"token": "1"
},
"hash": "CkpZA61vQ3Qfnh95NT3pDZEtS5sBZhhEQfdKbSEkj1kQN2kMQveqp",
"id": "MVvtsE9mBNhZwuMWvq6EdFTzPkvPmAgNRa3FCuzAFBxcjjmbUt6idiBPJGoQ3nvH2X5rJSFK6YMUyLCnLhPvSeKa49yiBq91AKKNYy5jjMRGegJFTi2dzfxcGiL92Lfv8YR8p8oLZB8jrgD386vcmq8AXvCRqhvbAuaSMHMTkfBb2jk6pHsmMTioytjk96m4fa8WW8UpVXVK8bYh9MvG42CQLgh42r7gpcSVpesZMuEpqmH3h4QScnBnTxkNqdru56Vbm3NthBChb1StfgpYNe8CxgHftRvWoEKfq2ECDAFLDxWTq39UARbvk3mB57cXbcKQANcEfyy5FMPJRnUv28tK7sZqUtVHcMpHrpxHnqw9LbDrW33qb1jB2kFQvZ",
"isDelegation": true,
"kind": "STAKE_DELEGATION",
"memo": "E4YxYSicMBEwDPtHBz4t7UQpbFKxL8yvrzYPM4Ee8U9uAWWX4Sa7v",
"nonce": 1328,
"receiver": {
"publicKey": "B62qpge4uMq4Vv5Rvc8Gw9qSquUYd6xoW1pz7HQkMSHm6h1o7pvLPAN",
"token": "1"
},
"source": {
"publicKey": "B62qogU1qY33L8jwRmkwjN42xpSNrv8UkxaKrRFZxJSgbaNRMtpMTg7",
"token": "1"
},
"to": "B62qpge4uMq4Vv5Rvc8Gw9qSquUYd6xoW1pz7HQkMSHm6h1o7pvLPAN",
"token": "1",
"toAccount": {
"token": "1",
"publicKey": "B62qpge4uMq4Vv5Rvc8Gw9qSquUYd6xoW1pz7HQkMSHm6h1o7pvLPAN"
}
}
}
}{
"message": "Error in sending delegation",
"error": "Query failed -- returned code 200. mutation($from:PublicKey!, $to:PublicKey!, $fee:UInt64!, $memo:String, $scalar:String, $field:String){ sendDelegation(input: { from:$from, to:$to, fee:$fee, memo:$memo, }, signature:{ scalar: $scalar, field: $field, }) { delegation { amount fee feePayer { publicKey token } feeToken from fromAccount { publicKey token } hash id isDelegation kind memo nonce receiver { publicKey token } source { publicKey token } to token toAccount { token publicKey } } } }"
}broadcast
Broadcast Delegation
Broadcasts a signed delegation transaction to the Mina blockchain
POST
/
broadcast
/
delegation
Broadcast Delegation
curl --request POST \
--url https://api.minaexplorer.com/broadcast/delegation \
--header 'Content-Type: application/json' \
--data '
{
"publicKey": "<string>",
"signature": {
"field": "<string>",
"scalar": "<string>"
},
"payload": {
"to": "<string>",
"from": "<string>",
"fee": "<string>",
"nonce": "<string>",
"memo": "<string>",
"validUntil": "<string>"
}
}
'import requests
url = "https://api.minaexplorer.com/broadcast/delegation"
payload = {
"publicKey": "<string>",
"signature": {
"field": "<string>",
"scalar": "<string>"
},
"payload": {
"to": "<string>",
"from": "<string>",
"fee": "<string>",
"nonce": "<string>",
"memo": "<string>",
"validUntil": "<string>"
}
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
publicKey: '<string>',
signature: {field: '<string>', scalar: '<string>'},
payload: {
to: '<string>',
from: '<string>',
fee: '<string>',
nonce: '<string>',
memo: '<string>',
validUntil: '<string>'
}
})
};
fetch('https://api.minaexplorer.com/broadcast/delegation', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.minaexplorer.com/broadcast/delegation",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'publicKey' => '<string>',
'signature' => [
'field' => '<string>',
'scalar' => '<string>'
],
'payload' => [
'to' => '<string>',
'from' => '<string>',
'fee' => '<string>',
'nonce' => '<string>',
'memo' => '<string>',
'validUntil' => '<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.minaexplorer.com/broadcast/delegation"
payload := strings.NewReader("{\n \"publicKey\": \"<string>\",\n \"signature\": {\n \"field\": \"<string>\",\n \"scalar\": \"<string>\"\n },\n \"payload\": {\n \"to\": \"<string>\",\n \"from\": \"<string>\",\n \"fee\": \"<string>\",\n \"nonce\": \"<string>\",\n \"memo\": \"<string>\",\n \"validUntil\": \"<string>\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.minaexplorer.com/broadcast/delegation")
.header("Content-Type", "application/json")
.body("{\n \"publicKey\": \"<string>\",\n \"signature\": {\n \"field\": \"<string>\",\n \"scalar\": \"<string>\"\n },\n \"payload\": {\n \"to\": \"<string>\",\n \"from\": \"<string>\",\n \"fee\": \"<string>\",\n \"nonce\": \"<string>\",\n \"memo\": \"<string>\",\n \"validUntil\": \"<string>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.minaexplorer.com/broadcast/delegation")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"publicKey\": \"<string>\",\n \"signature\": {\n \"field\": \"<string>\",\n \"scalar\": \"<string>\"\n },\n \"payload\": {\n \"to\": \"<string>\",\n \"from\": \"<string>\",\n \"fee\": \"<string>\",\n \"nonce\": \"<string>\",\n \"memo\": \"<string>\",\n \"validUntil\": \"<string>\"\n }\n}"
response = http.request(request)
puts response.read_body{
"message": "Delegation broadcast sucessfully",
"result": {
"delegation": {
"amount": "0",
"fee": "1000000000",
"feePayer": {
"publicKey": "B62qogU1qY33L8jwRmkwjN42xpSNrv8UkxaKrRFZxJSgbaNRMtpMTg7",
"token": "1"
},
"feeToken": "1",
"from": "B62qogU1qY33L8jwRmkwjN42xpSNrv8UkxaKrRFZxJSgbaNRMtpMTg7",
"fromAccount": {
"publicKey": "B62qogU1qY33L8jwRmkwjN42xpSNrv8UkxaKrRFZxJSgbaNRMtpMTg7",
"token": "1"
},
"hash": "CkpZA61vQ3Qfnh95NT3pDZEtS5sBZhhEQfdKbSEkj1kQN2kMQveqp",
"id": "MVvtsE9mBNhZwuMWvq6EdFTzPkvPmAgNRa3FCuzAFBxcjjmbUt6idiBPJGoQ3nvH2X5rJSFK6YMUyLCnLhPvSeKa49yiBq91AKKNYy5jjMRGegJFTi2dzfxcGiL92Lfv8YR8p8oLZB8jrgD386vcmq8AXvCRqhvbAuaSMHMTkfBb2jk6pHsmMTioytjk96m4fa8WW8UpVXVK8bYh9MvG42CQLgh42r7gpcSVpesZMuEpqmH3h4QScnBnTxkNqdru56Vbm3NthBChb1StfgpYNe8CxgHftRvWoEKfq2ECDAFLDxWTq39UARbvk3mB57cXbcKQANcEfyy5FMPJRnUv28tK7sZqUtVHcMpHrpxHnqw9LbDrW33qb1jB2kFQvZ",
"isDelegation": true,
"kind": "STAKE_DELEGATION",
"memo": "E4YxYSicMBEwDPtHBz4t7UQpbFKxL8yvrzYPM4Ee8U9uAWWX4Sa7v",
"nonce": 1328,
"receiver": {
"publicKey": "B62qpge4uMq4Vv5Rvc8Gw9qSquUYd6xoW1pz7HQkMSHm6h1o7pvLPAN",
"token": "1"
},
"source": {
"publicKey": "B62qogU1qY33L8jwRmkwjN42xpSNrv8UkxaKrRFZxJSgbaNRMtpMTg7",
"token": "1"
},
"to": "B62qpge4uMq4Vv5Rvc8Gw9qSquUYd6xoW1pz7HQkMSHm6h1o7pvLPAN",
"token": "1",
"toAccount": {
"token": "1",
"publicKey": "B62qpge4uMq4Vv5Rvc8Gw9qSquUYd6xoW1pz7HQkMSHm6h1o7pvLPAN"
}
}
}
}{
"message": "Error in sending delegation",
"error": "Query failed -- returned code 200. mutation($from:PublicKey!, $to:PublicKey!, $fee:UInt64!, $memo:String, $scalar:String, $field:String){ sendDelegation(input: { from:$from, to:$to, fee:$fee, memo:$memo, }, signature:{ scalar: $scalar, field: $field, }) { delegation { amount fee feePayer { publicKey token } feeToken from fromAccount { publicKey token } hash id isDelegation kind memo nonce receiver { publicKey token } source { publicKey token } to token toAccount { token publicKey } } } }"
}Body
application/jsonapplication/xml
Signed delegation transaction
⌘I