curl --request POST \
--url https://sandbox-api.borderless.xyz/v1/mastercard/crypto-credential/accounts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"accountAlias": "user@example.com",
"aliasType": "Email",
"status": "Active",
"country": "US",
"statusReasonInformation": [
{
"reasonCode": "ALIAS_UNDER_INVESTIGATION",
"description": "The alias is currently under investigation"
}
]
}
'import requests
url = "https://sandbox-api.borderless.xyz/v1/mastercard/crypto-credential/accounts"
payload = {
"accountAlias": "user@example.com",
"aliasType": "Email",
"status": "Active",
"country": "US",
"statusReasonInformation": [
{
"reasonCode": "ALIAS_UNDER_INVESTIGATION",
"description": "The alias is currently under investigation"
}
]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
accountAlias: 'user@example.com',
aliasType: 'Email',
status: 'Active',
country: 'US',
statusReasonInformation: [
{
reasonCode: 'ALIAS_UNDER_INVESTIGATION',
description: 'The alias is currently under investigation'
}
]
})
};
fetch('https://sandbox-api.borderless.xyz/v1/mastercard/crypto-credential/accounts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://sandbox-api.borderless.xyz/v1/mastercard/crypto-credential/accounts",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'accountAlias' => 'user@example.com',
'aliasType' => 'Email',
'status' => 'Active',
'country' => 'US',
'statusReasonInformation' => [
[
'reasonCode' => 'ALIAS_UNDER_INVESTIGATION',
'description' => 'The alias is currently under investigation'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://sandbox-api.borderless.xyz/v1/mastercard/crypto-credential/accounts"
payload := strings.NewReader("{\n \"accountAlias\": \"user@example.com\",\n \"aliasType\": \"Email\",\n \"status\": \"Active\",\n \"country\": \"US\",\n \"statusReasonInformation\": [\n {\n \"reasonCode\": \"ALIAS_UNDER_INVESTIGATION\",\n \"description\": \"The alias is currently under investigation\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://sandbox-api.borderless.xyz/v1/mastercard/crypto-credential/accounts")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"accountAlias\": \"user@example.com\",\n \"aliasType\": \"Email\",\n \"status\": \"Active\",\n \"country\": \"US\",\n \"statusReasonInformation\": [\n {\n \"reasonCode\": \"ALIAS_UNDER_INVESTIGATION\",\n \"description\": \"The alias is currently under investigation\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox-api.borderless.xyz/v1/mastercard/crypto-credential/accounts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"accountAlias\": \"user@example.com\",\n \"aliasType\": \"Email\",\n \"status\": \"Active\",\n \"country\": \"US\",\n \"statusReasonInformation\": [\n {\n \"reasonCode\": \"ALIAS_UNDER_INVESTIGATION\",\n \"description\": \"The alias is currently under investigation\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"accountAlias": "<string>",
"status": "Active",
"aliasType": "Email",
"country": "AF",
"statusReasonInformation": [
{
"reasonCode": "<string>",
"description": "<string>"
}
],
"additionalAccountAliases": [
{
"accountAlias": "<string>",
"aliasType": "Email",
"createdAt": "<string>",
"updatedAt": "<string>"
}
],
"cryptoAddresses": [
{
"id": "<string>",
"accountAlias": "<string>",
"status": "Active",
"address": "<string>",
"asset": "POL",
"createdAt": "<string>",
"updatedAt": "<string>"
}
],
"createdAt": "<string>",
"updatedAt": "<string>"
}Create a Crypto Credential account
Registers an alias with Mastercard Crypto Credential so it can receive crypto. Only accountAlias is required. Mastercard derives a domain name alias from it and returns it under additionalAccountAliases — that derived alias, not the one you submitted, is what other participants resolve. Registering an alias that already exists fails.
curl --request POST \
--url https://sandbox-api.borderless.xyz/v1/mastercard/crypto-credential/accounts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"accountAlias": "user@example.com",
"aliasType": "Email",
"status": "Active",
"country": "US",
"statusReasonInformation": [
{
"reasonCode": "ALIAS_UNDER_INVESTIGATION",
"description": "The alias is currently under investigation"
}
]
}
'import requests
url = "https://sandbox-api.borderless.xyz/v1/mastercard/crypto-credential/accounts"
payload = {
"accountAlias": "user@example.com",
"aliasType": "Email",
"status": "Active",
"country": "US",
"statusReasonInformation": [
{
"reasonCode": "ALIAS_UNDER_INVESTIGATION",
"description": "The alias is currently under investigation"
}
]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
accountAlias: 'user@example.com',
aliasType: 'Email',
status: 'Active',
country: 'US',
statusReasonInformation: [
{
reasonCode: 'ALIAS_UNDER_INVESTIGATION',
description: 'The alias is currently under investigation'
}
]
})
};
fetch('https://sandbox-api.borderless.xyz/v1/mastercard/crypto-credential/accounts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://sandbox-api.borderless.xyz/v1/mastercard/crypto-credential/accounts",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'accountAlias' => 'user@example.com',
'aliasType' => 'Email',
'status' => 'Active',
'country' => 'US',
'statusReasonInformation' => [
[
'reasonCode' => 'ALIAS_UNDER_INVESTIGATION',
'description' => 'The alias is currently under investigation'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://sandbox-api.borderless.xyz/v1/mastercard/crypto-credential/accounts"
payload := strings.NewReader("{\n \"accountAlias\": \"user@example.com\",\n \"aliasType\": \"Email\",\n \"status\": \"Active\",\n \"country\": \"US\",\n \"statusReasonInformation\": [\n {\n \"reasonCode\": \"ALIAS_UNDER_INVESTIGATION\",\n \"description\": \"The alias is currently under investigation\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://sandbox-api.borderless.xyz/v1/mastercard/crypto-credential/accounts")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"accountAlias\": \"user@example.com\",\n \"aliasType\": \"Email\",\n \"status\": \"Active\",\n \"country\": \"US\",\n \"statusReasonInformation\": [\n {\n \"reasonCode\": \"ALIAS_UNDER_INVESTIGATION\",\n \"description\": \"The alias is currently under investigation\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox-api.borderless.xyz/v1/mastercard/crypto-credential/accounts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"accountAlias\": \"user@example.com\",\n \"aliasType\": \"Email\",\n \"status\": \"Active\",\n \"country\": \"US\",\n \"statusReasonInformation\": [\n {\n \"reasonCode\": \"ALIAS_UNDER_INVESTIGATION\",\n \"description\": \"The alias is currently under investigation\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"accountAlias": "<string>",
"status": "Active",
"aliasType": "Email",
"country": "AF",
"statusReasonInformation": [
{
"reasonCode": "<string>",
"description": "<string>"
}
],
"additionalAccountAliases": [
{
"accountAlias": "<string>",
"aliasType": "Email",
"createdAt": "<string>",
"updatedAt": "<string>"
}
],
"cryptoAddresses": [
{
"id": "<string>",
"accountAlias": "<string>",
"status": "Active",
"address": "<string>",
"asset": "POL",
"createdAt": "<string>",
"updatedAt": "<string>"
}
],
"createdAt": "<string>",
"updatedAt": "<string>"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
The alias that identifies the account. This is the only field required to create an account, and it is how every later request addresses it.
255"user@example.com"
The kind of value accountAlias holds.
Email, PhoneNumber, DomainName "Email"
The status of the account. A suspended account stops resolving in alias lookups until it is set back to Active.
Active, Suspended, Decommissioned "Active"
The country the account belongs to, in ISO-3166-2 format. See ISO-3166-2 documentation.
AF, AL, DZ, AS, AD, AO, AI, AQ, AG, AR, AM, AW, AU, AT, AZ, BS, BH, BD, BB, BY, BE, BZ, BJ, BM, BT, BO, BQ, BA, BW, BV, BR, IO, BN, BG, BF, BI, CV, KH, CM, CA, KY, CF, TD, CL, CN, CX, CC, CO, KM, CD, CG, CK, CR, HR, CU, CW, CY, CZ, CI, DK, DJ, DM, DO, EC, EG, SV, GQ, ER, EE, SZ, ET, FK, FO, FJ, FI, FR, GF, PF, TF, GA, GM, GE, DE, GH, GI, GR, GL, GD, GP, GU, GT, GG, GN, GW, GY, HT, HM, VA, HN, HK, HU, IS, IN, ID, IR, IQ, IE, IM, IL, IT, JM, JP, JE, JO, KZ, KE, KI, KP, KR, KW, KG, LA, LV, LB, LS, LR, LY, LI, LT, LU, MO, MG, MW, MY, MV, ML, MT, MH, MQ, MR, MU, YT, MX, FM, MD, MC, MN, ME, MS, MA, MZ, MM, NA, NR, NP, NL, NC, NZ, NI, NE, NG, NU, NF, MP, NO, OM, PK, PW, PS, PA, PG, PY, PE, PH, PN, PL, PT, PR, QA, MK, RO, RU, RW, RE, BL, SH, KN, LC, MF, PM, VC, WS, SM, ST, SA, SN, RS, SC, SL, SG, SX, SK, SI, SB, SO, ZA, GS, SS, ES, LK, SD, SR, SJ, SE, CH, SY, TW, TJ, TZ, TH, TL, TG, TK, TO, TT, TN, TR, TM, TC, TV, UG, UA, AE, GB, UM, US, UY, UZ, VU, VE, VN, VG, VI, WF, EH, YE, ZM, ZW, AX, ZZ "US"
Why the account was put into the requested status. Only meaningful when status is sent as well.
10Show child attributes
Show child attributes
Response
Account created successfully.
The alias the account was registered under.
The status of the account. Only an active account resolves in alias lookups.
Active, Suspended, Decommissioned The kind of value accountAlias holds.
Email, PhoneNumber, DomainName The country the account belongs to, in ISO-3166-2 format. See ISO-3166-2 documentation.
AF, AL, DZ, AS, AD, AO, AI, AQ, AG, AR, AM, AW, AU, AT, AZ, BS, BH, BD, BB, BY, BE, BZ, BJ, BM, BT, BO, BQ, BA, BW, BV, BR, IO, BN, BG, BF, BI, CV, KH, CM, CA, KY, CF, TD, CL, CN, CX, CC, CO, KM, CD, CG, CK, CR, HR, CU, CW, CY, CZ, CI, DK, DJ, DM, DO, EC, EG, SV, GQ, ER, EE, SZ, ET, FK, FO, FJ, FI, FR, GF, PF, TF, GA, GM, GE, DE, GH, GI, GR, GL, GD, GP, GU, GT, GG, GN, GW, GY, HT, HM, VA, HN, HK, HU, IS, IN, ID, IR, IQ, IE, IM, IL, IT, JM, JP, JE, JO, KZ, KE, KI, KP, KR, KW, KG, LA, LV, LB, LS, LR, LY, LI, LT, LU, MO, MG, MW, MY, MV, ML, MT, MH, MQ, MR, MU, YT, MX, FM, MD, MC, MN, ME, MS, MA, MZ, MM, NA, NR, NP, NL, NC, NZ, NI, NE, NG, NU, NF, MP, NO, OM, PK, PW, PS, PA, PG, PY, PE, PH, PN, PL, PT, PR, QA, MK, RO, RU, RW, RE, BL, SH, KN, LC, MF, PM, VC, WS, SM, ST, SA, SN, RS, SC, SL, SG, SX, SK, SI, SB, SO, ZA, GS, SS, ES, LK, SD, SR, SJ, SE, CH, SY, TW, TJ, TZ, TH, TL, TG, TK, TO, TT, TN, TR, TM, TC, TV, UG, UA, AE, GB, UM, US, UY, UZ, VU, VE, VN, VG, VI, WF, EH, YE, ZM, ZW, AX, ZZ Why the account is in its current status.
Show child attributes
Show child attributes
Other aliases that resolve to this account, including the domain name alias Mastercard derives on creation. That derived alias is the one other participants resolve.
Show child attributes
Show child attributes
Blockchain addresses registered under this account, one per asset.
Show child attributes
Show child attributes
When the account was created.
When the account was last updated.
Was this page helpful?