Skip to main content

Prior Authorization

The Prior Authorization module provides endpoints for creating, retrieving, updating, and managing pre-authorization (pre-auth) requests. It serves as the core transactional interface for submitting healthcare service requests for adjudication by the Najeeb AI Engine.

Module Overview

This module handles the full lifecycle of a prior authorization: creation, status retrieval, bundle synchronization, status updates, reopening, and cancellation.

Base URL

https://api.{client_namespace}.najeeb.ai/v4.0/health

Authentication

All API requests are authenticated using an API key passed in a dedicated header:

access-key: YOUR_API_KEY

For access key provisioning, please contact Najeeb support.

Replace {client_namespace} with your organization's assigned namespace.

Authentication

All endpoints require the access-key header for authentication. Requests must be made over HTTPS.

HeaderTypeRequiredDescription
access-keystringYesYour unique API key for authentication
Content-TypestringYesMust be application/json
Security

Keep your API key confidential. Do not expose it in client-side code, public repositories, or insecure channels. If you suspect your key has been compromised, contact the Najeeb support team immediately to rotate it.


Endpoints

MethodTitleDescription
POSTCreate Prior AuthorizationCreate a new prior authorization
GETGet One Prior AuthorizationRetrieve a prior authorization by transaction ID
PATCHSync BundleSync NPHIES bundle by transaction ID
PATCHUpdate Prior AuthorizationUpdate prior authorization status and items
PATCHReopen Prior AuthorizationReopen a previously processed prior authorization
PATCHCancel Prior AuthorizationCancel a pre-authorization

1. Create Prior Authorization

API Endpoint

POST /approval-request/create

Creates a new prior authorization. The request is validated, processed by the Najeeb AI Engine, and an acknowledgement is returned synchronously.

2. Get One Prior Authorization

GET /approval-request/get-one/:transaction_id

Retrieves a single prior authorization by its transaction_id. Returns the full prior authorization details including status, items, and adjudication results.

Path Parameters

ParameterTypeRequiredDescription
transaction_idstringYesThe unique transaction ID of the prior authorization

Example Request

curl -X GET "https://api.{client_namespace}.najeeb.ai/v4.0/health/approval-request/get-one/550e8400-e29b-41d4-a716-446655440000" \
-H "access-key: YOUR_API_KEY" \
-H "Content-Type: application/json"

Success Response (200 OK)

Returns the full prior authorization object including all submitted fields, current status, item-level decisions, and processing metadata.

Error Responses

HTTP StatusError CodeDescription
404E_EPA_09Prior authorization not found for the given transaction_id
Example Error Response
{
"ErrorCode": "E_EPA_09",
"message": "Prior authorization not found",
"details": []
}

3. Sync Bundle

PATCH /approval-request/bundle/sync/:transaction_id

Synchronizes an NPHIES response bundle with an existing prior authorization. Use this endpoint to update the prior authorization with the NPHIES response data after receiving a bundle from the NPHIES platform.

Path Parameters

ParameterTypeRequiredDescription
transaction_idstringYesThe unique transaction ID of the prior authorization

Request Body Parameters

ParameterTypeRequiredDescriptionAccepted Values
response_bundle_id *stringYesThe NPHIES response bundle IDAlphanumeric string, max 255 characters
response_bundle_status *stringYesStatus of the NPHIES response bundleEnum: COMPLETED, PENDING, PROCESSING, REFERRED
response_bundle_date *stringYesDate of the NPHIES response bundleISO 8601 format: YYYY-MM-DDTHH:mm:ss.sssZ

Example Request

curl -X PATCH "https://api.{client_namespace}.najeeb.ai/v4.0/health/approval-request/bundle/sync/550e8400-e29b-41d4-a716-446655440000" \
-H "access-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"response_bundle_id": "BUNDLE-12345",
"response_bundle_status": "COMPLETED",
"response_bundle_date": "2025-02-15T12:00:00.000Z"
}'

Success Response (200 OK)

{
"message": "Bundle synced successfully"
}

Error Responses

HTTP StatusError CodeDescription
400E_BAD_REQUEST_400Request validation failed
404E_EPA_09Prior authorization not found for the given transaction_id

4. Update Prior Authorization

PATCH /approval-request/update/:transaction_id

Updates the status and item-level decisions of an existing prior authorization. This endpoint is used by reviewers to approve, partially approve, reject, or refer a prior authorization.

Path Parameters

ParameterTypeRequiredDescription
transaction_idstringYesThe unique transaction ID of the prior authorization

Request Body Parameters

Root Level Parameters

ParameterTypeRequiredDescriptionAccepted Values
status *stringYesNew status of the prior authorizationEnum: ACCEPTED, PARTIALLY_ACCEPTED, REJECTED, REFERRED
erp_reviewer_id *stringYesUsername of the reviewer performing the updateString
approval_remarksstringNoRemarks from the reviewerFree text
refferal_remarksstringNoRemarks for referral (applicable when status is REFERRED)Free text
internal_referral_notesstringNoInternal notes for referralFree text
internal_notesstringNoInternal notesFree text
referral_cchi_codestringConditionalCCHI code for referral provider. Required when status is REFERREDAlphanumeric string
referral_valid_daysnumberNoNumber of days the referral is validInteger, 1-365
itemsarrayNoArray of item-level updatesSee Update Item Object

Update Item Object

ParameterTypeRequiredDescriptionAccepted Values
statusstringNoItem-level statusEnum: ACCEPTED, REJECTED
approved_quantitynumberNoApproved quantity for the itemInteger, minimum 0
approved_amountnumberNoApproved amount for the itemDecimal, minimum 0
erp_item_idstringNoERP item identifierAlphanumeric string
reasonsarrayNoArray of rejection reason objectsSee below
Referral Requirements

When the status is set to REFERRED, the referral_cchi_code field is required. Omitting it will result in a 422 Unprocessable Entity error.

Example Request

curl -X PATCH "https://api.{client_namespace}.najeeb.ai/v4.0/health/approval-request/update/550e8400-e29b-41d4-a716-446655440000" \
-H "access-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"status": "PARTIALLY_ACCEPTED",
"erp_reviewer_id": "reviewer.username",
"approval_remarks": "Partially approved - adjusted quantities",
"items": [
{
"erp_item_id": "ITEM-001",
"status": "ACCEPTED",
"approved_quantity": 30,
"approved_amount": 150.00
},
{
"erp_item_id": "ITEM-002",
"status": "REJECTED",
"approved_quantity": 0,
"reasons": [
{
"code": "REJ-001",
"message": "Service not covered under current benefit plan"
}
]
}
]
}'

Success Response (200 OK)

{
"message": "Prior authorization updated successfully"
}

Error Responses

HTTP StatusError CodeDescription
400E_BAD_REQUEST_400Request validation failed
404E_EPA_09Prior authorization not found
404E_EPA_10User not found for the given erp_reviewer_id
404E_EPA_11Item not found
404E_EPA_12Benefit not found for item
404E_EPA_13Sub-benefit not found for item
404E_EPA_14Rejection reason not found
422E_EPA_15Status transition not allowed
422E_EPA_16Referral CCHI code is required when status is REFERRED

5. Reopen Prior Authorization

PATCH /approval-request/reopen/:transaction_id

Reopens a previously processed prior authorization. This allows a prior authorization that has been completed (approved, rejected, etc.) to be sent back for reprocessing.

Path Parameters

ParameterTypeRequiredDescription
transaction_idstringYesThe unique transaction ID of the prior authorization

Request Body Parameters

ParameterTypeRequiredDescriptionAccepted Values
nphies_reopen_reason *stringYesReason for reopening the prior authorizationEnum: CORRECTION, ADJUDICATION, MISCALCULATION, BENEFIT, AUDIT, CANCEL, OTHER
nphies_reopen_at *stringYesDate and time of the reopen actionISO 8601 format: YYYY-MM-DDTHH:mm:ss.sssZ
username *stringYesUsername of the user who reopened the requestString

Example Request

curl -X PATCH "https://api.{client_namespace}.najeeb.ai/v4.0/health/approval-request/reopen/550e8400-e29b-41d4-a716-446655440000" \
-H "access-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"nphies_reopen_reason": "CORRECTION",
"nphies_reopen_at": "2025-02-16T09:00:00.000Z",
"username": "admin.user"
}'

Success Response (200 OK)

{
"message": "Prior authorization reopened successfully"
}

Error Responses

HTTP StatusError CodeDescription
400E_BAD_REQUEST_400Request validation failed
404E_EPA_10User not found for the given username
404E_EPA_09Prior authorization not found for the given transaction_id

6. Cancel Prior Authorization

PATCH /approval-request/cancel/:transaction_id

Cancels a pre-authorization request. Once cancelled, the prior authorization cannot be processed further.

Path Parameters

ParameterTypeRequiredDescription
transaction_idstringYesThe unique transaction ID of the prior authorization to cancel

Example Request

curl -X PATCH "https://api.{client_namespace}.najeeb.ai/v4.0/health/approval-request/cancel/550e8400-e29b-41d4-a716-446655440000" \
-H "access-key: YOUR_API_KEY" \
-H "Content-Type: application/json"

Success Response (200 OK)

{
"message": "Pre auth cancelled successfully"
}

Error Responses

HTTP StatusError CodeDescription
404E_EPA_09Prior authorization not found for the given transaction_id
409E_EPA_17Pre-authorization has already been cancelled

Enums Reference

Member Gender

ValueDescription
MALEMale
FEMALEFemale

Marital Status

ValueDescription
SINGLESingle
MARRIEDMarried
ENGAGEDEngaged
UNKNOWNUnknown
WIDOWEDWidowed
DIVORCEDDivorced
SEPARATEDSeparated

Claim Type

ValueDescription
INSTITUTIONALInstitutional services for inpatients
PROFESSIONALProfessional services for outpatients
PHARMACYPharmacy services
DENTALDental services
OPTICALOptical services

Claim Sub-Type

ValueDescription
IN_PATIENTInpatient services
OUT_PATIENTOutpatient services
EMERGENCYEmergency services

Prior Authorization Status

ValueDescription
ACCEPTEDFully approved
PARTIALLY_ACCEPTEDPartially approved with item-level adjustments
REJECTEDRejected
REFERREDReferred to another provider or specialist

Advanced Prior Authorization Status

ValueDescription
ACCEPTEDAdvanced prior authorization accepted
REJECTEDAdvanced prior authorization rejected

Response Bundle Status

ValueDescription
COMPLETEDBundle processing completed
PENDINGBundle is pending processing
PROCESSINGBundle is currently being processed
REFERREDBundle has been referred

Diagnosis Type

ValueDescription
primaryPrimary diagnosis
secondarySecondary diagnosis

  • Member -- Managing patients and member records
  • Medical Provider -- Managing medical providers
  • Policy -- Policy management and benefit templates
  • Supporting Info -- Attaching supporting documents to prior authorizations
  • Communication -- Creating communications related to prior authorizations
  • Webhook -- Registering webhooks for event notifications