Create collaborator
curl --request POST \
--url https://api.capitalcheckin.app/v1/collaborators \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"email": "jsmith@example.com",
"position": "<string>",
"department": "<string>",
"phone": "<string>",
"hire_date": "2023-12-25",
"salary": 123,
"manager_id": "<string>",
"work_schedule": "<string>",
"location": "<string>",
"emergency_contact": {
"name": "<string>",
"phone": "<string>",
"relationship": "<string>"
}
}
'import requests
url = "https://api.capitalcheckin.app/v1/collaborators"
payload = {
"name": "<string>",
"email": "jsmith@example.com",
"position": "<string>",
"department": "<string>",
"phone": "<string>",
"hire_date": "2023-12-25",
"salary": 123,
"manager_id": "<string>",
"work_schedule": "<string>",
"location": "<string>",
"emergency_contact": {
"name": "<string>",
"phone": "<string>",
"relationship": "<string>"
}
}
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({
name: '<string>',
email: 'jsmith@example.com',
position: '<string>',
department: '<string>',
phone: '<string>',
hire_date: '2023-12-25',
salary: 123,
manager_id: '<string>',
work_schedule: '<string>',
location: '<string>',
emergency_contact: {name: '<string>', phone: '<string>', relationship: '<string>'}
})
};
fetch('https://api.capitalcheckin.app/v1/collaborators', 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.capitalcheckin.app/v1/collaborators",
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([
'name' => '<string>',
'email' => 'jsmith@example.com',
'position' => '<string>',
'department' => '<string>',
'phone' => '<string>',
'hire_date' => '2023-12-25',
'salary' => 123,
'manager_id' => '<string>',
'work_schedule' => '<string>',
'location' => '<string>',
'emergency_contact' => [
'name' => '<string>',
'phone' => '<string>',
'relationship' => '<string>'
]
]),
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.capitalcheckin.app/v1/collaborators"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"position\": \"<string>\",\n \"department\": \"<string>\",\n \"phone\": \"<string>\",\n \"hire_date\": \"2023-12-25\",\n \"salary\": 123,\n \"manager_id\": \"<string>\",\n \"work_schedule\": \"<string>\",\n \"location\": \"<string>\",\n \"emergency_contact\": {\n \"name\": \"<string>\",\n \"phone\": \"<string>\",\n \"relationship\": \"<string>\"\n }\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.capitalcheckin.app/v1/collaborators")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"position\": \"<string>\",\n \"department\": \"<string>\",\n \"phone\": \"<string>\",\n \"hire_date\": \"2023-12-25\",\n \"salary\": 123,\n \"manager_id\": \"<string>\",\n \"work_schedule\": \"<string>\",\n \"location\": \"<string>\",\n \"emergency_contact\": {\n \"name\": \"<string>\",\n \"phone\": \"<string>\",\n \"relationship\": \"<string>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.capitalcheckin.app/v1/collaborators")
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 \"name\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"position\": \"<string>\",\n \"department\": \"<string>\",\n \"phone\": \"<string>\",\n \"hire_date\": \"2023-12-25\",\n \"salary\": 123,\n \"manager_id\": \"<string>\",\n \"work_schedule\": \"<string>\",\n \"location\": \"<string>\",\n \"emergency_contact\": {\n \"name\": \"<string>\",\n \"phone\": \"<string>\",\n \"relationship\": \"<string>\"\n }\n}"
response = http.request(request)
puts response.read_body{
"id": "<string>",
"name": "<string>",
"email": "jsmith@example.com",
"phone": "<string>",
"position": "<string>",
"department": "<string>",
"hire_date": "2023-12-25",
"salary": 123,
"manager_id": "<string>",
"work_schedule": "<string>",
"location": "<string>",
"avatar_url": "<string>",
"emergency_contact": {
"name": "<string>",
"phone": "<string>",
"relationship": "<string>"
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}{
"error": "validation_error",
"message": "<string>",
"details": {}
}{
"error": "<string>",
"message": "<string>",
"details": {}
}Endpoints
Create collaborator
Create a new collaborator in the company
POST
/
v1
/
collaborators
Create collaborator
curl --request POST \
--url https://api.capitalcheckin.app/v1/collaborators \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"email": "jsmith@example.com",
"position": "<string>",
"department": "<string>",
"phone": "<string>",
"hire_date": "2023-12-25",
"salary": 123,
"manager_id": "<string>",
"work_schedule": "<string>",
"location": "<string>",
"emergency_contact": {
"name": "<string>",
"phone": "<string>",
"relationship": "<string>"
}
}
'import requests
url = "https://api.capitalcheckin.app/v1/collaborators"
payload = {
"name": "<string>",
"email": "jsmith@example.com",
"position": "<string>",
"department": "<string>",
"phone": "<string>",
"hire_date": "2023-12-25",
"salary": 123,
"manager_id": "<string>",
"work_schedule": "<string>",
"location": "<string>",
"emergency_contact": {
"name": "<string>",
"phone": "<string>",
"relationship": "<string>"
}
}
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({
name: '<string>',
email: 'jsmith@example.com',
position: '<string>',
department: '<string>',
phone: '<string>',
hire_date: '2023-12-25',
salary: 123,
manager_id: '<string>',
work_schedule: '<string>',
location: '<string>',
emergency_contact: {name: '<string>', phone: '<string>', relationship: '<string>'}
})
};
fetch('https://api.capitalcheckin.app/v1/collaborators', 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.capitalcheckin.app/v1/collaborators",
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([
'name' => '<string>',
'email' => 'jsmith@example.com',
'position' => '<string>',
'department' => '<string>',
'phone' => '<string>',
'hire_date' => '2023-12-25',
'salary' => 123,
'manager_id' => '<string>',
'work_schedule' => '<string>',
'location' => '<string>',
'emergency_contact' => [
'name' => '<string>',
'phone' => '<string>',
'relationship' => '<string>'
]
]),
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.capitalcheckin.app/v1/collaborators"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"position\": \"<string>\",\n \"department\": \"<string>\",\n \"phone\": \"<string>\",\n \"hire_date\": \"2023-12-25\",\n \"salary\": 123,\n \"manager_id\": \"<string>\",\n \"work_schedule\": \"<string>\",\n \"location\": \"<string>\",\n \"emergency_contact\": {\n \"name\": \"<string>\",\n \"phone\": \"<string>\",\n \"relationship\": \"<string>\"\n }\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.capitalcheckin.app/v1/collaborators")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"position\": \"<string>\",\n \"department\": \"<string>\",\n \"phone\": \"<string>\",\n \"hire_date\": \"2023-12-25\",\n \"salary\": 123,\n \"manager_id\": \"<string>\",\n \"work_schedule\": \"<string>\",\n \"location\": \"<string>\",\n \"emergency_contact\": {\n \"name\": \"<string>\",\n \"phone\": \"<string>\",\n \"relationship\": \"<string>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.capitalcheckin.app/v1/collaborators")
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 \"name\": \"<string>\",\n \"email\": \"jsmith@example.com\",\n \"position\": \"<string>\",\n \"department\": \"<string>\",\n \"phone\": \"<string>\",\n \"hire_date\": \"2023-12-25\",\n \"salary\": 123,\n \"manager_id\": \"<string>\",\n \"work_schedule\": \"<string>\",\n \"location\": \"<string>\",\n \"emergency_contact\": {\n \"name\": \"<string>\",\n \"phone\": \"<string>\",\n \"relationship\": \"<string>\"\n }\n}"
response = http.request(request)
puts response.read_body{
"id": "<string>",
"name": "<string>",
"email": "jsmith@example.com",
"phone": "<string>",
"position": "<string>",
"department": "<string>",
"hire_date": "2023-12-25",
"salary": 123,
"manager_id": "<string>",
"work_schedule": "<string>",
"location": "<string>",
"avatar_url": "<string>",
"emergency_contact": {
"name": "<string>",
"phone": "<string>",
"relationship": "<string>"
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}{
"error": "validation_error",
"message": "<string>",
"details": {}
}{
"error": "<string>",
"message": "<string>",
"details": {}
}Authorizations
OAuth2 access token for authentication
Body
application/json
Full name of the collaborator
Minimum string length:
2Email address (must be unique)
Job position or title
Department or team
Phone number
Date when collaborator was hired
Annual salary
ID of the manager
Work schedule (full-time, part-time, etc.)
Work location
Show child attributes
Show child attributes
Response
Collaborator created
Unique collaborator identifier
Full name of the collaborator
Email address
Phone number
Job position or title
Department or team
Collaborator status
Available options:
active, inactive, pending Collaborator role
Available options:
admin, manager, employee Date when collaborator was hired
Annual salary
ID of the manager
Work schedule (full-time, part-time, etc.)
Work location
Profile picture URL
Show child attributes
Show child attributes
Creation timestamp
Last update timestamp
⌘I