Skip to content

Commit e9c2709

Browse files
committed
Align auth registration with server client_type
1 parent b6b174b commit e9c2709

2 files changed

Lines changed: 2 additions & 0 deletions

File tree

insforge/auth/client.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,7 @@ async def create_user(
126126
response = await self._client._request_json(
127127
"POST",
128128
"/api/auth/users",
129+
params={"client_type": "server"},
129130
json=payload,
130131
exception_cls=InsforgeAuthError,
131132
)

tests/auth/test_auth_client.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -257,6 +257,7 @@ async def fake_request(method: str, url: httpx.URL, **kwargs: object) -> httpx.R
257257

258258
assert calls[3]["method"] == "POST"
259259
assert calls[3]["url"] == "https://example.com/api/auth/users"
260+
assert calls[3]["kwargs"]["params"] == {"client_type": "server"}
260261
assert calls[3]["kwargs"]["json"] == {
261262
"email": "b@example.com",
262263
"password": "secret123",

0 commit comments

Comments
 (0)