Delete a record
Remove a stored record by your client identifier.
deleteARecord removes a record using the identifier your application assigned, not Insion's record ID. Use it when the source object is deleted or must no longer be retained for moderation.
let result = try await client.deleteARecord(
request: .init(clientId: "post-123")
)
print(result.message)Signature
func deleteARecord(
request: Requests.DeleteApiV1IngestRequest,
requestOptions: RequestOptions? = nil
) async throws -> SuccessResponseThe request struct has one required field: clientId: String. It must be the same application-owned identifier used when ingesting or moderating the record. An Insion record id obtained from list, retrieve, or moderation responses is not the input expected by this operation.
Result and failure behavior
On success, the SDK returns SuccessResponse, whose message confirms the API result. A missing, unauthorized, or otherwise invalid deletion throws ApiError; handle .httpError to distinguish not-found and access errors. The operation does not return the deleted record, so copy anything needed for audit or UI use before deleting it.
Deletion changes server state. Avoid automatic retries unless your application can safely tolerate an ambiguous outcome after a timeout or transport failure. See Errors and responses for inspecting the thrown error.