curl --request POST \
--url https://nextvisit.app/api/v1/progress-notes \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: multipart/form-data' \
--form 'name=<string>' \
--form patient_id=123 \
--form file='@example-file' \
--form prompt_id=123import requests
url = "https://nextvisit.app/api/v1/progress-notes"
files = { "file": ("example-file", open("example-file", "rb")) }
payload = {
"name": "<string>",
"patient_id": "123",
"prompt_id": "123"
}
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, data=payload, files=files, headers=headers)
print(response.text)const form = new FormData();
form.append('name', '<string>');
form.append('patient_id', '123');
form.append('file', '<string>');
form.append('prompt_id', '123');
const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
options.body = form;
fetch('https://nextvisit.app/api/v1/progress-notes', 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://nextvisit.app/api/v1/progress-notes",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"name\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"patient_id\"\r\n\r\n123\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"prompt_id\"\r\n\r\n123\r\n-----011000010111000001101001--",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: multipart/form-data"
],
]);
$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://nextvisit.app/api/v1/progress-notes"
payload := strings.NewReader("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"name\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"patient_id\"\r\n\r\n123\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"prompt_id\"\r\n\r\n123\r\n-----011000010111000001101001--")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://nextvisit.app/api/v1/progress-notes")
.header("Authorization", "Bearer <token>")
.body("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"name\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"patient_id\"\r\n\r\n123\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"prompt_id\"\r\n\r\n123\r\n-----011000010111000001101001--")
.asString();require 'uri'
require 'net/http'
url = URI("https://nextvisit.app/api/v1/progress-notes")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request.body = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"name\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"patient_id\"\r\n\r\n123\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"prompt_id\"\r\n\r\n123\r\n-----011000010111000001101001--"
response = http.request(request)
puts response.read_body{
"id": 123,
"name": "Follow-up Visit - Jane Doe",
"team_id": 5,
"user_id": 42,
"created_at": "2023-04-10T15:30:00Z",
"updated_at": "2023-04-10T15:45:00Z",
"transcription": "Patient reports improvement in symptoms since last visit...",
"analysis": "Patient's condition has improved with current treatment regimen...",
"template": {
"id": 5,
"name": "Standard Follow-up",
"description": "Standard template for routine follow-up visits"
},
"patient": {
"$ref": "<unknown>"
},
"audio": {
"duration": 480,
"bitrate": 128000,
"size": 7680000,
"uploaded_at": "2023-04-10T15:30:00Z",
"expires_at": "2023-05-10T15:30:00Z",
"file_url": "https://storage.nextvisit.app/encounters/abc123.mp3?token=xyz"
},
"has": {
"content": true,
"transcription": true,
"signed": false
},
"user": {
"$ref": "<unknown>"
},
"transcription_started_at": "2023-04-10T15:35:00Z",
"transcription_completed_at": "2023-04-10T15:40:00Z",
"analysis_started_at": "2023-04-10T15:40:00Z",
"analysis_completed_at": "2023-04-10T15:45:00Z",
"error_state": null
}{
"message": "Unauthorized"
}{
"message": "The given data was invalid",
"errors": {
"name": [
"The name field is required"
],
"content": [
"The content must be at least 10 characters"
]
}
}Create a new progress note
Creates a new progress note with an associated audio file
curl --request POST \
--url https://nextvisit.app/api/v1/progress-notes \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: multipart/form-data' \
--form 'name=<string>' \
--form patient_id=123 \
--form file='@example-file' \
--form prompt_id=123import requests
url = "https://nextvisit.app/api/v1/progress-notes"
files = { "file": ("example-file", open("example-file", "rb")) }
payload = {
"name": "<string>",
"patient_id": "123",
"prompt_id": "123"
}
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, data=payload, files=files, headers=headers)
print(response.text)const form = new FormData();
form.append('name', '<string>');
form.append('patient_id', '123');
form.append('file', '<string>');
form.append('prompt_id', '123');
const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
options.body = form;
fetch('https://nextvisit.app/api/v1/progress-notes', 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://nextvisit.app/api/v1/progress-notes",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"name\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"patient_id\"\r\n\r\n123\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"prompt_id\"\r\n\r\n123\r\n-----011000010111000001101001--",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: multipart/form-data"
],
]);
$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://nextvisit.app/api/v1/progress-notes"
payload := strings.NewReader("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"name\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"patient_id\"\r\n\r\n123\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"prompt_id\"\r\n\r\n123\r\n-----011000010111000001101001--")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://nextvisit.app/api/v1/progress-notes")
.header("Authorization", "Bearer <token>")
.body("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"name\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"patient_id\"\r\n\r\n123\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"prompt_id\"\r\n\r\n123\r\n-----011000010111000001101001--")
.asString();require 'uri'
require 'net/http'
url = URI("https://nextvisit.app/api/v1/progress-notes")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request.body = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"name\"\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"patient_id\"\r\n\r\n123\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"prompt_id\"\r\n\r\n123\r\n-----011000010111000001101001--"
response = http.request(request)
puts response.read_body{
"id": 123,
"name": "Follow-up Visit - Jane Doe",
"team_id": 5,
"user_id": 42,
"created_at": "2023-04-10T15:30:00Z",
"updated_at": "2023-04-10T15:45:00Z",
"transcription": "Patient reports improvement in symptoms since last visit...",
"analysis": "Patient's condition has improved with current treatment regimen...",
"template": {
"id": 5,
"name": "Standard Follow-up",
"description": "Standard template for routine follow-up visits"
},
"patient": {
"$ref": "<unknown>"
},
"audio": {
"duration": 480,
"bitrate": 128000,
"size": 7680000,
"uploaded_at": "2023-04-10T15:30:00Z",
"expires_at": "2023-05-10T15:30:00Z",
"file_url": "https://storage.nextvisit.app/encounters/abc123.mp3?token=xyz"
},
"has": {
"content": true,
"transcription": true,
"signed": false
},
"user": {
"$ref": "<unknown>"
},
"transcription_started_at": "2023-04-10T15:35:00Z",
"transcription_completed_at": "2023-04-10T15:40:00Z",
"analysis_started_at": "2023-04-10T15:40:00Z",
"analysis_completed_at": "2023-04-10T15:45:00Z",
"error_state": null
}{
"message": "Unauthorized"
}{
"message": "The given data was invalid",
"errors": {
"name": [
"The name field is required"
],
"content": [
"The content must be at least 10 characters"
]
}
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
Response
Progress note created successfully
Unique identifier for the progress note
123
Name or title of the progress note
"Follow-up Visit - Jane Doe"
ID of the team this note belongs to
5
ID of the user who created this note
42
When the progress note was created
"2023-04-10T15:30:00Z"
When the progress note was last updated
"2023-04-10T15:45:00Z"
Transcribed content of the audio recording
"Patient reports improvement in symptoms since last visit..."
AI-generated analysis of the transcription
"Patient's condition has improved with current treatment regimen..."
Show child attributes
Show child attributes
Associated patient information
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Information about the user who created the note
Show child attributes
Show child attributes
When transcription process started
"2023-04-10T15:35:00Z"
When transcription was completed
"2023-04-10T15:40:00Z"
When analysis process started
"2023-04-10T15:40:00Z"
When analysis was completed
"2023-04-10T15:45:00Z"
Any error state during processing
null
Was this page helpful?