Create user
Creates a new user in Parchment
Response Examples
Success Response (201 Created)
Partial Success - User Already Exists (201 Created)
Partial Success = Provider Already Exists (201 Created)
Partial Success - Provider Creation Failed (201 Created)
Validation Error (422 Unprocessable Entity)
Unauthorized (401)
Response Fields
Success Response Data
| Field | Type | Description |
|---|---|---|
external_user_id | string | Your system’s user identifier (as provided in request) |
parchment_user_id | string | Parchment’s unique user identifier |
url | string | Direct link to user in Parchment portal |
Common Response Fields
All responses include these standard fields:| Field | Type | Description |
|---|---|---|
success | boolean | Indicates if the request was successful |
statusCode | number | HTTP status code |
timestamp | string | ISO 8601 timestamp of the response |
requestId | string | Unique identifier for debugging |
Status Codes
| Code | Status | Description |
|---|---|---|
201 | Created | User successfully created |
202 | Accepted | User creation accepted (demographic conflicts found) |
400 | Bad Request | Invalid request format or missing required fields |
401 | Unauthorized | Authentication required or token invalid |
403 | Forbidden | Insufficient permissions (missing CREATE_USER scope) |
409 | Conflict | Partner user ID already exists |
422 | Unprocessable Entity | Request validation failed |
500 | Internal Server Error | Unexpected server error |
Field Validation Requirements
Required Fields
| Field | Type | Required When | Description |
|---|---|---|---|
given_name | string | Always | User’s given name |
family_name | string | Always | User’s family name |
email | string | Always | User’s email address |
date_of_birth | string | When access_roles includes “provider” | Date of birth in YYYY-MM-DD format |
sex | string | When access_roles includes “provider” | Sex (M/F/I/N) |
hpii_number | string | When access_roles includes “provider” | Healthcare Provider Individual Identifier |
prescriber_type | string | When access_roles includes “provider” | Prescriber type (M/N/D/P/T) |
prescriber_number | string | When role is “provider” and prescriber_type is not “T” | Prescriber number |
qualifications | string | When access_roles includes “provider” | Professional qualifications |
Optional Fields
| Field | Type | Description |
|---|---|---|
access_roles | array | User roles |
title | string | Professional title |
provider_number | string | Medicare provider number |
ahpra_number | string | AHPRA registration number |
hospital_provider_number | string | Hospital provider number |
phone | string | Clinic’s Number |
Phone Number Format
Thephone field accepts Australian phone numbers in the following formats:
✅ Valid Examples:
0412345678- Mobile number (domestic format)0312345678- Melbourne landline (domestic format)0212345678- Sydney landline (domestic format)0712345678- Brisbane landline (domestic format)0812345678- Adelaide landline (domestic format)61412345678- International mobile (without + prefix)+61312345678- International landline (with + prefix)
0123456789- Starts with 1 (invalid area code)04123456789- Too many digits041234567- Too few digits04-1234-5678- Contains formatting characters+1234567890- Non-Australian number
String Length Requirements
- Family Name: 1-255 characters, cannot be empty
- Given Name: 1-255 characters, cannot be empty
- HPII Number: 16 digits exactly
- Prescriber Number: 1-10 characters
- AHPRA Number: 1-15 characters
- Provider Number: 1-15 characters
- Qualifications: 1-255 characters
Sex
M(Male)F(Female)I(Indeterminate)N(Not-stated)
Access Roles
Valid values foraccess_roles array:
admin(Administrative access)provider(Healthcare provider access)receptionist(Can read patient demographics)rx_reader(Can reissue scripts)
provider role is included, additional fields become required.
Prescriber Types
Valid values forprescriber_type when role is “provider”:
M(Medical Practitioner)E(Eye/Optometrist)U(Nurse)F(Midwife)D(Dentist)V(Vetinarian)T(Podiatrist)C(Pharmacist)
Integration Notes
- Store Request ID: Always log the
requestIdfor debugging support requests - Handle 202 Status: A 202 response indicates demographic conflicts were found but a matching user was returned
- Validation Errors: Use the
error.validationarray to display field-specific error messages - Partner User ID: Must be unique across your organization; use the format returned in
external_user_id - URL Access: The returned
urlprovides direct access to the user in the Parchment portal - Provider Role Requirements: When creating users with provider role, ensure all required provider fields are included
- Phone Validation: Phone numbers must follow Australian format - see validation requirements above
Example Request
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Headers
Organization secret for authentication - provided by Parchment
Path Parameters
Organization ID
Body
User data to add to Parchment
User information to be created
User's given name
"Darlene"
User's family name
"Cameron"
User's email address
"darlene.cameron@example.com"
Partner's unique identifier for the user
"CLINIKO#USER_12345"
User's date of birth in YYYY-MM-DD format (required if role includes 'provider')
"1969-10-02"
User's sex (required if role includes 'provider')
M, F, I, O "F"
User's Australian phone number. Must be a valid Australian number with digits only. Supports mobile (04xxxxxxxx) and landline (0[2378]xxxxxxxx) formats. International format with +61 or 61 prefix is also accepted.
"0412345678"
List of access roles for the user
admin, provider ["admin", "provider"]Healthcare Provider Individual Identifier (required if role includes 'provider')
"8003614900029560"
Prescriber type (required if role includes 'provider')
M, N, D, P, T "M"
Prescriber number (required if role includes 'provider' and prescriber_type is not 'T')
"1234567"
Professional qualifications (required if role includes 'provider')
"LLB"
Professional title
"Dr"
Medicare provider number
"123456789"
AHPRA registration number
"1234567896321"
Hospital provider number
"H123456"
Response
User created successfully
Indicates if the request was successful
true
HTTP status code
201
Human-readable success message
"User created successfully"
User creation response data
ISO 8601 timestamp of the response
"2024-01-15T10:30:00.000Z"
Unique identifier for request tracing
"req_1705312200000_abc123"
Pagination information for list operations

