Skip to content

Sign in with Localoge

“Sign in with Localoge” is a button you add to your login screen. Your user clicks it, signs in with us, agrees to share their identity with you, and comes back to your product signed in. There is no extra password to create.

It is the same flow as Connecting a host, with the same /connect link and the same code exchange. Only the scope changes.

{
"success": true,
"data": {
"host_ref": null,
"host_name": "Marie Dupont",
"identity": {
"sub": "lu_9c1e4b7a0d5f2e8a3b6c1d4e7f0a2b5c",
"name": "Marie Dupont",
"email": "marie@example.com",
"email_verified": true,
"phone": null,
"locale": "fr",
"listings_count": null
}
}
}
Field
sub A stable identifier for this user for you. It never changes and differs from one partner to another: this is the key to store, not the email.
name Their name.
email Their email, lowercased.
email_verified true if Localoge has verified that the user owns it. Only create an account automatically on that condition.
phone Always null: Localoge does not verify phone numbers, so we give you nothing we cannot vouch for.
locale Their language (fr, en…).
listings_count Number of their listings, only if the listings scope was granted. Otherwise null.

Nothing else is ever shared: no date of birth, no address, no ID document.

https://localoge.com/connect
?partner=your-identifier
&redirect_uri=https://your-tool.com/callback/localoge
&state=a-random-value-of-yours
&scope=identity
&code_challenge=BASE64URL(SHA256(code_verifier))
&code_challenge_method=S256
Parameter
scope identity for sign-in only. identity listings to also connect their properties: the user ticks or not “also link my listings” on the same screen.
state Required, at least 8 characters. A random value tied to your user’s session, which we return unchanged. Check it on return.
code_challenge, code_challenge_method PKCE S256, required. plain is rejected.
redirect_uri Must match what you registered with us. In production: https only.

Open this address in the user’s browser, not from your server.

https://your-tool.com/callback/localoge?code=9f2c1a44…&state=a-random-value-of-yours

If they decline: ?error=access_denied&state=…. Compare state with your session’s first.

Fenêtre de terminal
curl -X POST https://localoge.com/api/v1/channel/oauth/token \
-H "Authorization: Bearer $LOCALOGE_KEY" \
-H "Content-Type: application/json" \
-d '{ "code": "9f2c1a44…", "code_verifier": "the-secret-you-kept" }'

The response is the one at the top of this page. Find or create the user’s account on your side from sub, then open their session.

  • Identify by sub, never by email. Users can change their address.
  • Do not merge two accounts on an unverified email (email_verified: false).
  • Keep your own session. Localoge returns no access token and no refresh token: it vouches for the identity at the moment of sign-in, then it is up to you.
  • Test in the sandbox: https://sandbox.localoge.com/connect and https://sandbox.localoge.com/api/v1/channel/oauth/token, with your lok_test_ key. See Sandbox.
error Cause
invalid_scope Anything other than identity and/or listings.
pkce_required code_challenge missing.
invalid_pkce code_challenge_method is not S256, or the challenge is malformed.

On the exchange, every error answers FORBIDDEN with the reason: code inconnu, code expiré, code déjà utilisé, code_verifier invalide, autorisation retirée.