diff --git a/modules/mobile/app/controllers/mobile/v0/threads_controller.rb b/modules/mobile/app/controllers/mobile/v0/threads_controller.rb new file mode 100644 index 00000000000..e6fcc429c52 --- /dev/null +++ b/modules/mobile/app/controllers/mobile/v0/threads_controller.rb @@ -0,0 +1,24 @@ +# frozen_string_literal: true + +module Mobile + module V0 + class ThreadsController < MessagingController + def index + resource = client.get_folder_threads( + params[:folder_id].to_s, + params[:page_size], + params[:page], + params[:sort_field], + params[:sort_order] + ) + + raise Common::Exceptions::RecordNotFound, params[:folder_id] if resource.blank? + + render json: resource.data, + serializer: CollectionSerializer, + each_serializer: MyHealth::V1::ThreadsSerializer, + meta: resource.metadata + end + end + end +end diff --git a/modules/mobile/config/routes.rb b/modules/mobile/config/routes.rb index 5ff0275c4cd..89684c5441b 100644 --- a/modules/mobile/config/routes.rb +++ b/modules/mobile/config/routes.rb @@ -65,6 +65,7 @@ resources :folders, only: %i[index show create destroy], defaults: { format: :json } do resources :messages, only: [:index], defaults: { format: :json } + resources :threads, only: %i[index] end resources :messages, only: %i[show create destroy], defaults: { format: :json } do diff --git a/modules/mobile/docs/index.html b/modules/mobile/docs/index.html index 527939e167a..27b997f9322 100644 --- a/modules/mobile/docs/index.html +++ b/modules/mobile/docs/index.html @@ -2216,7 +2216,7 @@ -
Authorizations:
Bearer

Responses

Response samples

Content type
application/json
{
  • "data": [
    ],
  • "meta": {
    }
}

/v0/messaging/health/message_drafts

Save a new draft message

+

Response samples

Content type
application/json
{
  • "data": [
    ],
  • "meta": {
    }
}

/v0/messaging/health/folders/{id}/threads

List of threads in a secure messaging folder

+
Authorizations:
Bearer
path Parameters
folderId
required
string

The id of the folder that threads are being retrieved from

+
query Parameters
pageSize,
string

The size of the pagination you want. Defaults to 10

+
page,
string

The page number to get based on your page size

+
sortField,
string
Enum: "SENDER_NAME" "RECIPIENT_NAME" "SENT_DATE" "DRAFT_DATE"

The field to sort the results by

+
sortOrder,
string
Enum: "ASC" "DESC"

The order to sort the results by

+

Responses

Response samples

Content type
application/json
{
  • "data": [
    ]
}

/v0/messaging/health/message_drafts

Save a new draft message

Authorizations:
Bearer
Request Body schema: application/json
recipient_id
required
integer

The message recipient. This must be a valid recipient id that is assigned to the user. The list of valid recipients for a user can be obtained from the

/v0/messaging/health/recipients
endpoint.

category
required
string

Message category. This must be one of the values returned by the

@@ -2621,12 +2631,12 @@

Responses

Request samples

Content type
application/json
{
  • "recipient_id": 1763526,
  • "category": "OTHER",
  • "body": "What is the proper dosage and how long should I take this medication?",
  • "subject": "Question about my medication",
  • "draft_id": 0
}

Response samples

Content type
application/json
{
  • "recipient_id": 1763526,
  • "category": "OTHER",
  • "body": "What is the proper dosage and how long should I take this medication?",
  • "subject": "Question about my medication",
  • "draft_id": 0
}

/v0/messaging/health/message_drafts/{id}

Update an existing draft message

+

Request samples

Content type
application/json
{
  • "recipient_id": 1763526,
  • "category": "OTHER",
  • "body": "What is the proper dosage and how long should I take this medication?",
  • "subject": "Question about my medication",
  • "draft_id": 0
}

Response samples

Content type
application/json
{
  • "recipient_id": 1763526,
  • "category": "OTHER",
  • "body": "What is the proper dosage and how long should I take this medication?",
  • "subject": "Question about my medication",
  • "draft_id": 0
}

/v0/messaging/health/message_drafts/{id}

Update an existing draft message

Authorizations:
Bearer
path Parameters
id
required
string

The id of the draft that is to be updated

Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "body": "the updated message"
}

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/messaging/health/message_drafts/{reply_id}/replydraft

Save a new draft message as a reply to an existing message

+

Request samples

Content type
application/json
{
  • "body": "the updated message"
}

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/messaging/health/message_drafts/{reply_id}/replydraft

Save a new draft message as a reply to an existing message

Authorizations:
Bearer
path Parameters
reply_id
required
string

The id of the message that will be replied to

Request Body schema: application/json
recipient_id
required
integer

The message recipient. This must be a valid recipient id that is assigned to the user. The list of valid recipients for a user can be obtained from the

/v0/messaging/health/recipients
endpoint.

@@ -2636,13 +2646,13 @@

Responses

Request samples

Content type
application/json
{
  • "recipient_id": 1763526,
  • "category": "OTHER",
  • "body": "What is the proper dosage and how long should I take this medication?",
  • "subject": "Question about my medication",
  • "draft_id": 0
}

Response samples

Content type
application/json
{
  • "recipient_id": 1763526,
  • "category": "OTHER",
  • "body": "What is the proper dosage and how long should I take this medication?",
  • "subject": "Question about my medication",
  • "draft_id": 0
}

/v0/messaging/health/message_drafts/{reply_id}/replydraft/{draft_id}

Edit a draft message that was a reply to an existing message

+

Request samples

Content type
application/json
{
  • "recipient_id": 1763526,
  • "category": "OTHER",
  • "body": "What is the proper dosage and how long should I take this medication?",
  • "subject": "Question about my medication",
  • "draft_id": 0
}

Response samples

Content type
application/json
{
  • "recipient_id": 1763526,
  • "category": "OTHER",
  • "body": "What is the proper dosage and how long should I take this medication?",
  • "subject": "Question about my medication",
  • "draft_id": 0
}

/v0/messaging/health/message_drafts/{reply_id}/replydraft/{draft_id}

Edit a draft message that was a reply to an existing message

Authorizations:
Bearer
path Parameters
reply_id
required
string

The id of the message that will be replied to

draft_id
required
string

The id of the draft that is to be updated

Request Body schema: application/json
object

Responses

Request samples

Content type
application/json
{
  • "body": "the updated message"
}

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/messaging/health/messages

Send a new secure message

+

Request samples

Content type
application/json
{
  • "body": "the updated message"
}

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/messaging/health/messages

Send a new secure message

Authorizations:
Bearer
Request Body schema:

New message body.

NOTES:

    @@ -2668,21 +2678,21 @@

Responses

Request samples

Content type
{
  • "recipient_id": 1763526,
  • "category": "OTHER",
  • "body": "What is the proper dosage and how long should I take this medication?",
  • "subject": "Question about my medication",
  • "draft_id": 0
}

Response samples

Content type
application/json
{
  • "type": "messages",
  • "id": "123789",
  • "attributes": {
    },
  • "relationships": {
    },
  • "included": []
}

/v0/messaging/health/messages/categories

List available message categories

+

Request samples

Content type
{
  • "recipient_id": 1763526,
  • "category": "OTHER",
  • "body": "What is the proper dosage and how long should I take this medication?",
  • "subject": "Question about my medication",
  • "draft_id": 0
}

Response samples

Content type
application/json
{
  • "type": "messages",
  • "id": "123789",
  • "attributes": {
    },
  • "relationships": {
    },
  • "included": []
}

/v0/messaging/health/messages/categories

List available message categories

Authorizations:
Bearer

Responses

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/messaging/health/messages/signature

Gets user message signature preferences

+

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/messaging/health/messages/signature

Gets user message signature preferences

Authorizations:
Bearer

Responses

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/messaging/health/messages/{id}

Moves a secure message to the "Deleted" folder

+

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/messaging/health/messages/{id}

Moves a secure message to the "Deleted" folder

Authorizations:
Bearer
path Parameters
id
required
string

The id of the message that is to be deleted

Responses

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/messaging/health/messages/{id}

Get a secure message and mark the message as read.

+

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/messaging/health/messages/{id}

Get a secure message and mark the message as read.

NOTES:

  • Unlike listing messages in a folder, the message resource returned from this operation will include @@ -2693,18 +2703,18 @@
Authorizations:
Bearer

Responses

Response samples

Content type
application/json
{
  • "type": "messages",
  • "id": "123789",
  • "attributes": {
    },
  • "relationships": {
    },
  • "included": []
}

/v0/messaging/health/messages/{id}/move

Moves a secure message to a specified folder

+

Response samples

Content type
application/json
{
  • "type": "messages",
  • "id": "123789",
  • "attributes": {
    },
  • "relationships": {
    },
  • "included": []
}

/v0/messaging/health/messages/{id}/move

Moves a secure message to a specified folder

Authorizations:
Bearer
path Parameters
id
required
string

The id of the message that is to be moved

query Parameters
folder_id,
required
string

The id of the folder that the message is to be moved to

Responses

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/messaging/health/messages/{id}/attachments/{attachment_id}

Get a secure message attachment content as a direct binary download. Secure messaging supports the following file types/extensions: doc, docx, gif, jpg, pdf, png, rtf, txt, xls, xlsx.

+

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/messaging/health/messages/{id}/attachments/{attachment_id}

Get a secure message attachment content as a direct binary download. Secure messaging supports the following file types/extensions: doc, docx, gif, jpg, pdf, png, rtf, txt, xls, xlsx.

Authorizations:
Bearer
path Parameters
id
required
integer

ID of the message that we are retrieving attachments of

Responses

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/messaging/health/messages/{id}/reply

Send reply to a secure message

+

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/messaging/health/messages/{id}/reply

Send reply to a secure message

NOTE: If including file attachments, this request must be sent as multipart/form-data

File attachment restrictions (as imposed by MHV):

    @@ -2719,21 +2729,21 @@

Responses

Request samples

Content type
{
  • "recipient_id": 1112233,
  • "category": "TEST",
  • "subject": "My Test Results",
  • "body": "Dear provider, please clarify my test results. Thank you.",
  • "draft_id": 0
}

Response samples

Content type
application/json
{
  • "type": "messages",
  • "id": "123789",
  • "attributes": {
    },
  • "relationships": {
    },
  • "included": []
}

/v0/messaging/health/messages/{id}/thread

Gets a list of message summaries that are related to the message of the passed id and older than the message of +

Request samples

Content type
{
  • "recipient_id": 1112233,
  • "category": "TEST",
  • "subject": "My Test Results",
  • "body": "Dear provider, please clarify my test results. Thank you.",
  • "draft_id": 0
}

Response samples

Content type
application/json
{
  • "type": "messages",
  • "id": "123789",
  • "attributes": {
    },
  • "relationships": {
    },
  • "included": []
}

/v0/messaging/health/messages/{id}/thread

Gets a list of message summaries that are related to the message of the passed id and older than the message of the id provided. Does not include the message of the passed id itself.

Authorizations:
Bearer

Responses

Response samples

Content type
application/json
{
  • "data": [
    ],
  • "meta": {
    }
}

/v1/messaging/health/messages/{id}/thread

Gets a list of message summaries that are related to the message of the passed id regardless of their age in +

Response samples

Content type
application/json
{
  • "data": [
    ],
  • "meta": {
    }
}

/v1/messaging/health/messages/{id}/thread

Gets a list of message summaries that are related to the message of the passed id regardless of their age in relation to the message of the id provided. Does not include the message of the passed id itself.

Authorizations:
Bearer

Responses

Response samples

Content type
application/json
{
  • "data": [
    ],
  • "meta": {
    }
}

/v0/messaging/health/recipients

List available recipients to which messages may be sent

+

Response samples

Content type
application/json
{
  • "data": [
    ],
  • "meta": {
    }
}

/v0/messaging/health/recipients

List available recipients to which messages may be sent

Authorizations:
Bearer

Responses

Response samples

Content type
application/json
{
  • "data": [
    ],
  • "meta": {
    }
}

/v0/military-service-history

Returns user's service history

+

Response samples

Content type
application/json
{
  • "data": [
    ],
  • "meta": {
    }
}

/v0/military-service-history

Returns user's service history

Authorizations:
Bearer

Responses

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/payment-history

Returns user's payment history

+

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/payment-history

Returns user's payment history

Authorizations:
Bearer

Responses

Response samples

Content type
application/json
{
  • "data": [
    ],
  • "meta": {
    }
}

/v0/payment-information/benefits

Returns direct deposit payment info

+

Response samples

Content type
application/json
{
  • "data": [
    ],
  • "meta": {
    }
}

/v0/payment-information/benefits

Returns direct deposit payment info

Authorizations:
Bearer

Responses

Response samples

Content type
application/json
{
  • "type": "paymentInformation",
  • "id": "abe3f152-90b0-45cb-8776-4958bad0e0ef",
  • "attributes": {
    }
}

/v0/payment-information/benefits

Returns updated direct deposit payment info

+

Response samples

Content type
application/json
{
  • "type": "paymentInformation",
  • "id": "abe3f152-90b0-45cb-8776-4958bad0e0ef",
  • "attributes": {
    }
}

/v0/payment-information/benefits

Returns updated direct deposit payment info

Authorizations:
Bearer
Request Body schema: application/json

New direct deposit info

accountNumber
required
string
accountType
required
string
Enum: "Savings" "Checking"
financialInstitutionName
required
string
financialInstitutionRoutingNumber
required
string

Responses

Request samples

Content type
application/json
{
  • "accountNumber": "12345678901",
  • "accountType": "Savings",
  • "financialInstitutionName": "PACIFIC PREMIER BANK",
  • "financialInstitutionRoutingNumber": "021000021"
}

Response samples

Content type
application/json
{
  • "type": "paymentInformation",
  • "id": "abe3f152-90b0-45cb-8776-4958bad0e0ef",
  • "attributes": {
    }
}

/v0/push/prefs/{endpointSid}

Get the user's push notification preferences

+

Request samples

Content type
application/json
{
  • "accountNumber": "12345678901",
  • "accountType": "Savings",
  • "financialInstitutionName": "PACIFIC PREMIER BANK",
  • "financialInstitutionRoutingNumber": "021000021"
}

Response samples

Content type
application/json
{
  • "type": "paymentInformation",
  • "id": "abe3f152-90b0-45cb-8776-4958bad0e0ef",
  • "attributes": {
    }
}

/v0/push/prefs/{endpointSid}

Get the user's push notification preferences

Authorizations:
Bearer
path Parameters
endpointSid
required
string

device endpointSid provided by the register endpoint

Responses

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/push/prefs/{endpointSid}

Set the user's push notification preferences

+

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/push/prefs/{endpointSid}

Set the user's push notification preferences

Authorizations:
Bearer
path Parameters
endpointSid
required
string

device endpointSid provided by the register endpoint

Request Body schema: application/json

Push notification preferences

preference
required
string
Enum: "appointment_reminders" "secure_message_alerts"
enabled
required
boolean

Responses

Request samples

Content type
application/json
{
  • "preference": "appointment_reminders",
  • "enabled": true
}

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/push/register

Allows a new app install to register to receive push notifications

+

Request samples

Content type
application/json
{
  • "preference": "appointment_reminders",
  • "enabled": true
}

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/push/register

Allows a new app install to register to receive push notifications

Authorizations:
Bearer
Request Body schema: application/json

Device information

deviceToken
required
string
osName
required
string
Enum: "ios" "android"
deviceName
string
appName
required
string
debug
boolean

Flag to switch between sandbox and non-sandbox app sid. Lower envs only

Responses

Request samples

Content type
application/json
{
  • "deviceToken": "740f4707bebcf74f9b7c25d48e3358945f6aa01da5ddb387462c7eaf61bb78ad",
  • "osName": "ios",
  • "deviceName": "Galaxy 8",
  • "appName": "va_mobile_app",
  • "debug": true
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/push/send

Allows client to trigger specified push notification to be sent to specified endpoint

+

Request samples

Content type
application/json
{
  • "deviceToken": "740f4707bebcf74f9b7c25d48e3358945f6aa01da5ddb387462c7eaf61bb78ad",
  • "osName": "ios",
  • "deviceName": "Galaxy 8",
  • "appName": "va_mobile_app",
  • "debug": true
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/push/send

Allows client to trigger specified push notification to be sent to specified endpoint

Authorizations:
Bearer
Request Body schema: application/json

Template id, endpoint sid, and personalization for template

appName
required
string
templateId
required
string
required
object
debug
boolean

Flag to switch between sandbox and non-sandbox app sid. Lower envs only

Responses

Request samples

Content type
application/json
{
  • "appName": "va_mobile_app",
  • "templateId": "0EF7C8C9390847D7B3B521426EFF5814",
  • "personalization": {
    },
  • "debug": true
}

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/user

Returns the user profile, including the user's addresses and the services the user has the requisite ids to access. Meta data for this endpoint returns all the services available in the API.

+

Request samples

Content type
application/json
{
  • "appName": "va_mobile_app",
  • "templateId": "0EF7C8C9390847D7B3B521426EFF5814",
  • "personalization": {
    },
  • "debug": true
}

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/user

Returns the user profile, including the user's addresses and the services the user has the requisite ids to access. Meta data for this endpoint returns all the services available in the API.

Authorizations:
Bearer
header Parameters
X-Key-Inflection
string
Example: camel

Allows the API to return camelCase keys rather than snake_case.

Responses

Response samples

Content type
application/json
{
  • "data": {
    },
  • "meta": {
    }
}

/v1/user

Returns the user profile, including the user's addresses and the services the user has the requisite ids to access. Meta data for this endpoint returns all the services available in the API. v1 includes LOGINGOV as login type.

+

Response samples

Content type
application/json
{
  • "data": {
    },
  • "meta": {
    }
}

/v1/user

Returns the user profile, including the user's addresses and the services the user has the requisite ids to access. Meta data for this endpoint returns all the services available in the API. v1 includes LOGINGOV as login type.

Authorizations:
Bearer
header Parameters
X-Key-Inflection
string
Example: camel

Allows the API to return camelCase keys rather than snake_case.

Responses

Response samples

Content type
application/json
{
  • "data": {
    },
  • "meta": {
    }
}

/v0/user/addresses

Deletes a user's address

+

Response samples

Content type
application/json
{
  • "data": {
    },
  • "meta": {
    }
}

/v0/user/addresses

Deletes a user's address

Authorizations:
Bearer
header Parameters
X-Key-Inflection
string
Example: camel

Allows the API to return camelCase keys rather than snake_case.

Request Body schema: application/json

A domestic, internation, or military address

id
required
integer
addressLine1
required
string
addressLine2
required
string, null
addressLine3
required
string, null
addressPou
required
string
Enum: "RESIDENCE/CHOICE" "CORRESPONDENCE"
addressType
required
string
Enum: "DOMESTIC" "INTERNATIONAL" "MILITARY"
city
required
string
countryCode
required
string
internationalPostalCode
required
string, null
province
required
string, null
stateCode
required
string
zipCode
required
string
zipCodeSuffix
required
string, null

Responses

Request samples

Content type
application/json
{
  • "id": 157032,
  • "addressLine1": "1493 Martin Luther King Rd",
  • "addressLine2": null,
  • "addressLine3": null,
  • "addressPou": "RESIDENCE/CHOICE",
  • "addressType": "DOMESTIC",
  • "city": "Fulton",
  • "countryCode": "US",
  • "internationalPostalCode": null,
  • "province": null,
  • "stateCode": "NY",
  • "zipCode": "97062",
  • "zipCodeSuffix": "1234"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/addresses

Creates a new residential or mailing address for a user. Calling this endpoint is the second step in adding a new address for a user. The first step is to call the address validation endpoint to check if an address is valid. If it is valid you'll receive a 'addressMetaData' object back with the addresses confidence score. This object should then be included along with the new address in the request body. If the user wishes to continue with an 'invalid' address then the 'validationKey' should be passed along with the new address in the request body. This lets the underlying service know that an invalid address be passed through.

+

Request samples

Content type
application/json
{
  • "id": 157032,
  • "addressLine1": "1493 Martin Luther King Rd",
  • "addressLine2": null,
  • "addressLine3": null,
  • "addressPou": "RESIDENCE/CHOICE",
  • "addressType": "DOMESTIC",
  • "city": "Fulton",
  • "countryCode": "US",
  • "internationalPostalCode": null,
  • "province": null,
  • "stateCode": "NY",
  • "zipCode": "97062",
  • "zipCodeSuffix": "1234"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/addresses

Creates a new residential or mailing address for a user. Calling this endpoint is the second step in adding a new address for a user. The first step is to call the address validation endpoint to check if an address is valid. If it is valid you'll receive a 'addressMetaData' object back with the addresses confidence score. This object should then be included along with the new address in the request body. If the user wishes to continue with an 'invalid' address then the 'validationKey' should be passed along with the new address in the request body. This lets the underlying service know that an invalid address be passed through.

Authorizations:
Bearer
header Parameters
X-Key-Inflection
string
Example: camel

Allows the API to return camelCase keys rather than snake_case.

Request Body schema: application/json

A domestic, internation, or military address

any

Responses

Request samples

Content type
application/json
Example
{
  • "addressLine1": "1493 Martin Luther King Rd",
  • "addressPou": "RESIDENCE/CHOICE",
  • "addressType": "DOMESTIC",
  • "city": "Fulton",
  • "countryCodeIso3": "USA",
  • "countryName": "United States",
  • "stateCode": "MS",
  • "validationKey": -1206619807,
  • "zipCode": "38843"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/addresses

Updates a user's residential or mailing address. Calling this endpoint is the second step in adding a new address for a user. The first step is to call the address validation endpoint to check if an address is valid. If it is valid you'll receive a 'addressMetaData' object back with the addresses confidence score. This object should then be included along with the new address in the request body. If the user wishes to continue with an 'invalid' address then the 'validationKey' should be passed along with the new address in the request body. This lets the underlying service know that an invalid address be passed through.

+

Request samples

Content type
application/json
Example
{
  • "addressLine1": "1493 Martin Luther King Rd",
  • "addressPou": "RESIDENCE/CHOICE",
  • "addressType": "DOMESTIC",
  • "city": "Fulton",
  • "countryCodeIso3": "USA",
  • "countryName": "United States",
  • "stateCode": "MS",
  • "validationKey": -1206619807,
  • "zipCode": "38843"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/addresses

Updates a user's residential or mailing address. Calling this endpoint is the second step in adding a new address for a user. The first step is to call the address validation endpoint to check if an address is valid. If it is valid you'll receive a 'addressMetaData' object back with the addresses confidence score. This object should then be included along with the new address in the request body. If the user wishes to continue with an 'invalid' address then the 'validationKey' should be passed along with the new address in the request body. This lets the underlying service know that an invalid address be passed through.

Authorizations:
Bearer
header Parameters
X-Key-Inflection
string
Example: camel

Allows the API to return camelCase keys rather than snake_case.

Request Body schema: application/json

A domestic, internation, or military address

any

Responses

Request samples

Content type
application/json
Example
{
  • "addressLine1": "1493 Martin Luther King Rd",
  • "addressPou": "RESIDENCE/CHOICE",
  • "addressType": "DOMESTIC",
  • "city": "Fulton",
  • "countryCodeIso3": "USA",
  • "countryName": "United States",
  • "id": 181513,
  • "stateCode": "MS",
  • "validationKey": -1206619807,
  • "zipCode": "38843"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/addresses/validate

Validates a residential or mailing address for a user. Calling this endpoint is the first step in adding a new address for a user. If the address is valid you'll receive a 'addressMetaData' object back with the addresses confidence score. This object should then be included along with the new address in the request body. If the user wishes to continue with an 'invalid' address then the 'validationKey' should be passed along with the new address in the request body. This lets the underlying service know that an invalid address be passed through.

+

Request samples

Content type
application/json
Example
{
  • "addressLine1": "1493 Martin Luther King Rd",
  • "addressPou": "RESIDENCE/CHOICE",
  • "addressType": "DOMESTIC",
  • "city": "Fulton",
  • "countryCodeIso3": "USA",
  • "countryName": "United States",
  • "id": 181513,
  • "stateCode": "MS",
  • "validationKey": -1206619807,
  • "zipCode": "38843"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/addresses/validate

Validates a residential or mailing address for a user. Calling this endpoint is the first step in adding a new address for a user. If the address is valid you'll receive a 'addressMetaData' object back with the addresses confidence score. This object should then be included along with the new address in the request body. If the user wishes to continue with an 'invalid' address then the 'validationKey' should be passed along with the new address in the request body. This lets the underlying service know that an invalid address be passed through.

Authorizations:
Bearer
header Parameters
X-Key-Inflection
string
Example: camel

Allows the API to return camelCase keys rather than snake_case.

Request Body schema: application/json

A domestic, internation, or military address

any

Responses

Request samples

Content type
application/json
{
  • "addressLine1": "51 W Weber Rd",
  • "addressPou": "CORRESPONDENCE",
  • "addressType": "DOMESTIC",
  • "city": "Columbus",
  • "countryCodeIso3": "USA",
  • "countryName": "United States",
  • "stateCode": "OH",
  • "type": "DOMESTIC",
  • "zipCode": "43202"
}

Response samples

Content type
application/json
Example
{
  • "data": [
    ],
  • "meta": {
    }
}

/v0/user/emails

Deletes a user's email address

+

Request samples

Content type
application/json
{
  • "addressLine1": "51 W Weber Rd",
  • "addressPou": "CORRESPONDENCE",
  • "addressType": "DOMESTIC",
  • "city": "Columbus",
  • "countryCodeIso3": "USA",
  • "countryName": "United States",
  • "stateCode": "OH",
  • "type": "DOMESTIC",
  • "zipCode": "43202"
}

Response samples

Content type
application/json
Example
{
  • "data": [
    ],
  • "meta": {
    }
}

/v0/user/emails

Deletes a user's email address

Authorizations:
Bearer
header Parameters
X-Key-Inflection
string
Example: camel

Allows the API to return camelCase keys rather than snake_case.

Request Body schema: application/json

The email address to delete

id
required
integer
emailAddress
required
string

Responses

Request samples

Content type
application/json
{
  • "emailAddress": "person42@example.com",
  • "id": "42,"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/emails

Creates a new email address

+

Request samples

Content type
application/json
{
  • "emailAddress": "person42@example.com",
  • "id": "42,"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/emails

Creates a new email address

Authorizations:
Bearer
header Parameters
X-Key-Inflection
string
Example: camel

Allows the API to return camelCase keys rather than snake_case.

Request Body schema: application/json

The new email address

any

Responses

Request samples

Content type
application/json
{
  • "emailAddress": "person42@example.com"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/emails

Updates a user's email address

+

Request samples

Content type
application/json
{
  • "emailAddress": "person42@example.com"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/emails

Updates a user's email address

Authorizations:
Bearer
header Parameters
X-Key-Inflection
string
Example: camel

Allows the API to return camelCase keys rather than snake_case.

Request Body schema: application/json

The new email address

id
required
integer
emailAddress
required
string

Responses

Request samples

Content type
application/json
{
  • "emailAddress": "person42@example.com",
  • "id": "42,"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/gender_identity

Updates a user's gender identity. Only id.me or login.gov users may use this

+

Request samples

Content type
application/json
{
  • "emailAddress": "person42@example.com",
  • "id": "42,"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/gender_identity

Updates a user's gender identity. Only id.me or login.gov users may use this

Authorizations:
Bearer
header Parameters
X-Key-Inflection
string
Example: camel

Allows the API to return camelCase keys rather than snake_case.

Request Body schema: application/json

The new gender identity key

code
required
string

Responses

Request samples

Content type
application/json
{
  • "code": "B"
}

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/user/gender_identity/edit

Retrieves a list of valid gender identity keys. Note that this endpoint does not use the camel case key inflection header like most other mobile endpoints to keep the keys upcase. Only id.me or login.gov users may use this

+

Request samples

Content type
application/json
{
  • "code": "B"
}

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/user/gender_identity/edit

Retrieves a list of valid gender identity keys. Note that this endpoint does not use the camel case key inflection header like most other mobile endpoints to keep the keys upcase. Only id.me or login.gov users may use this

Authorizations:
Bearer

Responses

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/logout

Logs the user out by revoking their access token from the IAM SSOe OAuth service and destroying the IAM user, user identity, and session objects from Redis.

+

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/logout

Logs the user out by revoking their access token from the IAM SSOe OAuth service and destroying the IAM user, user identity, and session objects from Redis.

Authorizations:
Bearer
header Parameters
X-Key-Inflection
string
Example: camel

Allows the API to return camelCase keys rather than snake_case.

Responses

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/user/preferred_name

Updates a user's preferred name. Only id.me or login.gov users may use this

+

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/user/preferred_name

Updates a user's preferred name. Only id.me or login.gov users may use this

Authorizations:
Bearer
header Parameters
X-Key-Inflection
string
Example: camel

Allows the API to return camelCase keys rather than snake_case.

Request Body schema: application/json

The new preferred name

text
required
string

Responses

Request samples

Content type
application/json
{
  • "text": "New Preferred Name"
}

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/user/phones

Deletes one of a user's phone numbers

+

Request samples

Content type
application/json
{
  • "text": "New Preferred Name"
}

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

/v0/user/phones

Deletes one of a user's phone numbers

Authorizations:
Bearer
header Parameters
X-Key-Inflection
string
Example: camel

Allows the API to return camelCase keys rather than snake_case.

Request Body schema: application/json

The phone number to delete

id
required
integer
areaCode
required
string
countryCode
required
string
phoneNumber
required
string
phoneType
required
string
Enum: "HOME" "FAX" "MOBILE" "WORK"
extension
required
string

Responses

Request samples

Content type
application/json
{
  • "id": 157032,
  • "areaCode": "704",
  • "countryCode": "1",
  • "phoneNumber": "7749069",
  • "phoneType": "HOME",
  • "extension": "4567"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/phones

Creats a phone number for a user

+

Request samples

Content type
application/json
{
  • "id": 157032,
  • "areaCode": "704",
  • "countryCode": "1",
  • "phoneNumber": "7749069",
  • "phoneType": "HOME",
  • "extension": "4567"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/phones

Creats a phone number for a user

Authorizations:
Bearer
header Parameters
X-Key-Inflection
string
Example: camel

Allows the API to return camelCase keys rather than snake_case.

Request Body schema: application/json

The new phone number

id
integer
areaCode
required
string
countryCode
required
string
phoneNumber
required
string
phoneType
required
string
Enum: "HOME" "FAX" "MOBILE" "WORK"
extension
required
string

Responses

Request samples

Content type
application/json
{
  • "id": 157032,
  • "areaCode": "704",
  • "countryCode": "1",
  • "phoneNumber": "7749069",
  • "phoneType": "HOME",
  • "extension": "4567"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/phones

Updates a user's phone number

+

Request samples

Content type
application/json
{
  • "id": 157032,
  • "areaCode": "704",
  • "countryCode": "1",
  • "phoneNumber": "7749069",
  • "phoneType": "HOME",
  • "extension": "4567"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v0/user/phones

Updates a user's phone number

Authorizations:
Bearer
header Parameters
X-Key-Inflection
string
Example: camel

Allows the API to return camelCase keys rather than snake_case.

Request Body schema: application/json

The new phone number

id
required
integer
areaCode
required
string
countryCode
required
string
phoneNumber
required
string
phoneType
required
string
Enum: "HOME" "FAX" "MOBILE" "WORK"
extension
required
string

Responses

Request samples

Content type
application/json
{
  • "id": 157032,
  • "areaCode": "704",
  • "countryCode": "1",
  • "phoneNumber": "7749069",
  • "phoneType": "HOME",
  • "extension": "4567"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v1/health/immunizations

Returns a paginated list of immunization records for given user

+

Request samples

Content type
application/json
{
  • "id": 157032,
  • "areaCode": "704",
  • "countryCode": "1",
  • "phoneNumber": "7749069",
  • "phoneType": "HOME",
  • "extension": "4567"
}

Response samples

Content type
application/json
{
  • "data": {
    }
}

/v1/health/immunizations

Returns a paginated list of immunization records for given user

Authorizations:
Bearer

Responses

Response samples

Content type
application/json
{
  • "data": [
    ],
  • "meta": {
    }
}
+

Response samples

Content type
application/json
{
  • "data": [
    ],
  • "meta": {
    }
}