j9九游会登录/ 云商店/ / / / / / / 组织部门信息同步(增量)
更新时间:2024-01-19 gmt 08:00

组织部门信息同步(增量)-j9九游会登录

接口说明

  • 管理员被授权管理某企业后,在买家中心登录,对管理的企业执行新建、编辑、删除部门操作时,云商店调用该接口,请求商家同步该企业的组织增量变更;商家接口需要执行增量组织信息同步,保存信息,并返回通知云商店。
  • 商家的服务器在处理接口请求时,需要做好幂等性处理。

    对于同一个实例,相同的租户,相同的orgcode,要支持多次请求新增,或者删除,多次新增不应产生新的数据,且需要返回成功,如果是删除,多次删除也需要返回成功,不能因已删除返回失败,删除时不需要校验(新购商品)接口产生的实例是否存在。

请求方法:post

接口url:生产地址 固定子路径,其中固定子路径为/produceapi/singleorgsync;

接口示例:生产地址为https://example.isv.com,则接口url为https://example.isv.com/produceapi/singleorgsync

headers请参数

参数

必选

参数类型

描述

authtoken

m

string(255)

签名信息,请参考auth token取值说明

body请求参数

参数

必选

参数类型

描述

instanceid

m

string(64)

说明:

卖家申请应用凭证的时候传空,买家必传。

tenantid

m

string(64)

租户id,与租户的同步信息保持一致

orgcode

m

string(64)

部门代码 租户自定义,租户内唯一

orgname

m

vachar(128)

部门名称 所在层级唯一,允许租户更新名称

parentcode

o

string(64)

上级部门的orgcode,如果是顶层部门,这个值为空,其他场景不能为空,允许租户更新当前部门归属的上层部门

flag

m

integer(2)

0-删除 1-新增,2-修改

testflag

m

integer(2)

0-生产正式数据 1-调测数据

timestamp

m

string

默认时区东8区,时间戳,时间格式:20220420114117642

响应参数

参数

必选

参数类型

描述

resultcode

m

string(6)

响应码,具体请参见调用结果码说明

resultmsg

o

string(255)

响应信息

示例:

post https://example.isv.com/produceapi/singleorgsync
connection: keep-alive
content-type: application/json
authtoken: "stbnylu**************2ubt271qdr6wdavltlrb”
host: example.isv.com
user-agent: apache-httpclient/4.5.3 (java/1.8.0_191)
{
 "instanceid": "hua********23456",
 "instanceid": "hua********23456", 
 "tenantid": "68cbc********0d92f36422fa0e", 
 "orgcode": "10000", 
 "orgname": "开发部", 
 "parentcode": "", 
 "flag": 1, 
 "testflag": 0, 
 "timestamp": "20220413093539534" ,
}
http/1.1 200 ok
body-sign: sign_type="hmac-sha256", signature= "xxxxxxxxxx"  
content-type: application/json
{
" resultcode": "000000",
" resultmsg": "success"
}

http body签名:

body-sign: sign_type="hmac-sha256", signature= "xxxxxxxxxxxxx" ,详情参考《http body签名》

相关文档

网站地图