https://analytics.flowsery.com/analytics/api/v1/paymentsDelete payment records by transaction ID, visitor, or within a date range.
Workspace tokens need a website selector
Workspace API tokens can access every website in the workspace. Pass either <code>websiteId</code> or <code>domain</code> so Flowsery knows which website to query or mutate. Website API keys are already scoped to one website, so the selector can be omitted.Website selector
| Parameter | Type | Description |
|---|---|---|
websiteId | string | Website ID to use with a workspace API token. Omit when authenticating with a website API key. |
domain | string | Website domain to use with a workspace API token when websiteId is not provided. Omit when authenticating with a website API key. |
At least one filter required
At least one query parameter must be provided. Calling this endpoint with no filters returns a 400 error.Query parameters
| Parameter | Type | Description |
|---|---|---|
transactionId | string | Remove the payment matching a specific transaction ID. |
visitorId | string | Remove all payments tied to a specific visitor ID. |
startAt | string | ISO 8601 start timestamp (e.g., 2024-01-01T00:00:00Z). |
endAt | string | ISO 8601 end timestamp (e.g., 2024-01-31T23:59:59Z). |
Deletion behavior
<strong>Transaction ID only:</strong> Removes the specific payment record.
<strong>Visitor ID only:</strong> Removes all payments for that visitor (all time).
<strong>Time range only:</strong> Removes every payment within that period.
<strong>Visitor ID + time range:</strong> Removes payments for the visitor within the window.
<strong>Transaction ID + time range:</strong> Removes the specific transaction if it falls within the range.
Error responses
<strong>400 Bad Request</strong> -- No filter parameters were provided.
<strong>401 Unauthorized</strong> -- API token is missing, invalid, expired, or not accepted for this endpoint.
curl -X DELETE "https://analytics.flowsery.com/analytics/api/v1/payments?websiteId=flid_abc123&transactionId=payment_456" \
-H "Authorization: Bearer <workspace-or-website-token>"curl -X DELETE "https://analytics.flowsery.com/analytics/api/v1/payments?visitorId=a3ab2331-989f-4cfa-91c6-2461c9e3c6bd&startAt=2024-01-01T00:00:00Z&endAt=2024-03-31T23:59:59Z" \
-H "Authorization: Bearer <workspace-or-website-token>"{
"status": "success",
"data": [
{
"deleted": 3,
"message": "Payment records deleted successfully"
}
]
}