Integrate Rayor Connect

Add “Continue with Rayor” to your site in minutes. WordPress plugin, PHP SDK and docs — it’s all in the kit.

Integration kit
rayor-connect-integration.zip
WordPress plugin (Author: Rayor) · PHP SDK · HTML button · documentation
Download the ZIP
AI-assisted integration
Integrating with an AI?

Give this link to your assistant (Claude, Copilot, Cursor…): it contains everything — endpoints, scopes, examples — to generate the right code.

Integrate “Sign in with Rayor” by following https://connect.rayor.fr/llms.txt

How it works

1

Redirect

Send the user to authorize.php with your domain and a return URL.

2

Get the code

Rayor sends the user back to your redirect_uri with a single-use code.

3

Exchange

Server-side, call api.php?code=… and get the JSON profile. That’s it.

Integration example

// 1) Start: redirect to Rayor
header("Location: https://connect.rayor.fr/authorize.php?" . http_build_query([
    "client_id"     => "mon-site.fr",
    "redirect_uri"  => "https://mon-site.fr/callback.php",
    "scope"         => "openid profile email",
    "response_type" => "code",
    "state"         => $_SESSION["rc_state"] = bin2hex(random_bytes(16)),
]));

// 2) callback.php: check the state, then exchange the code (single use)
if (($_GET["state"] ?? "") !== ($_SESSION["rc_state"] ?? "x")) exit("invalid state");
$user = json_decode(file_get_contents(
    "https://connect.rayor.fr/api.php?code=" . urlencode($_GET["code"])
), true);
// $user["rayor_id"], $user["email"], $user["given_name"] ...

“Continue with Rayor” button

<a href="https://connect.rayor.fr/authorize.php?client_id=mon-site.fr&redirect_uri=https://mon-site.fr/callback&scope=openid%20profile%20email&response_type=code"
   style="display:inline-flex;align-items:center;gap:8px;padding:11px 18px;border-radius:12px;background:#0a6cff;color:#fff;font:600 15px system-ui;text-decoration:none">
  <img src="https://connect.rayor.fr/logo.svg" height="18" alt=""> Continue with Rayor
</a>

Endpoints

GET /authorize.phpConsent screen
GET /api.php?code=Code → JSON profile (single use, 5 min)

Scopes

openidrayor_id
profilegiven_name · family_name · nickname · picture
emailemail · email_verified
phonephone_number · phone_number_verified
addressaddress
agebirthdate · age · age_verified
subscriptionrayor_plus · rayor_plan
preferencesliquid_glass

Only fields from scopes that are both requested and allowed are returned. openid is the minimum.

Examples

Same user, three requests. You only get what you ask for.

scope openid — the bare minimum
{
  "rayor_id": "RAY-42-XY"
}
scope openid profile email — standard sign-in
{
  "given_name": "Camille",
  "family_name": "Martin",
  "nickname": "Camille",
  "rayor_id": "RAY-42-XY",
  "picture": "https://connect.rayor.fr/avatar.php?u=…",
  "email": "camille@exemple.fr",
  "email_verified": true
}
scope openid email subscription preferences — an app that handles Plus & the theme
{
  "rayor_id": "RAY-42-XY",
  "email": "camille@exemple.fr",
  "email_verified": true,
  "rayor_plus": true,
  "rayor_plan": "plus",
  "liquid_glass": true
}

In the kit

WordPress plugin — automatic button + [rayor_connect] shortcode, account creation.
PHP SDK — dependency-free Rayor\RayorConnect class + full example.
HTML button — official “Continue with Rayor” markup, ready to copy and paste.
Documentation — full protocol, scopes, security best practices.

Your brand on the sign-in screen

Your visitors see your logo, name and color while signing in, and get the code in your name. On request, after verification. Become a partner →

Try it now

Start a real sign-in on the demo store.

See the demo