Wex Health and Benefits APIs

Sections

Theme switcher

Create Agreement Responses Agreement Response

Header Parameters

X-Request-Idstring

Optional correlation ID associated with the request, comprised of alphanumeric or hyphen characters up to 36 characters in length.

Idempotency-Keystring Required

Unique idempotency key (UUID v4). Repeated requests with the same key return the original response.

Authorizationstring

Body Parameters

agreement_idinteger

The ID of the agreement being accepted.

individual_idinteger

The individual (consumer) who accepted the agreement.

accepted_bystring | null

Identifies who accepted on the individual behalf.

response_textstring | null

Optional free-text captured at the point of acceptance.

Response

201
Object

Consent record created successfully.

Response Attributes

agreement_idinteger

Agreement identifier.

individual_idinteger

Individual identifier.

accept_datestring

UTC timestamp when the response was accepted.

response_codeinteger

Response code (1 = accepted).

accepted_bystring | null

Who accepted on the individual behalf.

response_textstring | null

Free-text captured at the point of acceptance.

400
Object

Request body is missing or contains invalid values.

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

Bearer token is missing or invalid.

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

Caller token does not resolve to a known customer shard.

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

The referenced agreementId does not exist within the caller scope.

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.

409
Object

A consent record for this individual and agreement already exists and is active.

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?

POST

/

Select
1

Response

Was this section helpful?