RedScrapeRedScrapeDocs

API Overview

Base URL, authentication, error handling, and common patterns for the RedScrape API.

Base URL

All API endpoints are relative to:

https://api.redscrape.com/api/public

Authentication

Most endpoints require an API key passed via the X-API-Key header:

curl -H "X-API-Key: your_api_key" \
  https://api.redscrape.com/api/public/account/me

Public Endpoints (no auth required)

EndpointDescription
GET /products/List all products
GET /products/calculate-gb-priceCalculate custom data pricing
GET /products/gb-tier-limitsGet min/max GB for a product
POST /payments/calculate-pricePreview purchase cost
GET /payments/verify-coupon/{code}Validate a coupon

Error Handling

Errors return a JSON object with a detail field:

{
  "detail": "Insufficient wallet balance"
}

HTTP Status Codes

CodeDescription
200Success
201Created
400Bad request invalid parameters
401Unauthorized missing or invalid API key
403Forbidden access denied
404Not found
422Validation error check request body
429Rate limited too many requests
500Internal server error

Request Format

  • Use Content-Type: application/json for POST/PUT/PATCH requests
  • Query parameters for GET requests
  • Path parameters where indicated (e.g. /subscriptions/{sub_id})

Pagination

Paginated endpoints accept page and per_page query parameters and return a meta object:

{
  "items": [...],
  "meta": {
    "total": 47,
    "pages": 3,
    "page": 1,
    "per_page": 20
  }
}

On this page