Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/Gianluca-X/DigitalMoney/llms.txt

Use this file to discover all available pages before exploring further.

Permanently unlinks and deletes a card from the specified account. The service confirms both that the card exists and that it is actually associated with the given account before deletion. If either condition fails, a 404 is returned. On success, a JSON confirmation message is returned with 200 OK.

Endpoint

DELETE /accounts/{accountId}/cards/{cardId}
Base URL: http://localhost:8085

Authentication

A valid Bearer JWT is required in the Authorization header. Requests without a valid token are rejected at the API Gateway before reaching this endpoint.

Path Parameters

accountId
long
required
The numeric identifier of the account that owns the card.
cardId
long
required
The numeric identifier of the card to remove.

Response

Returns 200 OK with a JSON confirmation object on successful deletion.

Response Fields

message
string
A human-readable confirmation string. Value is always "Tarjeta eliminada exitosamente".

Example Request

curl -X DELETE "http://localhost:8085/accounts/42/cards/7" \
  -H "Authorization: Bearer eyJhbGciOiJSUzI1NiJ9..."

Example Response

{
  "message": "Tarjeta eliminada exitosamente"
}

Error Responses

StatusExceptionCondition
401 UnauthorizedMissing or expired Bearer token (rejected at the gateway).
404 Not FoundCardNotFoundExceptionNo card with cardId exists, or the card is not associated with accountId.
Deletion is permanent. Once removed, the card record cannot be recovered. Any pending deposit operations that referenced this card will fail if retried.
To confirm a card was successfully deleted, you can follow up with a GET /accounts/{accountId}/cards/{cardId} call — it should return 404 after a successful delete.

Build docs developers (and LLMs) love