Payout details
Retrieving payout details
To get detailed information about a specific payout from the Tulu Switch API, you can use a GET request to the payout's endpoint. Below is an example using cURL:
const handleGenerateKeys = async () => {
try {
// Send a POST request to the API endpoint to generate keys
const resp = await fetchJson(`/api/dbo/settings/keys?t=key`, {
method: "POST",
headers: {
token: token, // Token for authorization
"Content-Type": "application/json", // Request content type
},
});
// Log the response from the API
console.log(resp);
// If the response status code is '00',
update input values with generated keys
if (resp.statusCode === "00") {
setInputValue(resp.data.sk_live); // Update input with secret key
setInputValue1(resp.data.pk_live); // Update input with public key
} else {
// Handle other response status codes if needed
}
} catch (error) {
// Log any errors that occur during the process
console.log(error);
}
}
Request details
Response details
A successful response will contain a JSON object with detailed payout information. Here's a simplified example:
const handleGenerateKeys = async () => {
try {
// Send a POST request to the API
endpoint to generate keys
const resp = await fetchJson(`/api/dbo/settings/keys?t=key`, {
method: "POST",
headers: {
token: token, // Token for authorization
"Content-Type": "application/json", // Request content type
},
});
// Log the response from the API
console.log(resp);
// If the response status code is '00',
update input values with generated keys
if (resp.statusCode === "00") {
setInputValue(resp.data.sk_live); // Update input with secret key
setInputValue1(resp.data.pk_live); // Update input with public key
} else {
// Handle other response status codes if needed
}
} catch (error) {
// Log any errors that occur during the process
console.log(error);
}
}
Contact Us for Developer Support
Contact our dedicated developer support team for assistance, guidance, or any questions you have regarding Tuluswitch API integration. We're here to ensure your development experience is smooth and successful.
Read Our Developer Blog for Insights
Master the Tuluswitch API with our Developer Blog! Get expert insights, advanced tips, and industry trends beyond the documentation. Stay connected with the developer community to build exceptional payment platforms. Visit the blog now and unlock your full potential!