Créer une demande de transport national
curl --request POST \
--url 'https://api.papslogistics.com/requests?apikey=' \
--header 'Content-Type: application/json' \
--data '
{
"executionDate": "2026-08-01",
"vehicles": [
{
"numberOfVehicule": 1
}
],
"stops": [
{
"address": "Dakar-Plateau, Dakar, Sénégal",
"itemsToPick": [
{
"product": {
"reference": "4759XHG0MKH",
"description": "iPhone 13 Pro Max",
"quantity": 3,
"value": 3000,
"pickup": 3
},
"counter": 3
}
],
"itemsToDelivered": [
{
"product": {
"reference": "4759XHG0MKH",
"description": "iPhone 13 Pro Max",
"quantity": 3,
"value": 3000,
"pickup": 3
},
"counter": 3
}
],
"receiver": {
"firstname": "John",
"lastname": "Doe",
"phoneNumber": "+221770000000",
"email": "[email protected]",
"entreprise": "John Corporation",
"address": "Dakar-Plateau, Dakar, Sénégal",
"specificationAddress": "côté brioche"
}
}
],
"additionnalInfos": "Test"
}
'import requests
url = "https://api.papslogistics.com/requests?apikey="
payload = {
"executionDate": "2026-08-01",
"vehicles": [{ "numberOfVehicule": 1 }],
"stops": [
{
"address": "Dakar-Plateau, Dakar, Sénégal",
"itemsToPick": [
{
"product": {
"reference": "4759XHG0MKH",
"description": "iPhone 13 Pro Max",
"quantity": 3,
"value": 3000,
"pickup": 3
},
"counter": 3
}
],
"itemsToDelivered": [
{
"product": {
"reference": "4759XHG0MKH",
"description": "iPhone 13 Pro Max",
"quantity": 3,
"value": 3000,
"pickup": 3
},
"counter": 3
}
],
"receiver": {
"firstname": "John",
"lastname": "Doe",
"phoneNumber": "+221770000000",
"email": "[email protected]",
"entreprise": "John Corporation",
"address": "Dakar-Plateau, Dakar, Sénégal",
"specificationAddress": "côté brioche"
}
}
],
"additionnalInfos": "Test"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
executionDate: '2026-08-01',
vehicles: [{numberOfVehicule: 1}],
stops: [
{
address: 'Dakar-Plateau, Dakar, Sénégal',
itemsToPick: [
{
product: {
reference: '4759XHG0MKH',
description: 'iPhone 13 Pro Max',
quantity: 3,
value: 3000,
pickup: 3
},
counter: 3
}
],
itemsToDelivered: [
{
product: {
reference: '4759XHG0MKH',
description: 'iPhone 13 Pro Max',
quantity: 3,
value: 3000,
pickup: 3
},
counter: 3
}
],
receiver: {
firstname: 'John',
lastname: 'Doe',
phoneNumber: '+221770000000',
email: '[email protected]',
entreprise: 'John Corporation',
address: 'Dakar-Plateau, Dakar, Sénégal',
specificationAddress: 'côté brioche'
}
}
],
additionnalInfos: 'Test'
})
};
fetch('https://api.papslogistics.com/requests?apikey=', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.papslogistics.com/requests?apikey=",
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([
'executionDate' => '2026-08-01',
'vehicles' => [
[
'numberOfVehicule' => 1
]
],
'stops' => [
[
'address' => 'Dakar-Plateau, Dakar, Sénégal',
'itemsToPick' => [
[
'product' => [
'reference' => '4759XHG0MKH',
'description' => 'iPhone 13 Pro Max',
'quantity' => 3,
'value' => 3000,
'pickup' => 3
],
'counter' => 3
]
],
'itemsToDelivered' => [
[
'product' => [
'reference' => '4759XHG0MKH',
'description' => 'iPhone 13 Pro Max',
'quantity' => 3,
'value' => 3000,
'pickup' => 3
],
'counter' => 3
]
],
'receiver' => [
'firstname' => 'John',
'lastname' => 'Doe',
'phoneNumber' => '+221770000000',
'email' => '[email protected]',
'entreprise' => 'John Corporation',
'address' => 'Dakar-Plateau, Dakar, Sénégal',
'specificationAddress' => 'côté brioche'
]
]
],
'additionnalInfos' => 'Test'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.papslogistics.com/requests?apikey="
payload := strings.NewReader("{\n \"executionDate\": \"2026-08-01\",\n \"vehicles\": [\n {\n \"numberOfVehicule\": 1\n }\n ],\n \"stops\": [\n {\n \"address\": \"Dakar-Plateau, Dakar, Sénégal\",\n \"itemsToPick\": [\n {\n \"product\": {\n \"reference\": \"4759XHG0MKH\",\n \"description\": \"iPhone 13 Pro Max\",\n \"quantity\": 3,\n \"value\": 3000,\n \"pickup\": 3\n },\n \"counter\": 3\n }\n ],\n \"itemsToDelivered\": [\n {\n \"product\": {\n \"reference\": \"4759XHG0MKH\",\n \"description\": \"iPhone 13 Pro Max\",\n \"quantity\": 3,\n \"value\": 3000,\n \"pickup\": 3\n },\n \"counter\": 3\n }\n ],\n \"receiver\": {\n \"firstname\": \"John\",\n \"lastname\": \"Doe\",\n \"phoneNumber\": \"+221770000000\",\n \"email\": \"[email protected]\",\n \"entreprise\": \"John Corporation\",\n \"address\": \"Dakar-Plateau, Dakar, Sénégal\",\n \"specificationAddress\": \"côté brioche\"\n }\n }\n ],\n \"additionnalInfos\": \"Test\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.papslogistics.com/requests?apikey=")
.header("Content-Type", "application/json")
.body("{\n \"executionDate\": \"2026-08-01\",\n \"vehicles\": [\n {\n \"numberOfVehicule\": 1\n }\n ],\n \"stops\": [\n {\n \"address\": \"Dakar-Plateau, Dakar, Sénégal\",\n \"itemsToPick\": [\n {\n \"product\": {\n \"reference\": \"4759XHG0MKH\",\n \"description\": \"iPhone 13 Pro Max\",\n \"quantity\": 3,\n \"value\": 3000,\n \"pickup\": 3\n },\n \"counter\": 3\n }\n ],\n \"itemsToDelivered\": [\n {\n \"product\": {\n \"reference\": \"4759XHG0MKH\",\n \"description\": \"iPhone 13 Pro Max\",\n \"quantity\": 3,\n \"value\": 3000,\n \"pickup\": 3\n },\n \"counter\": 3\n }\n ],\n \"receiver\": {\n \"firstname\": \"John\",\n \"lastname\": \"Doe\",\n \"phoneNumber\": \"+221770000000\",\n \"email\": \"[email protected]\",\n \"entreprise\": \"John Corporation\",\n \"address\": \"Dakar-Plateau, Dakar, Sénégal\",\n \"specificationAddress\": \"côté brioche\"\n }\n }\n ],\n \"additionnalInfos\": \"Test\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.papslogistics.com/requests?apikey=")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"executionDate\": \"2026-08-01\",\n \"vehicles\": [\n {\n \"numberOfVehicule\": 1\n }\n ],\n \"stops\": [\n {\n \"address\": \"Dakar-Plateau, Dakar, Sénégal\",\n \"itemsToPick\": [\n {\n \"product\": {\n \"reference\": \"4759XHG0MKH\",\n \"description\": \"iPhone 13 Pro Max\",\n \"quantity\": 3,\n \"value\": 3000,\n \"pickup\": 3\n },\n \"counter\": 3\n }\n ],\n \"itemsToDelivered\": [\n {\n \"product\": {\n \"reference\": \"4759XHG0MKH\",\n \"description\": \"iPhone 13 Pro Max\",\n \"quantity\": 3,\n \"value\": 3000,\n \"pickup\": 3\n },\n \"counter\": 3\n }\n ],\n \"receiver\": {\n \"firstname\": \"John\",\n \"lastname\": \"Doe\",\n \"phoneNumber\": \"+221770000000\",\n \"email\": \"[email protected]\",\n \"entreprise\": \"John Corporation\",\n \"address\": \"Dakar-Plateau, Dakar, Sénégal\",\n \"specificationAddress\": \"côté brioche\"\n }\n }\n ],\n \"additionnalInfos\": \"Test\"\n}"
response = http.request(request)
puts response.read_body{
"code": 200,
"message": "Success",
"error": "<string>",
"data": {
"executionDate": "2026-08-01",
"productType": "COURIERS",
"vehicles": [
{
"vehicleType": "SCOOTER",
"numberOfVehicule": 1
}
],
"stops": [
{
"action": "Delivery",
"address": "Dakar-Plateau, Dakar, Sénégal",
"itemsToPick": [
{
"product": {
"reference": "4759XHG0MKH",
"description": "iPhone 13 Pro Max",
"weight": "S",
"quantity": 3,
"value": 3000,
"pickup": 3
},
"counter": 3
}
],
"itemsToDelivered": [
{
"product": {
"reference": "4759XHG0MKH",
"description": "iPhone 13 Pro Max",
"weight": "S",
"quantity": 3,
"value": 3000,
"pickup": 3
},
"counter": 3
}
],
"receiver": {
"firstname": "John",
"lastname": "Doe",
"phoneNumber": "+221770000000",
"email": "[email protected]",
"entreprise": "John Corporation",
"address": "Dakar-Plateau, Dakar, Sénégal",
"specificationAddress": "côté brioche"
}
}
],
"additionnalInfos": "Test"
}
}Transport Requests
Créer une demande de transport
Crée une demande de transport national avec un ou plusieurs arrêts.
POST
/
requests
Créer une demande de transport national
curl --request POST \
--url 'https://api.papslogistics.com/requests?apikey=' \
--header 'Content-Type: application/json' \
--data '
{
"executionDate": "2026-08-01",
"vehicles": [
{
"numberOfVehicule": 1
}
],
"stops": [
{
"address": "Dakar-Plateau, Dakar, Sénégal",
"itemsToPick": [
{
"product": {
"reference": "4759XHG0MKH",
"description": "iPhone 13 Pro Max",
"quantity": 3,
"value": 3000,
"pickup": 3
},
"counter": 3
}
],
"itemsToDelivered": [
{
"product": {
"reference": "4759XHG0MKH",
"description": "iPhone 13 Pro Max",
"quantity": 3,
"value": 3000,
"pickup": 3
},
"counter": 3
}
],
"receiver": {
"firstname": "John",
"lastname": "Doe",
"phoneNumber": "+221770000000",
"email": "[email protected]",
"entreprise": "John Corporation",
"address": "Dakar-Plateau, Dakar, Sénégal",
"specificationAddress": "côté brioche"
}
}
],
"additionnalInfos": "Test"
}
'import requests
url = "https://api.papslogistics.com/requests?apikey="
payload = {
"executionDate": "2026-08-01",
"vehicles": [{ "numberOfVehicule": 1 }],
"stops": [
{
"address": "Dakar-Plateau, Dakar, Sénégal",
"itemsToPick": [
{
"product": {
"reference": "4759XHG0MKH",
"description": "iPhone 13 Pro Max",
"quantity": 3,
"value": 3000,
"pickup": 3
},
"counter": 3
}
],
"itemsToDelivered": [
{
"product": {
"reference": "4759XHG0MKH",
"description": "iPhone 13 Pro Max",
"quantity": 3,
"value": 3000,
"pickup": 3
},
"counter": 3
}
],
"receiver": {
"firstname": "John",
"lastname": "Doe",
"phoneNumber": "+221770000000",
"email": "[email protected]",
"entreprise": "John Corporation",
"address": "Dakar-Plateau, Dakar, Sénégal",
"specificationAddress": "côté brioche"
}
}
],
"additionnalInfos": "Test"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
executionDate: '2026-08-01',
vehicles: [{numberOfVehicule: 1}],
stops: [
{
address: 'Dakar-Plateau, Dakar, Sénégal',
itemsToPick: [
{
product: {
reference: '4759XHG0MKH',
description: 'iPhone 13 Pro Max',
quantity: 3,
value: 3000,
pickup: 3
},
counter: 3
}
],
itemsToDelivered: [
{
product: {
reference: '4759XHG0MKH',
description: 'iPhone 13 Pro Max',
quantity: 3,
value: 3000,
pickup: 3
},
counter: 3
}
],
receiver: {
firstname: 'John',
lastname: 'Doe',
phoneNumber: '+221770000000',
email: '[email protected]',
entreprise: 'John Corporation',
address: 'Dakar-Plateau, Dakar, Sénégal',
specificationAddress: 'côté brioche'
}
}
],
additionnalInfos: 'Test'
})
};
fetch('https://api.papslogistics.com/requests?apikey=', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.papslogistics.com/requests?apikey=",
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([
'executionDate' => '2026-08-01',
'vehicles' => [
[
'numberOfVehicule' => 1
]
],
'stops' => [
[
'address' => 'Dakar-Plateau, Dakar, Sénégal',
'itemsToPick' => [
[
'product' => [
'reference' => '4759XHG0MKH',
'description' => 'iPhone 13 Pro Max',
'quantity' => 3,
'value' => 3000,
'pickup' => 3
],
'counter' => 3
]
],
'itemsToDelivered' => [
[
'product' => [
'reference' => '4759XHG0MKH',
'description' => 'iPhone 13 Pro Max',
'quantity' => 3,
'value' => 3000,
'pickup' => 3
],
'counter' => 3
]
],
'receiver' => [
'firstname' => 'John',
'lastname' => 'Doe',
'phoneNumber' => '+221770000000',
'email' => '[email protected]',
'entreprise' => 'John Corporation',
'address' => 'Dakar-Plateau, Dakar, Sénégal',
'specificationAddress' => 'côté brioche'
]
]
],
'additionnalInfos' => 'Test'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.papslogistics.com/requests?apikey="
payload := strings.NewReader("{\n \"executionDate\": \"2026-08-01\",\n \"vehicles\": [\n {\n \"numberOfVehicule\": 1\n }\n ],\n \"stops\": [\n {\n \"address\": \"Dakar-Plateau, Dakar, Sénégal\",\n \"itemsToPick\": [\n {\n \"product\": {\n \"reference\": \"4759XHG0MKH\",\n \"description\": \"iPhone 13 Pro Max\",\n \"quantity\": 3,\n \"value\": 3000,\n \"pickup\": 3\n },\n \"counter\": 3\n }\n ],\n \"itemsToDelivered\": [\n {\n \"product\": {\n \"reference\": \"4759XHG0MKH\",\n \"description\": \"iPhone 13 Pro Max\",\n \"quantity\": 3,\n \"value\": 3000,\n \"pickup\": 3\n },\n \"counter\": 3\n }\n ],\n \"receiver\": {\n \"firstname\": \"John\",\n \"lastname\": \"Doe\",\n \"phoneNumber\": \"+221770000000\",\n \"email\": \"[email protected]\",\n \"entreprise\": \"John Corporation\",\n \"address\": \"Dakar-Plateau, Dakar, Sénégal\",\n \"specificationAddress\": \"côté brioche\"\n }\n }\n ],\n \"additionnalInfos\": \"Test\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.papslogistics.com/requests?apikey=")
.header("Content-Type", "application/json")
.body("{\n \"executionDate\": \"2026-08-01\",\n \"vehicles\": [\n {\n \"numberOfVehicule\": 1\n }\n ],\n \"stops\": [\n {\n \"address\": \"Dakar-Plateau, Dakar, Sénégal\",\n \"itemsToPick\": [\n {\n \"product\": {\n \"reference\": \"4759XHG0MKH\",\n \"description\": \"iPhone 13 Pro Max\",\n \"quantity\": 3,\n \"value\": 3000,\n \"pickup\": 3\n },\n \"counter\": 3\n }\n ],\n \"itemsToDelivered\": [\n {\n \"product\": {\n \"reference\": \"4759XHG0MKH\",\n \"description\": \"iPhone 13 Pro Max\",\n \"quantity\": 3,\n \"value\": 3000,\n \"pickup\": 3\n },\n \"counter\": 3\n }\n ],\n \"receiver\": {\n \"firstname\": \"John\",\n \"lastname\": \"Doe\",\n \"phoneNumber\": \"+221770000000\",\n \"email\": \"[email protected]\",\n \"entreprise\": \"John Corporation\",\n \"address\": \"Dakar-Plateau, Dakar, Sénégal\",\n \"specificationAddress\": \"côté brioche\"\n }\n }\n ],\n \"additionnalInfos\": \"Test\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.papslogistics.com/requests?apikey=")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"executionDate\": \"2026-08-01\",\n \"vehicles\": [\n {\n \"numberOfVehicule\": 1\n }\n ],\n \"stops\": [\n {\n \"address\": \"Dakar-Plateau, Dakar, Sénégal\",\n \"itemsToPick\": [\n {\n \"product\": {\n \"reference\": \"4759XHG0MKH\",\n \"description\": \"iPhone 13 Pro Max\",\n \"quantity\": 3,\n \"value\": 3000,\n \"pickup\": 3\n },\n \"counter\": 3\n }\n ],\n \"itemsToDelivered\": [\n {\n \"product\": {\n \"reference\": \"4759XHG0MKH\",\n \"description\": \"iPhone 13 Pro Max\",\n \"quantity\": 3,\n \"value\": 3000,\n \"pickup\": 3\n },\n \"counter\": 3\n }\n ],\n \"receiver\": {\n \"firstname\": \"John\",\n \"lastname\": \"Doe\",\n \"phoneNumber\": \"+221770000000\",\n \"email\": \"[email protected]\",\n \"entreprise\": \"John Corporation\",\n \"address\": \"Dakar-Plateau, Dakar, Sénégal\",\n \"specificationAddress\": \"côté brioche\"\n }\n }\n ],\n \"additionnalInfos\": \"Test\"\n}"
response = http.request(request)
puts response.read_body{
"code": 200,
"message": "Success",
"error": "<string>",
"data": {
"executionDate": "2026-08-01",
"productType": "COURIERS",
"vehicles": [
{
"vehicleType": "SCOOTER",
"numberOfVehicule": 1
}
],
"stops": [
{
"action": "Delivery",
"address": "Dakar-Plateau, Dakar, Sénégal",
"itemsToPick": [
{
"product": {
"reference": "4759XHG0MKH",
"description": "iPhone 13 Pro Max",
"weight": "S",
"quantity": 3,
"value": 3000,
"pickup": 3
},
"counter": 3
}
],
"itemsToDelivered": [
{
"product": {
"reference": "4759XHG0MKH",
"description": "iPhone 13 Pro Max",
"weight": "S",
"quantity": 3,
"value": 3000,
"pickup": 3
},
"counter": 3
}
],
"receiver": {
"firstname": "John",
"lastname": "Doe",
"phoneNumber": "+221770000000",
"email": "[email protected]",
"entreprise": "John Corporation",
"address": "Dakar-Plateau, Dakar, Sénégal",
"specificationAddress": "côté brioche"
}
}
],
"additionnalInfos": "Test"
}
}Authorizations
Body
application/json
Response
200 - application/json
Demande de transport créée