API 💻
Postman Collection
Testing vs Production
After creating an account you can access the test API endpoints on our sandbox server:
This endpoint is identical to our production endpoint but does not allow PHI and only returns dummy card results.
Once you have signed our Business Associate Agreement (BAA) you will be able to access the production server:
Admin Endpoints
The admin endpoints are designed for managing access tokens within our system. These endpoints can only be called using a valid API key. They provide a secure way to generate and manage tokens, ensuring that only authorized users can access sensitive data and functionalities.
Get Access Token
GET
https://sandbox.cardscan.ai/v1/access-token
This endpoint generates the JSON Web Token (JWT) for a web or mobile user
Query Parameters
Name | Type | Description |
---|---|---|
user_id | String | Unique identifier for the user |
This endpoint generates a short-lived session token that the web/mobile user will use to directly authenticate with CardScan's servers. See the Authentication page for more details.
This function takes an optional user_id
which must be unique between your users.
See Authentication for code examples.
Insurance Card Scanning Endpoints
Create Card
POST
https://sandbox.cardscan.ai/v1/cards
Creates a card object to initiate the scanning process and will be used for generating upload endpoints.
Request Body
Name | Type | Description |
---|---|---|
enable_backside_scan | boolean | Enabled scanning of both sides of the insurance cards. Important for eligibility checks and prior auth. Default: False |
enable_livescan | boolean | Allows the card to process multiple updates per side. Required for live scanning. Default: False |
Generate Upload Url
POST
https://sandbox.cardscan.ai/v1/cards/:card_id/generate-upload-url
Generates a URL and signed payload to enable direct image upload to AWS S3.
Path Parameters
Name | Type | Description |
---|---|---|
card_id* | UUID | For the card entity to link the upload with. |
Request Body
Name | Type | Description |
---|---|---|
orientation* | Enum | 'front' - the front face of the insurance card, often containing the name, member_id, etc. 'back' - the back side of the card, often containing the claims address, and various phone number. |
The S3 URL only supports HTTP POSTs, not PUTs.
The upload_parameters
may change at any time, please make sure to not hardcode the list in any POST command.
List Scanned Cards
GET
https://sandbox.cardscan.ai/v1/cards
Query Parameters
Name | Type | Description |
---|---|---|
cursor | string | Used to paginate through results when count is greater that limit. |
limit | integer | Count of cards to return. Default: 50 Max: 500 |
The next_cursor
field is only present in the response_metadata
when there are additional results to request.
The completed
card in this example is truncated, for a full card and supported states, please see Get Card Details below.
Get Card
GET
https://sandbox.cardscan.ai/v1/cards/:cardId
Path Parameters
Name | Type | Description |
---|---|---|
cardId* | string | UUID of card |
Cards returned by this endpoint and the /v1/cards
endpoint have a state field:
Value | Description |
---|---|
pending | This card ID has been reserved but a corresponding file has not yet been uploaded |
processing | The card is being processed by our ML pipeline. |
completed | Card processing is completed and the card |
error | An error has occurred, see |
unknown | An unknown issue has occurred, please contact support for help. |
After being processed by the ML pipeline, each element is labeled and when the probability is above our minimum threshold the results are returned.
Name | Description | Example |
---|---|---|
group_number | The group number identifies the specific benefits associated with the plan. This is missing with some payers and exchange plans. | 98755 |
member_number | A unique identifier for each member and dependent. This is used to verify coverage and arrange payment for services. | 128845682 |
payer_name | The name of the health insurance payer or 3rd party administrator. | unitedhealthcare |
payer_id | The payer ID or EDI for the insurance company. This is as written on the card and not matched to a clearing house. | 87726 |
rx_bin rx_pcn rx_group rx_id | These are used to identify how a prescription drug will be reimbursed and where a pharmacy can send a reimbursement claim to | 610279 9987 UHC 12458765 |
member_name | Most often the policyholder, but on some cards this is the dependent the card was issues to. | Emily Dickinson |
dependent_names | This is a list of all dependents found on the card. | Richard Dickinson |
plan_name | Our best attempt to determine the name of the plan for this card. This is missing on many cards. | unitedhealthcare choice plus |
plan_id | An identifier representing the plan associated with this card. | (80840) 911-80708-01 |
client_name | The name of the employer who is contracted with the 3rd party administrator. | Apple, Inc. |
plan_details | When available a list of: deductibles, co-pays, co-insurance, PCP name. | Office: $25 ER: $300 |
start_date | The date when coverage starts. | 04/01/2021 |
card_specific_id | A non-specific but prominent identifier found on the card. | 54243 |
phone_numbers | A list of all phone numbers found of the front and back of the card. | 800-400-5251 |
addresses | A list of all addresses found on the card. | UnitedHealthcare P.O. Box 740800 Atlanta, GA 30374-0800 |
Note: If an element is missing it means it is either not available on this type of card, or we did not have a high enough confidence to return it.
Delete Card
DELETE
https://sandbox.cardscan.ai/v1/cards/:cardId
This will trigger a soft delete of the specified card.
Path Parameters
Name | Type | Description |
---|---|---|
cardId* | String | UUID of the card |
Note: All of the images, ML results, eligibility results, and PHI will be removed, but the card record and performance statistics will remain.
Flag Card
POST
https://sandbox.cardscan.ai/v1/cards/:cardId/flag
This endpoint allows you to flag a specific card with a particular type of flag. Flags are used to mark cards for special attention or action.
Path Parameters
Name | Type | Description |
---|---|---|
cardId* | String | UUID of the card |
Request Body
Name | Type | Allowed values | Description |
---|---|---|---|
flag_type* | String |
| The flag type used to mark the card |
message | String | An optional message to add additional information |
Magic Links
Generate magic link
GET
/generate-magic-link
Generates a magic link for the currently authenticated user. The generated token expires in one hour. This endpoint is called by the React Widget when using the Web To Mobile Handoff feature.
Validate magic link
GET
/validate-magic-link?token=<magic-token>
Validates that the provided magic link token is valid and if so, returns an Access Token with limited capabilities. You need to use this endpoint if you want to self-host the Web To Mobile Handoff feature.
Eligibility Verification
Our Eligibility Verification Endpoints offer a seamless way to check the insurance eligibility of patients. They provide real-time verification of coverage details, ensuring accurate and efficient processing of healthcare services.
Please see the Eligibility Verification page for full details on the product offering.
Our Eligibility Verification Endpoints operate similarly to our Insurance Card Scanning Endpoints. Users can create a new eligibility request, which is processed asynchronously. The system updates the record as the state changes, providing real-time insights into insurance coverage and benefits.
Note: Currently a completed insurance card scan is required to start the eligibility verification process.
To create an eligibility request, users must provide subscriber and dependent demographics along with provider details, including a National Provider Identifier (NPI). This information is essential for accurately verifying insurance eligibility.
You can locate a providers NPI on the NPPES NPI Registry search page.
Last updated