Skip to main content
POST
/
2025-06-09
/
wallets
Create Wallet
curl --request POST \
  --url https://staging.crossmint.com/api/2025-06-09/wallets \
  --header 'Content-Type: application/json' \
  --header 'X-API-KEY: <x-api-key>' \
  --data '
{
  "chainType": "evm",
  "config": {
    "adminSigner": {
      "type": "external-wallet",
      "address": "0x1234567890123456789012345678901234567890"
    },
    "delegatedSigners": [
      {
        "signer": {
          "type": "passkey",
          "id": "cWtP7gmZbd98HbKUuGXx5Q",
          "name": "hgranger",
          "publicKey": {
            "x": "38035223810536273945556366218149112558607829411547667975304293530457502824247",
            "y": "91117823763706733837104303008228095481082989039135234750508288790583476078729"
          }
        },
        "scopes": {
          "type": "transfer",
          "tokenLocator": "base-sepolia:usdc",
          "spendingLimit": {
            "amount": "10",
            "interval": 86400
          }
        },
        "expiresAt": "2023-11-07T05:31:56Z"
      }
    ],
    "creationSeed": "0"
  },
  "type": "smart",
  "owner": "<string>",
  "alias": "my-usdc-wallet"
}
'
import requests

url = "https://staging.crossmint.com/api/2025-06-09/wallets"

payload = {
    "chainType": "evm",
    "config": {
        "adminSigner": {
            "type": "external-wallet",
            "address": "0x1234567890123456789012345678901234567890"
        },
        "delegatedSigners": [
            {
                "signer": {
                    "type": "passkey",
                    "id": "cWtP7gmZbd98HbKUuGXx5Q",
                    "name": "hgranger",
                    "publicKey": {
                        "x": "38035223810536273945556366218149112558607829411547667975304293530457502824247",
                        "y": "91117823763706733837104303008228095481082989039135234750508288790583476078729"
                    }
                },
                "scopes": {
                    "type": "transfer",
                    "tokenLocator": "base-sepolia:usdc",
                    "spendingLimit": {
                        "amount": "10",
                        "interval": 86400
                    }
                },
                "expiresAt": "2023-11-07T05:31:56Z"
            }
        ],
        "creationSeed": "0"
    },
    "type": "smart",
    "owner": "<string>",
    "alias": "my-usdc-wallet"
}
headers = {
    "X-API-KEY": "<x-api-key>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
  method: 'POST',
  headers: {'X-API-KEY': '<x-api-key>', 'Content-Type': 'application/json'},
  body: JSON.stringify({
    chainType: 'evm',
    config: {
      adminSigner: {type: 'external-wallet', address: '0x1234567890123456789012345678901234567890'},
      delegatedSigners: [
        {
          signer: {
            type: 'passkey',
            id: 'cWtP7gmZbd98HbKUuGXx5Q',
            name: 'hgranger',
            publicKey: {
              x: '38035223810536273945556366218149112558607829411547667975304293530457502824247',
              y: '91117823763706733837104303008228095481082989039135234750508288790583476078729'
            }
          },
          scopes: {
            type: 'transfer',
            tokenLocator: 'base-sepolia:usdc',
            spendingLimit: {amount: '10', interval: 86400}
          },
          expiresAt: '2023-11-07T05:31:56Z'
        }
      ],
      creationSeed: '0'
    },
    type: 'smart',
    owner: '<string>',
    alias: 'my-usdc-wallet'
  })
};

fetch('https://staging.crossmint.com/api/2025-06-09/wallets', 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://staging.crossmint.com/api/2025-06-09/wallets",
  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([
    'chainType' => 'evm',
    'config' => [
        'adminSigner' => [
                'type' => 'external-wallet',
                'address' => '0x1234567890123456789012345678901234567890'
        ],
        'delegatedSigners' => [
                [
                                'signer' => [
                                                                'type' => 'passkey',
                                                                'id' => 'cWtP7gmZbd98HbKUuGXx5Q',
                                                                'name' => 'hgranger',
                                                                'publicKey' => [
                                                                                                                                'x' => '38035223810536273945556366218149112558607829411547667975304293530457502824247',
                                                                                                                                'y' => '91117823763706733837104303008228095481082989039135234750508288790583476078729'
                                                                ]
                                ],
                                'scopes' => [
                                                                'type' => 'transfer',
                                                                'tokenLocator' => 'base-sepolia:usdc',
                                                                'spendingLimit' => [
                                                                                                                                'amount' => '10',
                                                                                                                                'interval' => 86400
                                                                ]
                                ],
                                'expiresAt' => '2023-11-07T05:31:56Z'
                ]
        ],
        'creationSeed' => '0'
    ],
    'type' => 'smart',
    'owner' => '<string>',
    'alias' => 'my-usdc-wallet'
  ]),
  CURLOPT_HTTPHEADER => [
    "Content-Type: application/json",
    "X-API-KEY: <x-api-key>"
  ],
]);

$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://staging.crossmint.com/api/2025-06-09/wallets"

	payload := strings.NewReader("{\n  \"chainType\": \"evm\",\n  \"config\": {\n    \"adminSigner\": {\n      \"type\": \"external-wallet\",\n      \"address\": \"0x1234567890123456789012345678901234567890\"\n    },\n    \"delegatedSigners\": [\n      {\n        \"signer\": {\n          \"type\": \"passkey\",\n          \"id\": \"cWtP7gmZbd98HbKUuGXx5Q\",\n          \"name\": \"hgranger\",\n          \"publicKey\": {\n            \"x\": \"38035223810536273945556366218149112558607829411547667975304293530457502824247\",\n            \"y\": \"91117823763706733837104303008228095481082989039135234750508288790583476078729\"\n          }\n        },\n        \"scopes\": {\n          \"type\": \"transfer\",\n          \"tokenLocator\": \"base-sepolia:usdc\",\n          \"spendingLimit\": {\n            \"amount\": \"10\",\n            \"interval\": 86400\n          }\n        },\n        \"expiresAt\": \"2023-11-07T05:31:56Z\"\n      }\n    ],\n    \"creationSeed\": \"0\"\n  },\n  \"type\": \"smart\",\n  \"owner\": \"<string>\",\n  \"alias\": \"my-usdc-wallet\"\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("X-API-KEY", "<x-api-key>")
	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://staging.crossmint.com/api/2025-06-09/wallets")
  .header("X-API-KEY", "<x-api-key>")
  .header("Content-Type", "application/json")
  .body("{\n  \"chainType\": \"evm\",\n  \"config\": {\n    \"adminSigner\": {\n      \"type\": \"external-wallet\",\n      \"address\": \"0x1234567890123456789012345678901234567890\"\n    },\n    \"delegatedSigners\": [\n      {\n        \"signer\": {\n          \"type\": \"passkey\",\n          \"id\": \"cWtP7gmZbd98HbKUuGXx5Q\",\n          \"name\": \"hgranger\",\n          \"publicKey\": {\n            \"x\": \"38035223810536273945556366218149112558607829411547667975304293530457502824247\",\n            \"y\": \"91117823763706733837104303008228095481082989039135234750508288790583476078729\"\n          }\n        },\n        \"scopes\": {\n          \"type\": \"transfer\",\n          \"tokenLocator\": \"base-sepolia:usdc\",\n          \"spendingLimit\": {\n            \"amount\": \"10\",\n            \"interval\": 86400\n          }\n        },\n        \"expiresAt\": \"2023-11-07T05:31:56Z\"\n      }\n    ],\n    \"creationSeed\": \"0\"\n  },\n  \"type\": \"smart\",\n  \"owner\": \"<string>\",\n  \"alias\": \"my-usdc-wallet\"\n}")
  .asString();
require 'uri'
require 'net/http'

url = URI("https://staging.crossmint.com/api/2025-06-09/wallets")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["X-API-KEY"] = '<x-api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"chainType\": \"evm\",\n  \"config\": {\n    \"adminSigner\": {\n      \"type\": \"external-wallet\",\n      \"address\": \"0x1234567890123456789012345678901234567890\"\n    },\n    \"delegatedSigners\": [\n      {\n        \"signer\": {\n          \"type\": \"passkey\",\n          \"id\": \"cWtP7gmZbd98HbKUuGXx5Q\",\n          \"name\": \"hgranger\",\n          \"publicKey\": {\n            \"x\": \"38035223810536273945556366218149112558607829411547667975304293530457502824247\",\n            \"y\": \"91117823763706733837104303008228095481082989039135234750508288790583476078729\"\n          }\n        },\n        \"scopes\": {\n          \"type\": \"transfer\",\n          \"tokenLocator\": \"base-sepolia:usdc\",\n          \"spendingLimit\": {\n            \"amount\": \"10\",\n            \"interval\": 86400\n          }\n        },\n        \"expiresAt\": \"2023-11-07T05:31:56Z\"\n      }\n    ],\n    \"creationSeed\": \"0\"\n  },\n  \"type\": \"smart\",\n  \"owner\": \"<string>\",\n  \"alias\": \"my-usdc-wallet\"\n}"

response = http.request(request)
puts response.read_body
{
  "chainType": "evm",
  "type": "smart",
  "address": "0x1234567890123456789012345678901234567890",
  "config": {
    "adminSigner": {
      "type": "external-wallet",
      "address": "<string>",
      "locator": "<string>"
    },
    "delegatedSigners": [
      {
        "type": "external-wallet",
        "address": "<string>",
        "locator": "<string>",
        "scopes": [
          "<unknown>"
        ],
        "expiresAt": "<string>",
        "chains": {}
      }
    ]
  },
  "owner": "email:test@example.com",
  "createdAt": 123,
  "alias": "my-usdc-wallet"
}
{
  "error": true,
  "message": "<error message>"
}

Headers

X-API-KEY
string
required

API key required for authentication

x-idempotency-key
string

Unique key to prevent duplicate wallet creation

Body

application/json

EVM smart wallet creation input

chainType
enum<string>
required
Available options:
evm
config
object
required
type
enum<string>
default:smart
Available options:
smart
owner
string
alias
string

The wallet alias

Example:

"my-usdc-wallet"

Response

Returns an existing wallet (200) if one already exists for the provided owner or idempotencyKey, or creates and returns a new wallet (201). The response includes the wallet details and whether it was newly created.

chainType
enum<string>
required

The blockchain type of the wallet

Available options:
evm
type
enum<string>
required

The wallet type (smart or mpc)

Available options:
smart,
mpc
Example:

"smart"

address
string
required

The onchain address of the wallet

Example:

"0x1234567890123456789012345678901234567890"

config
object

EVM wallet type specific configuration settings

owner
string

The user that owns this wallet in format :

Example:

"email:test@example.com"

createdAt

ISO timestamp of when the wallet was created

alias
string

The wallet alias

Example:

"my-usdc-wallet"