v2

latestOpenAPI 3.0.12026-07-26334612609.5 KB
Users

Creates many new users

post/environments/{environmentId}/users/bulk

Path parameters

environmentIdstring required
Example:95b11417-f18f-457f-8804-68e361f9164f

ID of the environment

Query parameters

upsertboolean

Update user data if user already exists

Request body

aliasstring
firstNamestring
lastNamestring
jobTitlestring
phoneNumberstring
metadataobject
mfaBackupCodeAcknowledgement'pending' | 'complete' nullable
tShirtSizestring
teamstring
policiesConsentboolean
countrystring nullable

Standard ISO 3166-1 alpha-2 two-letter country code

usernamestring nullable

Alphanumeric with slugs and underscores username

btcWalletstring nullable

BTC wallet address

kdaWalletstring nullable

KDA wallet address

ltcWalletstring nullable

LTC wallet address

ckbWalletstring nullable

CKB wallet address

kasWalletstring nullable

KAS wallet address

dogeWalletstring nullable

DOGE wallet address

emailNotificationboolean
discordNotificationboolean
newsletterNotificationboolean
emailVerifiedAtstring date-time

When provided, the user email will be marked as verified in our system and the user will be allowed to sign in with that email. When social is enabled and the social provider has a verified email, we will automatically associate that social with the existing user.

emailstring

If email is trusted and verified, please provide a emailVerifiedAt timestamp. This will ensure that a user signing in with this email can access the correctly-created user account.

Example request

[
  {
    "alias": "An example name",
    "firstName": "An example name",
    "lastName": "An example name",
    "jobTitle": "An example name",
    "phoneNumber": "An example name",
    "tShirtSize": "An example name",
    "team": "An example name",
    "country": "US",
    "username": "johndoe",
    "btcWallet": "3FZbgi29cpjq2GjdwV8eyHuJJnkLtktZc5",
    "kdaWallet": "k:0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF",
    "ltcWallet": "LUttH43tQ4x4qniCKr1Rqo8ESeXFPdv9ax",
    "ckbWallet": "ckt1q9876543210abcdefghijklmnopqrstuvwxyz",
    "kasWallet": "kaspa:qrelgny7sr3vahq69yykxx36m65gvmhryxrlwngfzgu8xkdslum2yxjp3ap8m",
    "dogeWallet": "DPcy35vmuk8GXcfu1vgFFEeij3BuYYJQKB",
    "email": "hello-world@foobar.com",
    "wallets": [
      {
        "publicWalletAddress": "0xbF394748301603f18d953C90F0b087CBEC0E1834",
        "walletName": "An example name"
      }
    ],
    "oauthAccounts": [
      {
        "accountId": "An example name",
        "emails": [
          "hello-world@foobar.com"
        ],
        "displayName": "An example name",
        "username": "An example name"
      }
    ]
  }
]

Response

Successfully completed bulk user request

totalinteger

Example response

{
  "created": [
    {
      "id": "95b11417-f18f-457f-8804-68e361f9164f",
      "projectEnvironmentId": "95b11417-f18f-457f-8804-68e361f9164f",
      "verifiedCredentials": [
        {
          "address": "0xbF394748301603f18d953C90F0b087CBEC0E1834",
          "refId": "95b11417-f18f-457f-8804-68e361f9164f",
          "signerRefId": "95b11417-f18f-457f-8804-68e361f9164f",
          "id": "95b11417-f18f-457f-8804-68e361f9164f",
          "wallet_properties": {
            "turnkeySubOrganizationId": "95b11417-f18f-457f-8804-68e361f9164f",
            "turnkeyPrivateKeyId": "95b11417-f18f-457f-8804-68e361f9164f",
            "turnkeyHDWalletId": "95b11417-f18f-457f-8804-68e361f9164f",
            "turnkeyUserId": "95b11417-f18f-457f-8804-68e361f9164f"
          },
          "phoneNumber": "9171113333",
          "phoneCountryCode": "1",
          "isoCountryCode": "US",
          "previous_users": [
            "95b11417-f18f-457f-8804-68e361f9164f"
          ]
        }
      ],
      "lastVerifiedCredentialId": "95b11417-f18f-457f-8804-68e361f9164f",
      "sessionId": "95b11417-f18f-457f-8804-68e361f9164f",
      "alias": "An example name",
      "country": "US",
      "firstName": "An example name",
      "jobTitle": "An example name",
      "lastName": "An example name",
      "tShirtSize": "An example name",
      "team": "An example name",
      "username": "An example name",
      "scope": "superuser marketing operations",
      "missingFields": [
        {
          "validationRules": {
            "regex": "^0x",
            "validOptions": [
              {
                "label": "small"
              },
              {
                "label": "medium"
              },
              {
                "label": "large"
              }
            ],
            "checkboxText": "Agree to the terms and conditions"
          }
        }
      ],
      "sessions": [
        {
          "id": "95b11417-f18f-457f-8804-68e361f9164f"
        }
      ],
      "wallets": [
        {
          "id": "95b11417-f18f-457f-8804-68e361f9164f",
          "name": "An example name",
          "publicKey": "0xbF394748301603f18d953C90F0b087CBEC0E1834",
          "properties": {
            "turnkeySubOrganizationId": "95b11417-f18f-457f-8804-68e361f9164f",
            "turnkeyPrivateKeyId": "95b11417-f18f-457f-8804-68e361f9164f",
            "turnkeyHDWalletId": "95b11417-f18f-457f-8804-68e361f9164f",
            "turnkeyUserId": "95b11417-f18f-457f-8804-68e361f9164f"
          }
        }
      ],
      "chainalysisChecks": [
        {
          "id": "95b11417-f18f-457f-8804-68e361f9164f",
          "walletPublicKey": "0xbF394748301603f18d953C90F0b087CBEC0E1834"
        }
      ],
      "oauthAccounts": [
        {
          "id": "95b11417-f18f-457f-8804-68e361f9164f"
        }
      ],
      "mfaDevices": [
        {
          "id": "95b11417-f18f-457f-8804-68e361f9164f"
        }
      ]
    }
  ],
  "updated": [
    {
      "id": "95b11417-f18f-457f-8804-68e361f9164f",
      "projectEnvironmentId": "95b11417-f18f-457f-8804-68e361f9164f",
      "verifiedCredentials": [
        {
          "address": "0xbF394748301603f18d953C90F0b087CBEC0E1834",
          "refId": "95b11417-f18f-457f-8804-68e361f9164f",
          "signerRefId": "95b11417-f18f-457f-8804-68e361f9164f",
          "id": "95b11417-f18f-457f-8804-68e361f9164f",
          "wallet_properties": {
            "turnkeySubOrganizationId": "95b11417-f18f-457f-8804-68e361f9164f",
            "turnkeyPrivateKeyId": "95b11417-f18f-457f-8804-68e361f9164f",
            "turnkeyHDWalletId": "95b11417-f18f-457f-8804-68e361f9164f",
            "turnkeyUserId": "95b11417-f18f-457f-8804-68e361f9164f"
          },
          "phoneNumber": "9171113333",
          "phoneCountryCode": "1",
          "isoCountryCode": "US",
          "previous_users": [
            "95b11417-f18f-457f-8804-68e361f9164f"
          ]
        }
      ],
      "lastVerifiedCredentialId": "95b11417-f18f-457f-8804-68e361f9164f",
      "sessionId": "95b11417-f18f-457f-8804-68e361f9164f",
      "alias": "An example name",
      "country": "US",
      "firstName": "An example name",
      "jobTitle": "An example name",
      "lastName": "An example name",
      "tShirtSize": "An example name",
      "team": "An example name",
      "username": "An example name",
      "scope": "superuser marketing operations",
      "missingFields": [
        {
          "validationRules": {
            "regex": "^0x",
            "validOptions": [
              {
                "label": "small"
              },
              {
                "label": "medium"
              },
              {
                "label": "large"
              }
            ],
            "checkboxText": "Agree to the terms and conditions"
          }
        }
      ],
      "sessions": [
        {
          "id": "95b11417-f18f-457f-8804-68e361f9164f"
        }
      ],
      "wallets": [
        {
          "id": "95b11417-f18f-457f-8804-68e361f9164f",
          "name": "An example name",
          "publicKey": "0xbF394748301603f18d953C90F0b087CBEC0E1834",
          "properties": {
            "turnkeySubOrganizationId": "95b11417-f18f-457f-8804-68e361f9164f",
            "turnkeyPrivateKeyId": "95b11417-f18f-457f-8804-68e361f9164f",
            "turnkeyHDWalletId": "95b11417-f18f-457f-8804-68e361f9164f",
            "turnkeyUserId": "95b11417-f18f-457f-8804-68e361f9164f"
          }
        }
      ],
      "chainalysisChecks": [
        {
          "id": "95b11417-f18f-457f-8804-68e361f9164f",
          "walletPublicKey": "0xbF394748301603f18d953C90F0b087CBEC0E1834"
        }
      ],
      "oauthAccounts": [
        {
          "id": "95b11417-f18f-457f-8804-68e361f9164f"
        }
      ],
      "mfaDevices": [
        {
          "id": "95b11417-f18f-457f-8804-68e361f9164f"
        }
      ]
    }
  ],
  "failed": [
    {
      "user": {
        "id": "95b11417-f18f-457f-8804-68e361f9164f",
        "projectEnvironmentId": "95b11417-f18f-457f-8804-68e361f9164f",
        "verifiedCredentials": [
          {
            "address": "0xbF394748301603f18d953C90F0b087CBEC0E1834",
            "refId": "95b11417-f18f-457f-8804-68e361f9164f",
            "signerRefId": "95b11417-f18f-457f-8804-68e361f9164f",
            "id": "95b11417-f18f-457f-8804-68e361f9164f",
            "wallet_properties": {
              "turnkeySubOrganizationId": "95b11417-f18f-457f-8804-68e361f9164f",
              "turnkeyPrivateKeyId": "95b11417-f18f-457f-8804-68e361f9164f",
              "turnkeyHDWalletId": "95b11417-f18f-457f-8804-68e361f9164f",
              "turnkeyUserId": "95b11417-f18f-457f-8804-68e361f9164f"
            },
            "phoneNumber": "9171113333",
            "phoneCountryCode": "1",
            "isoCountryCode": "US",
            "previous_users": [
              "95b11417-f18f-457f-8804-68e361f9164f"
            ]
          }
        ],
        "lastVerifiedCredentialId": "95b11417-f18f-457f-8804-68e361f9164f",
        "sessionId": "95b11417-f18f-457f-8804-68e361f9164f",
        "alias": "An example name",
        "country": "US",
        "firstName": "An example name",
        "jobTitle": "An example name",
        "lastName": "An example name",
        "tShirtSize": "An example name",
        "team": "An example name",
        "username": "An example name",
        "scope": "superuser marketing operations",
        "missingFields": [
          {
            "validationRules": {
              "regex": "^0x",
              "validOptions": [
                {
                  "label": "small"
                },
                {
                  "label": "medium"
                },
                {
                  "label": "large"
                }
              ],
              "checkboxText": "Agree to the terms and conditions"
            }
          }
        ],
        "sessions": [
          {
            "id": "95b11417-f18f-457f-8804-68e361f9164f"
          }
        ],
        "wallets": [
          {
            "id": "95b11417-f18f-457f-8804-68e361f9164f",
            "name": "An example name",
            "publicKey": "0xbF394748301603f18d953C90F0b087CBEC0E1834",
            "properties": {
              "turnkeySubOrganizationId": "95b11417-f18f-457f-8804-68e361f9164f",
              "turnkeyPrivateKeyId": "95b11417-f18f-457f-8804-68e361f9164f",
              "turnkeyHDWalletId": "95b11417-f18f-457f-8804-68e361f9164f",
              "turnkeyUserId": "95b11417-f18f-457f-8804-68e361f9164f"
            }
          }
        ],
        "chainalysisChecks": [
          {
            "id": "95b11417-f18f-457f-8804-68e361f9164f",
            "walletPublicKey": "0xbF394748301603f18d953C90F0b087CBEC0E1834"
          }
        ],
        "oauthAccounts": [
          {
            "id": "95b11417-f18f-457f-8804-68e361f9164f"
          }
        ],
        "mfaDevices": [
          {
            "id": "95b11417-f18f-457f-8804-68e361f9164f"
          }
        ]
      },
      "error": "Resources already exists for this Object"
    }
  ]
}