Skip to main content
POST
/
notes
/
create
Create Note
curl --request POST \
  --url https://api.decodahealth.com/notes/create \
  --header 'API-KEY: <api-key>' \
  --header 'Content-Type: application/json' \
  --header 'TENANT: <tenant>' \
  --data '
{
  "patientId": "<string>",
  "providerId": "<string>",
  "locationId": "<string>",
  "eventId": "<string>",
  "parentNoteId": "<string>",
  "content": "<string>",
  "aiGenerated": false,
  "noteTranscriptId": "<string>",
  "template": {
    "id": "<string>",
    "name": "<string>",
    "createdDate": "2023-11-07T05:31:56Z",
    "contentTemplate": "<string>",
    "attachments": []
  },
  "prompt": "<string>",
  "icd10Codes": [
    "<string>"
  ],
  "cptCodes": [
    "<string>"
  ]
}
'
import requests

url = "https://api.decodahealth.com/notes/create"

payload = {
"patientId": "<string>",
"providerId": "<string>",
"locationId": "<string>",
"eventId": "<string>",
"parentNoteId": "<string>",
"content": "<string>",
"aiGenerated": False,
"noteTranscriptId": "<string>",
"template": {
"id": "<string>",
"name": "<string>",
"createdDate": "2023-11-07T05:31:56Z",
"contentTemplate": "<string>",
"attachments": []
},
"prompt": "<string>",
"icd10Codes": ["<string>"],
"cptCodes": ["<string>"]
}
headers = {
"TENANT": "<tenant>",
"API-KEY": "<api-key>",
"Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'POST',
headers: {TENANT: '<tenant>', 'API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
patientId: '<string>',
providerId: '<string>',
locationId: '<string>',
eventId: '<string>',
parentNoteId: '<string>',
content: '<string>',
aiGenerated: false,
noteTranscriptId: '<string>',
template: {
id: '<string>',
name: '<string>',
createdDate: '2023-11-07T05:31:56Z',
contentTemplate: '<string>',
attachments: []
},
prompt: '<string>',
icd10Codes: ['<string>'],
cptCodes: ['<string>']
})
};

fetch('https://api.decodahealth.com/notes/create', 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.decodahealth.com/notes/create",
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([
'patientId' => '<string>',
'providerId' => '<string>',
'locationId' => '<string>',
'eventId' => '<string>',
'parentNoteId' => '<string>',
'content' => '<string>',
'aiGenerated' => false,
'noteTranscriptId' => '<string>',
'template' => [
'id' => '<string>',
'name' => '<string>',
'createdDate' => '2023-11-07T05:31:56Z',
'contentTemplate' => '<string>',
'attachments' => [

]
],
'prompt' => '<string>',
'icd10Codes' => [
'<string>'
],
'cptCodes' => [
'<string>'
]
]),
CURLOPT_HTTPHEADER => [
"API-KEY: <api-key>",
"Content-Type: application/json",
"TENANT: <tenant>"
],
]);

$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.decodahealth.com/notes/create"

payload := strings.NewReader("{\n \"patientId\": \"<string>\",\n \"providerId\": \"<string>\",\n \"locationId\": \"<string>\",\n \"eventId\": \"<string>\",\n \"parentNoteId\": \"<string>\",\n \"content\": \"<string>\",\n \"aiGenerated\": false,\n \"noteTranscriptId\": \"<string>\",\n \"template\": {\n \"id\": \"<string>\",\n \"name\": \"<string>\",\n \"createdDate\": \"2023-11-07T05:31:56Z\",\n \"contentTemplate\": \"<string>\",\n \"attachments\": []\n },\n \"prompt\": \"<string>\",\n \"icd10Codes\": [\n \"<string>\"\n ],\n \"cptCodes\": [\n \"<string>\"\n ]\n}")

req, _ := http.NewRequest("POST", url, payload)

req.Header.Add("TENANT", "<tenant>")
req.Header.Add("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://api.decodahealth.com/notes/create")
.header("TENANT", "<tenant>")
.header("API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"patientId\": \"<string>\",\n \"providerId\": \"<string>\",\n \"locationId\": \"<string>\",\n \"eventId\": \"<string>\",\n \"parentNoteId\": \"<string>\",\n \"content\": \"<string>\",\n \"aiGenerated\": false,\n \"noteTranscriptId\": \"<string>\",\n \"template\": {\n \"id\": \"<string>\",\n \"name\": \"<string>\",\n \"createdDate\": \"2023-11-07T05:31:56Z\",\n \"contentTemplate\": \"<string>\",\n \"attachments\": []\n },\n \"prompt\": \"<string>\",\n \"icd10Codes\": [\n \"<string>\"\n ],\n \"cptCodes\": [\n \"<string>\"\n ]\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.decodahealth.com/notes/create")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["TENANT"] = '<tenant>'
request["API-KEY"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"patientId\": \"<string>\",\n \"providerId\": \"<string>\",\n \"locationId\": \"<string>\",\n \"eventId\": \"<string>\",\n \"parentNoteId\": \"<string>\",\n \"content\": \"<string>\",\n \"aiGenerated\": false,\n \"noteTranscriptId\": \"<string>\",\n \"template\": {\n \"id\": \"<string>\",\n \"name\": \"<string>\",\n \"createdDate\": \"2023-11-07T05:31:56Z\",\n \"contentTemplate\": \"<string>\",\n \"attachments\": []\n },\n \"prompt\": \"<string>\",\n \"icd10Codes\": [\n \"<string>\"\n ],\n \"cptCodes\": [\n \"<string>\"\n ]\n}"

response = http.request(request)
puts response.read_body
{
  "id": "<string>",
  "parentNoteId": "<string>",
  "version": 123,
  "currentVersion": 123,
  "aiGenerated": true,
  "patient": {
    "id": "<string>",
    "createdDate": "2023-11-07T05:31:56Z",
    "firstName": "<string>",
    "lastName": "<string>",
    "phoneNumber": "<string>",
    "email": "<string>",
    "locationId": "<string>",
    "externalId": "<string>",
    "address": "<string>",
    "addressLineTwo": "<string>",
    "city": "<string>",
    "state": "<string>",
    "zipCode": "<string>",
    "country": "<string>",
    "addressValid": true,
    "meta": {},
    "isArchived": true,
    "primaryLocationId": "<string>",
    "gender": "<string>",
    "dateOfBirth": "2023-12-25",
    "patientMedications": [
      "<string>"
    ],
    "onSchedulingBlacklist": true,
    "surchargeDisabled": true,
    "tags": [
      {
        "id": "<string>",
        "name": "<string>",
        "isActive": true,
        "createdDate": "2023-11-07T05:31:56Z",
        "emoji": "<string>",
        "color": "<string>",
        "updatedDate": "2023-11-07T05:31:56Z"
      }
    ],
    "creditBalance": 123,
    "preferredProviderId": "<string>",
    "memberships": [
      {
        "id": "<string>",
        "membership": {
          "id": "<string>",
          "name": "<string>",
          "textColor": "<string>"
        },
        "startDate": "2023-11-07T05:31:56Z"
      }
    ],
    "goalWeight": 123,
    "measurements": [
      {
        "patientId": "<string>",
        "createdDate": "2023-11-07T05:31:56Z",
        "id": "<string>",
        "height": 123,
        "weight": 123,
        "systolicBp": 123,
        "diastolicBp": 123,
        "pulse": 123,
        "temperature": 123,
        "waistCircumference": 123,
        "noteId": "<string>",
        "measurementDate": "2023-11-07T05:31:56Z",
        "eventId": "<string>",
        "creatorId": "<string>"
      }
    ],
    "medications": [
      {
        "id": "<string>",
        "createdDate": "2023-11-07T05:31:56Z",
        "patientId": "<string>",
        "name": "<string>",
        "providerId": "<string>",
        "sideEffects": "<string>",
        "administrationLocation": "<string>",
        "amount": 123,
        "lotNumber": "<string>",
        "stockId": "<string>",
        "noteId": "<string>",
        "doseDate": "2023-11-07T05:31:56Z",
        "comment": "<string>",
        "frequency": "<string>",
        "quantity": 123,
        "isUsedAsTemplate": true,
        "signedOffProviderId": "<string>",
        "signedOffDate": "2023-11-07T05:31:56Z",
        "provider": {
          "id": "<string>",
          "firstName": "<string>",
          "lastName": "<string>",
          "phoneNumber": "<string>",
          "email": "<string>",
          "locationId": "<string>"
        }
      }
    ],
    "optedOutOfSms": true,
    "appointmentCount": 123,
    "totalSpent": 123
  },
  "createdDate": "2023-11-07T05:31:56Z",
  "eventId": "<string>",
  "duration": 123,
  "content": "<string>",
  "summary": "<string>",
  "template": {
    "id": "<string>",
    "name": "<string>",
    "createdDate": "2023-11-07T05:31:56Z",
    "contentTemplate": "<string>",
    "attachments": []
  },
  "transcript": {
    "id": "<string>",
    "transcript": "<string>",
    "createdDate": "2023-11-07T05:31:56Z",
    "duration": 123
  },
  "providers": [],
  "sourceDocuments": [],
  "icd10Codes": [
    {
      "code": "<string>",
      "shortDesc": "<string>",
      "longDesc": "<string>",
      "categorical": true
    }
  ],
  "cptCodes": [
    {
      "code": "<string>",
      "category1": "<string>",
      "category2": "<string>",
      "category3": "<string>",
      "category4": "<string>",
      "category5": "<string>",
      "category6": "<string>",
      "description": "<string>",
      "notes": "<string>"
    }
  ],
  "signedOffProviderId": "<string>",
  "signedOffDate": "2023-11-07T05:31:56Z"
}
{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}

Headers

TENANT
string
required

The tenant you are making this request on behalf of

API-KEY
string
required

Your api key

Body

application/json
patientId
string
required
providerId
string
required
locationId
string | null
eventId
string | null
parentNoteId
string | null
content
string | null
aiGenerated
boolean
default:false
noteTranscriptId
string | null
template
NoteTemplateTableItem · object | null
prompt
string | null
icd10Codes
string[] | null
cptCodes
string[] | null

Response

Successful Response

id
string
required
parentNoteId
string
required
version
integer
required
currentVersion
integer
required
aiGenerated
boolean
required
patient
PatientDetail · object
required
createdDate
string<date-time>
required
eventId
string | null
duration
integer | null
content
string | null
summary
string | null
template
NoteTemplateTableItem · object | null
transcript
NoteTranscriptSummary · object | null
providers
ProviderTiny · object[]
sourceDocuments
DocumentSummary · object[]
icd10Codes
ICDTenCode · object[] | null
cptCodes
CPTCode · object[] | null
signedOffProviderId
string | null
signedOffDate
string<date-time> | null