Register a facility
curl --request POST \
--url https://sandbox.rcintell.com/v1/facilities \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"ccn": "170001",
"city": "Topeka",
"facility_type": "short_term_acute",
"is_rural": false,
"name": "Acme General Hospital",
"npi": "1234567890",
"pos_code": "22",
"state": "KS",
"zip_code": "66601"
}
'import requests
url = "https://sandbox.rcintell.com/v1/facilities"
payload = {
"ccn": "170001",
"city": "Topeka",
"facility_type": "short_term_acute",
"is_rural": False,
"name": "Acme General Hospital",
"npi": "1234567890",
"pos_code": "22",
"state": "KS",
"zip_code": "66601"
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
ccn: '170001',
city: 'Topeka',
facility_type: 'short_term_acute',
is_rural: false,
name: 'Acme General Hospital',
npi: '1234567890',
pos_code: '22',
state: 'KS',
zip_code: '66601'
})
};
fetch('https://sandbox.rcintell.com/v1/facilities', 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://sandbox.rcintell.com/v1/facilities",
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([
'ccn' => '170001',
'city' => 'Topeka',
'facility_type' => 'short_term_acute',
'is_rural' => false,
'name' => 'Acme General Hospital',
'npi' => '1234567890',
'pos_code' => '22',
'state' => 'KS',
'zip_code' => '66601'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-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://sandbox.rcintell.com/v1/facilities"
payload := strings.NewReader("{\n \"ccn\": \"170001\",\n \"city\": \"Topeka\",\n \"facility_type\": \"short_term_acute\",\n \"is_rural\": false,\n \"name\": \"Acme General Hospital\",\n \"npi\": \"1234567890\",\n \"pos_code\": \"22\",\n \"state\": \"KS\",\n \"zip_code\": \"66601\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-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.post("https://sandbox.rcintell.com/v1/facilities")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"ccn\": \"170001\",\n \"city\": \"Topeka\",\n \"facility_type\": \"short_term_acute\",\n \"is_rural\": false,\n \"name\": \"Acme General Hospital\",\n \"npi\": \"1234567890\",\n \"pos_code\": \"22\",\n \"state\": \"KS\",\n \"zip_code\": \"66601\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.rcintell.com/v1/facilities")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"ccn\": \"170001\",\n \"city\": \"Topeka\",\n \"facility_type\": \"short_term_acute\",\n \"is_rural\": false,\n \"name\": \"Acme General Hospital\",\n \"npi\": \"1234567890\",\n \"pos_code\": \"22\",\n \"state\": \"KS\",\n \"zip_code\": \"66601\"\n}"
response = http.request(request)
puts response.read_body{
"ccn": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"is_active": true,
"name": "<string>",
"address_line1": "<string>",
"cbsa": "<string>",
"cbsa_detail": {
"cbsa_code": "<string>",
"cbsa_name": "<string>",
"county_fips": "<string>",
"county_name": "<string>",
"is_metropolitan": true
},
"ccn_facility_type": "<string>",
"certifications": [
"<string>"
],
"city": "<string>",
"county": "<string>",
"facility_type": "<string>",
"gpci": {
"locality_name": "<string>",
"locality_number": "<string>",
"mp_gpci": 123,
"pe_gpci": 123,
"pw_gpci": 123,
"year": 123
},
"is_rural": true,
"mac": {
"jurisdiction": "<string>",
"mac_id": "<string>",
"mac_name": "<string>",
"mac_number": "<string>",
"phone": "<string>",
"website": "<string>"
},
"npi": "<string>",
"pos_code": "<string>",
"resolved_layers": {},
"state": "<string>",
"zip_code": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"ctx": {},
"input": "<unknown>"
}
]
}facilities
Register a facility
Register a new healthcare facility by CCN.
The CCN (Medicare Provider Number) is parsed to determine the facility’s
state and facility type. facility_type defaults to the CCN’s CMS range
(e.g. xx1800-xx1989 → fqhc); a caller-supplied value is normalized and
must agree with the CCN. Each CCN must be unique within a tenant.
POST
/
v1
/
facilities
Register a facility
curl --request POST \
--url https://sandbox.rcintell.com/v1/facilities \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"ccn": "170001",
"city": "Topeka",
"facility_type": "short_term_acute",
"is_rural": false,
"name": "Acme General Hospital",
"npi": "1234567890",
"pos_code": "22",
"state": "KS",
"zip_code": "66601"
}
'import requests
url = "https://sandbox.rcintell.com/v1/facilities"
payload = {
"ccn": "170001",
"city": "Topeka",
"facility_type": "short_term_acute",
"is_rural": False,
"name": "Acme General Hospital",
"npi": "1234567890",
"pos_code": "22",
"state": "KS",
"zip_code": "66601"
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
ccn: '170001',
city: 'Topeka',
facility_type: 'short_term_acute',
is_rural: false,
name: 'Acme General Hospital',
npi: '1234567890',
pos_code: '22',
state: 'KS',
zip_code: '66601'
})
};
fetch('https://sandbox.rcintell.com/v1/facilities', 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://sandbox.rcintell.com/v1/facilities",
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([
'ccn' => '170001',
'city' => 'Topeka',
'facility_type' => 'short_term_acute',
'is_rural' => false,
'name' => 'Acme General Hospital',
'npi' => '1234567890',
'pos_code' => '22',
'state' => 'KS',
'zip_code' => '66601'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-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://sandbox.rcintell.com/v1/facilities"
payload := strings.NewReader("{\n \"ccn\": \"170001\",\n \"city\": \"Topeka\",\n \"facility_type\": \"short_term_acute\",\n \"is_rural\": false,\n \"name\": \"Acme General Hospital\",\n \"npi\": \"1234567890\",\n \"pos_code\": \"22\",\n \"state\": \"KS\",\n \"zip_code\": \"66601\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-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.post("https://sandbox.rcintell.com/v1/facilities")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"ccn\": \"170001\",\n \"city\": \"Topeka\",\n \"facility_type\": \"short_term_acute\",\n \"is_rural\": false,\n \"name\": \"Acme General Hospital\",\n \"npi\": \"1234567890\",\n \"pos_code\": \"22\",\n \"state\": \"KS\",\n \"zip_code\": \"66601\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.rcintell.com/v1/facilities")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"ccn\": \"170001\",\n \"city\": \"Topeka\",\n \"facility_type\": \"short_term_acute\",\n \"is_rural\": false,\n \"name\": \"Acme General Hospital\",\n \"npi\": \"1234567890\",\n \"pos_code\": \"22\",\n \"state\": \"KS\",\n \"zip_code\": \"66601\"\n}"
response = http.request(request)
puts response.read_body{
"ccn": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"is_active": true,
"name": "<string>",
"address_line1": "<string>",
"cbsa": "<string>",
"cbsa_detail": {
"cbsa_code": "<string>",
"cbsa_name": "<string>",
"county_fips": "<string>",
"county_name": "<string>",
"is_metropolitan": true
},
"ccn_facility_type": "<string>",
"certifications": [
"<string>"
],
"city": "<string>",
"county": "<string>",
"facility_type": "<string>",
"gpci": {
"locality_name": "<string>",
"locality_number": "<string>",
"mp_gpci": 123,
"pe_gpci": 123,
"pw_gpci": 123,
"year": 123
},
"is_rural": true,
"mac": {
"jurisdiction": "<string>",
"mac_id": "<string>",
"mac_name": "<string>",
"mac_number": "<string>",
"phone": "<string>",
"website": "<string>"
},
"npi": "<string>",
"pos_code": "<string>",
"resolved_layers": {},
"state": "<string>",
"zip_code": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"ctx": {},
"input": "<unknown>"
}
]
}Body
application/json
Register a new healthcare facility.
Facility type key (fqhc, rhc, short_term_acute, cah, ltch, irf, ipf, snf, hha, asc, outpatient_hospital, ...). Omit to derive it from the CCN's CMS number range. A supplied value is normalized and must agree with the CCN; hospital CCNs may also be registered as outpatient_hospital or asc.
Maximum string length:
64Response
Created facility profile
Facility profile with resolved knowledge layers.