Spindl
  • 👋Overview
    • Introduction
    • Attribution
    • Privacy
  • Your Spindl app setup
    • Managing team members
  • 🪄Features
    • 📈Onchain Attribution
      • 📉Plotting attribution
    • 📊Web3-native Analytics
      • Chart Builder
      • Event Selection and Filtering
      • Line Chart
      • Funnel
      • Cohort Retention
      • Sankey Diagram
      • Big Numbers
      • Pies and Donuts
    • 🧍‍♂️Audiences
      • Creating an audience
    • 🔗Short Links
      • 🖇️Custom Domains
    • 🤝Referrals
      • Management and reporting
      • ⏩Quick Start
      • ⛓️Technical Details
  • ⚙️Techncial
    • ⏩Start Here
    • Google GTM Guide
    • Javascript SDK / HTML Script Guide
      • ➡️Install
      • ➡️Wallet Connects
      • ➡️Page Views
      • ➡️Custom Events
      • ✅Verify That Events Are Sent Correctly
      • React, Next.js & Html Examples
      • Setup a Reverse Proxy
        • Using Next.js
        • Using Cloudflare Workers
        • Netlify
      • ➡️Referrals
      • Default vs Lite SDK Versions
      • Security
    • API
      • ➡️Short Links
      • ➡️Custom Events API
      • Data Exports
    • Android SDK
    • iOS (Swift) SDK
    • On-Chain
      • ➡️Rewards
  • Contact Spindl
  • Ads
    • ⏩Start Here
    • 📢Creative Specifications
      • Web Banner Ads
      • Discord Embeds
Powered by GitBook
On this page
  • Get all links for your organization
  • Create a link
  1. Techncial
  2. API

Short Links

Redirect links are one of the core primitives on Spindl. They map a Spindl link (https://spindl.link/abcd) to a specified URL (typically a dApp website).

Get all links for your organization

GET https://api.spindl.xyz/v1/links

Links will sorted by the time they were created, descending.

Headers

Name
Type
Description

X-API-Key*

String

The API token

{
  "links": [
    {
      "id": "dfec5988-5108-465c-be87-ce42039f572e",
      "name": "Spindl Campaign - 2022 - Discord",
      "link": "https://spindl.link/bcdef",
      "redirectUrl": "https://demo.spindl.xyz/",
      "createdAt": "2022-11-09T22:56:24.303Z",
      "totalVisits": 0,
      "latestVisit": null
    },
    {
      "id": "7c087843-a7a1-4b2c-9f28-2ccbe40f23e5",
      "name": "Spindl Campaign - 2022 - Twitter",
      "link": "https://spindl.link/abcd",
      "redirectUrl": "https://demo.spindl.xyz/",
      "createdAt": "2022-11-04T00:29:49.810Z",
      "totalVisits": 100,
      "latestVisit": "2022-11-06T17:32:12.632Z"
    }
  ]
}

Create a link

POST https://api.spindl.xyz/v1/links

Create a new short link with Spindl tracking.

Headers

Name
Type
Description

X-API-Key

String

The API token

Request Body

Name
Type
Description

name*

String

The internal name of the link. While names aren't unique, we recommend using descriptive names like "Winter Campaign - Twitter Post 1"

url*

String

The URL to redirect to (typically where your app lives).

{
  "link": {
    "id": "dfec5988-5108-465c-be87-ce42039f572e",
    "name": "Test New 2",
    "link": "https://spindl.link/abcde",
    "redirectUrl": "https://demo.spindl.xyz/",
    "createdAt": "2022-11-09T22:56:24.303Z",
    "totalVisits": 0,
    "latestVisit": null
  }
}

PreviousAPINextCustom Events API

Last updated 9 months ago

⚙️
➡️