Get user profile
curl --request GET \
--url https://staging.api.mavapay.co/api/v1/user \
--header 'X-API-KEY: <api-key>'import requests
url = "https://staging.api.mavapay.co/api/v1/user"
headers = {"X-API-KEY": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-KEY': '<api-key>'}};
fetch('https://staging.api.mavapay.co/api/v1/user', 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://staging.api.mavapay.co/api/v1/user",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-KEY: <api-key>"
],
]);
$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://staging.api.mavapay.co/api/v1/user"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-KEY", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://staging.api.mavapay.co/api/v1/user")
.header("X-API-KEY", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://staging.api.mavapay.co/api/v1/user")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-KEY"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"status": "ok",
"data": {
"id": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"name": "John Doe",
"email": "johndoe@email.com",
"phone": "+2348123456789",
"businessName": "John Doe Enterprises",
"emailVerified": true,
"kycInfo": {
"address": "3 Opebi Road, Ikeja, Lagos",
"phone": "+2348123456789",
"nationality": "Nigeria",
"businessName": "John Doe Enterprises"
},
"account": {
"id": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"walletDetails": {
"id": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"balance": "10000000",
"bankAccount": {
"bankName": "KUDA MICROFINANCE BANK",
"bankCode": "090267",
"bankAccountNumber": "0123456789",
"bankAccountName": "Satoshi Nakamoto",
"currency": "NGN",
"walletId": "d1614a76-9c7f-4111-98a7-43199f307e5b-123456789"
},
"transactions": [
{
"id": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"walletId": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"ref": "99eeff854ffd345fffs67890",
"hash": "189727ef2e0f35921af7858b96e27cbad960b0ec2bb2a4ab73b6a231f9ce8727",
"amount": 1000,
"fees": 0,
"autopayout": true,
"createdAt": "2021-07-01T12:00:00Z",
"updatedAt": "2021-07-01T12:00:00Z",
"metadata": {
"id": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"orderId": "99854-2345",
"bankCode": "090267",
"bankAccountName": "Satoshi Nakamoto",
"bankAccountNumber": "0123456789",
"customerInternalFee": 0,
"createdAt": "2021-07-01T12:00:00Z",
"updatedAt": "2021-07-01T12:00:00Z"
}
}
]
},
"ownerId": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"apiKey": "d1614a76411198a743199f307e5b",
"totalSatsExchanged": 1000,
"webhook": {
"id": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"url": "https://webhook.site/12345678-1234-1234-1234-123456789012",
"secret": "secret",
"isActive": true
},
"settings": {
"id": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"autopayout": true,
"notification": {
"email": true,
"sms": true
}
}
}
}
}{
"message": "<string>",
"status": "error"
}User
Get user profile
Returns an exhaustive user profile detail
GET
/
user
Get user profile
curl --request GET \
--url https://staging.api.mavapay.co/api/v1/user \
--header 'X-API-KEY: <api-key>'import requests
url = "https://staging.api.mavapay.co/api/v1/user"
headers = {"X-API-KEY": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-KEY': '<api-key>'}};
fetch('https://staging.api.mavapay.co/api/v1/user', 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://staging.api.mavapay.co/api/v1/user",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-KEY: <api-key>"
],
]);
$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://staging.api.mavapay.co/api/v1/user"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-KEY", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://staging.api.mavapay.co/api/v1/user")
.header("X-API-KEY", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://staging.api.mavapay.co/api/v1/user")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-KEY"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"status": "ok",
"data": {
"id": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"name": "John Doe",
"email": "johndoe@email.com",
"phone": "+2348123456789",
"businessName": "John Doe Enterprises",
"emailVerified": true,
"kycInfo": {
"address": "3 Opebi Road, Ikeja, Lagos",
"phone": "+2348123456789",
"nationality": "Nigeria",
"businessName": "John Doe Enterprises"
},
"account": {
"id": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"walletDetails": {
"id": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"balance": "10000000",
"bankAccount": {
"bankName": "KUDA MICROFINANCE BANK",
"bankCode": "090267",
"bankAccountNumber": "0123456789",
"bankAccountName": "Satoshi Nakamoto",
"currency": "NGN",
"walletId": "d1614a76-9c7f-4111-98a7-43199f307e5b-123456789"
},
"transactions": [
{
"id": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"walletId": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"ref": "99eeff854ffd345fffs67890",
"hash": "189727ef2e0f35921af7858b96e27cbad960b0ec2bb2a4ab73b6a231f9ce8727",
"amount": 1000,
"fees": 0,
"autopayout": true,
"createdAt": "2021-07-01T12:00:00Z",
"updatedAt": "2021-07-01T12:00:00Z",
"metadata": {
"id": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"orderId": "99854-2345",
"bankCode": "090267",
"bankAccountName": "Satoshi Nakamoto",
"bankAccountNumber": "0123456789",
"customerInternalFee": 0,
"createdAt": "2021-07-01T12:00:00Z",
"updatedAt": "2021-07-01T12:00:00Z"
}
}
]
},
"ownerId": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"apiKey": "d1614a76411198a743199f307e5b",
"totalSatsExchanged": 1000,
"webhook": {
"id": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"url": "https://webhook.site/12345678-1234-1234-1234-123456789012",
"secret": "secret",
"isActive": true
},
"settings": {
"id": "d1614a76-9c7f-4111-98a7-43199f307e5b",
"autopayout": true,
"notification": {
"email": true,
"sms": true
}
}
}
}
}{
"message": "<string>",
"status": "error"
}⌘I
