Add a staff member
Add a doctor or staff member to your workspace from your own system, with their public profile.
Adds a person to your workspace from your own system. It is meant for hospitals whose doctors never open the Medos app. One call sets a doctor up completely: their details, their role, the locations they work at, and the public profile patients see on your clinic site.
API-key only, gated on devapi_users_create.
Parameters
Headers
x-api-keystringrequiredExample: mk_…Your Developer API key. Server-side only.
X-Acting-User-IdstringExample: MDU_A1B2C3D4E5F6The staff member the call is attributed to, as an MDU_… id. Omit it to attribute the call to the workspace admin.
Content-TypestringrequiredExample: application/jsonThe body is JSON. Anything else is a 415.
Body
firstNamestringrequiredExample: AshaUp to 100 characters.
middleNamestringUp to 100 characters.
lastNamestringExample: RaoUp to 100 characters.
countryCodestringExample: +91With phoneNumber: both or neither.
phoneNumberstringExample: 98765432104 to 15 digits, without the country code.
gender"MALE" | "FEMALE" | "OTHER"enumRequired to publish a profile.
dateOfBirthstringExample: 1985-04-12YYYY-MM-DD, not in the future.
emailstringrequiredExample: asha.rao@clinic.exampleTheir sign-in. Medos emails a one-time link to set a password.
rolestringrequiredExample: DOCTORA role in your workspace, by name: DOCTOR, ALLIED_PROFESSIONAL, STAFF or one of your own. Not ADMIN.
addressIdsstringrequiredExample: [1]The locations they work at, from GET /v1/addresses.
profilestringExample: {"prefix":"Dr.","specialization":"Dermatology","registrationNumber":"KMC-12345"}The public profile, published on the clinic's site. DOCTOR and ALLIED_PROFESSIONAL only; a doctor's needs registrationNumber.
- They are added, not invited. The member is active at the given locations as soon as the call returns. There is no invitation to accept. Medos emails them a one-time link to set a password, which they need only if they will ever sign in.
roleis a role's name in your workspace:DOCTOR,ALLIED_PROFESSIONAL,STAFFor a role you created. Case does not matter.ADMINcannot be granted through the API. Adding an admin stays in the Medos app, so a leaked key cannot hand anyone control of your clinic.addressIdsare your own locations, fromGET /v1/addresses. Anyone else's is a400and nobody is added.profileis published straight away on your clinic's site. It is only forDOCTORandALLIED_PROFESSIONALstaff and needs agender, and a doctor's also needs aregistrationNumber. Each of these is checked before anyone is added. Photos and the gallery are uploads, and are added in the Medos app.- Seats work as they do for an invitation. A member beyond the seats your plan has paid for is added but locked until a seat is free.
Responses
The 201 body is the member as stored. id is their MDU_… staff id, the one
every other route takes: a practitioner's slots, bookings and records name them
by it. profile is the profile this call published, or null if you sent none.
If part of the request fails
Adding a member is several steps in Medos. If one fails after the member was
added, the error says so and names their id. Send the rest with
PUT /v1/staff/{staffId}. Do not
add them again: the email already has an account, so a second add is refused.