pcall PUT "/api/v1/partner/mandates/JM_261009101612456H3N8W2L5C9V1Z4/enrichment-questions" '{
"enrichment_questions": [
{
"key": "has_licence",
"type": "yes_no",
"text": "Do you hold a valid forklift licence?",
"knockout": "no",
"required": true
},
{
"key": "why_this_job",
"type": "voice",
"text": "Tell us in your own words why you want this job.",
"required": false
}
]
}'const res = await call("PUT", "/api/v1/partner/mandates/JM_261009101612456H3N8W2L5C9V1Z4/enrichment-questions", {
"enrichment_questions": [
{
"key": "has_licence",
"type": "yes_no",
"text": "Do you hold a valid forklift licence?",
"knockout": "no",
"required": true
},
{
"key": "why_this_job",
"type": "voice",
"text": "Tell us in your own words why you want this job.",
"required": false
}
]
});
const { data } = await res.json();res = call("PUT", "/api/v1/partner/mandates/JM_261009101612456H3N8W2L5C9V1Z4/enrichment-questions", {
"enrichment_questions": [
{
"key": "has_licence",
"type": "yes_no",
"text": "Do you hold a valid forklift licence?",
"knockout": "no",
"required": True
},
{
"key": "why_this_job",
"type": "voice",
"text": "Tell us in your own words why you want this job.",
"required": False
}
]
})
data = res.json()["data"]<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api-bc.userecord.io/api/v1/partner/mandates/{mandate_id}/enrichment-questions",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'enrichment_questions' => [
[
'key' => 'has_licence',
'type' => 'yes_no',
'text' => 'Do you hold a valid forklift licence?',
'knockout' => 'no',
'required' => true
],
[
'key' => 'why_this_job',
'type' => 'voice',
'text' => 'Tell us in your own words why you want this job.',
'required' => false
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>",
"x-secret-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api-bc.userecord.io/api/v1/partner/mandates/{mandate_id}/enrichment-questions"
payload := strings.NewReader("{\n \"enrichment_questions\": [\n {\n \"key\": \"has_licence\",\n \"type\": \"yes_no\",\n \"text\": \"Do you hold a valid forklift licence?\",\n \"knockout\": \"no\",\n \"required\": true\n },\n {\n \"key\": \"why_this_job\",\n \"type\": \"voice\",\n \"text\": \"Tell us in your own words why you want this job.\",\n \"required\": false\n }\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("x-api-key", "<api-key>")
req.Header.Add("x-secret-key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api-bc.userecord.io/api/v1/partner/mandates/{mandate_id}/enrichment-questions")
.header("x-api-key", "<api-key>")
.header("x-secret-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"enrichment_questions\": [\n {\n \"key\": \"has_licence\",\n \"type\": \"yes_no\",\n \"text\": \"Do you hold a valid forklift licence?\",\n \"knockout\": \"no\",\n \"required\": true\n },\n {\n \"key\": \"why_this_job\",\n \"type\": \"voice\",\n \"text\": \"Tell us in your own words why you want this job.\",\n \"required\": false\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-bc.userecord.io/api/v1/partner/mandates/{mandate_id}/enrichment-questions")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["x-api-key"] = '<api-key>'
request["x-secret-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"enrichment_questions\": [\n {\n \"key\": \"has_licence\",\n \"type\": \"yes_no\",\n \"text\": \"Do you hold a valid forklift licence?\",\n \"knockout\": \"no\",\n \"required\": true\n },\n {\n \"key\": \"why_this_job\",\n \"type\": \"voice\",\n \"text\": \"Tell us in your own words why you want this job.\",\n \"required\": false\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"mandate_id": "JM_261009101612456H3N8W2L5C9V1Z4",
"job_id": "job-10452",
"status": "preparing",
"flow_version": 2,
"methods": [
"data_enrichment",
"skill_verification",
"interest_collection"
],
"changed": true,
"warnings": []
}
}{
"success": false,
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}{
"success": false,
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}{
"success": false,
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}{
"success": false,
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}{
"success": false,
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}Replace screening questions
Replace only the screening questions (1 to 5, or 10 with enrichment only).
Scope: mandates:write · Idempotency-Key: optional
pcall PUT "/api/v1/partner/mandates/JM_261009101612456H3N8W2L5C9V1Z4/enrichment-questions" '{
"enrichment_questions": [
{
"key": "has_licence",
"type": "yes_no",
"text": "Do you hold a valid forklift licence?",
"knockout": "no",
"required": true
},
{
"key": "why_this_job",
"type": "voice",
"text": "Tell us in your own words why you want this job.",
"required": false
}
]
}'const res = await call("PUT", "/api/v1/partner/mandates/JM_261009101612456H3N8W2L5C9V1Z4/enrichment-questions", {
"enrichment_questions": [
{
"key": "has_licence",
"type": "yes_no",
"text": "Do you hold a valid forklift licence?",
"knockout": "no",
"required": true
},
{
"key": "why_this_job",
"type": "voice",
"text": "Tell us in your own words why you want this job.",
"required": false
}
]
});
const { data } = await res.json();res = call("PUT", "/api/v1/partner/mandates/JM_261009101612456H3N8W2L5C9V1Z4/enrichment-questions", {
"enrichment_questions": [
{
"key": "has_licence",
"type": "yes_no",
"text": "Do you hold a valid forklift licence?",
"knockout": "no",
"required": True
},
{
"key": "why_this_job",
"type": "voice",
"text": "Tell us in your own words why you want this job.",
"required": False
}
]
})
data = res.json()["data"]<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api-bc.userecord.io/api/v1/partner/mandates/{mandate_id}/enrichment-questions",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'enrichment_questions' => [
[
'key' => 'has_licence',
'type' => 'yes_no',
'text' => 'Do you hold a valid forklift licence?',
'knockout' => 'no',
'required' => true
],
[
'key' => 'why_this_job',
'type' => 'voice',
'text' => 'Tell us in your own words why you want this job.',
'required' => false
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>",
"x-secret-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api-bc.userecord.io/api/v1/partner/mandates/{mandate_id}/enrichment-questions"
payload := strings.NewReader("{\n \"enrichment_questions\": [\n {\n \"key\": \"has_licence\",\n \"type\": \"yes_no\",\n \"text\": \"Do you hold a valid forklift licence?\",\n \"knockout\": \"no\",\n \"required\": true\n },\n {\n \"key\": \"why_this_job\",\n \"type\": \"voice\",\n \"text\": \"Tell us in your own words why you want this job.\",\n \"required\": false\n }\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("x-api-key", "<api-key>")
req.Header.Add("x-secret-key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api-bc.userecord.io/api/v1/partner/mandates/{mandate_id}/enrichment-questions")
.header("x-api-key", "<api-key>")
.header("x-secret-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"enrichment_questions\": [\n {\n \"key\": \"has_licence\",\n \"type\": \"yes_no\",\n \"text\": \"Do you hold a valid forklift licence?\",\n \"knockout\": \"no\",\n \"required\": true\n },\n {\n \"key\": \"why_this_job\",\n \"type\": \"voice\",\n \"text\": \"Tell us in your own words why you want this job.\",\n \"required\": false\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-bc.userecord.io/api/v1/partner/mandates/{mandate_id}/enrichment-questions")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["x-api-key"] = '<api-key>'
request["x-secret-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"enrichment_questions\": [\n {\n \"key\": \"has_licence\",\n \"type\": \"yes_no\",\n \"text\": \"Do you hold a valid forklift licence?\",\n \"knockout\": \"no\",\n \"required\": true\n },\n {\n \"key\": \"why_this_job\",\n \"type\": \"voice\",\n \"text\": \"Tell us in your own words why you want this job.\",\n \"required\": false\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"mandate_id": "JM_261009101612456H3N8W2L5C9V1Z4",
"job_id": "job-10452",
"status": "preparing",
"flow_version": 2,
"methods": [
"data_enrichment",
"skill_verification",
"interest_collection"
],
"changed": true,
"warnings": []
}
}{
"success": false,
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}{
"success": false,
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}{
"success": false,
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}{
"success": false,
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}{
"success": false,
"error": {
"code": "VALIDATION_FAILED",
"message": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>"
}
],
"request_id": "<string>"
}
}Authorizations
Your key id, VFN_TEST_… or VFN_LIVE_…. Sent on every request.
Your secret, VFN_SK_…. Not a real header, and never sent to the API. It is only a form field for Try it, which uses it to sign your request in your browser. In your own code you sign each request with the secret and send x-api-key, x-timestamp and x-signature (see Authentication).
Headers
Optional. A retry with the same key returns the first answer (kept 24 h). Leave empty in Try it: a new one is made for every call.
255Path Parameters
Record's mandate id (JM_...): the mandate_id returned when you create the mandate
^JM_[A-Z0-9]{10,40}$Body
0 to 5 enrichment questions (up to 10 when data_enrichment is the only method)
50Show child attributes
Show child attributes

