Frontend
Create a new donor and process their donation
POST
/
frontend
/
checkout
/
signup
/
{client_id}
/
{program_id}
/
{session_id}
Create a new donor and process their donation
curl --request POST \
--url https://api.helpyousponsor.com/v1/frontend/checkout/signup/{client_id}/{program_id}/{session_id} \
--header 'Content-Type: application/json' \
--data '
{
"signup_username": "donor123",
"email": "donor@gmail.com",
"signup_password": "password123",
"method_signup": "3",
"firstName": "John",
"lastName": "Doe",
"cardHolderName": "John Doe",
"dn_donor_name": "John Doe",
"paying_processing": "1",
"rememberMe": "false",
"token": "token123"
}
'import requests
url = "https://api.helpyousponsor.com/v1/frontend/checkout/signup/{client_id}/{program_id}/{session_id}"
payload = {
"signup_username": "donor123",
"email": "donor@gmail.com",
"signup_password": "password123",
"method_signup": "3",
"firstName": "John",
"lastName": "Doe",
"cardHolderName": "John Doe",
"dn_donor_name": "John Doe",
"paying_processing": "1",
"rememberMe": "false",
"token": "token123"
}
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({
signup_username: 'donor123',
email: 'donor@gmail.com',
signup_password: 'password123',
method_signup: '3',
firstName: 'John',
lastName: 'Doe',
cardHolderName: 'John Doe',
dn_donor_name: 'John Doe',
paying_processing: '1',
rememberMe: 'false',
token: 'token123'
})
};
fetch('https://api.helpyousponsor.com/v1/frontend/checkout/signup/{client_id}/{program_id}/{session_id}', 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.helpyousponsor.com/v1/frontend/checkout/signup/{client_id}/{program_id}/{session_id}",
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([
'signup_username' => 'donor123',
'email' => 'donor@gmail.com',
'signup_password' => 'password123',
'method_signup' => '3',
'firstName' => 'John',
'lastName' => 'Doe',
'cardHolderName' => 'John Doe',
'dn_donor_name' => 'John Doe',
'paying_processing' => '1',
'rememberMe' => 'false',
'token' => 'token123'
]),
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.helpyousponsor.com/v1/frontend/checkout/signup/{client_id}/{program_id}/{session_id}"
payload := strings.NewReader("{\n \"signup_username\": \"donor123\",\n \"email\": \"donor@gmail.com\",\n \"signup_password\": \"password123\",\n \"method_signup\": \"3\",\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"cardHolderName\": \"John Doe\",\n \"dn_donor_name\": \"John Doe\",\n \"paying_processing\": \"1\",\n \"rememberMe\": \"false\",\n \"token\": \"token123\"\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.helpyousponsor.com/v1/frontend/checkout/signup/{client_id}/{program_id}/{session_id}")
.header("Content-Type", "application/json")
.body("{\n \"signup_username\": \"donor123\",\n \"email\": \"donor@gmail.com\",\n \"signup_password\": \"password123\",\n \"method_signup\": \"3\",\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"cardHolderName\": \"John Doe\",\n \"dn_donor_name\": \"John Doe\",\n \"paying_processing\": \"1\",\n \"rememberMe\": \"false\",\n \"token\": \"token123\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.helpyousponsor.com/v1/frontend/checkout/signup/{client_id}/{program_id}/{session_id}")
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 \"signup_username\": \"donor123\",\n \"email\": \"donor@gmail.com\",\n \"signup_password\": \"password123\",\n \"method_signup\": \"3\",\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"cardHolderName\": \"John Doe\",\n \"dn_donor_name\": \"John Doe\",\n \"paying_processing\": \"1\",\n \"rememberMe\": \"false\",\n \"token\": \"token123\"\n}"
response = http.request(request)
puts response.read_body{
"status": "success",
"redirect": "/frontend/donor_view/1/1/1",
"email": "donor@gmail.com",
"username": "donor123",
"message": "You have successfully signed up!"
}{
"status": "error",
"email": "donor@example.com",
"username": "donor123",
"redirect": "/frontend/donor_view/1/1/1",
"message": "Donation failed, error message"
}{
"message": "Validation error",
"errors": {}
}Path Parameters
The ID of the client
The ID of the program
The ID of the session
Body
application/json
Donor and donation details
Example:
"donor123"
Example:
"donor@gmail.com"
Example:
"password123"
Example:
"3"
Example:
"John"
Example:
"Doe"
Example:
"John Doe"
Example:
"John Doe"
Example:
"1"
Example:
"false"
Example:
"token123"
Previous
Forgot UsernameHandles the process for users who have forgotten their username by initiating a new session.
Next
⌘I
Create a new donor and process their donation
curl --request POST \
--url https://api.helpyousponsor.com/v1/frontend/checkout/signup/{client_id}/{program_id}/{session_id} \
--header 'Content-Type: application/json' \
--data '
{
"signup_username": "donor123",
"email": "donor@gmail.com",
"signup_password": "password123",
"method_signup": "3",
"firstName": "John",
"lastName": "Doe",
"cardHolderName": "John Doe",
"dn_donor_name": "John Doe",
"paying_processing": "1",
"rememberMe": "false",
"token": "token123"
}
'import requests
url = "https://api.helpyousponsor.com/v1/frontend/checkout/signup/{client_id}/{program_id}/{session_id}"
payload = {
"signup_username": "donor123",
"email": "donor@gmail.com",
"signup_password": "password123",
"method_signup": "3",
"firstName": "John",
"lastName": "Doe",
"cardHolderName": "John Doe",
"dn_donor_name": "John Doe",
"paying_processing": "1",
"rememberMe": "false",
"token": "token123"
}
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({
signup_username: 'donor123',
email: 'donor@gmail.com',
signup_password: 'password123',
method_signup: '3',
firstName: 'John',
lastName: 'Doe',
cardHolderName: 'John Doe',
dn_donor_name: 'John Doe',
paying_processing: '1',
rememberMe: 'false',
token: 'token123'
})
};
fetch('https://api.helpyousponsor.com/v1/frontend/checkout/signup/{client_id}/{program_id}/{session_id}', 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.helpyousponsor.com/v1/frontend/checkout/signup/{client_id}/{program_id}/{session_id}",
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([
'signup_username' => 'donor123',
'email' => 'donor@gmail.com',
'signup_password' => 'password123',
'method_signup' => '3',
'firstName' => 'John',
'lastName' => 'Doe',
'cardHolderName' => 'John Doe',
'dn_donor_name' => 'John Doe',
'paying_processing' => '1',
'rememberMe' => 'false',
'token' => 'token123'
]),
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.helpyousponsor.com/v1/frontend/checkout/signup/{client_id}/{program_id}/{session_id}"
payload := strings.NewReader("{\n \"signup_username\": \"donor123\",\n \"email\": \"donor@gmail.com\",\n \"signup_password\": \"password123\",\n \"method_signup\": \"3\",\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"cardHolderName\": \"John Doe\",\n \"dn_donor_name\": \"John Doe\",\n \"paying_processing\": \"1\",\n \"rememberMe\": \"false\",\n \"token\": \"token123\"\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.helpyousponsor.com/v1/frontend/checkout/signup/{client_id}/{program_id}/{session_id}")
.header("Content-Type", "application/json")
.body("{\n \"signup_username\": \"donor123\",\n \"email\": \"donor@gmail.com\",\n \"signup_password\": \"password123\",\n \"method_signup\": \"3\",\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"cardHolderName\": \"John Doe\",\n \"dn_donor_name\": \"John Doe\",\n \"paying_processing\": \"1\",\n \"rememberMe\": \"false\",\n \"token\": \"token123\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.helpyousponsor.com/v1/frontend/checkout/signup/{client_id}/{program_id}/{session_id}")
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 \"signup_username\": \"donor123\",\n \"email\": \"donor@gmail.com\",\n \"signup_password\": \"password123\",\n \"method_signup\": \"3\",\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"cardHolderName\": \"John Doe\",\n \"dn_donor_name\": \"John Doe\",\n \"paying_processing\": \"1\",\n \"rememberMe\": \"false\",\n \"token\": \"token123\"\n}"
response = http.request(request)
puts response.read_body{
"status": "success",
"redirect": "/frontend/donor_view/1/1/1",
"email": "donor@gmail.com",
"username": "donor123",
"message": "You have successfully signed up!"
}{
"status": "error",
"email": "donor@example.com",
"username": "donor123",
"redirect": "/frontend/donor_view/1/1/1",
"message": "Donation failed, error message"
}{
"message": "Validation error",
"errors": {}
}
