提交代缴订单

  • 正式地址:https://api.shebaotong.com/v1/order/place
  • 测试地址:http://test.shebaotong.com/order/place
  • 支持格式:FORM DATA
  • HTTP请求方式:POST
  • 是否需要授权:是
  • 如果参数包含多个子参数时,该参数格式应为JSON格式的字符串。如 请求示例 中的invoice参数
    参保人身份证号码如果最后一位为“X”,系统将自动转为大写


请求示例:


    "access_token": "cdb6de50014c1e696f4b8c0c3fb0f708",
    "usercode": "20151406396",
    "invoice": {
        "title": "",
        "address": "",
        "consignee": "",
        "phone": ""
    },
    "emps": [
        {
            "id": "441481111111111111",
            "name": "何郭辉",
            "idtype": "idcard",
            "phone": "13411111114",
            "gender": "男",
            "birthday": "1990-08-10"
        }
    ],
    "add": [
        {
            "id": "441481111111111111",
            "name": "何郭辉",
            "ins": {
                "type": "shanghaiwuxian",
                "base": 4000
            },
            "hf": {
                "type": "shanghaigongjijin",
                "base": 5000
            }
        }
    ],
    "keep": [
        {
            "id": "441481111111111112",
            "name": "樊玲玲"
        }
    ],
    "stop": [
        {
            "id": "441481111111111111",
            "name": "何郭辉"
        },
        {
            "id": "441481111111111112",
            "name": "樊玲玲",
            "ins": true,
            "hf": false
        }
    ],
    "overdue": [
        {
            "id": "441481199204174832",
            "name": "何郭辉",
            "ins": [
                {
                    "month": "201506",
                    "base": 5000
                },
                {
                    "month": "201507",
                    "base": 5000
                }
            ],
            "hf": [
                {
                    "month": "201506",
                    "base": 5000
                },
                {
                    "month": "201507",
                    "base": 5000
                }
            ]
        }
    ],
    "basechg": [
        {
            "id": "441481199204174832",
            "name": "何郭辉",
            "insbase": 5000,
            "hfbase": 6000
        }
    ]

请求参数说明:

必需 类型 说明
access_token String 申请后获得
usercode String 此用户在社保通中的唯一标识符,在创建社保通平台企业账号中获得
invoice Array 如若用户需要开票,则需求填入开票信息
title String 发票抬头
address String 快递地址
consignee String 发票接收人
phone String 联系电话
month Number 补缴月份
emps Array 报增人员的信息集合,若有报增人员,此集合为必需值
add Array 报增人员集合
keep Array 续缴人员集合
basechg Array 基数变更人员集合
overdue Array 补缴人员集合
name String 姓名
idtype String 证件类型
idcard为身份证
passport 为护照
gender String 性别,若idtype为passport,此项必填
birthday String 出生年月,若idtype为passport,此项必填
id String 证件号
ins Object 社保缴交信息
hf Object 公积金缴交信息
type String 社保公积金缴交类型,对应按城市获取社保公积金基础数据
获取的社保公积金type
base String 社保公积金缴交基数
stop Array 停缴人员集合

add、overdue、keep、stop、basechg需确保至少有一个不为空; 若某成员在2月份为续缴状态,但3月份提交的订单此成员即未标明续缴,也未标明停缴,我方将自动停缴此成员;如需要单独停缴社保或者公积金时,在stop集合中单独设置ins与hf为true或false,具体可见示例;如果某成员同时出现续缴和停缴信息,我方将优先处理停缴申请,再处理续缴请求(由于停缴需我方进行确认,故续缴请求将会失败);如果接口接入方和社保通在合作中规定不为订单开票,但是却提交的订单发票信息,则返回5019错误信息。

返回结果示例:

{
    "orderid": "486902185116451",
    "amount": 2586329.07,
    "ordsum": 2586329.07,
    "ordPaymentFee": 250,
    "ordRefundFee": 130,
    "service": 0,
    "success": [
        {
            "base": 4000,
            "co": 1460,
            "code": "shebao",
            "id": "441481111111111111",
            "name": "何郭辉",
            "in": 420,
            "month": "201512",
            "odf": 0,
            "status": "add",
            "type": "shanghaiwuxian",
            "sum": 1880
        },
        {
            "base": 4000,
            "co": 1460,
            "code": "shebao",
            "id": "441481111111111112",
            "name": "高其刚",
            "in": 420,
            "month": "201512",
            "odf": 0,
            "status": "add",
            "type": "shanghaiwuxian",
            "sum": 1880
        },
        {
            "base": 4000,
            "co": 1460,
            "code": "shebao",
            "id": "441481111111111113",
            "name": "吴艺",
            "in": 420,
            "month": "201512",
            "odf": 0,
            "status": "add",
            "type": "shanghaiwuxian",
            "sum": 1880
        }
    ],
    "fail": [
        {
            "id": "441481199204174832",
            "name": "何郭辉",
            "code": "shebao",
            "status": "keep",
            "month": "201512",
            "errcode": 5011,
            "msg":"该人员本月已提交过订单"
        }
    ],
    "paymentFeeDtl": [
        {
            "co": 200,
            "code": "shebao",
            "desc": "11111",
            "feeType": "normal",
            "id": "632623111103244929",
            "in": 50,
            "month": "201605",
            "name": "金金",
            "service": 0,
            "sum": 250,
            "type": "tianjinhsebaochengzhen",
            "dtl":[{
                  "insCode": "yanglao",
                  "orgDiff": "678",
                  "empDiff": "261.7"
             }]
        }
    ],
    "refundFeeDtl": [
        {
            "co": 100,
            "code": "shebao",
            "desc": "1111",
            "feeType": "normal",
            "id": "420626111111114311",
            "in": 20,
            "month": "201605",
            "name": "李多多",
            "service": 10,
            "sum": 130,
            "type": "chengdushebaochengzhen"
        }
    ]
}

返回字段说明:

类型 说明
orderid String 若创建成功,则返回订单号
amount Number 订单金额
service Number 服务费
ordsum Number 订单总金额
success Array 提交成功人员集合
name String 姓名
id String 证件号
base Number 基数
co Number 公司缴纳部分
in Number 个人缴纳部分
odf Number 补缴时产生的滞纳金
status String 服务类型:add/overdue/keep/basechg/stop,分别对应报增/补缴/续缴/基数变更/停缴
month String 缴费月份,如果是补缴,则为补缴月份
sum Number 总缴纳金额
fail Array 提交失败人员集合
code String 在成功人员集合中为:shebao/gongjijin,分别对应社保/公积金
在失败人员集合中为,shebao/gongjijin/info,分别对应社保/公积金/基础信息
errcode Number 提交失败原因编码
msg String 失败原因
ordPaymentFee Number 订单补收费用合计
ordRefundFee Number 订单补退费用合计
paymentFeeDtl Number 订单补收明细
refundFeeDtl Number 订单补退明细
feeType String 补收/补退的费用类型,normal/once,分别表示正常和一次性
desc String 订单补收/补退原因
insCode String 险种
orgDiff Number 订单补收/补退明细的单位金额
empDiff Number 订单补收/补退明细的个人金额

关于错误返回值与错误代码,详见错误代码说明

若订单中所有人员订单都缴纳失败,则返回信息中orderid为空;当fail中code为info时,无status与month字段。