Replace Card with Special Address
Learn how to replace a card with a special address in the Fleet Management Services API.
Step 1: Fetch your Bearer Token
Use the WEX-provided client_id and client_secret to request for your bearer token.
CURL
curl --location --request POST 'https://wmd.xc.wexonline.com/oauth-service/uaa/oauth/token' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--header 'Accept-Encoding: gzip,deflate,br' \
--data 'grant_type=client_credentials&client_secret=1234&client_id=some-client-id'
Step 2: Replace card
To successfully replace the card, ensure you have your card_idhandy. The card_idis required as a path parameter.
Note on shipping: This special address is a one-time use shipping address for this card only. It is not saved anywhere, so you must re-enter it for any future card orders.
CURL
curl --location --request POST 'https://wmd.xc.wexonline.com/fleet-service/v3/cards/replacements' \
--header 'accept-encoding: gzip,deflate,br' \
--header 'user_id: test-replace' \
--header 'content-type: application/json' \
--header 'authorization: Bearer' \
--data-raw '{
"replacement_reason": "Card Refresh",
"address_type": "Special",
"special_address": {
"address_line1": "Street 1",
"city": "City Z",
"contact_name": "Jon Doh",
"contact_phone_number": "1231231234",
"country_code": "US",
"postal_code": "29881",
"residential_indicator": false,
"state": "CA"
}
}'
Was this section helpful?
On this page
- Replace Card with Special Address