addToWallet.co
Workspaces
Pricing
API Docs
Tutorial Blog
Tools
Google Sheet Extension
PDF to Pass
Image to Pass
QR Code Generator
Barcode Generator
Integrations
© 2026 Hazelnut Ventures LLC. All Rights Reserved.
FAQsTrustContact Us
Overview
AuthenticationPass JSON GeneratorCreate PassGet PassUpdate PassDelete PassNotificationsGet Credits
Create TemplateList TemplatesGet TemplateUpdate TemplateDelete TemplateDynamic Pass Gen
Create Loyalty TemplateManage LoyaltyActivity Log
List User GroupsAdd UserList UsersUpdate UserDelete UserBatch Status

Delete Pass API

Overview

The Delete Pass API enables you to archive digital passes by setting their state to EXPIRED. This endpoint moves the pass to the archived section of users' wallets based on its unique identifier.

Base URL

https://app.addtowallet.co
DELETE/api/card/delete/{cardId}

Authentication

All API requests must include your API key in the request headers:

"apikey": "your-api-key-here"

Request Parameters

Include the pass ID in the URL path. No request body is required for this endpoint.

Request Parameters

NameTypeRequiredDescription
cardIdstringYes
Path parameter: unique identifier of the pass to be archived
curl -X DELETE 'https://api.addtowallet.co/api/card/delete/66b6005bb7bddce8f05a3392' -H 'apikey: YOUR_API_KEY'

Response

Upon successful archival, the API returns a JSON object containing:

{
  "msg": "Card successfully marked as deleted",
  "deleteStatus": {
    "acknowledged": true,
    "modifiedCount": 1,
    "upsertedId": null,
    "upsertedCount": 0,
    "matchedCount": 1
  }
}

Error Codes

The API may return the following error status codes:

Status CodeErrorDescription
400Bad RequestInvalid pass ID format
401UnauthorizedMissing or invalid API key
403ForbiddenInsufficient permissions to archive the pass
404Not FoundThe requested pass does not exist
500Internal Server ErrorUnexpected server error. Please contact support

Example error response:

{
  "success": false,
  "error": "Pass not found",
  "errorCode": "PASS_NOT_FOUND"
}

Important Notes

  • Archive action: Pass will be moved to archived section with EXPIRED state
  • User access: Users can still view the pass in their archived section
  • Pass state: The pass stateType will be set to EXPIRED
  • Data retention: All pass data and analytics will be preserved
  • Verification: Always double-check the cardId before archiving