# Update the same-day delivery template

# Dxplaination of Interface Call Request

http请求方式:POST
https://api.weixin.qq.com/product/offline/update_same_city_template?access_token=xxxxxxxxx

# Example of request parameters

{
    "same_city_template":{
        "template_id":60114,
        "shipper":1,
        "scope":5000,
        "same_city_valuation":{
            "type":0
        },
        "special_time":{
            "type":0
        },
        "delivery_time":{
            "start_business_hour":9,
            "start_business_minute":30,
            "end_business_hour":22,
            "end_business_minute":0,
            "book_time":1440,
            "first_val_meter":3000,
            "first_val_minutes":30,
            "second_val_meter":1000,
            "second_val_minutes":10
        }
    }
}

# Examples of back-up

{
    "errcode" : 0,
    "errcode" : "",
}

# Dxplaination of request parameters

参数 type Is it compulsory? Introductions
same_city_template.template_id number yes Same city distribution template ID
same_city_template.shipper number yes Suppliers
same_city_template.scope number yes Delivery range, metre per unit
same_city_template.same_city_valuation object yes Methods of pricing
same_city_template.special_time object yes Special Hours
same_city_template.delivery_time object yes Delivery time

# Dxplaination of callback parameters

参数 type Introductions
errcode string Error code
errmsg string Error message

# object-same_city_valuation

参数 type Is it compulsory? Introductions
type number yes Type of billing
condition_free_valuation object no Free shipping conditions
tiered_billing_valuation object no Stairway billing method

# object-same_city_valuation.condition_free_valuation

参数 type Is it compulsory? Introductions
min_free_price number yes Conditions Minimum Amount Free of Freight

# object-same_city_valuation.tiered_billing_valuation

参数 type Is it compulsory? Introductions
min_send_price number yes Minimum starting amount, divided
first_val_meter number yes Within xx minutes
first_price number yes Within xx minutes
second_val_meter number yes Each additional xx meters
second_price number yes Increase xx points

# object-special_time

参数 type Is it compulsory? Introductions
type number yes type
extra_fee_valuation object no Additional charges for special periods

# object-special_time.extra_fee_valuation

参数 type Is it compulsory? Introductions
fee_details[].start_hour number yes Start time, hours
fee_details[].start_minute number yes Start time, minutes
fee_details[].end_hour number yes End time, hours
fee_details[].end_minute number yes End time, minutes
fee_details[].fee number yes Fees for this period

# object-delivery_time

Within the first_val_meter, every time you add the second_val_meter, you need to add the second_val_minutes

参数 type Is it compulsory? Introductions
start_business_hour number yes Time of opening shop, hours
start_business_minute number yes Time to open a shop, minutes
end_business_hour number yes Closing time, hours
end_business_minute number yes Closing time, minutes
book_time number yes Can be scheduled for time, minutes
first_val_meter number yes Range of delivery, meters
first_val_minutes number yes Delivery time, minutes
second_val_meter number yes Increase in reach, metres
second_val_minutes number yes Increase in delivery time, minutes

# Enumeration values-shipper

枚举值 string Introductions
0 Shipper_Unknown unknown
1 Shipper_MerchantSend Merchant delivery
2 Shipper_ThirdPartySend Third Party Delivery

# Enumeration value - same_city_valuation.type

枚举值 string Introductions
0 ValuationType_Free Free shipping
1 ValuationType_ConditionFree Conditions Free shipping
2 ValuationType_TieredBilling Staircase billing

# Enumeration value - special_time.type

枚举值 string Introductions
0 ValuationType_Free No additional costs
1 ValuationType_ExtraFee Additional cost increase

# Return code

返回码 Error Type
-1 System exceptions
-2 Token too long