Back to Home
GLOOOP
API Docs

Getting Started

Get up and running with the Glooop API in minutes. Create your first API key and make your first request.

1

Create an API Key

First, you need to create an API key from your Glooop dashboard:

  1. Log in to your Glooop account at http://localhost:3000
  2. Navigate to the "API Keys" page from the sidebar
  3. Click "Create API Key"
  4. Enter a name (e.g., "My Mobile App")
  5. Select a tier (FREE, DEVELOPER, BUSINESS, or ENTERPRISE)
  6. ⚠️ Copy the key immediately! It will only be shown once.

Security Note: Your API key is like a password. Never share it publicly or commit it to version control.

2

Make Your First Request

Now that you have an API key, let's make your first request to fetch all deals:

Using cURL

curl -X GET "https://api.glooop.fun/api/v1/public/v1/deals" \
  -H "X-API-Key: glp_sk_YOUR_API_KEY_HERE"

Using JavaScript (fetch)

const response = await fetch('https://api.glooop.fun/api/v1/public/v1/deals', {
  headers: {
    'X-API-Key': 'glp_sk_YOUR_API_KEY_HERE'
  }
});

const data = await response.json();
console.log(data.data.deals);

Using Python (requests)

import requests

headers = {
    'X-API-Key': 'glp_sk_YOUR_API_KEY_HERE'
}

response = requests.get(
    'https://api.glooop.fun/api/v1/public/v1/deals',
    headers=headers
)

data = response.json()
print(data['data']['deals'])
3

Understand the Response

All API responses follow a consistent format:

{
  "success": true,
  "message": "Deals retrieved successfully",
  "data": {
    "deals": [
      {
        "id": "deal_123",
        "title": "50% Off Pizza",
        "description": "Get half off any large pizza",
        "discountPercentage": 50,
        "price": 0.05,
        "totalSupply": 100,
        "availableSupply": 75,
        "merchant": {
          "id": "merchant_456",
          "businessName": "Pizza Palace",
          "walletAddress": "BrGJZh6Aa..."
        },
        "expiryDate": "2025-12-31T23:59:59Z",
        "createdAt": "2025-01-15T10:00:00Z"
      }
      // ... more deals
    ],
    "total": 15,
    "page": 1,
    "limit": 10
  },
  "statusCode": 200
}
4

Handle Rate Limits

Every response includes rate limit headers:

X-RateLimit-Limit: 100
X-RateLimit-Remaining: 95
X-RateLimit-Reset: 1640000000

If you exceed your rate limit, you'll receive a 429 status code:

{
  "success": false,
  "message": "Rate limit exceeded. Limit: 100 requests per minute.",
  "statusCode": 429
}

Next Steps