Wex Health and Benefits APIs

Sections

Theme switcher

Get Cards

Header Parameters

Authorizationstring

Query Parameters

consumer_idstring Required

The associated consumer identifier (Required).

providerstring

The issuing provider/bank of the card (Optional).

is_primaryboolean

Filter to retrieve cards by primary status: set to 'true' to retrieve only primary cards, 'false' for only dependent cards, or omit to retrieve all cards (primary and dependent).

page_sizeinteger

Number of items per page

Minimum
1
Maximum
100
Default value
20
pageinteger

Zero-based page number

Default value
0
last_four_digitsstring

Optional filter to search for cards by their last four digits. When provided, must be a valid four-digit numeric string (e.g., "0123").

Pattern
^[0-9]{4}$
includestring

Comma-separated list of optional fields to include in the response. Supported value: allowed_actions. When specified, each card in the response will include an allowed_actions object. When omitted, the standard card response is returned without the allowed_actions field.

Response

200
Object

Successful retrieval of the list of cards.

Response Attributes

itemsarray Required

List of card resources.

Max items
100

Show child attributes

paginationobject | null

Show child attributes

400
Object

Invalid request.

Response Attributes

typestring | null
titlestring | null
statusinteger | null
detailstring | null
instancestring | null
invalid_paramsarray | null

List of invalid parameters that caused the validation error.

Max items
10

Show child attributes

errorsobject

Human-readable validation error messages keyed by field name. Each key maps to one or more error message strings.

validation_errorsobject

Field-level validation errors keyed by field name. Each key maps to one or more structured error details.

401
Object

Unauthorized. Authentication failed.

Response Attributes

typestring | null
titlestring | null
statusinteger | null
detailstring | null
instancestring | null
invalid_paramsarray | null

List of invalid parameters that caused the validation error.

Max items
10

Show child attributes

errorsobject

Human-readable validation error messages keyed by field name. Each key maps to one or more error message strings.

validation_errorsobject

Field-level validation errors keyed by field name. Each key maps to one or more structured error details.

403
Object

Forbidden. User does not have permission to access card resources for the specified consumer.

Response Attributes

typestring | null
titlestring | null
statusinteger | null
detailstring | null
instancestring | null
invalid_paramsarray | null

List of invalid parameters that caused the validation error.

Max items
10

Show child attributes

errorsobject

Human-readable validation error messages keyed by field name. Each key maps to one or more error message strings.

validation_errorsobject

Field-level validation errors keyed by field name. Each key maps to one or more structured error details.

404
Object

Consumer not found.

Response Attributes

typestring | null
titlestring | null
statusinteger | null
detailstring | null
instancestring | null
invalid_paramsarray | null

List of invalid parameters that caused the validation error.

Max items
10

Show child attributes

errorsobject

Human-readable validation error messages keyed by field name. Each key maps to one or more error message strings.

validation_errorsobject

Field-level validation errors keyed by field name. Each key maps to one or more structured error details.

500
Object

Internal server error. An unexpected error occurred while processing the request.

Response Attributes

typestring | null
titlestring | null
statusinteger | null
detailstring | null
instancestring | null
invalid_paramsarray | null

List of invalid parameters that caused the validation error.

Max items
10

Show child attributes

errorsobject

Human-readable validation error messages keyed by field name. Each key maps to one or more error message strings.

validation_errorsobject

Field-level validation errors keyed by field name. Each key maps to one or more structured error details.

default
Object

Unexpected error

Response Attributes

typestring | null
titlestring | null
statusinteger | null
detailstring | null
instancestring | null
invalid_paramsarray | null

List of invalid parameters that caused the validation error.

Max items
10

Show child attributes

errorsobject

Human-readable validation error messages keyed by field name. Each key maps to one or more error message strings.

validation_errorsobject

Field-level validation errors keyed by field name. Each key maps to one or more structured error details.

Was this section helpful?

GET

/

Select
1

Response

Was this section helpful?