El API de ZRU utiliza métodos HTTP y una estructura RESTful de endpoint.
- La autenticación del API se realiza vía Header Authorization.
- Todas las peticiones se deben realizar en formato JSON, y las respuestas del API son en dicho formato.
El API de ZRU utiliza métodos HTTP y una estructura RESTful de endpoint.
curl -i -X GET \
https://api.zrupay.com/v1/shipping/ \
-H 'Authorization: YOUR_API_KEY_HERE'
{ "count": 0, "items_per_page": 0, "next": "string", "previous": "string", "results": [ { … } ] }
curl -i -X POST \
https://api.zrupay.com/v1/shipping/ \
-H 'Authorization: YOUR_API_KEY_HERE' \
-H 'Content-Type: application/json' \
-d '{
"name": "SHIPPING_NAME",
"price": 100
}'
{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "name": "string", "price": 0.1 }
curl -i -X GET \
'https://api.zrupay.com/v1/shipping/{shipping-id}/' \
-H 'Authorization: YOUR_API_KEY_HERE'
{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "name": "string", "price": 0.1 }
curl -i -X PATCH \
'https://api.zrupay.com/v1/shipping/{shipping-id}/' \
-H 'Authorization: YOUR_API_KEY_HERE' \
-H 'Content-Type: application/json' \
-d '{
"price": 50
}'
{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "name": "string", "price": 0.1 }
curl -i -X DELETE \
'https://api.zrupay.com/v1/shipping/{shipping-id}/' \
-H 'Authorization: YOUR_API_KEY_HERE'