Cambia lo stato di un preventivo
curl --request POST \
--url https://api.dentalspace.ai/v1/treatment-plans/{id}/status \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"acceptedAmount": 123
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({acceptedAmount: 123})
};
fetch('https://api.dentalspace.ai/v1/treatment-plans/{id}/status', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.dentalspace.ai/v1/treatment-plans/{id}/status"
payload = { "acceptedAmount": 123 }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"patientId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"facilityId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"description": "<string>",
"status": "draft",
"totalCost": 123,
"presentedAmount": 123,
"presentedAt": "<string>",
"acceptedAmount": 123,
"acceptedAt": "<string>",
"doctorId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"createdAt": "<string>",
"updatedAt": "<string>",
"items": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"treatmentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"cost": 123,
"status": "<string>",
"priority": 0,
"doctorId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"tooth": 0,
"surface": "<string>",
"treatmentArea": "<string>",
"diagnosisId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
],
"odontogramType": "<string>",
"toothData": {},
"diagnoses": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"tooth": 0,
"issueType": "<string>",
"issueCategory": "<string>",
"treatmentArea": "<string>",
"surfaces": [
"<string>"
],
"severity": "<string>",
"note": "<string>",
"status": "<string>"
}
]
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {},
"requestId": "<string>"
}
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {},
"requestId": "<string>"
}
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {},
"requestId": "<string>"
}
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {},
"requestId": "<string>"
}
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {},
"requestId": "<string>"
}
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {},
"requestId": "<string>"
}
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {},
"requestId": "<string>"
}
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {},
"requestId": "<string>"
}
}Preventivi
Cambia lo stato di un preventivo
Scope: treatment_plans:write.
proposed → standby (presentato) · proposed/standby → accepted/rejected. Una bozza non cambia stato via API.
POST
/
treatment-plans
/
{id}
/
status
Cambia lo stato di un preventivo
curl --request POST \
--url https://api.dentalspace.ai/v1/treatment-plans/{id}/status \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"acceptedAmount": 123
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({acceptedAmount: 123})
};
fetch('https://api.dentalspace.ai/v1/treatment-plans/{id}/status', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.dentalspace.ai/v1/treatment-plans/{id}/status"
payload = { "acceptedAmount": 123 }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"patientId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"facilityId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"description": "<string>",
"status": "draft",
"totalCost": 123,
"presentedAmount": 123,
"presentedAt": "<string>",
"acceptedAmount": 123,
"acceptedAt": "<string>",
"doctorId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"createdAt": "<string>",
"updatedAt": "<string>",
"items": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"treatmentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"cost": 123,
"status": "<string>",
"priority": 0,
"doctorId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"tooth": 0,
"surface": "<string>",
"treatmentArea": "<string>",
"diagnosisId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
],
"odontogramType": "<string>",
"toothData": {},
"diagnoses": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"tooth": 0,
"issueType": "<string>",
"issueCategory": "<string>",
"treatmentArea": "<string>",
"surfaces": [
"<string>"
],
"severity": "<string>",
"note": "<string>",
"status": "<string>"
}
]
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {},
"requestId": "<string>"
}
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {},
"requestId": "<string>"
}
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {},
"requestId": "<string>"
}
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {},
"requestId": "<string>"
}
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {},
"requestId": "<string>"
}
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {},
"requestId": "<string>"
}
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {},
"requestId": "<string>"
}
}{
"error": {
"code": "invalid_request",
"message": "<string>",
"details": {},
"requestId": "<string>"
}
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Identificativo della risorsa.
Pattern:
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$Body
application/json
Response
Il preventivo aggiornato.
Pattern:
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$Pattern:
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$Pattern:
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$Available options:
draft, proposed, standby, accepted, rejected, in_progress, completed Pattern:
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$Show child attributes
Show child attributes
Solo con clinical:read.
Solo con clinical:read.
Show child attributes
Show child attributes
Solo con clinical:read.
Show child attributes
Show child attributes