Skip to main content

Get default package sizes

GET https://delivery-api.paysera.com/rest/v1/default-package-sizes

Retrieve enabled default package size options.

Returns a list of package sizes with their dimensions (weight in grams, width/length/height in millimeters).

Pagination​

Use limit and offset parameters to navigate through results.

Authorization​

This endpoint requires MAC (Message Authentication Code) authentication.

Authorization Header Format:

Authorization: MAC id="YOUR_PROJECT_ID",ts="1234567890",nonce="xyz123",mac="GENERATED_MAC_HASH"

Example:

Authorization: MAC id="a9b8c7d6e5f4g3h2", ts="1234567890", nonce="xyz123abc456def", mac="dGhpcyBpcyBhIHJhbmRvbSBtYWMgaGFzaCB2YWx1ZQ==", ext="body_hash=cmFuZG9tQm9keUhhc2hWYWx1ZQ%3D%3D"

For more details, please refer to the Authentication section.

Parameters​

Query Parameters​

NameTypeRequiredDescription
limitintegerMaximum number of results
offsetintegerNumber of results to skip
order_bystringSort field
order_directionstringSort direction
afterstringCursor for pagination (after)
beforestringCursor for pagination (before)

Example​

Request​

GET https://delivery-api.paysera.com/rest/v1/default-package-sizes?limit=20&offset=value&order_by=value&order_direction=value&after=value&before=value
Authorization: MAC id="CLIENT_ID", ts="TIMESTAMP", nonce="RANDOM_STRING", mac="MAC_HASH"

Response​

{
"_metadata": {
"total": 5,
"offset": 0,
"limit": 20
},
"package_sizes": [
{
"id": 1,
"code": "small",
"weight": 1000,
"width": 200,
"length": 300,
"height": 100
},
{
"id": 2,
"code": "medium",
"weight": 5000,
"width": 400,
"length": 500,
"height": 300
}
]
}

AUTHORIZATION: HTTP

REQUEST

Base URL
https://delivery-api.paysera.com
Query Parameters
limit
Maximum number of results
offset
Number of results to skip
order_by
Sort field
order_direction
Sort direction
after
Cursor for pagination (after)
before
Cursor for pagination (before)

RESPONSE

Package sizes retrieved successfully
{
"_metadata": {
"total": 5,
"offset": 0,
"limit": 20
},
"package_sizes": [
{
"id": 1,
"code": "small",
"weight": 1000,
"width": 200,
"length": 300,
"height": 100
},
{
"id": 2,
"code": "medium",
"weight": 5000,
"width": 400,
"length": 500,
"height": 300
}
]
}