[PR #6665] [MERGED] return no content with status code 204 #3827

Closed
opened 2026-03-03 10:21:43 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/dani-garcia/vaultwarden/pull/6665
Author: @stefan0xC
Created: 1/5/2026
Status: Merged
Merged: 1/5/2026
Merged by: @BlackDex

Base: mainHead: return-no-content


📝 Commits (1)

  • ae0da92 return no content with status code 204

📊 Changes

1 file changed (+1 additions, -0 deletions)

View changed files

📝 src/api/identity.rs (+1 -0)

📄 Description

As discussed in https://github.com/dani-garcia/vaultwarden/issues/6592#issuecomment-3709484614 the Bitwarden android app expects the status code to be 204 No Content for this endpoint if the response is empty. (Cf. AccountsController.cs#L124). With the default 200 it tries to convert it to JSON which fails. kotlinx.serialization.json.internal.JsonDecodingException: Cannot read Json element because of unexpected end of the input at path: $

(To test you need to configure both mail and set SIGNUPS_VERIFY=true otherwise you can just choose a password.)


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/dani-garcia/vaultwarden/pull/6665 **Author:** [@stefan0xC](https://github.com/stefan0xC) **Created:** 1/5/2026 **Status:** ✅ Merged **Merged:** 1/5/2026 **Merged by:** [@BlackDex](https://github.com/BlackDex) **Base:** `main` ← **Head:** `return-no-content` --- ### 📝 Commits (1) - [`ae0da92`](https://github.com/dani-garcia/vaultwarden/commit/ae0da92e396a05db8340b787108cdef099649f3e) return no content with status code 204 ### 📊 Changes **1 file changed** (+1 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `src/api/identity.rs` (+1 -0) </details> ### 📄 Description As discussed in https://github.com/dani-garcia/vaultwarden/issues/6592#issuecomment-3709484614 the Bitwarden android app expects the status code to be `204 No Content` for this endpoint if the response is empty. (Cf. [AccountsController.cs#L124](https://github.com/bitwarden/server/blob/68702611916668660521c9657ad5b317fd9ebca4/src/Identity/Controllers/AccountsController.cs#L124)). With the default `200` it tries to convert it to JSON which fails. ```kotlinx.serialization.json.internal.JsonDecodingException: Cannot read Json element because of unexpected end of the input at path: $``` (To test you need to configure both mail and set `SIGNUPS_VERIFY=true` otherwise you can just choose a password.) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-03 10:21:43 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/vaultwarden#3827
No description provided.