Withdraw Pending Tokens Parameters
curl --request GET \
--url https://portal-api.magna.so/api/{portalId}/parameters/staking-withdrawimport requests
url = "https://portal-api.magna.so/api/{portalId}/parameters/staking-withdraw"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://portal-api.magna.so/api/{portalId}/parameters/staking-withdraw', 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://portal-api.magna.so/api/{portalId}/parameters/staking-withdraw",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://portal-api.magna.so/api/{portalId}/parameters/staking-withdraw"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://portal-api.magna.so/api/{portalId}/parameters/staking-withdraw")
.asString();require 'uri'
require 'net/http'
url = URI("https://portal-api.magna.so/api/{portalId}/parameters/staking-withdraw")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"from": "0x99Fcf70F401A2308C37C7e8d726fFBfe89AF1Bbd",
"to": "0x1d654f0984e9f42BF8F9bD69A6C23965310c81D1",
"data": "0x1bff5ed900000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000002463383662336533632d636633382d343139302d626539662d62373936386238353662373800000000000000000000000000000000000000000000000000000000",
"platformFee": "0"
}{
"errors": [
{
"path": "query.wallet",
"message": "Required"
}
]
}{
"error": "STAKE_NOT_FOUND"
}{
"error": "internal server error"
}Staking
Withdraw Pending Tokens Parameters
Constructs transaction parameters for withdrawing tokens so the user could sign it
GET
/
api
/
{portalId}
/
parameters
/
staking-withdraw
Withdraw Pending Tokens Parameters
curl --request GET \
--url https://portal-api.magna.so/api/{portalId}/parameters/staking-withdrawimport requests
url = "https://portal-api.magna.so/api/{portalId}/parameters/staking-withdraw"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://portal-api.magna.so/api/{portalId}/parameters/staking-withdraw', 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://portal-api.magna.so/api/{portalId}/parameters/staking-withdraw",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://portal-api.magna.so/api/{portalId}/parameters/staking-withdraw"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://portal-api.magna.so/api/{portalId}/parameters/staking-withdraw")
.asString();require 'uri'
require 'net/http'
url = URI("https://portal-api.magna.so/api/{portalId}/parameters/staking-withdraw")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"from": "0x99Fcf70F401A2308C37C7e8d726fFBfe89AF1Bbd",
"to": "0x1d654f0984e9f42BF8F9bD69A6C23965310c81D1",
"data": "0x1bff5ed900000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000002463383662336533632d636633382d343139302d626539662d62373936386238353662373800000000000000000000000000000000000000000000000000000000",
"platformFee": "0"
}{
"errors": [
{
"path": "query.wallet",
"message": "Required"
}
]
}{
"error": "STAKE_NOT_FOUND"
}{
"error": "internal server error"
}⌘I