GET
https://api.stableyard.fi
/
sdk
/
v1
/
check-username
curl -X GET "https://api.stableyard.fi/sdk/v1/check-username?username=alice" \
  -H "Authorization: Basic $(echo -n $STABLEYARD_APP_ID:$STABLEYARD_APP_SECRET | base64)"
{
  "success": true,
  "data": {
    "message": "Username is available",
    "userNameExists": false
  },
  "requestId": "req_xyz789"
}
Check if a username is available before registration or when setting a username. Prevents conflicts and provides instant feedback for your UI.

Authentication

Authorization
string
required
Basic authentication. Value: Basic base64(STABLEYARD_APP_ID:STABLEYARD_APP_SECRET). Obtain your credentials from the Stableyard SDK.

Query Parameters

username
string
required
The username to check availability for
userId
string
Exclude this user from the check (for username updates)

Response

success
boolean
Indicates if the request was successful
data
object
Availability check result
curl -X GET "https://api.stableyard.fi/sdk/v1/check-username?username=alice" \
  -H "Authorization: Basic $(echo -n $STABLEYARD_APP_ID:$STABLEYARD_APP_SECRET | base64)"
{
  "success": true,
  "data": {
    "message": "Username is available",
    "userNameExists": false
  },
  "requestId": "req_xyz789"
}

Username Rules

RuleRequirement
Length3-20 characters
CharactersAlphanumeric and underscores only
CaseCase-insensitive (Alice = alice)
UniquenessUnique within partner namespace