Ask, reply and learn. Join the community of Akaunting.
Hello there,
I know I've been spamming the forum lately, but this issue really bothers me and was present in version 1.3 already and is still present in version 2.0.2.
I can't delete customers (or now contacts of type "customer") using the REST API.
The api route under /routes/api.php describes the following:
$api->resource('contacts', 'Common\Contacts');
So requesting /api/contacts using GET returns all registered contacts.
When I now call DELETE @ /api/contacts/{contact_id}?company_id={company_id}
I'm facing a 404 response:
{
"message": "No query results for model [App\\Models\\Common\\Contact] 2",
"status_code": 404,
"debug": { … }
}
So please, @Admin, @Developers, what am I doing wrong??
Regards,
L. Behr
Hello Lennart,
Are you able to GET that contact?
Regards
I am indeed able to GET that contact, it returns:
{
"data": {
"id": 2,
"company_id": 1,
"user_id": 33,
"type": "customer", ...
}
}
DELETE however does not work.
GET request was:
GET @ /api/contacts/2?company_id=1
im still not able to delete from the three dot menu (...) but if i use the bulk delete option it works.
still cant delete anything just hangs up https://imgur.com/undefined
still having the same problem anything i try to delete will not delete
i still cant delete a single item. i must always use the bulk action delete. even if its one item/user/invoice/transaction
Showing 1 to 8 of 8 discussions