Skip to content
Sourcebox API Reference
Manage Document delete
latest

Manage Document delete🔗

The delete action deletes documents by ID. This is available to persisting accounts, and non-persisting accounts when coupled with the Search! product.

Manage Document delete parameters

Parameter Description Content type
account The Sourcebox account name text
username The username of the user text
password The password associated to the user text
trxmlid The trxml id of the document to be deleted number
externalid The external id of the document to be deleted, as an alternative to trxmlid. text

Note: trxmlid is a unique ID automatically assigned by Sourcebox to a document when sent for parsing or indexing to Search. To link a document to an ID from an external system, such as an ATS, use externalid.

The input document selector is either:

  • trxmlid or
  • externalid

The service accepts only one of these arguments. When externalid is supplied and there are multiple documents with this externalid then all of those documents are deleted.

If the account is not persisting and the account or the user use the Search! product, this action will delete the document with the given ID from the Search! environment configured for this account.

Example using curl🔗

POST request with application/x-www-form-urlencoded parameters

curl "https://home.textkernel.nl/sourcebox/manageDocument"
            --data account=test --data username=test --data password=xyz --data externalid=a8
            --data action=delete --data format=template

Error codes🔗

The error codes for the delete method are a subset of the errors for the get method:

  • INVALID_ACTION
  • INVALID_CREDENTIALS
  • DOCUMENT_NOT_FOUND
  • DOCUMENT_ACCESS_DENIED
  • SEARCH_ERROR (Only if the account is not persisting and uses the Search! product)
  • OTHER

Please refer to Manage Document get Error Codes for a description of each code.