Skip to main content
DELETE
Delete affiliate

📌 Endpoint

DELETE /stores/{storeId}/affiliates/{affiliateId} Removes an affiliate from the store (soft delete). The affiliate disappears from listings, but the record remains in the database for safety — including commission resolution no longer considers it.
Requirement: The affiliate must be paused (status: "inativo") for at least 7 days before it can be deleted. Otherwise, the API returns 400 (AFFILIATE_NOT_PAUSED or AFFILIATE_PAUSE_PERIOD_NOT_ELAPSED).

🔐 Authentication

  • Private route.
  • Requires the Authorization header with your API key and an active plan.

🧾 Route parameters


✅ Request example


📦 Success response (200)


⚠️ Possible errors

  • 400 INVALID_DATA → invalid parameters
  • 400 AFFILIATE_NOT_PAUSED → the affiliate must be paused (status: "inativo") before deletion
  • 400 AFFILIATE_PAUSE_PERIOD_NOT_ELAPSED → the affiliate must remain paused for at least 7 days
  • 401 API_KEY_NOT_PROVIDED → Authorization header not provided
  • 401 INVALID_API_KEY → invalid API key
  • 401 UNAUTHENTICATED → unauthenticated user
  • 403 USER_DISABLED → user disabled
  • 403 NO_ACTIVE_SUBSCRIPTION → no active plan
  • 404 STORE_NOT_FOUND → store not found
  • 404 AFFILIATE_NOT_FOUND → affiliate not found
  • 429 RATE_LIMIT_EXCEEDED → per-minute rate limit exceeded
  • 500 INTERNAL_SERVER_ERROR → internal server error
  • 503 SERVICE_UNAVAILABLE → service unavailable

Authorizations

Authorization
string
header
default:YOUR_API_KEY_HERE
required

Path Parameters

storeId
string
required
Required string length: 1 - 50
affiliateId
string
required
Required string length: 1 - 50

Response

Delete affiliate.

code
string
required
Example:

"AFFILIATE_DELETED"