Skip to main content
POST
Create or update records

Authorizations

Authorization
string
header
required

Access token for your workspace.

Query Parameters

type
enum<string>
required

Which catalog to act on.

Available options:
medication,
lab_test,
symptom,
diagnosis
mode
enum<string>
default:upsert

upsert leaves records not in the request alone; reconcile deactivates them.

Available options:
upsert,
reconcile
dry_run
boolean
default:false

Validate and count without writing.

confirm_shrink
boolean
default:false

Allow a reconcile that deactivates more than half of the catalog.

overwrite
boolean
default:false

CSV only. Replace the whole catalog with the file. Not allowed with mode=reconcile.

Body

Minimum array length: 1
medication_id
string
required

Your id for the drug.

Maximum string length: 200
name
string
required
Maximum string length: 200
aliases
string[]

Alternate names and short forms, used by search.

Maximum string length: 200
display_name
string

Shown to end users. Defaults to name.

Maximum string length: 200
strength
string
Maximum string length: 32
generic_name
string
Maximum string length: 300
generic_id
string
Maximum string length: 64
generic_list
string[]

All generic (salt) components.

Maximum string length: 100
generic_list_ids
string[]
Maximum string length: 64
form_name
string

Dosage form. Matched case-insensitively against the accepted drug forms; a match links the drug to Eka's form, and any other value is stored as text without that link.

Maximum string length: 64
sku
string
Maximum string length: 64
schedule_code
string
Maximum string length: 32
custom_type
string
Maximum string length: 64
therapy_class
string
Maximum string length: 128
therapy_class_id
string
Maximum string length: 64
action_class
string
Maximum string length: 128
action_class_id
string
Maximum string length: 64
manufacturer
string
Maximum string length: 200
otc
boolean
is_active
boolean

Defaults to true on write.

Response

Written (or, with dry_run=true, validated and counted).

success
boolean
required
message
string
required
data
object