Fee Tutorial
How to create a product fee
1
curl -i -X POST
'https://api.emporix.io/fee/{tenant}/fees'
-H 'Authorization: Bearer {{OAUTH2_ACCESS_TOKEN}}'
-H 'Content-Language: string'
-H 'Content-Type: application/json'
-d '{
"name": {
"de": "Sixpack PET",
"en": "Sixpack PET"
},
"code": "apple_picking_fee",
"feeType": "ABSOLUTE",
"siteCode": "main",
"feeAbsolute": {
"amount": 3.5,
"currency": "EUR"
},
"active": true,
"taxable": false
}'2
curl -i -X PUT
'https://api.emporix.io/fee/{tenant}/productFees/{productId}/fees?siteCode=main&partial=false'
-H 'Authorization: Bearer {{OAUTH2_ACCESS_TOKEN}}'
-H 'Content-Type: application/json'
-d '{
"feeIds": [
"57b30fd2289c48001daf5486",
"96b30fd4586c48001daf1752"
]
}'3
curl -i -X GET
'https://api.emporix.io/fee/{tenant}/productFees/{productId}/fees?siteCode=main&expand=false'
-H 'Accept-Language: *'
-H 'Authorization: Bearer {{OAUTH2_ACCESS_TOKEN}}'curl -i -X POST
'https://api.emporix.io/fee/{tenant}/itemFees/searchByProductId'
-H 'Authorization: Bearer {{OAUTH2_ACCESS_TOKEN}}'
-H 'Content-Type: application/json'
-d '{
"productId": "Apple_A_productId",
"siteCodes": [
"example_site_code"
],
"pageNumber": 1,
"pageSize": 10
}'How to create a payment fee
1
curl -i -X POST
'https://api.emporix.io/fee/{tenant}/fees'
-H 'Authorization: Bearer {{OAUTH2_ACCESS_TOKEN}}'
-H 'Content-Language: string'
-H 'Content-Type: application/json'
-d '{
"name": {
"de": "Sixpack PET",
"en": "Sixpack PET"
},
"code": "apple_picking_fee",
"feeType": "ABSOLUTE",
"siteCode": "main",
"feeAbsolute": {
"amount": 3.5,
"currency": "EUR"
},
"active": true,
"taxable": false
}'2
curl -i -X POST
'https://api.emporix.io/fee/{tenant}/itemFees'
-H 'Authorization: Bearer {{OAUTH2_ACCESS_TOKEN}}'
-H 'Content-Language: string'
-H 'Content-Type: application:json'
-d '[object Object]'3
curl -i -X PUT
'https://api.emporix.io/fee/{tenant}/itemFees/{itemYRN}/fees?partial=false'
-H 'Authorization: Bearer {{OAUTH2_ACCESS_TOKEN}}'
-H 'Content-Type: application/json'
-d '{
"feeIds": [
"57b30fd2289c48001daf5486",
"96b30fd4586c48001daf1752"
]
}'4
curl -i -X POST
'https://api.emporix.io/fee/{tenant}/itemFees/search?siteCode=main'
-H 'Authorization: Bearer {{OAUTH2_ACCESS_TOKEN}}'
-H 'Content-Type: application/json'
-d '{
"itemYrns": [
"urn:yaas:saasag:caasproduct:product:tenantName;5c2e4957a46b0e0008491095",
"urn:yaas:saasag:caasproduct:product:tenantName;5c2e4957a46b0e0008491096"
],
"siteCode": "main"
}'Last updated
Was this helpful?

