Render HTML candidate cards
curl --request POST \
--url https://api.instaview.sk/sourcing/render-html \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"profileIds": [
"profile_abc123",
"profile_def456"
],
"theme": "dark"
}
'import requests
url = "https://api.instaview.sk/sourcing/render-html"
payload = {
"profileIds": ["profile_abc123", "profile_def456"],
"theme": "dark"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({profileIds: ['profile_abc123', 'profile_def456'], theme: 'dark'})
};
fetch('https://api.instaview.sk/sourcing/render-html', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.instaview.sk/sourcing/render-html",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'profileIds' => [
'profile_abc123',
'profile_def456'
],
'theme' => 'dark'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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.instaview.sk/sourcing/render-html"
payload := strings.NewReader("{\n \"profileIds\": [\n \"profile_abc123\",\n \"profile_def456\"\n ],\n \"theme\": \"dark\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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.post("https://api.instaview.sk/sourcing/render-html")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"profileIds\": [\n \"profile_abc123\",\n \"profile_def456\"\n ],\n \"theme\": \"dark\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.instaview.sk/sourcing/render-html")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"profileIds\": [\n \"profile_abc123\",\n \"profile_def456\"\n ],\n \"theme\": \"dark\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"renderedCount": 2,
"data": [
{
"profileId": "a1b2c3d4e5f6",
"success": true,
"name": "Jane Smith",
"htmlContent": "<div style=\"...\">…</div>",
"errorCode": "PROFILE_NOT_FOUND"
}
]
}{
"statusCode": 400,
"message": "Validation failed",
"error": "Bad Request"
}{
"statusCode": 400,
"message": "Validation failed",
"error": "Bad Request"
}{
"statusCode": 400,
"message": "Validation failed",
"error": "Bad Request"
}{
"statusCode": 400,
"message": "Validation failed",
"error": "Bad Request"
}Sourcing
Render HTML Candidate Cards
Generates self-contained HTML/CSS candidate profile cards for up to 10 profile IDs. Synchronous — returns immediately with rendered card snippets. Supports ‘dark’ (default) and ‘light’ themes.
POST
/
sourcing
/
render-html
Render HTML candidate cards
curl --request POST \
--url https://api.instaview.sk/sourcing/render-html \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"profileIds": [
"profile_abc123",
"profile_def456"
],
"theme": "dark"
}
'import requests
url = "https://api.instaview.sk/sourcing/render-html"
payload = {
"profileIds": ["profile_abc123", "profile_def456"],
"theme": "dark"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({profileIds: ['profile_abc123', 'profile_def456'], theme: 'dark'})
};
fetch('https://api.instaview.sk/sourcing/render-html', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.instaview.sk/sourcing/render-html",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'profileIds' => [
'profile_abc123',
'profile_def456'
],
'theme' => 'dark'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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.instaview.sk/sourcing/render-html"
payload := strings.NewReader("{\n \"profileIds\": [\n \"profile_abc123\",\n \"profile_def456\"\n ],\n \"theme\": \"dark\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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.post("https://api.instaview.sk/sourcing/render-html")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"profileIds\": [\n \"profile_abc123\",\n \"profile_def456\"\n ],\n \"theme\": \"dark\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.instaview.sk/sourcing/render-html")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"profileIds\": [\n \"profile_abc123\",\n \"profile_def456\"\n ],\n \"theme\": \"dark\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"renderedCount": 2,
"data": [
{
"profileId": "a1b2c3d4e5f6",
"success": true,
"name": "Jane Smith",
"htmlContent": "<div style=\"...\">…</div>",
"errorCode": "PROFILE_NOT_FOUND"
}
]
}{
"statusCode": 400,
"message": "Validation failed",
"error": "Bad Request"
}{
"statusCode": 400,
"message": "Validation failed",
"error": "Bad Request"
}{
"statusCode": 400,
"message": "Validation failed",
"error": "Bad Request"
}{
"statusCode": 400,
"message": "Validation failed",
"error": "Bad Request"
}Generates self-contained, responsive HTML/CSS profile cards for up to 10 candidate profile IDs. This endpoint is synchronous — it returns immediately with rendered card snippets.
Overview
The rendered HTML cards are ready to embed directly into your ATS, internal recruitment dashboards, or email templates. Each card includes:- Candidate name (gradient-styled heading)
- Current role and company
- AI match score badge
- InstaView rationale summary
- Primary skills list
- LinkedIn profile link button
Themes
| Theme | Description |
|---|---|
"dark" | Dark slate background (#0f172a) — default |
"light" | Clean white background (#ffffff) |
Examples
Request
{
"profileIds": ["prof_a9238f82-a723", "prof_e8321c12-b912"],
"theme": "dark"
}
Response (200 OK)
{
"success": true,
"renderedCount": 2,
"data": [
{
"profileId": "prof_a9238f82-a723",
"success": true,
"name": "Jane Doe",
"htmlContent": "<div style=\"font-family: 'Inter', system-ui, ...\">\u2026</div>"
},
{
"profileId": "prof_e8321c12-b912",
"success": true,
"name": "Alex Smith",
"htmlContent": "<div style=\"font-family: 'Inter', system-ui, ...\">\u2026</div>"
}
]
}
Partial Failure (200 OK)
If a profile ID is not found for the authenticating company, it is returned withsuccess: false — the rest of the batch is still rendered:
{
"success": true,
"renderedCount": 1,
"data": [
{
"profileId": "prof_a9238f82-a723",
"success": true,
"name": "Jane Doe",
"htmlContent": "<div>\u2026</div>"
},
{
"profileId": "prof_unknown-xyz",
"success": false,
"errorCode": "PROFILE_NOT_FOUND"
}
]
}
Embedding the Card
ThehtmlContent string can be inserted directly into your HTML via innerHTML or server-side template rendering:
const res = await fetch('https://api.instaview.sk/sourcing/render-html', {
method: 'POST',
headers: {
'Authorization': `Bearer ${process.env.INSTAVIEW_API_KEY}`,
'Content-Type': 'application/json',
},
body: JSON.stringify({ profileIds: ['prof_a9238f82-a723'], theme: 'light' }),
});
const { data } = await res.json();
document.getElementById('candidate-container').innerHTML = data
.filter(d => d.success)
.map(d => d.htmlContent)
.join('');
Always sanitize third-party content before inserting it into the DOM if your CSP or security policy restricts inline styles. The HTML is self-contained and uses only inline CSS — no scripts are included.
Authorizations
API key for authentication using Bearer scheme
Body
application/json
Array of profile IDs for which to render HTML cards. Maximum 10 per request.
Required array length:
1 - 10 elementsExample:
["profile_abc123", "profile_def456"]
Visual theme for the rendered HTML cards (default: 'dark').
Available options:
dark, light Example:
"dark"