Skip to main content
DELETE
/
api
/
unipile
/
accounts
Disconnect a Unipile LinkedIn account
curl --request DELETE \
  --url https://app.puffle.ai/api/unipile/accounts \
  --header 'Authorization: Bearer <token>'
{
  "success": true
}

Overview

This path serves two verbs: GET /api/unipile/accountslistUnipileAccounts. Returns every LinkedIn account owned by the caller with status in ('connected', 'credentials_required'). Rows missing display name or premium flags are lazily enriched from Unipile on the call and the enrichment is persisted. If Unipile returns 404 for a row, we flip it to disconnected before returning. DELETE /api/unipile/accounts?accountId=<uuid>deleteUnipileAccount. Soft-disconnects one account: calls Unipile’s DELETE endpoint best-effort (failures there do not block our own cleanup), then sets status to disconnected. The row is preserved so historical campaign data stays intact; the account just stops being usable for new sends.

AI agent notes

Soft delete only. The row stays in accounts — historical prospects, conversations, and sent-message records keep working. To re-enable, use reconnectUnipileAccount with the same accountId.accountId is a query parameter for DELETE, not a path segment and not a JSON body. DELETE /api/unipile/accounts?accountId=aaaa...-1111-....Best-effort Unipile cleanup. If Unipile’s DELETE fails we still mark our row disconnected and return 200. An orphaned Unipile-side account is harmless — it stops counting against anything on our side once our status flips.Active campaigns. Disconnecting an account used by an active campaign does not cancel in-flight prospects. The engine will start failing future sends on that account — pause or delete the campaign first if you want a clean stop.Listing is non-destructive but does write. The GET path can persist enrichment updates and auto-flip a row to disconnected on a confirmed Unipile 404. Safe to call frequently, but not a pure read.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Query Parameters

accountId
string<uuid>
required

Supabase UUID of the account row to disconnect. Passed as a query string parameter (not path or body).

Pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$

Response

Account marked disconnected. Unipile-side deletion was attempted best-effort.

success
enum<boolean>
required
Available options:
true