MENU navbar-image

Introduction

This documentation aims to provide all the information you need to work with our API.

<aside>As you scroll, you'll see code examples for working with the API in different programming languages in the dark area to the right (or as part of the content on mobile).
You can switch the language used with the tabs at the top right (or from the nav menu at the top left on mobile).</aside>

Authenticating requests

To authenticate requests, include an Authorization header with the value "Bearer {YOUR_AUTH_KEY}".

All authenticated endpoints are marked with a requires authentication badge in the documentation below.

You can retrieve your token by visiting your dashboard and clicking Generate API token.

AI Blood Assistant

Grounded Claude chatbot answering donation questions (can I donate, why deferred, where to donate, what to eat). Works for guests and logged-in users.

Whether the assistant is configured/available

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/assistant/status" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/assistant/status"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/assistant/status could not be found."
}
 

Request      

GET api/v1/assistant/status

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Send a message to the assistant

Pass conversation_uuid to continue a conversation, or omit to start a new one.

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/assistant/message" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"message\": \"vmqeopfuudtdsufvyvddq\",
    \"conversation_uuid\": \"66529e01-d113-3473-8d6f-9e11e09332ea\"
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/assistant/message"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "message": "vmqeopfuudtdsufvyvddq",
    "conversation_uuid": "66529e01-d113-3473-8d6f-9e11e09332ea"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/assistant/message

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

message   string     

Must not be greater than 2000 characters. Example: vmqeopfuudtdsufvyvddq

conversation_uuid   string  optional    

Example: 66529e01-d113-3473-8d6f-9e11e09332ea

Account

Delete my account

requires authentication

Play Store / App Store compliant self-service deletion. The account is deactivated and soft-deleted (retained in the database for audit, blood-safety traceability and legal retention) — the user can no longer sign in. We record an optional reason. All access tokens are revoked.

Example request:
curl --request DELETE \
    "http://localhost/elifesaver-app/public/api/v1/account" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"reason\": \"vmqeopfuudtdsufvyvddq\",
    \"details\": \"amniihfqcoynlazghdtqt\"
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/account"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "reason": "vmqeopfuudtdsufvyvddq",
    "details": "amniihfqcoynlazghdtqt"
};

fetch(url, {
    method: "DELETE",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

DELETE api/v1/account

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

reason   string  optional    

Must not be greater than 100 characters. Example: vmqeopfuudtdsufvyvddq

details   string  optional    

Must not be greater than 1000 characters. Example: amniihfqcoynlazghdtqt

Appointments

Donor-facing appointment booking — the mobile equivalent of the donor panel's "Book a slot to donate". A donor books a screening/donation slot at a facility; staff later check them in (which opens a donation journey).

My appointments + the data the booking form needs (facilities, tags)

requires authentication

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/appointments" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/appointments"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/appointments could not be found."
}
 

Request      

GET api/v1/appointments

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Book a donation slot

requires authentication

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/appointments" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"hospital_id\": 17,
    \"scheduled_at\": \"2107-09-01\",
    \"tags\": [
        17
    ]
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/appointments"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "hospital_id": 17,
    "scheduled_at": "2107-09-01",
    "tags": [
        17
    ]
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/appointments

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

hospital_id   integer     

Example: 17

scheduled_at   string     

Must be a valid date. Must be a date after now. Example: 2107-09-01

tags   integer[]  optional    

Cancel a booked appointment

requires authentication

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/appointments/1/cancel" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/appointments/1/cancel"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Request      

POST api/v1/appointments/{appointment_id}/cancel

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

appointment_id   integer     

The ID of the appointment. Example: 1

Authentication

Registration and Sanctum token issuance for the mobile app. Tokens are bearer tokens returned in the token field; send as Authorization: Bearer {token}.

Login

Authenticate a donor, patient, doctor or admin by email OR phone.

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/auth/login" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"email\": \"qkunze@example.com\",
    \"phone\": \"consequatur\",
    \"password\": \"O[2UZ5ij-e\\/dl4m{o,\"
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/auth/login"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "email": "qkunze@example.com",
    "phone": "consequatur",
    "password": "O[2UZ5ij-e\/dl4m{o,"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/auth/login

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

email   string  optional    

This field is required when phone is not present. Must be a valid email address. Example: qkunze@example.com

phone   string  optional    

This field is required when email is not present. Example: consequatur

password   string     

Example: O[2UZ5ij-e/dl4m{o,

Register donor

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/auth/register/donor" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"vmqeopfuudtdsufvyvddq\",
    \"gender\": \"consequatur\",
    \"email\": \"carolyne.luettgen@example.org\",
    \"phone\": \"consequatur\",
    \"password\": \"[2UZ5ij-e\\/dl4\",
    \"address\": \"consequatur\",
    \"city\": \"consequatur\",
    \"blood_group\": \"consequatur\"
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/auth/register/donor"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "name": "vmqeopfuudtdsufvyvddq",
    "gender": "consequatur",
    "email": "carolyne.luettgen@example.org",
    "phone": "consequatur",
    "password": "[2UZ5ij-e\/dl4",
    "address": "consequatur",
    "city": "consequatur",
    "blood_group": "consequatur"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/auth/register/donor

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

name   string     

Must not be greater than 255 characters. Example: vmqeopfuudtdsufvyvddq

gender   string  optional    

Example: consequatur

email   string     

Must be a valid email address. Example: carolyne.luettgen@example.org

phone   string  optional    

Example: consequatur

password   string     

Must be at least 6 characters. Example: [2UZ5ij-e/dl4

address   string  optional    

Example: consequatur

city   string  optional    

Example: consequatur

blood_group   string     

Must match an existing stored value. Example: consequatur

Register patient

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/auth/register/patient" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"vmqeopfuudtdsufvyvddq\",
    \"gender\": \"consequatur\",
    \"email\": \"carolyne.luettgen@example.org\",
    \"phone\": \"consequatur\",
    \"password\": \"[2UZ5ij-e\\/dl4\",
    \"blood_group\": \"consequatur\"
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/auth/register/patient"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "name": "vmqeopfuudtdsufvyvddq",
    "gender": "consequatur",
    "email": "carolyne.luettgen@example.org",
    "phone": "consequatur",
    "password": "[2UZ5ij-e\/dl4",
    "blood_group": "consequatur"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/auth/register/patient

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

name   string     

Must not be greater than 255 characters. Example: vmqeopfuudtdsufvyvddq

gender   string  optional    

Example: consequatur

email   string     

Must be a valid email address. Example: carolyne.luettgen@example.org

phone   string  optional    

Example: consequatur

password   string     

Must be at least 6 characters. Example: [2UZ5ij-e/dl4

blood_group   string  optional    

Must match an existing stored value. Example: consequatur

Current user

requires authentication

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/me" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/me"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/me could not be found."
}
 

Request      

GET api/v1/me

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Logout

requires authentication

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/auth/logout" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/auth/logout"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Request      

POST api/v1/auth/logout

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Blood Requests

List blood requests

requires authentication

Patients see their own requests; donors see active requests compatible with their blood group.

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/blood-requests" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/blood-requests"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/blood-requests could not be found."
}
 

Request      

GET api/v1/blood-requests

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Compatible appeals near me

requires authentication

Open appeals the donor can donate to, ranked by urgency + proximity to home or the town they're currently visiting.

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/blood-requests/compatible" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/blood-requests/compatible"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/blood-requests/compatible could not be found."
}
 

Request      

GET api/v1/blood-requests/compatible

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

My pledges

requires authentication

Appeals this donor has pledged to (responded to). Lets the app show the donor their commitments — separate from appeals they created as a requester.

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/blood-requests/my-pledges" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/blood-requests/my-pledges"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/blood-requests/my-pledges could not be found."
}
 

Request      

GET api/v1/blood-requests/my-pledges

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Create a blood request

requires authentication

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/blood-requests" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"blood_group\": \"consequatur\",
    \"number_of_bags\": 45,
    \"health_facility\": \"consequatur\",
    \"hospital_id\": 17,
    \"medical_info\": \"consequatur\",
    \"priority\": \"urgent\"
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/blood-requests"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "blood_group": "consequatur",
    "number_of_bags": 45,
    "health_facility": "consequatur",
    "hospital_id": 17,
    "medical_info": "consequatur",
    "priority": "urgent"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/blood-requests

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

blood_group   string     

Must match an existing stored value. Example: consequatur

number_of_bags   integer  optional    

Must be at least 1. Example: 45

health_facility   string  optional    

Example: consequatur

hospital_id   integer  optional    

Must match an existing stored value. Example: 17

medical_info   string  optional    

Example: consequatur

priority   string  optional    

Example: urgent

Must be one of:
  • routine
  • urgent
  • emergency

Respond to a blood request

requires authentication

A donor pledges/accepts a request. Records the response and credits the donor.

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/blood-requests/1/respond" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/blood-requests/1/respond"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Request      

POST api/v1/blood-requests/{bloodRequest_id}/respond

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

bloodRequest_id   integer     

The ID of the bloodRequest. Example: 1

Cancel a blood request

requires authentication

The requester (or an admin) cancels their own appeal. It immediately drops out of every donor's feed. Already-fulfilled or cancelled appeals can't be cancelled again.

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/blood-requests/1/cancel" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/blood-requests/1/cancel"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Request      

POST api/v1/blood-requests/{bloodRequest_id}/cancel

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

bloodRequest_id   integer     

The ID of the bloodRequest. Example: 1

Escalate to Emergency Mode

requires authentication

Ranks compatible nearby donors and fans out a multi-channel appeal. Only the requester (or an admin) may escalate.

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/blood-requests/1/escalate" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/blood-requests/1/escalate"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Request      

POST api/v1/blood-requests/{bloodRequest_id}/escalate

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

bloodRequest_id   integer     

The ID of the bloodRequest. Example: 1

Ranked donor matches for a request (staff/requester view).

requires authentication

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/blood-requests/1/matches" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/blood-requests/1/matches"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/blood-requests/1/matches could not be found."
}
 

Request      

GET api/v1/blood-requests/{bloodRequest_id}/matches

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

bloodRequest_id   integer     

The ID of the bloodRequest. Example: 1

Campaigns (Blood Drives)

List published campaigns (public)

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/campaigns" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/campaigns"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/campaigns could not be found."
}
 

Request      

GET api/v1/campaigns

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Show one campaign with progress (public)

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/campaigns/3" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/campaigns/3"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/campaigns/3 could not be found."
}
 

Request      

GET api/v1/campaigns/{campaign_id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

campaign_id   integer     

The ID of the campaign. Example: 3

Register for a campaign

requires authentication

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/campaigns/3/register" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/campaigns/3/register"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Request      

POST api/v1/campaigns/{campaign_id}/register

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

campaign_id   integer     

The ID of the campaign. Example: 3

My campaign registrations

requires authentication

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/my/campaign-registrations" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/my/campaign-registrations"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/my/campaign-registrations could not be found."
}
 

Request      

GET api/v1/my/campaign-registrations

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Community Media

Upload community photos/videos. Prefer the direct-to-Cloudinary flow (get a signature, upload from the device, then attach the descriptor to a post) for large files — it keeps media off the app server.

Upload a media file (server compresses/offloads); returns a media descriptor

requires authentication

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/media" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: multipart/form-data" \
    --header "Accept: application/json" \
    --form "file=@C:\Users\USER\AppData\Local\Temp\php54DA.tmp" 
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/media"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "multipart/form-data",
    "Accept": "application/json",
};

const body = new FormData();
body.append('file', document.querySelector('input[name="file"]').files[0]);

fetch(url, {
    method: "POST",
    headers,
    body,
}).then(response => response.json());

Request      

POST api/v1/media

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: multipart/form-data

Accept        

Example: application/json

Body Parameters

file   file     

Must be a file. Example: C:\Users\USER\AppData\Local\Temp\php54DA.tmp

Signature for a direct browser/device upload to Cloudinary

requires authentication

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/media/signature" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/media/signature"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/media/signature could not be found."
}
 

Request      

GET api/v1/media/signature

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Content & Community

Knowledge Center and the community feed.

Knowledge categories with published article counts

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/knowledge/categories" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/knowledge/categories"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/knowledge/categories could not be found."
}
 

Request      

GET api/v1/knowledge/categories

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

List published knowledge articles (optionally by category slug)

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/knowledge/articles" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/knowledge/articles"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/knowledge/articles could not be found."
}
 

Request      

GET api/v1/knowledge/articles

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Show a single knowledge article

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/knowledge/articles/1" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/knowledge/articles/1"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/knowledge/articles/1 could not be found."
}
 

Request      

GET api/v1/knowledge/articles/{article_id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

article_id   integer     

The ID of the article. Example: 1

Community feed (public posts), ranked for the viewer

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/feed" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/feed"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/feed could not be found."
}
 

Request      

GET api/v1/feed

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

List a post's comments

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/posts/170/comments" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/posts/170/comments"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/posts/170/comments could not be found."
}
 

Request      

GET api/v1/posts/{post_id}/comments

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

post_id   integer     

The ID of the post. Example: 170

Create a post

requires authentication

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/posts" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"body\": \"vmqeopfuudtdsufvyvddq\",
    \"type\": \"announcement\",
    \"image_url\": \"http:\\/\\/www.kunde.com\\/\",
    \"is_anonymous\": false,
    \"media\": [
        {
            \"type\": \"image\",
            \"url\": \"http:\\/\\/www.harber.com\\/fuga-aspernatur-natus-earum-quas\"
        }
    ]
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/posts"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "body": "vmqeopfuudtdsufvyvddq",
    "type": "announcement",
    "image_url": "http:\/\/www.kunde.com\/",
    "is_anonymous": false,
    "media": [
        {
            "type": "image",
            "url": "http:\/\/www.harber.com\/fuga-aspernatur-natus-earum-quas"
        }
    ]
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/posts

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

body   string     

Must not be greater than 5000 characters. Example: vmqeopfuudtdsufvyvddq

type   string  optional    

Example: announcement

Must be one of:
  • update
  • announcement
  • educational
  • milestone
image_url   string  optional    

Must be a valid URL. Example: http://www.kunde.com/

is_anonymous   boolean  optional    

Example: false

media   object[]  optional    
type   string  optional    

This field is required when media is present. Example: image

Must be one of:
  • image
  • video
url   string  optional    

This field is required when media is present. Must be a valid URL. Example: http://www.harber.com/fuga-aspernatur-natus-earum-quas

React to a post (toggle)

requires authentication

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/posts/170/react" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/posts/170/react"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Request      

POST api/v1/posts/{post_id}/react

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

post_id   integer     

The ID of the post. Example: 170

Comment on a post

requires authentication

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/posts/170/comment" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"body\": \"vmqeopfuudtdsufvyvddq\",
    \"parent_id\": 17,
    \"is_anonymous\": true
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/posts/170/comment"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "body": "vmqeopfuudtdsufvyvddq",
    "parent_id": 17,
    "is_anonymous": true
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/posts/{post_id}/comment

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

post_id   integer     

The ID of the post. Example: 170

Body Parameters

body   string     

Must not be greater than 2000 characters. Example: vmqeopfuudtdsufvyvddq

parent_id   integer  optional    

Must match an existing stored value. Example: 17

is_anonymous   boolean  optional    

Example: true

Donations (financial)

Money donations to support the platform, via CamPay mobile money. Anyone can give — anonymously or named — no account required. Separate from blood donation.

Donation config: enabled, currency, minimum + suggested amounts.

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/donate/info" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/donate/info"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/donate/info could not be found."
}
 

Request      

GET api/v1/donate/info

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Initiate a donation collection (mobile-money prompt to the donor's phone).

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/donate" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"amount\": 17,
    \"phone\": \"consequatur\",
    \"is_anonymous\": false,
    \"donor_name\": \"mqeopfuudtdsufvyvddqa\",
    \"message\": \"mniihfqcoynlazghdtqtq\"
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/donate"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "amount": 17,
    "phone": "consequatur",
    "is_anonymous": false,
    "donor_name": "mqeopfuudtdsufvyvddqa",
    "message": "mniihfqcoynlazghdtqtq"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/donate

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

amount   integer     

Example: 17

phone   string     

Example: consequatur

is_anonymous   boolean  optional    

Example: false

donor_name   string  optional    

Must not be greater than 120 characters. Example: mqeopfuudtdsufvyvddqa

message   string  optional    

Must not be greater than 500 characters. Example: mniihfqcoynlazghdtqtq

Donor Data

Get donor credit balance

requires authentication

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/credit" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/credit"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/credit could not be found."
}
 

Request      

GET api/v1/credit

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Next eligible donation date

requires authentication

Males wait 3 months, females 4 months between donations.

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/donation-info" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/donation-info"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/donation-info could not be found."
}
 

Request      

GET api/v1/donation-info

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Get serology / blood test results

requires authentication

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/results" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/results"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/results could not be found."
}
 

Request      

GET api/v1/results

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Eligibility

The admin-authored donation-eligibility questionnaire. Medical rules live in data (admins edit questions/options in the panel), so the app never hardcodes them — fetch the questions, submit the answers, get a decision.

Eligibility questionnaire

requires authentication

The active questions that apply to this donor, each with its answer options.

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/eligibility/questions" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/eligibility/questions"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/eligibility/questions could not be found."
}
 

Request      

GET api/v1/eligibility/questions

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Submit eligibility answers

requires authentication

Records a self-assessment and returns the decision (eligible / deferred / refer) plus any advice. This is advisory — staff re-screen at the centre.

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/eligibility/assess" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"answers\": {
        \"1\": 2,
        \"3\": 5
    }
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/eligibility/assess"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "answers": {
        "1": 2,
        "3": 5
    }
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/eligibility/assess

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

answers   object     

Map of question_id => chosen option_id.

Endpoints

GET api/v1/towns

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/towns" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/towns"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/towns could not be found."
}
 

Request      

GET api/v1/towns

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Engagement

Achievements, certificates, leaderboards, referrals and the health tracker.

Public leaderboard (scope: national|region|hospital|gender)

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/leaderboard" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/leaderboard"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/leaderboard could not be found."
}
 

Request      

GET api/v1/leaderboard

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

My achievements

requires authentication

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/achievements" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/achievements"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/achievements could not be found."
}
 

Request      

GET api/v1/achievements

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

My certificates

requires authentication

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/certificates" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/certificates"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/certificates could not be found."
}
 

Request      

GET api/v1/certificates

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Download a certificate PDF

requires authentication

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/certificates/66529e01-d113-3473-8d6f-9e11e09332ea/download" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/certificates/66529e01-d113-3473-8d6f-9e11e09332ea/download"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/certificates/66529e01-d113-3473-8d6f-9e11e09332ea/download could not be found."
}
 

Request      

GET api/v1/certificates/{uuid}/download

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

uuid   string     

Example: 66529e01-d113-3473-8d6f-9e11e09332ea

My referral code + stats

requires authentication

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/referral" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/referral"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/referral could not be found."
}
 

Request      

GET api/v1/referral

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

List my health records

requires authentication

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/health-records" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/health-records"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/health-records could not be found."
}
 

Request      

GET api/v1/health-records

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Add a health record (BMI auto-computed)

requires authentication

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/health-records" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"weight_kg\": 21,
    \"height_cm\": 13,
    \"hemoglobin\": 16,
    \"bp_systolic\": 5,
    \"bp_diastolic\": 14,
    \"pulse\": 16,
    \"temperature\": 6,
    \"recorded_at\": \"2026-08-03T01:03:13\"
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/health-records"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "weight_kg": 21,
    "height_cm": 13,
    "hemoglobin": 16,
    "bp_systolic": 5,
    "bp_diastolic": 14,
    "pulse": 16,
    "temperature": 6,
    "recorded_at": "2026-08-03T01:03:13"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/health-records

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

weight_kg   number  optional    

Must be at least 0. Must not be greater than 400. Example: 21

height_cm   number  optional    

Must be at least 0. Must not be greater than 300. Example: 13

hemoglobin   number  optional    

Must be at least 0. Must not be greater than 30. Example: 16

bp_systolic   integer  optional    

Must be at least 0. Must not be greater than 300. Example: 5

bp_diastolic   integer  optional    

Must be at least 0. Must not be greater than 200. Example: 14

pulse   integer  optional    

Must be at least 0. Must not be greater than 300. Example: 16

temperature   number  optional    

Must be at least 30. Must not be greater than 45. Example: 6

recorded_at   string  optional    

Must be a valid date. Example: 2026-08-03T01:03:13

Lookups

Reference data for populating mobile dropdowns. Public (no auth required).

List hospitals & health facilities

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/hospitals" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/hospitals"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/hospitals could not be found."
}
 

Request      

GET api/v1/hospitals

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Get one hospital's GPS coordinates

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/hospitals/1/location" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/hospitals/1/location"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/hospitals/1/location could not be found."
}
 

Request      

GET api/v1/hospitals/{hospital_id}/location

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

hospital_id   integer     

The ID of the hospital. Example: 1

List blood groups

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/blood-groups" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/blood-groups"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/blood-groups could not be found."
}
 

Request      

GET api/v1/blood-groups

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

List regions (geography)

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/regions" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/regions"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/regions could not be found."
}
 

Request      

GET api/v1/regions

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Gamification assets — mascot moods, celebration banners + sounds, by trigger

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/celebration-assets" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/celebration-assets"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/celebration-assets could not be found."
}
 

Request      

GET api/v1/celebration-assets

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

App startup config: version gating + social handles (admin-editable)

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/app-config" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/app-config"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/app-config could not be found."
}
 

Request      

GET api/v1/app-config

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Notifications

In-app notification history for the mobile app (blood appeals, emergencies, request updates, milestones). Push delivery is separate (FCM); this is the durable list the user can browse and mark as read.

List my notifications (paginated, newest first) + unread count

requires authentication

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/notifications" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/notifications"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/notifications could not be found."
}
 

Request      

GET api/v1/notifications

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Mark a single notification as read

requires authentication

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/notifications/consequatur/read" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/notifications/consequatur/read"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Request      

POST api/v1/notifications/{id}/read

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

id   string     

The ID of the notification. Example: consequatur

Mark all my notifications as read

requires authentication

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/notifications/read-all" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/notifications/read-all"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Request      

POST api/v1/notifications/read-all

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Organizations & Volunteers

Public organization leaderboard (by lives impacted)

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/organizations/leaderboard" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/organizations/leaderboard"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/organizations/leaderboard could not be found."
}
 

Request      

GET api/v1/organizations/leaderboard

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Public organization profile + impact stats

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/organizations/4" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/organizations/4"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/organizations/4 could not be found."
}
 

Request      

GET api/v1/organizations/{organization_id}

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

organization_id   integer     

The ID of the organization. Example: 4

Join an organization via its invite code (as a registered donor)

requires authentication

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/organizations/join" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"invite_code\": \"consequatur\"
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/organizations/join"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "invite_code": "consequatur"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/organizations/join

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

invite_code   string     

Example: consequatur

Apply to volunteer

requires authentication

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/volunteers/apply" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"type\": \"regional_ambassador\",
    \"organization_id\": 17
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/volunteers/apply"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "type": "regional_ambassador",
    "organization_id": 17
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/volunteers/apply

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

type   string     

Example: regional_ambassador

Must be one of:
  • campaign_volunteer
  • event_coordinator
  • regional_ambassador
  • campus_ambassador
organization_id   integer  optional    

Must match an existing stored value. Example: 17

Payments

CamPay mobile-money flow for the (optional) blood-appeal fee. When payment is disabled the appeal is created immediately and no charge is made.

Payment configuration (call before showing a payment UI)

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/payments/info" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/payments/info"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/payments/info could not be found."
}
 

Request      

GET api/v1/payments/info

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

Check payment status (poll every ~5s) — reconciles with CamPay.

Example request:
curl --request GET \
    --get "http://localhost/elifesaver-app/public/api/v1/payments/consequatur/status" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/payments/consequatur/status"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (404):

Show headers
cache-control: no-cache, private
content-type: application/json
 

{
    "message": "The route elifesaver-app/public/api/v1/payments/consequatur/status could not be found."
}
 

Request      

GET api/v1/payments/{reference}/status

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json

URL Parameters

reference   string     

Example: consequatur

Initiate a blood-appeal payment

requires authentication

If payment is disabled the appeal is created immediately (free). Otherwise a payment record is created and a CamPay collection is initiated.

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/payments/initiate" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"phone\": \"consequatur\",
    \"blood_group\": \"consequatur\",
    \"number_of_bags\": 45,
    \"health_facility\": \"consequatur\",
    \"medical_info\": \"consequatur\"
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/payments/initiate"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "phone": "consequatur",
    "blood_group": "consequatur",
    "number_of_bags": 45,
    "health_facility": "consequatur",
    "medical_info": "consequatur"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/payments/initiate

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

phone   string  optional    

This field is required when payment_enabled is true. Example: consequatur

blood_group   string     

Must match an existing stored value. Example: consequatur

number_of_bags   integer  optional    

Must be at least 1. Example: 45

health_facility   string  optional    

Example: consequatur

medical_info   string  optional    

Example: consequatur

Profile

Update the authenticated user's profile

requires authentication

Example request:
curl --request PUT \
    "http://localhost/elifesaver-app/public/api/v1/profile" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"name\": \"vmqeopfuudtdsufvyvddq\",
    \"password\": \"OP>@;4\",
    \"phone\": \"consequatur\",
    \"address\": \"consequatur\",
    \"city\": \"consequatur\",
    \"avatar_url\": \"https:\\/\\/www.mueller.com\\/laborum-eius-est-dolor-dolores-minus-voluptatem\",
    \"blood_group\": \"consequatur\"
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/profile"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "name": "vmqeopfuudtdsufvyvddq",
    "password": "OP>@;4",
    "phone": "consequatur",
    "address": "consequatur",
    "city": "consequatur",
    "avatar_url": "https:\/\/www.mueller.com\/laborum-eius-est-dolor-dolores-minus-voluptatem",
    "blood_group": "consequatur"
};

fetch(url, {
    method: "PUT",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

PUT api/v1/profile

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

name   string  optional    

Must not be greater than 255 characters. Example: vmqeopfuudtdsufvyvddq

password   string  optional    

Must be at least 6 characters. Example: OP>@;4

phone   string  optional    

Example: consequatur

address   string  optional    

Example: consequatur

city   string  optional    

Example: consequatur

avatar_url   string  optional    

Must be a valid URL. Must not be greater than 2048 characters. Example: https://www.mueller.com/laborum-eius-est-dolor-dolores-minus-voluptatem

blood_group   string  optional    

Must match an existing stored value. Example: consequatur

Register / update the device FCM token for push notifications

requires authentication

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/profile/device-token" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"registration_token\": \"consequatur\"
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/profile/device-token"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "registration_token": "consequatur"
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/profile/device-token

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

registration_token   string     

Example: consequatur

Update my coarse current location (town I'm visiting)

requires authentication

Consent-based and deliberately imprecise (city/subdivision only) so nearby appeals follow the donor when travelling. Send shares_location:false to stop.

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/profile/location" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json" \
    --data "{
    \"current_subdivision_id\": 17,
    \"current_city\": \"mqeopfuudtdsufvyvddqa\",
    \"shares_location\": true
}"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/profile/location"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

let body = {
    "current_subdivision_id": 17,
    "current_city": "mqeopfuudtdsufvyvddqa",
    "shares_location": true
};

fetch(url, {
    method: "POST",
    headers,
    body: JSON.stringify(body),
}).then(response => response.json());

Request      

POST api/v1/profile/location

Headers

Authorization        

Example: Bearer {YOUR_AUTH_KEY}

Content-Type        

Example: application/json

Accept        

Example: application/json

Body Parameters

current_subdivision_id   integer  optional    

Must match an existing stored value. Example: 17

current_city   string  optional    

Must not be greater than 120 characters. Example: mqeopfuudtdsufvyvddqa

shares_location   boolean     

Example: true

Webhooks

Server-to-server callbacks. No user auth — verified by a shared key instead.

CamPay payment IPN

Example request:
curl --request POST \
    "http://localhost/elifesaver-app/public/api/v1/webhooks/campay" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "http://localhost/elifesaver-app/public/api/v1/webhooks/campay"
);

const headers = {
    "Content-Type": "application/json",
    "Accept": "application/json",
};


fetch(url, {
    method: "POST",
    headers,
}).then(response => response.json());

Request      

POST api/v1/webhooks/campay

Headers

Content-Type        

Example: application/json

Accept        

Example: application/json