请求样例
$ curl --request POST \
--url https://api.mokahr.com/api-platform/v1/open-platform/survey/balance \
--header 'Authorization: Bearer 6efe04cbc4b00ed85e2d8e9d3e8e622de435e55a' \
--header 'Content-Type: application/json' \
--data '{"discount": 0.4,"balance": "100","freeCount": 5, "appId": "fabd076f-1a0f-4fa8-8a5c-306d264e3df1"}'| 字段 | 必填 | 类型 | 描述 |
|---|---|---|---|
| discount | 否 | Number | 折扣(0-10) 不传或超出范围均当无折扣计算 |
| balance | 是 | Number | 账户余额 |
| freeCount | 否 | Number | 不计余额剩余次数 |
| appId | 是 | String | 绑定成功后第一次获取accessToken时moka返回 |
请求样例
$ curl --request POST \
--url https://api.mokahr.com/api-platform/v1/open-platform/survey/custom-fields \
--header 'Authorization: Bearer 6efe04cbc4b00ed85e2d8e9d3e8e622de435e55a' \
--header 'Content-Type: application/json' \
--data '{"customFields": [{"name": "company","description": "公司"},{"name": "abc","description": "Moka页面显示的名字"}]}'| 字段 | 必填 | 类型 | 描述 |
|---|---|---|---|
| customFields | 是 | Array | 自定义字段数组 |
| customFields[].type | 是 | integer | 自定义字段类型: 0:单行文本,1:多行文本,2:单选题,3:多选题,4:候选人公司,5:候选人学校 |
| customFields[].options | 否 | array | 自定义字段选择项,选填,当type为2或3的时候,添加JSON型数组, sample: [{ "id": 1, "name": "A"},{"id":2,"name":"B"}]id表示选择组件的选项ID name表示选择组件的选项 名称,发起背调时 单选时 传递的参数值是id,多选时 传递的参数值是以逗号分隔的多个id |
| customFields[].name | 是 | String | 传给接口的字段key |
| customFields[].description | 是 | String | Moka页面显示的名字 |
请求样例
$ curl --location --request POST 'https://api.mokahr.com/api-platform/v1/open-platform/survey/menus' \
--header 'Authorization: Bearer 7**********************79' \
--header 'Content-Type: application/json' \
--data-raw '{
"menuList": [
{
"price": 280,
"name": "社招B套餐",
"menuId": "D7***************439A",
"description": "社招B套餐"
},
{
"price": 150,
"name": "学生套餐",
"menuId": "BCA8****************C9EA439A",
"description": "学生套餐"
}
],
"appId": "1a7c7b6d-6***************5acc14f0"
}'| 字段 | 必填 | 类型 | 描述 |
|---|---|---|---|
| menuList | 是 | Array | 套餐列表 |
| menuList[].menuId | 是 | String | 套餐ID |
| menuList[].name | 是 | String | 套餐名称 |
| menuList[].description | 是 | String | 套餐描述 |
| menuList[].price | 是 | Number | 套餐价格 |
| appId | 是 | String | 绑定成功后第一次获取accessToken时moka返回 |
| menuList[].customFields | 否 | array | 套餐自定义字段(参照自定义字段接口) |
| menuList[].customFields[].type | 是 | number | 自定义字段类型: 0:单行文本,1:多行文本,2:单选题,3:多选题,4:候选人公司,5:候选人学校 |
| menuList[].customFields[].name | 是 | string | 自定义字段描述 |
| menuList[].customFields[].description | 是 | string | 自定义字段描述 |
| menuList[].customFields[].options | 否 | array | 自定义字段选择项,选填,当type为2或3的时候,添加JSON型数组, sample: [{ "id": "1", "name": "A"},{"id":"2","name":"B"}]id表示选择组件的选项ID name表示选择组件的选项名称,发起背调时 单选时 传递的参数值是id,多选时 传递的参数值是以逗号分隔的多个id |
| menuList[].customFields[].options[].id | 是 | string | 选择组件的选项ID |
| menuList[].customFields[].options[].name | 是 | string | 选择组件的选项名称 |
请求样例
$ curl --request POST \
--url https://api.mokahr.com/api-platform/v1/open-platform/survey/menu \
--header 'Authorization: Bearer 6efe04cbc4b00ed85e2d8e9d3e8e622de435e55a' \
--header 'Content-Type: application/json' \
--data '{"menuId": "1112","name": "test","price": 0,"appId": "a5fb37d3-f2d1-4121-b59f-b1ca385096b0"}'| 字段 | 必填 | 类型 | 描述 |
|---|---|---|---|
| menuId | 是 | String | 套餐ID |
| name | 是 | String | 套餐名称 |
| description | 否 | String | 套餐描述 |
| price | 是 | Number | 试卷消耗 |
| appId | 是 | String | 绑定成功后第一次获取accessToken时moka返回 |
| customFields | 否 | array | 套餐自定义字段(参照自定义字段接口) |
| customFields[].type | 是 | number | 自 定义字段类型: 0:单行文本,1:多行文本,2:单选题,3:多选题,4:候选人公司,5:候选人学校 |
| customFields[].name | 是 | string | 自定义字段描述 |
| customFields[].description | 是 | string | 自定义字段描述 |
| customFields[].options | 否 | array | 自定义字段选择项,选填,当type为2或3的时候,添加JSON型数组, sample: [{ "id": "1", "name": "A"},{"id":"2","name":"B"}]id表示选择组件的选项ID name表示选择组件的选项名称,发起背调时 单选时 传递的参数值是id,多选时 传递的参数值是以逗号分隔的多个id |
| customFields[].options[].id | 是 | string | 选择组件的选项ID |
| customFields[].options[].name | 是 | string | 选择组件的选项名称 |
请求样例
$ curl --request DELETE \
--url https://api.mokahr.com/api-platform/v1/open-platform/survey/menu \
--header 'Authorization: Bearer 6efe04cbc4b00ed85e2d8e9d3e8e622de435e55a' \
--header 'Content-Type: application/json' \
--data '{"menuId": "1","appId": "a5fb37d3-f2d1-4121-b59f-b1ca385096b0"}'| 字段 | 必填 | 类型 | 描述 |
|---|---|---|---|
| menuId | 是 | String | 套餐Id |
| appId | 是 | String | 绑定成功后第一次获取accessToken时moka返回 |
请求样例
$ curl --request POST \
--url http://api.mokahr.com/v1/open-platform/survey/result \
--header 'Authorization: Bearer 6efe04cbc4b00ed85e2d8e9d3e8e622de435e55a' \
--header 'Content-Type: application/json' \
--data '{
"result": "xxx",
"surveyId": "1",
"attachment": {
"name": "123.html",
"url": "http://www.example.com/index.html"
}
}'| 字段 | 必填 | 类型 | 描述 |
|---|---|---|---|
| result | 否 | String | 结果(长度限制20个字符,为空时默认为完成) |
| attachment | 是 | Object | 附件 |
| attachment.name | 是 | String | 附件名称(需要带上后缀名) |
| attachment.url | 是 | String | 附件URL,不需要url编码 |
| surveyId | 是 | Number | 创建背调的时候moka传给第三方供应商的surveyId |
| 字段 | 必填 | 类型 | 描述 |
|---|---|---|---|
| success | 是 | boolean | 返回结果是否成功 |
请求样例
$ curl --request POST \
--url http://api.mokahr.com/v1/open-platform/survey/stage \
--header 'Authorization: Bearer 6efe04cbc4b00ed85e2d8e9d3e8e622de435e55a' \
--header 'Content-Type: application/json' \
--data '{"stageId": "1", "name": "发送链接给候选人", "stageAt": "2019-10-10 01:01:01", "surveyId": 3}'返回样例
{
success: true
}| 字段 | 必填 | 类型 | 描述 |
|---|---|---|---|
| stageId | 否 | String | 背调阶段ID |
| name | 是 | String | 背调阶段名称 |
| stageAt | 是 | datetime | 背调阶段的时间 |
| surveyId | 是 | Number | 创建背调的时候moka传给第三方供应商的surveyId |
| 字段 | 必填 | 类型 | 描述 |
|---|---|---|---|
| success | 是 | boolean | 返回结果是否成功 |
请求样例
$ curl --request POST \
--url https://api.mokahr.com/api-platform/v1/open-platform/survey/getCandidateInfo \
--header 'Authorization: Bearer 6efe04cbc4b00ed85e2d8e9d3e8e622de435e55a' \
--header 'Content-Type: application/json' \
--data '{"surveyId": 18}'返回样例
{
code: 0,
msg: "success",
data: {
resumeUrl: "https://proxy-oss-test.mokahr.com/a5684434-86d8-44db-bd69-76ebe942e12e.pdf?OSSAccessKeyId=LTAIoEXIQWCGUAZO&Expires=1599462096&Signature=IrNuG2qaCJXp8FM7JyvPe04N5%2B0%3D"
}
}| 字段 | 必填 | 类型 | 描述 |
|---|---|---|---|
| surveyId | 是 | Number | 创建背调的时候moka传给第三方供应商的surveyId |