evconcierge_client — a relying party's calls into concierge
What a direction's backend (invest, admin, the Service-Arb panel) calls on concierge, the EV identity plane. Server-side only: the client secret never reaches a browser.
- Sign-in is concierge's code flow with PKCE:
PkceVerifier+random_state+Authorize::urlsend the browser to/api/auth/authorize; the callback redeems the code withConciergeClient::exchange_code;refresh_client_tokenrotates the pair. get_me— the one RPC a relying party's access token opens, and where the party re-readspermissions, the only thing it may gate on.publish_catalog(permissions and aliases) andpublish_scope_catalog(approval kinds and notification topics), under the client credential.- The direction's inbox (
ScopeInboxService):list_scope_notifications(anInboxQuery, 20 per page unless told otherwise),scope_unread_countandscope_notification_settingsby concierge'suser_id;mark_scope_notifications_readandset_scope_topic_subscriptionwith the access token this client holds for the user, sent asx-ev-user-tokenbeside the client credential.
use ;
let concierge = connect_lazy?;
let verifier = generate?;
let state = random_state?;
let location = Authorize .url;
// … the browser comes back with `code` …
let tokens = concierge.exchange_code.await?;
let me = concierge.get_me.await?;
Errors are values (ConciergeError), one arm per reaction: Refused ends the session,
Unavailable is worth a retry (is_transient), Rejected carries concierge's own
reason. Every call has a timeout (ClientConfig::timeout, 5 s by default).
The wire types are concierge's own evconcierge_contracts of the same release,
re-exported as evconcierge_client::proto. Building needs no protoc on PATH.
Keeping a copy of concierge's users (suspensions, grants, MEMBER_JOINED) is a different
job: the evconcierge_projection crate.