Download OpenAPI specification:Download
You can find out more about Swagger at
paps-swagger.
For this sample, you can use the api key special-key to test the authorization filters.
Paps offers an API that allows developers to extend the built-in functionality of these warehousing, delivery, shipping services. The Paps API allows you to create tasks (delivery and shipping).
Before you can integrate a PAPS product or solution, you must configure your development environment to obtain a key,
which authorizes your REST API calls.
To test your web and mobile applications, you can use [swagger]. You must have a developer account, personal or professional.
To test your web and mobile apps with mock shipping, create a personal account to represent a buyer and a business account to represent a merchant.
Note: If you do not have an key, click [Create].This document provides important security related guidelines and best practices for both development projects and system integrations. The following two main topics are covered:
PAPS offers two forms of authentication:
OAuth2 - an open protocol to allow secure authorization in a simple and standard method from web, mobile and desktop applications.
https://paps-api.papslogistics.com/<path>?apiKey=<apiKey>
Conduct tests here
All unsuccessful queries will return a code other than 200
The list of codes explaining only the errors of the services and not the errors from the Developer application :
200 Successful: The request was successful.400 Bad request : The request cannot continue because it is missing a mandatory parameter. Check that you have set all parameters to execute the request.401 Unauthorised: The authentication of the request did not go well. You did not include the security key that allows us to authenticate you.402 Unknown key: The security key in the request is incorrect. Please check that the key is the one that was sent to you by email.502 Bad gateway: The request cannot be fulfilled at this time. Please try again laterThe API restores, from the shipment number, the history of the known follow-up statuses for the following services:
It allows a simple integration and a harmonized follow-up of the statuses of these various products. The "event" object gathers the events linked to the flashings of a sending by our services during its routing. These events, which can be redundant, carry codes useful to your information systems.
Definitions of key terms
| Security Scheme Type | TERMS |
|---|---|
| terms definition | Authorization URL: https://paps-api.papslogistics.com/oauth/dialog key terms:
|
This request is used to add a customer to your top customer list. This is to facilitate and execute an order as fast as possible; it is convenient for an express delivery.
| cookieParam | integer <int64> Some cookie |
| firstname required | string Example: kiamet customer's FirstName |
| lastname required | string Example: MAV customer's LastName |
| phoneNumber required | number Example: +221 72 700 60 30 customer's phone |
| address required | string Example: 75 cite keur gorgui, Dakar,Sénégal Customer's shipping address |
| email required | |
| company | string Example: PAPS Customer's company |
| specificationAddress | string Example: PAPS specific address of the customer |
curl -X POST \ https://api.papslogistics.com/v1/clients/receivers?apiKey=special_key \ -H 'Content-Type: application.json' \ -H 'X-Paps-Access-Token: {access_token}' \ -d ' { "firstname": "lastname": "phoneNumber": "address": "email": "company": "specificationAddress": } '
{- "firstname": "trinhchin",
- "lastname": "innos",
- "phoneNumber": 19593855059,
- "entreprise": "hinno",
- "address": "Dakar-Plateau, Dakar, Sénégal",
- "specificationAddress": "côté boulangerie"
}retrieve....
| cookieParam | integer <int64> Some cookie |
| firstname required | string Example: kiamet customer's FirstName |
| lastname required | string Example: MAV customer's LastName |
| phoneNumber required | number Example: +221 72 700 60 30 customer's phone |
| address required | string Example: 75 cite keur gorgui, Dakar,Sénégal Customer's shipping address |
| email required | |
| company | string Example: PAPS Customer's company |
| specificationAddress | string Example: PAPS specific address of the customer |
{- "receiver_UID": "600aba46c6082a3bca550f15",
- "receiver_firstname": "daback",
- "receiver_lastname": "YAPO",
- "receiver_phone_number": 19593691730,
- "receiver_entreprise": "wetchou",
- "receiver_address": {
- "country": "Senegal",
- "city"": "Sicap-Liberté",
- "region"": "Dakar Region",
- "address"": "Dakar Sacré Coeur, Dakar Region, Senegal",
- "place_id"": "ChIJJdWNz7tywQ4Rxth1EgBU1p0",
- "additional_address": null,
- "location": {
- "latitude": 14.7133509,
- "longitude": -17.4621269
}
}, - "receiver_specification_address": "côté boulangerie",
- "receiver_client_UID": "600aba46c6082a3bca550f15",
- "receiver_created_at": "2021-01-21T15:50:32.155Z",
- "receiver_last_edited_at": "2021-01-22T15:50:32.155Z"
}This request is used to add a user. This is to delegate tasks within your team.
| cookieParam | integer <int64> Some cookie |
| firstname required | string Example: kiamet User FirstName |
| lastname required | string Example: MAV User LastName |
| phoneNumber required | number Example: +221 72 700 60 30 User phone |
| job required | string Example: responsible for shipments The name job of the User |
| email required | |
| profile required | string Default: SIMPLE Select a profile to assign : ADMIN , SIMPLE |
| pictureURL | string Example: http://localhost.com/picture/3141321424 The avatar of the User |
curl -X POST \ https://api.papslogistics.com/v1/clients/users?apiKey=special_key \ -H 'Content-Type: application.json' \ -H 'X-Paps-Access-Token: {access_token}' \ -d ' { "firstname": "trinhchin", "lastname": "innos", "phoneNumber": "+221770000000", "email": "[email protected]", "job": "hinno", "profile": "ADMIN", "pictureURL": "http://localhost.com/picture/3141321424" } '
{- "firstname": "trinhchin",
- "lastname": "innos",
- "phoneNumber": 19593855059,
- "job": "hinno",
- "profil": "ADMIN",
}This request is used to add and or store these items. It consists of creating virtual products to store at PAPS to facilitate delivery; useful for saving money!
| cookieParam required | integer <int64> Some cookie |
| picture required | Array of strings <url> <= 20 items Example: PAPS specific address of the customer |
| name required | string Example: basket Name of product |
| reference required | string Example: i280 product reference |
| description required | string Example: bla bla bla description product |
| category required | string Example: play category of product |
| value required | number Example: 1599 price of product |
| volume | number Example: 9 volume product |
| packageSize required | string total package size (S, M, L, XL, XXL) items |
curl -X POST \ https://api.papslogistics.com/v1/catalogues?apiKey=special_key \ -H 'Content-Type: application.json' \ -H 'X-Paps-Access-Token: {access_token}' \ -d ' { "picture": "http://localhost.com/picture/3141321424", "name": "iPhone 12", "reference": "£3205", "description": "apple iphone gold", "category": "Phones & Tablets", "value": "800998", "volume": "12", "packageSize": "S" } '
{- "code": 200,
- "message": "successfully",
- "data": "Object<T>"
}This request is used to add and or store these items. It consists of creating virtual products to store at PAPS to facilitate delivery; useful for saving money!
| cookieParam | integer <int64> Some cookie |
| picture required | Array of strings <url> <= 1 items Example: PAPS specific address of the customer |
| name required | string Example: basket Name of product |
| reference required | string Example: i280 product reference |
| description required | string Example: bla bla bla description product |
| category required | string Example: play category of product |
| value required | number Example: 1599 price of product |
| volume | number Example: 9 volume product |
| packageSize required | string total package size (S, M, L, XL, XXL) items |
curl -X POST \ https://api.papslogistics.com/v1/products?apiKey=special_key \ -H 'Content-Type: application.json' \ -H 'X-Paps-Access-Token: {access_token}' \ -d ' { "picture": "http://localhost.com/picture/3141321424", "name": "iPhone 12", "reference": "£3205", "description": "apple iphone gold", "category": "Phones & Tablets", "value": "800998", "volume": "12", "packageSize": "S" } '
{- "code": 200,
- "message": "successfully",
- "data": "Object<T>"
}This request is used to create a pickup task. A pickup task refers to an errand where the package is to be picked up and delivered.
| cookieParam | integer <int64> Some cookie |
| datePickup required | string <date> Example: 2021-12-01T08:37:08.432Z date of pick items |
| timePickup required | string Example: 11:00 time of pick items |
| vehicleType required | string <time> vehicle type : VAN, MINIVAN, SCOOTER |
| address required | array Example: 75 cite keur gorgui, Dakar,Sénégal Customer's shipping address |
required | object Example: customers_auth customer's name |
required | object Example: parcels_auth products to pick |
curl -X 'POST' \ 'http://localhost:14300/tasks' \ -H 'accept: application/json' \ -H 'Content-Type: application/json' \ -d '{ "type": "PICKUP", "datePickup": "2022-01-31T15:05:20.492Z", "timePickup": "11:00", "vehicleType": "SCOOTER", "address": "Dakar-Plateau, Dakar, Sénégal", "receiver": { "firstname": "trinhchin", "lastname": "innos", "phoneNumber": "+221770000000", "email": "[email protected]", "entreprise": "hinno", "address": "Dakar-Plateau, Dakar, Sénégal", "specificationAddress": "côté brioche" }, "parcels": [ { "packageSize": "S", "description": "trinhchin", "price": 10000, "amountCollect": 10000 } ]}
{- "job_type": "PICKUP",
- "job_address": {
- "country": "Senegal",
- "countryCode": "SN",
- "city": "Dakar-Plateau",
- "region": "Dakar Region",
- "address": "Dakar-Plateau, Dakar Region, Senegal",
- "additional_address": "string",
- "location": {
- "latitude": 14.6629438,
- "longitude": -17.4374803
}, - "place_id": "ChIJXRv0vE5ywQ4RpvG-1YKthC0"
}, - "job_date": "2020-01-01T00:00:00.000Z",
- "job_slot_start": 660,
- "job_slot_end": 780,
- "job_time": 660,
- "job_vehicle_type": "SCOOTER"
}object origin address | |
object destination address | |
object cart item | |
| apiKey required | string Your special key generated |
{- "origin": {
- "country": "string",
- "city": "string",
- "address1": "string"
}, - "destination": {
- "country": "string",
- "city": "string",
- "address1": "string"
}, - "items": {
- "name": "string",
- "quantity": 0,
- "grams": 0,
- "price": 0
}, - "apiKey": "ibes7i7gmpsv326bkz38qkdjfdskjfndn72l1v28mzpb0p7aqq",
- "petType": "getRates"
}| pickupLocation required | string pickup address |
| name required | string product name |
| category required | any Default: "otherCategories" Enum: "otherCategories" "sportingGoods" "videoGamesConsoles" "babyProducts" "fashion" "homeOffice" "householdAppliances" "computers" "electronics" "phonesTablets" "food" "healthBeauty" select category |
| additionalInfo required | string add description product |
| packageSize required | any Default: "S" Enum: "S" "M" "L" "XL" "XXL" select package size |
| destinationAddress required | string destination address (please submit specific address) |
| vehicle required | any Default: "MiniVan" Enum: "MiniVan" "Truck" "Van" chose vehicle type |
| shipDate required | string <date-time> Estimated ship date |
| shipType | string Type of shipping tour |
{- "pickupLocation": "Dakar, plateau",
- "name": "string",
- "category": "otherCategories",
- "additionalInfo": "string",
- "packageSize": "S",
- "destinationAddress": "Dakar, plateau",
- "vehicle": "MiniVan",
- "shipDate": "2019-08-24T14:15:22Z",
- "shipType": "string"
}