Add a shipping address
curl --request POST \
--url https://store.salesive.com/api/v1/user/address \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'x-shop-id: <api-key>' \
--data '
{
"name": "Jane Smith",
"phone": "+2348099887766",
"email": "jane@example.com",
"address": "12 Marina Road",
"city": "Lagos",
"state": "Lagos",
"zipCode": "100001",
"country": "Nigeria",
"latitude": 6.5244,
"longitude": 3.3792,
"landmark": "<string>",
"isDefault": false
}
'import requests
url = "https://store.salesive.com/api/v1/user/address"
payload = {
"name": "Jane Smith",
"phone": "+2348099887766",
"email": "jane@example.com",
"address": "12 Marina Road",
"city": "Lagos",
"state": "Lagos",
"zipCode": "100001",
"country": "Nigeria",
"latitude": 6.5244,
"longitude": 3.3792,
"landmark": "<string>",
"isDefault": False
}
headers = {
"Authorization": "Bearer <token>",
"x-shop-id": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
Authorization: 'Bearer <token>',
'x-shop-id': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
name: 'Jane Smith',
phone: '+2348099887766',
email: 'jane@example.com',
address: '12 Marina Road',
city: 'Lagos',
state: 'Lagos',
zipCode: '100001',
country: 'Nigeria',
latitude: 6.5244,
longitude: 3.3792,
landmark: '<string>',
isDefault: false
})
};
fetch('https://store.salesive.com/api/v1/user/address', 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://store.salesive.com/api/v1/user/address",
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([
'name' => 'Jane Smith',
'phone' => '+2348099887766',
'email' => 'jane@example.com',
'address' => '12 Marina Road',
'city' => 'Lagos',
'state' => 'Lagos',
'zipCode' => '100001',
'country' => 'Nigeria',
'latitude' => 6.5244,
'longitude' => 3.3792,
'landmark' => '<string>',
'isDefault' => false
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"x-shop-id: <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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://store.salesive.com/api/v1/user/address"
payload := strings.NewReader("{\n \"name\": \"Jane Smith\",\n \"phone\": \"+2348099887766\",\n \"email\": \"jane@example.com\",\n \"address\": \"12 Marina Road\",\n \"city\": \"Lagos\",\n \"state\": \"Lagos\",\n \"zipCode\": \"100001\",\n \"country\": \"Nigeria\",\n \"latitude\": 6.5244,\n \"longitude\": 3.3792,\n \"landmark\": \"<string>\",\n \"isDefault\": false\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("x-shop-id", "<api-key>")
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://store.salesive.com/api/v1/user/address")
.header("Authorization", "Bearer <token>")
.header("x-shop-id", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"Jane Smith\",\n \"phone\": \"+2348099887766\",\n \"email\": \"jane@example.com\",\n \"address\": \"12 Marina Road\",\n \"city\": \"Lagos\",\n \"state\": \"Lagos\",\n \"zipCode\": \"100001\",\n \"country\": \"Nigeria\",\n \"latitude\": 6.5244,\n \"longitude\": 3.3792,\n \"landmark\": \"<string>\",\n \"isDefault\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://store.salesive.com/api/v1/user/address")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["x-shop-id"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"Jane Smith\",\n \"phone\": \"+2348099887766\",\n \"email\": \"jane@example.com\",\n \"address\": \"12 Marina Road\",\n \"city\": \"Lagos\",\n \"state\": \"Lagos\",\n \"zipCode\": \"100001\",\n \"country\": \"Nigeria\",\n \"latitude\": 6.5244,\n \"longitude\": 3.3792,\n \"landmark\": \"<string>\",\n \"isDefault\": false\n}"
response = http.request(request)
puts response.read_body{}{}User
Add shipping address
Add a new shipping address to the authenticated shopper’s address book.
POST
/
user
/
address
Add a shipping address
curl --request POST \
--url https://store.salesive.com/api/v1/user/address \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'x-shop-id: <api-key>' \
--data '
{
"name": "Jane Smith",
"phone": "+2348099887766",
"email": "jane@example.com",
"address": "12 Marina Road",
"city": "Lagos",
"state": "Lagos",
"zipCode": "100001",
"country": "Nigeria",
"latitude": 6.5244,
"longitude": 3.3792,
"landmark": "<string>",
"isDefault": false
}
'import requests
url = "https://store.salesive.com/api/v1/user/address"
payload = {
"name": "Jane Smith",
"phone": "+2348099887766",
"email": "jane@example.com",
"address": "12 Marina Road",
"city": "Lagos",
"state": "Lagos",
"zipCode": "100001",
"country": "Nigeria",
"latitude": 6.5244,
"longitude": 3.3792,
"landmark": "<string>",
"isDefault": False
}
headers = {
"Authorization": "Bearer <token>",
"x-shop-id": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
Authorization: 'Bearer <token>',
'x-shop-id': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
name: 'Jane Smith',
phone: '+2348099887766',
email: 'jane@example.com',
address: '12 Marina Road',
city: 'Lagos',
state: 'Lagos',
zipCode: '100001',
country: 'Nigeria',
latitude: 6.5244,
longitude: 3.3792,
landmark: '<string>',
isDefault: false
})
};
fetch('https://store.salesive.com/api/v1/user/address', 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://store.salesive.com/api/v1/user/address",
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([
'name' => 'Jane Smith',
'phone' => '+2348099887766',
'email' => 'jane@example.com',
'address' => '12 Marina Road',
'city' => 'Lagos',
'state' => 'Lagos',
'zipCode' => '100001',
'country' => 'Nigeria',
'latitude' => 6.5244,
'longitude' => 3.3792,
'landmark' => '<string>',
'isDefault' => false
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"x-shop-id: <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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://store.salesive.com/api/v1/user/address"
payload := strings.NewReader("{\n \"name\": \"Jane Smith\",\n \"phone\": \"+2348099887766\",\n \"email\": \"jane@example.com\",\n \"address\": \"12 Marina Road\",\n \"city\": \"Lagos\",\n \"state\": \"Lagos\",\n \"zipCode\": \"100001\",\n \"country\": \"Nigeria\",\n \"latitude\": 6.5244,\n \"longitude\": 3.3792,\n \"landmark\": \"<string>\",\n \"isDefault\": false\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("x-shop-id", "<api-key>")
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://store.salesive.com/api/v1/user/address")
.header("Authorization", "Bearer <token>")
.header("x-shop-id", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"Jane Smith\",\n \"phone\": \"+2348099887766\",\n \"email\": \"jane@example.com\",\n \"address\": \"12 Marina Road\",\n \"city\": \"Lagos\",\n \"state\": \"Lagos\",\n \"zipCode\": \"100001\",\n \"country\": \"Nigeria\",\n \"latitude\": 6.5244,\n \"longitude\": 3.3792,\n \"landmark\": \"<string>\",\n \"isDefault\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://store.salesive.com/api/v1/user/address")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["x-shop-id"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"Jane Smith\",\n \"phone\": \"+2348099887766\",\n \"email\": \"jane@example.com\",\n \"address\": \"12 Marina Road\",\n \"city\": \"Lagos\",\n \"state\": \"Lagos\",\n \"zipCode\": \"100001\",\n \"country\": \"Nigeria\",\n \"latitude\": 6.5244,\n \"longitude\": 3.3792,\n \"landmark\": \"<string>\",\n \"isDefault\": false\n}"
response = http.request(request)
puts response.read_body{}{}Request
POST /user/address
Authorization: Bearer {{token}}
x-shop-id: {{shopId}}
Content-Type: application/json
{
"name": "Jane Smith",
"phone": "+2348099887766",
"address": "12 Marina Road",
"city": "Lagos",
"state": "Lagos",
"country": "Nigeria",
"isDefault": false
}
Body parameters
| Field | Type | Description |
|---|---|---|
name | string | Required. Recipient name (2–100 chars). |
phone | string | Required. Contact phone (6–30 chars). |
email | string | Optional. Recipient email. |
address | string | Optional. Street address. |
city | string | Optional. |
state | string | Optional. |
zipCode | string | Optional. |
country | string | Optional. |
latitude | number | Optional. -90 to 90. |
longitude | number | Optional. -180 to 180. |
landmark | string | Optional. |
isDefault | boolean | Optional. Make this the default address. |
Successful response
{
"status": 200,
"success": true,
"message": "Address added successfully",
"data": {
"address": {
"_id": "651f8a9b2c3d4e5f60718300",
"user": "651f8a1b2c3d4e5f60718293",
"name": "Jane Smith",
"phone": "+2348099887766",
"address": "12 Marina Road",
"city": "Lagos",
"state": "Lagos",
"country": "Nigeria",
"isDefault": false,
"createdAt": "2026-06-18T03:21:00.000Z",
"updatedAt": "2026-06-18T03:21:00.000Z"
}
}
}
Error response
{
"status": 400,
"success": false,
"message": "\"phone\" is required",
"data": {}
}
Authorizations
JWT issued by the Salesive Store API for authenticated shoppers.
Optional storefront identifier sent as a header to scope responses to a specific shop. Try It requests remember this value once provided.
Headers
Optional identifier that scopes responses to a specific storefront when the referer cannot be inferred.
Body
application/json
Example:
"Jane Smith"
Example:
"+2348099887766"
Example:
"jane@example.com"
Example:
"12 Marina Road"
Example:
"Lagos"
Example:
"Lagos"
Example:
"100001"
Example:
"Nigeria"
Example:
6.5244
Example:
3.3792
Example:
false
Response
Address added.
The response is of type object.
Was this page helpful?
⌘I

