urlsbid
← Back to Home

Documentation

Authentication

urls.bid uses X (Twitter) OAuth for user authentication and API keys for programmatic access. To authenticate API requests, include your API key in the Authorization header.

Headers
Authorization: Bearer ub_live_xxxxxxxxxxxxxxxxx

Links API

POST/link/createLink

Create a new short link. Optionally make it a gated (paid) link by providing a price.

Request
Example Request
{
  "destinationUrl": "https://example.com/my-long-url",
  "customSlug": "my-custom-slug", // optional
  "isGated": true,
  "priceUsd": 1.50,
  "payToAddress": "0xYourBaseWallet",
  "payToSol": "3JypB...r5TGS",
  "acceptedChains": ["base", "solana"]
}
Response
Example Response
{
  "slug": "my-custom-slug",
  "shortUrl": "https://urls.bid/my-custom-slug"
}
POST/link/getMyLinks

Retrieve a list of all your created links.

Response
Example Response
[
  {
    "id": "link_123",
    "slug": "my-custom-slug",
    "destUrl": "https://example.com/my-long-url",
    "clicks": 42,
    "revenue": 15.50
  }
]
GET/api/links/:slug

Get metadata details for a specific link by its slug (public GET endpoint).

POST/link/updateLink

Update a link's destination URL or price.

POST/link/deleteLink

Delete a link permanently.

POST/link/getLinkAnalytics

Get click analytics and revenue data for a link.

POST/link/createPromoLink

Create a promotional link with special tracking.

Bio API

POST/bio/createBioProfile

Create your bio profile.

POST/bio/getMyBioProfile

Get your own bio profile details.

POST/bio/getPublicBio

Get a public bio profile.

POST/bio/addBioLink

Add a new link to your bio profile.

POST/bio/updateBioLink

Update a bio link.

POST/bio/deleteBioLink

Remove a link from your bio.

POST/bio/reorderBioLinks

Reorder the links on your bio profile.

x402 Endpoints

These endpoints support the x402 micropayment protocol for agentic monetization.

GET/s/:slug

Resolve a short link. Returns 402 Payment Required if the link is gated.

GET/files/:fileId

Access a gated file.

GET/data/:dataset

Query a gated dataset.

POST/api/agent/*

Agent-specific API routes with built-in x402 support.

Well-known Endpoints

Standardized endpoints for agent discovery and protocol support.

PathDescription
/.well-known/agent.jsonAgent capability discovery manifest
/.well-known/x402.jsonx402 payment protocol configuration
/llms.txtContext file for LLMs and AI agents

Error Codes

CodeStatusDescription
400Bad RequestInvalid parameters provided
401UnauthorizedMissing or invalid API key
402Payment Requiredx402 payment required to access resource
404Not FoundResource does not exist
429Too Many RequestsRate limit exceeded

Rate Limits

API requests are limited to 100 requests per minute per IP address, and 1000 requests per hour per API key. If you exceed these limits, you will receive a 429 Too Many Requests response.