Links
Check Code Availability
Check if a custom code is available for use before creating a link
GET
Request
Your project API key:
b2co_your_api_keyThe custom code to check for availability (3-50 characters, alphanumeric, hyphens, and underscores only)
Response
Indicates if the request was successful
Code availability information
The code that was checked
Whether the code is available for use (true = available, false = already in use)
Human-readable message about the code availability
Code Requirements
Code Format Rules:
- Length: 3-50 characters
- Allowed characters: letters (a-z, A-Z), numbers (0-9), hyphens (-), underscores (_)
- Case sensitive:
MyCodeandmycodeare different - Must be unique within your project
Error Codes
Invalid code format or length
API key is missing or invalid
Too many requests, please try again later
Usage Tips
Use this endpoint in your workflow:- Check if your desired code is available
- If available, proceed with link creation
- If not available, try a different code or let the system generate one automatically