Expand description
Unofficial async Rust client for the Grindr API, powering the Open Grind client.
It talks to Grindr the same way the official Android app does: same TLS and HTTP/2 fingerprint, same header order, same device identity. On top of that it handles login, token refresh, requests, and the realtime websocket.
It’s only a transport — it doesn’t ship types for individual endpoints. You pick the path and deserialize the response body yourself.
§Overview
GrindrClient— the main entry point. Cheap to clone, refreshes the token on its own, and runs the realtime websocket in the background once you opt in withGrindrClient::connect.DeviceInfo— a fake but believable device identity.Session— credentials you can save and resume from.RawResponse— the status and body from a request.WsEvent/WsCommand— incoming and outgoing realtime messages.
§Example
use grindr::{DeviceInfo, GrindrClient, Method};
// Make a device identity once, save it, and reuse it next time.
let client = GrindrClient::new(DeviceInfo::generate(), None)?;
client.login("user@example.com", "hunter2").await?;
// Make a request — the session token is added for you.
let resp = client
.request_authenticated_raw(Method::GET, "/v3/me/profile", None)
.await?;
println!("status = {}", resp.status);§Disclaimer
This is an unofficial library, not affiliated with or endorsed by Grindr. It is provided for research and interoperability. Automating access may violate Grindr’s Terms of Service; you are responsible for how you use it.
Structs§
- BanDetails
- A timed ban’s details, from the JWT
banDetailsclaim. - BanInfo
- Details of a ban from the login/refresh response body.
- Bytes
- Request body bytes, re-exported from
bytesfor use withGrindrClient::request_authenticated_bytes. A cheaply cloneable and sliceable chunk of contiguous memory. - Device
Info - A fake Android device identity used to fill in request headers.
- Device
Signing Key - A persistable device signing key.
- Grindr
Client - An async client for the Grindr API.
- Grindr
Headers - References https://opengrind.org/grindr-api/security-headers#correct-headers-order
- Login
Result - The outcome of a successful login or token refresh.
- Media
Upload Response - Response from a signed chat-media upload (
POST /v6/chat/media/upload). - Method
- HTTP method, re-exported from
wreqfor use withGrindrClient::request_authenticated_raw. The Request Method (VERB) - RawResponse
- A raw API response: the HTTP status and the unparsed body bytes.
- Session
- An authenticated session.
- Upload
Profile Image Response - Response from a signed profile-image upload (
POST /v5/media/upload). - Uploaded
Profile Image - One size variant in an
UploadProfileImageResponse. - WsCommand
- A command to send over the websocket.
- WsEvent
- An event received over the websocket.
Enums§
- Auth
Event - Emitted on
GrindrClient::auth_event_receiverwhen a background token refresh changes the auth state. - BanKind
- What a
GrindrError::Bannedapplies to, from the error code in the body. - Grindr
Error - Errors returned by this crate.
- Restriction
- An account restriction carried in the session JWT.
- Session
Kind - How a
Sessionwas obtained. - Verification
Region - Region for a
Restriction::AgeVerification. - WsConnection
State - Whether the websocket is connected.
Constants§
- APP_
VERSION - The Grindr Android app version this crate emulates.
Functions§
- build_
device_ info_ header - Builds the
L-Device-Infoheader value from aDeviceInfo. - build_
user_ agent - Builds the
User-Agentthe app sends, e.g.grindr3/26.11.0.168192;168192;Free;Android 14;Pixel 8;Google. - probe_
emulation - The
EmulationProviderthat gives awreqclient the same TLS and HTTP/2 fingerprint as the Android app.