Update a Fee

Update Fee Rule

PUT https://workspace.myeshopbox.com/payments/api/v1/fee

Headers

Name
Type
Description

Authorization

string

The Bearer token to grant API access

Request Body

Name
Type
Description

forRevision

boolean

Tells whether fee is to be revised or corrected true : major change false : minor change

version

string

Version of the fee after it is updated

ruleId

string

Mongo Id of the fee updated

fee

array

Detail of when fee is charged Also see: The fee Object

validFrom

string

Datetime from which fee will

validTo

string

Datetime when fee will be expired

feeRules

object

Details of fee rules Also see: The feeRules Object

feePortalid

number

Id of portal for which fee is updated

portalId

string

Unique Id for a portal (Ex. Amazon, Flipkart)

feeId

string

Unique Id for fee created or Unique Id for already present fee

feeName

string

Name of the created fees

isInclusiveTax

string

"1" if fees is tax inclusive else "0"

inclusiveTaxPercentage

string

Percentage of tax applicable on a fee

validFrom

string

Date from which fees will be activated

feePortalId

string

Unique Id for a fee on a particular portal

{
    "id": "378",
    "accountId": "28",
    "version": "2.4",
    "ruleId": "5d7f2b78ad0cf200017cebbb",
    "portalId": "2",
    "feeId": "1",
    "feeName": "",
    "isInclusiveTax": "0",
    "inclusiveTaxPercentage": 11.0,
    "fee": [
        {
            "eventType": "cancelled",
            "eventSubType": "",
            "partialPercentageValue": 0.0,
            "feeCharged": "CHARGED_FEE"
        }
    ],
    "validFrom": "2019-09-09T00:00:00.000+05:30",
    "validTo": "2019-09-11T00:00:00.000+05:30",
    "feeRules": [
        {
            "feeRanges": [
                {
                    "rangeType": "product selling price",
                    "rangeTypeUnit": "INR",
                    "minRange": 0.0,
                    "maxRange": 100.0
                }
            ],
            "feeValues": [
                {
                    "type": "fixed",
                    "value": 12.0,
                    "applicableOn": "Per Order"
                }
            ]
        }
    ],
    "feePortalId": "378",
    "forRevision": false
}
curl -X PUT https://workspace.myeshopbox.com/payments/api/v1/fee \
-H "Content-Type: application/json" \
-H "Authorization: Bearer XXXX" \
-d $'{
    "portalId": 3,
    "feeId": "40",
    "feeName": null,
    "isInclusiveTax": "0",
    "inclusiveTaxPercentage": "63",
    "chargedFee": "cancelled",
    "chargedFeeCases": "",
    "courierReturnedFee": "",
    "courierReturnedPercent": "",
    "customerReturnedFee": "",
    "customerReturnedPercent": "",
    "validityPeriod": "definite",
    "validFrom": "2019-09-09",
    "validTo": "2019-09-11",
    "fee": [
        {
            "eventType": "shipped",
            "eventSubType": "",
            "partialPercentageValue": "",
            "feeCharged": "CHARGED_FEE"
        },
        {
            "eventType": "returned",
            "eventSubType": "courier",
            "partialPercentageValue": "",
            "feeCharged": "REVERSED_FEE"
        },
        {
            "eventType": "returned",
            "eventSubType": "customer",
            "partialPercentageValue": "",
            "feeCharged": "REVERSED_FEE"
        }
    ],
    "feeRules": [
        {
            "details": {
                "shippingZone": "regional"
            },
            "feeValues": [
                {
                    "type": "fixed",
                    "value": 2,
                    "applicableOn": "Per Order",
                    "id": 1
                }
            ]
        }
    ],
    "id": 603,
    "ruleId": "5d7a4867ad0cf20001e527df",
    "forRevision": true
}'

Last updated